feat(model): add Claude Opus 4.8 and retire Opus 4.1#89
Open
hakula139 wants to merge 5 commits into
Open
Conversation
Opus 4.8 shares 4.7's full capability set (interleaved thinking, context management, 1M context, the Low..Max effort ladder, structured outputs) and the same $5/$25 pricing, so a single most-specific-first MODELS row makes it fully functional: betas, pricing, context window, and the auto-compaction threshold all derive from the table. Make it the default model and the `opus` alias target. The combined model+effort picker lists 4.8 in place of 4.7 (4.7 stays selectable via the table), mirroring how 4.6 was dropped from the roster when 4.7 shipped. oxide-code keeps its highest-non-Max effort heuristic, so 4.8 defaults to xhigh rather than upstream's high default.
Opus 4.1 is no longer a supported model. Remove its MODELS row, the OPUS_4_1_RATES pricing constant, and the tests that pinned its older $15/$75 pricing and display labels. `lookup` now treats `claude-opus-4-1` as a retired family that resolves to nothing, asserted alongside the other absent ids. Collapse the Opus 4.1 references in the API and status-line research docs into the 4.5 tier, which carries the same beta profile and is the lowest Opus the table still models.
The beta matrix mirrors the families oxide-code's MODELS table actually sends. Base Opus 4, Sonnet 4, and Haiku 4 resolve to nothing in `lookup` (asserted by lookup_unknown_or_retired), so their columns documented profiles the client never emits. The 4.5 vs 4.6+ columns still carry the tier-gating contrast (effort, context-1m), and the unknown-alias fallback is already covered in prose.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
The highest-non-Max heuristic resolved both Opus 4.7 and 4.8 to xhigh, but upstream defaults every effort-capable model to `high` and Claude Code bumps only 4.7 to `xhigh` (4.8 rides the `high` default). Replace the heuristic with an explicit per-model `default_effort` on Capabilities: xhigh on 4.7, high on 4.8 / 4.6 / Sonnet 4.6, none on models without effort. The default model (Opus 4.8) now resolves to `high`, so derived max_tokens is 32K.
The API and status-line research docs describe upstream rather than oxide-code's supported set, so restore Opus 4.1 and the base-4 columns in the beta matrix and pricing table (oxide-code still drops 4.1 from its own model table). Collapse contiguous version ranges to the `4.1+` / `4.5+` shorthand. Correct the effort docs: the per-model default note now states the real upstream default (`high` everywhere, with Claude Code bumping 4.7 to `xhigh`), the configuration guide's default table matches, and the tier-guide link points to the effort doc that carries the table instead of a mislabeled migration-guide link.
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.
Summary
Adds Claude Opus 4.8 as the default model and retires Opus 4.1 from oxide-code's model table.
opusalias target. It shares 4.7's capability set and $5 / $25 pricing, so a singleMODELSrow wires up betas, pricing, the 1M context window, and the auto-compaction threshold.default_effortgivesxhighon Opus 4.7 andhighon Opus 4.8 (the upstream API default), replacing the old highest-non-Max heuristic.Design decisions
MODELSrow drives a model. Betas, pricing, context window, and the auto-compaction threshold all derive fromlookup, so 4.8 needed exactly one declarative row.high; Claude Code bumps only 4.7 toxhigh(4.8 rides thehighdefault). The highest-non-Max heuristic couldn't express "4.7 xhigh, 4.8 high", soCapabilities::default_effortstores it explicitly.xhighstays the recommended pick for coding — set it with/effort.docs/research/**mirrors upstream, so the beta matrix and pricing table retain Opus 4.1 and the base-4 columns, using the4.1+/4.5+shorthand.Changes
model.rsdefault_effort(xhigh on 4.7, high on 4.8 / 4.6 / Sonnet 4.6), removes the retired Opus 4.1 row + import, and updates the effort / display / absent-family tests.model/pricing.rsOPUS_4_1_RATESconstant.config.rsclaude-opus-4-8[1m]; the resolved default effort is nowhigh(derivedmax_tokens32K).client/anthropic/betas.rsprompt/environment.rsslash/model.rsopusalias at 4.8 and updates roster / alias / dated-id tests.slash/picker.rsslash.rs,tui/components/welcome.rs,tui/components/status.rs,tui/components/snapshots/*.snapdocs/guide/configuration.mddocs/research/api/anthropic.md4.1+shorthand.docs/research/tui/status-line.mdOpus 4.5+shorthand.docs/design/tui/welcome.md,docs/design/tui/status-line.mdTest plan
cargo fmt --all --checkcargo buildcargo clippy --all-targets -- -D warnings: zero warningscargo test: 2094 tests passcargo llvm-cov: not run (cargo-llvm-covunavailable in this environment)pnpm lint: 0 errorspnpm spellcheck: 0 issues