fix: align Anthropic-compatible model capabilities - #1746
Conversation
🦋 Changeset detectedLatest commit: 787a838 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
commit: |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 83ebc583e1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: afa1478aac
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 786f7b0fb1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0070c40ca1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b0f012051a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 787a838727
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
* fix: align Anthropic-compatible model capabilities * fix: warn on Anthropic effort mismatches * fix: harden Anthropic model resolution * fix: align Anthropic replay and ACP thinking state * fix: normalize Anthropic thinking stream payloads * fix: backfill non-empty preserved thinking * fix: resolve session thinking effort with provider context * fix: honor adaptive thinking opt-out in effort resolution
…oonshotAI#1676 MoonshotAI#1625 MoonshotAI#1746 MoonshotAI#1753 MoonshotAI#1757) Critical fixes cherry-picked from upstream v0.24.x: - fix(agent-core-v2): align rate-limit retries with v1 (MoonshotAI#1598) - fix: preserve empty reasoning across providers (MoonshotAI#1676) - fix: resolve and synchronize thinking effort (MoonshotAI#1625) - fix: align Anthropic-compatible model capabilities (MoonshotAI#1746) - fix(kap-server): close auth bypass via percent-encoded API paths (MoonshotAI#1753) - fix: preserve the crash error in diagnostic logs on unexpected exit (MoonshotAI#1757)
Related Issue
No linked issue. This fixes a reproducible Anthropic-compatible provider regression during model switching and session resume.
Problem
Anthropic-compatible models with custom names were treated as legacy budget-thinking Claude models. Valid backend-specific efforts such as
maxorhighcould therefore be rejected or normalized before reaching the backend. The same validation could abort session resume while replaying a historical effort that no longer appeared in the currentsupport_effortsmetadata.Preserved-thinking sessions had a second failure mode: with
keep = "all", strict compatible endpoints rejected replayed assistant messages that had text but no thinking block.What changed
support_effortsthrough the v1 and v2 model catalogs and expose the inferred choices in the TUI.support_effortsas advisory for the actual Anthropic wire protocol: emit a warning, preserve the requested effort unchanged, and let the configured backend validate it. Native Kimi and other protocols retain strict client-side validation.always_thinkingbehavior on the actual wire protocol, including Kimi-managed models withprotocol = "anthropic".Checklist
gen-changesetsskill, or this PR needs no changeset.gen-docsskill, or this PR needs no doc update.Validation
@moonshot-ai/kosong,@moonshot-ai/agent-core,@moonshot-ai/agent-core-v2, and@moonshot-ai/kimi-code.agent-core-v2domain-layer check.