fix: Combine prompt and memory to encourage tool use
This commit is contained in:
parent
f8247944bb
commit
4b6c4b3260
1 changed files with 2 additions and 10 deletions
|
|
@ -35,17 +35,9 @@ async function generateAIResponse(post: Post, memory: string, parsedThread: stri
|
||||||
role: "model" as const,
|
role: "model" as const,
|
||||||
parts: [
|
parts: [
|
||||||
{
|
{
|
||||||
/*
|
text: `${modelPrompt
|
||||||
? Once memory blocks are working, this will pull the prompt from the database, and the prompt will be
|
|
||||||
? automatically initialized with the administrator's handle from the env variables. I only did this so
|
|
||||||
? that if anybody runs the code themselves, they just have to edit the env variables, nothing else.
|
|
||||||
*/
|
|
||||||
text: modelPrompt
|
|
||||||
.replace("{{ administrator }}", env.ADMIN_HANDLE)
|
.replace("{{ administrator }}", env.ADMIN_HANDLE)
|
||||||
.replace("{{ handle }}", env.HANDLE),
|
.replace("{{ handle }}", env.HANDLE)}\n\n${memory}`,
|
||||||
},
|
|
||||||
{
|
|
||||||
text: memory,
|
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue