Repository navigation
fix(openclaw): default to claude-sonnet-4-6 instead of retired claude-sonnet-4-5 - #420
Open
pcbeingused33 wants to merge 2 commits into
Open
pcbeingused33 wants to merge 2 commits into
pcbeingused33 wants to merge 2 commits into
Conversation
claude-sonnet-4-5 was retired on 2026-11-30, so every wrapper run now fails with not_found. Default to claude-sonnet-5-5 and allow overriding it via AGENT_S_MODEL, like the existing AGENT_S_GROUND_MODEL.
…-sonnet-4-5 claude-sonnet-4-5 was retired, so every wrapper run fails with not_found. claude-sonnet-4-6 is active and works with the current Anthropic engine (no default thinking, accepts temperature).
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
integrations/openclaw/agent_s_wrapper.pyhardcodes--model claude-sonnet-4-5. Anthropic retiredclaude-sonnet-4-5on 2026-11-30 (https://platform.claude.com/docs/en/about-claude/model-deprecations), so every task started through the OpenClaw wrapper now fails at the first API call with anot_founderror.Changes:
claude-sonnet-4-6and readsAGENT_S_MODELto override it, following the existingAGENT_S_GROUND_MODELpattern.AGENT_S_MODEL.tests/test_openclaw_wrapper.py. It mocksshutil.whichandsubprocess.runand checks the--modelvalue passed toagent_s: the default, and the value set throughAGENT_S_MODEL. Both tests fail on main and pass with this change (python -m unittest tests.test_openclaw_wrapper).Why
claude-sonnet-4-6and not the listed replacementclaude-sonnet-5-5: Sonnet 5.5 thinks by default and rejects a non-defaulttemperature. The s3 Anthropic engine currently returnscontent[0].text(the thinking block on 5.5) and always sendstemperature(e.g.0.0from the grounding text-span call), so a 5.5 default would just trade thenot_founderror for another failure. Sonnet 4.6 is active (retirement not before February 2027), does not think unless asked and acceptstemperature, so it matches the request the engine sends today. Once #205 lands (it reads text blocks by type and omitstemperatureforsonnet-5*), the default can move toclaude-sonnet-5-5; in the meantimeAGENT_S_MODEL=claude-sonnet-5-5is available for anyone running with #205.This PR was prepared with the help of an AI coding assistant.