depth flag should drive iteration / budget / source defaults #30
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
The
depthparameter (shallow/balanced/deep) is currently passed only as a text hint inside the agent's user message. It has no mechanical effect on iteration counts, token budgets, or source counts — those are governed independently by--max-iterationsand--budget. The LLM is expected to "interpret" depth, which is unreliable and makes the flag essentially cosmetic.Goal
Make
deptha real control knob: choosing a depth picks sensible defaults formax_iterations,token_budget, andmax_sources. Explicit--max-iterations/--budgetflags still override.Suggested defaults (open to discussion)
(
balancedmatches today's defaults so the change is backward-compatible for existing callers.)Scope
ResearchConstraints(or a newdepth_defaults()helper) maps depth → defaultsWebResearcher.research()applies depth defaults only when the constraint field is at its default value — explicit overrides winresearchtool: same logicaskcommand: when--max-iterations/--budgetare not explicitly set, the depth chooses; when they are, they override (Click can detect this withclick.get_current_context().get_parameter_source(...))Tests
balancedis unchanged from current defaults (regression check)Out of scope