Skip to content

Commit 557e1a2

Browse files
committed
feat: improve error messaging for tool-call limit in chat UI
1 parent e7b74fe commit 557e1a2

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -780,6 +780,8 @@ default_policy = "prompt"
780780
max_tool_loops = 100
781781
```
782782

783+
When a turn hits this guard, the chat UI now surfaces a clear error explaining that tool execution stopped and points you to `[tools].max_tool_loops` in `vtagent.toml` so you can raise the limit before retrying.
784+
783785
### Distribution & Releases
784786

785787
VTCode supports multiple distribution channels for easy installation:

docs/project/TODO.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,3 @@ can we let the agent output text as ansi codes directly, and not markdown, so we
216216
▌ mode is Full Auto in welcome message
217217

218218
---
219-
220-
▌ check dead code: vtagent-core/src/core/agent/runner.rs
221-
▌ if can be used, if not remove it

src/agent/runloop/unified.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ pub(crate) async fn run_single_agent_loop_unified(
261261
"I reached the configured tool-call limit of {} for this turn and paused further tool execution. Increase `tools.max_tool_loops` in vtcode.toml if you need more, then ask me to continue.",
262262
max_tool_loops
263263
);
264-
renderer.line(MessageStyle::Response, &notice)?;
264+
renderer.line(MessageStyle::Error, &notice)?;
265265
ensure_turn_bottom_gap(&mut renderer, &mut bottom_gap_applied)?;
266266
working_history.push(uni::Message::assistant(notice));
267267
break 'outer;

0 commit comments

Comments
 (0)