0.0.13 • Published 2 months ago
@sftech/nestjs-prompt v0.0.13
nestjs-prompt
This library provides a RESTApi for creating and managing prompts to be used with LLMs. It depend on the @sftech/nestjs-db library.
For installation run the following command:
npm install @sftech/nestjs-core @sftech/nestjs-db @sftech/nestjs-prompt
Afterwards you can use the library in your nestjs application. Therefore import the NestJsPromptModule in your app.module.ts:
import { NestjsDbModule, DatabaseOptionsMapper } from '@sftech/nestjs-db';
import { NestjsPromptModule } from '@sftech/nestjs-prompt';
import { NestJsCoreModule } from '@sftech/nestjs-core';
...
@Module({
imports: [NestJsCoreModule.register(), NestjsDbModule.register(DatabaseOptionsMapper.map()), NestjsPromptModule.register()],
providers: [],
...
})
export class AppModule {
}
On the next startup of your application the database will be created and the tables for the prompt library will be created. Once application is started you can use the prompting endpoints.