feat(agent): maxSteps configurable, défaut 8->24 (tâches multi-outils) (v0.37.0)
Construire un workflow n8n (flux SDK) dépasse 8 étapes. maxAgentSteps via CHLOVA_MAX_AGENT_STEPS, passé config -> ChatService -> runAgentTurn. 83 tests verts. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016w5jRe87MGdd6AMvXQcHNi
This commit is contained in:
@@ -20,6 +20,8 @@ export interface ChatServiceDeps {
|
||||
systemPrompt: string;
|
||||
logger: Logger;
|
||||
store?: ConversationStore;
|
||||
/** Plafond d'étapes par tour (multi-outils). Défaut runAgentTurn sinon. */
|
||||
maxSteps?: number;
|
||||
}
|
||||
|
||||
export interface ChatResult {
|
||||
@@ -75,6 +77,7 @@ export class ChatService {
|
||||
actor,
|
||||
guard: this.deps.guard,
|
||||
logger: this.deps.logger,
|
||||
...(this.deps.maxSteps ? { maxSteps: this.deps.maxSteps } : {}),
|
||||
});
|
||||
this.deps.logger.info({ actor, steps }, "tour d'agent terminé");
|
||||
return reply;
|
||||
|
||||
Reference in New Issue
Block a user