-
Notifications
You must be signed in to change notification settings - Fork 1
[TASK] Refactor default MaxChatCompletionIterations from 10 to 50 #123
Copy link
Copy link
Closed
Description
Summary
The current default value for MaxChatCompletionIterations is set to 10, which is too low for complex agentic tasks that require multiple tool calls and reasoning steps. This frequently causes tasks to be prematurely canceled before completion.
Current behavior:
- Default: 10 iterations
- Complex tasks (e.g., web scraping with multiple pages, multi-step data processing) hit this limit and get canceled
- Users must manually override via environment variable:
A2A_AGENT_CLIENT_MAX_CHAT_COMPLETION_ITERATIONS=50
Proposed change:
- Increase default from 10 to 50 iterations
- This provides better out-of-the-box experience for agentic workloads
- Still allows override via environment variable for specific needs
Real-world example:
Browser agent attempting to scrape blog articles hit max iterations at 10, task was canceled mid-execution. After increasing to 30, task completed successfully but could have used more iterations.
Acceptance Criteria
- Update default value in
server/config/config.gofrom 10 to 50 - Update default value in
server/agent_builder.gofrom 10 to 50 - Update default value in
server/agent.gofrom 10 to 50 - Update documentation in
README.mdto reflect new default (10 → 50) - Update all test files that reference the old default value of 10
- Ensure
Config.Validate()still enforces minimum of 1 iteration - Verify backward compatibility: environment variable still overrides default
Reactions are currently unavailable