Skip to content

Commit 4f47f08

Browse files
committed
docs: add optional placeholder messages for example prompts in AdminForthAgent
1 parent 3320b80 commit 4f47f08

2 files changed

Lines changed: 13 additions & 0 deletions

File tree

adminforth/documentation/docs/tutorial/08-Plugins/26-agent.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,13 @@ import CompletionAdapterOpenAIChatGPT from '@adminforth/completion-adapter-open-
203203
plugins: [
204204
...
205205
new AdminForthAgent({
206+
// optional, can be used to suggest example prompts in the UI
207+
// placeholderMessages: async ({ adminUser, httpExtra }) => {
208+
// return [
209+
// 'What is a cars count in SQLite',
210+
// 'Build average car price by days chart in SQLite',
211+
// ];
212+
// },
206213
modes: [
207214
{
208215
name: 'Balanced',

dev-demo/resources/adminuser.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,12 @@ export default {
193193
},
194194
}),
195195
new AdminForthAgent({
196+
placeholderMessages: async ({ adminUser, httpExtra }) => {
197+
return [
198+
"What is a cars count in SQLite",
199+
"Build average car price by days chart in SQLite",
200+
]
201+
},
196202
modes: [
197203
{
198204
name: 'Balanced',

0 commit comments

Comments
 (0)