All connectors
Frameworks

NestJS

NestJS module + guard.

BonkLM as a first-class Nest module. Inject the engine, attach the guard to controllers, or scope it globally via APP_GUARD.

Install

pnpm add @blackunicorn/bonklm-nestjs

Minimal example

import { Module } from '@nestjs/common'
import { BonkLMModule } from '@blackunicorn/bonklm-nestjs'

@Module({
  imports: [BonkLMModule.forRoot({ validators: ['prompt-injection'] })],
})
export class AppModule {}
Related connectors