fix: bound max_tokens on the openrouter calls
Neither the coordinator nor the graph resolver set max_tokens, so openrouter reserved the model's entire output window against the key's remaining budget and returned 402 before running anything: 131k tokens reserved to produce a few hundred. It never showed up with the old model because its output window is small enough to fit under the limit. Both are now bounded and overridable by env. The headroom is deliberate, the newer reasoning models spend completion tokens thinking before they answer. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WnNxwxfXSbeNtjvtz5gayb
This commit is contained in:
+1
-1
@@ -12,7 +12,7 @@ ALPHA_VANTAGE_API_KEY=
|
||||
FINNHUB_API_KEY=
|
||||
|
||||
OPEN_ROUTER_API_KEY=
|
||||
OPEN_ROUTER_LLM_MODEL=qwen/qwen3-235b-a22b-2507
|
||||
OPEN_ROUTER_LLM_MODEL=~deepseek/deepseek-v4-flash-latest
|
||||
OPEN_ROUTER_EMBED_MODEL=qwen/qwen3-embedding-8b
|
||||
|
||||
# Paper execution is disabled unless AUTONOMY_EXECUTION_MODE=paper.
|
||||
|
||||
Reference in New Issue
Block a user