aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/ChatBox/Agent.ts
diff options
context:
space:
mode:
authorA.J. Shulman <Shulman.aj@gmail.com>2024-08-07 13:08:41 -0400
committerA.J. Shulman <Shulman.aj@gmail.com>2024-08-07 13:08:41 -0400
commitb7c024c8c5b85f91828d6cd20ffc3bfca229af21 (patch)
tree74536498c0301dbbc53b67f2eaac5fd40a7fa3d9 /src/client/views/nodes/ChatBox/Agent.ts
parenta4107cdf6d53654275a678a79eff9962bcd02beb (diff)
trying to get rules to delete after using rool
Diffstat (limited to 'src/client/views/nodes/ChatBox/Agent.ts')
-rw-r--r--src/client/views/nodes/ChatBox/Agent.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/client/views/nodes/ChatBox/Agent.ts b/src/client/views/nodes/ChatBox/Agent.ts
index fddfdfcb1..04729414a 100644
--- a/src/client/views/nodes/ChatBox/Agent.ts
+++ b/src/client/views/nodes/ChatBox/Agent.ts
@@ -22,6 +22,7 @@ export class Agent {
private _summaries: () => string;
constructor(_vectorstore: Vectorstore, summaries: () => string, history: () => string) {
+ console.log(process.env.OPENAI_KEY);
this.client = new OpenAI({ apiKey: process.env.OPENAI_KEY, dangerouslyAllowBrowser: true });
this.vectorstore = _vectorstore;
this._history = history;
@@ -77,7 +78,7 @@ export class Agent {
const nextPrompt = [
{
type: 'text',
- text: `<step${i} role="user">` + builder.build({ action_rules: this.tools[currentAction].getActionRule() }) + `<\step>`,
+ text: `<step${i} role="user">` + builder.build({ action_rules: this.tools[currentAction].getActionRule(true) }) + `<\step>`,
},
];
this.interMessages.push({ role: 'user', content: nextPrompt });