mirror of
https://github.com/sqlchat/sqlchat.git
synced 2025-09-23 18:43:18 +08:00
chore: add bot template
This commit is contained in:
3
assistants/template/README.md
Normal file
3
assistants/template/README.md
Normal file
@ -0,0 +1,3 @@
|
||||
# Bot template
|
||||
|
||||
You can contribute your own bot with this template.
|
13
assistants/template/index.ts
Normal file
13
assistants/template/index.ts
Normal file
@ -0,0 +1,13 @@
|
||||
// It's a template for creating new bots.
|
||||
export default {
|
||||
id: "the-id-of-your-bot",
|
||||
name: "The name of your bot",
|
||||
description: "The description of your bot",
|
||||
avatar: "The avatar link of your bot",
|
||||
// The function to get the prompt of the bot.
|
||||
getPrompt: (input: string): string => {
|
||||
// You can do some preprocessing here.
|
||||
const formatedInput = input.trim().toLowerCase();
|
||||
return `The prompt of your bot. The question is ${formatedInput}`;
|
||||
},
|
||||
};
|
Reference in New Issue
Block a user