Uh oh!
There was an error while loading. Please reload this page.
fix(plan): resolve model from agent config in plan tools - #18161
fix(plan): resolve model from agent config in plan tools#18161filipeandre wants to merge 1 commit into
Conversation
This PR doesn't fully meet our contributing guidelines and PR template. What needs to be fixed:
Please edit this PR description to address the above within 2 hours, or it will be automatically closed. If you believe this was flagged incorrectly, please let a maintainer know. |
Thanks for your contribution! This PR doesn't have a linked issue. All PRs must reference an existing issue. Please:
See CONTRIBUTING.md for details. |
The following comment was made by an LLM, it may be inaccurate: Potential Duplicate Found:
This suggests PR #18163 may be a duplicate or related PR addressing the exact same issue. You should verify whether this is an alternate version of the same fix or if both PRs should exist. |
Summary
PlanExitToolnow resolves the model for thebuildagent usingAgent.get("build")config, falling back to the last session model if none is configuredPlanEnterTooldoes the same for theplanagentgetLastModelhelper tolastModel(style) and extracts aresolveModelhelperMotivation
When a user configures a specific model for the
buildorplanagent (e.g.agent.build.model = "openai/gpt-4o"), the plan tools were ignoring that config and always using the last model seen in the session. This PR wires upAgent.get()so the configured model is respected.