refactor(models): preserve legacy claude-opus-4-6 aliases and category mapping

Addresses review feedback on #3486:

1. claude-thinking-legacy-alias now matches both claude-opus-4-6-thinking
   and claude-opus-4-7-thinking, canonicalizing both to claude-opus-4-7.
   The previous diff retargeted the regex to 4-7 only, which dropped
   backward compatibility for users still pinned to the 4-6 thinking
   suffix.

2. MODEL_TO_CATEGORY_MAP keeps the claude-opus-4-6 to unspecified-high
   entry alongside the new 4-7 entry. The map is order-independent from
   MODEL_VERSION_MAP, so preserving the 4-6 key avoids relying on a
   specific migration ordering for legacy agent configs.

3. Fix stale 'Claude Opus 4.6' labels and BDD test comments that the
   sed-based bump missed.
This commit is contained in:
YeonGyu-Kim
2026-04-17 15:35:11 +09:00
parent f34a074f12
commit 5478bab457
4 changed files with 6 additions and 5 deletions
+2 -2
View File
@@ -61,7 +61,7 @@ describe("updateConnectedProvidersCache", () => {
name: "Anthropic",
env: [],
models: {
"claude-opus-4-7": { id: "claude-opus-4-7", name: "Claude Opus 4.6" },
"claude-opus-4-7": { id: "claude-opus-4-7", name: "Claude Opus 4.7" },
"claude-sonnet-4-6": { id: "claude-sonnet-4-6", name: "Claude Sonnet 4.6" },
},
},
@@ -84,7 +84,7 @@ describe("updateConnectedProvidersCache", () => {
{ id: "gpt-5.4", name: "GPT-5.4" },
],
anthropic: [
{ id: "claude-opus-4-7", name: "Claude Opus 4.6" },
{ id: "claude-opus-4-7", name: "Claude Opus 4.7" },
{ id: "claude-sonnet-4-6", name: "Claude Sonnet 4.6" },
],
})