foliko 1.1.90 → 1.1.91
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/core/agent-chat.js +2 -1
package/package.json
CHANGED
package/src/core/agent-chat.js
CHANGED
|
@@ -475,7 +475,7 @@ class AgentChatHandler extends EventEmitter {
|
|
|
475
475
|
if (!this._aiClient) {
|
|
476
476
|
throw new Error('AI client not configured.');
|
|
477
477
|
}
|
|
478
|
-
|
|
478
|
+
this._validateToolCalls(messages);
|
|
479
479
|
const systemPrompt = framework.getSystemPrompt();
|
|
480
480
|
//await fs.promises.writeFile(`.${sessionId}_systemPrompt.md`, systemPrompt); // 调试用:保存系统提示词
|
|
481
481
|
const tools = this._getAITools(aiTool);
|
|
@@ -650,6 +650,7 @@ class AgentChatHandler extends EventEmitter {
|
|
|
650
650
|
if (!this._aiClient) {
|
|
651
651
|
throw new Error('AI client not configured.');
|
|
652
652
|
}
|
|
653
|
+
this._validateToolCalls(messages);
|
|
653
654
|
const systemPrompt = framework.getSystemPrompt();
|
|
654
655
|
const tools = this._getAITools(aiTool);
|
|
655
656
|
|