Skip to content

feat(models): add Claude Opus 4.8 - #34014

Closed
Couiz wants to merge 1 commit into
NousResearch:mainfrom
Couiz:feat/add-claude-opus-4-8
Closed

feat(models): add Claude Opus 4.8#34014
Couiz wants to merge 1 commit into
NousResearch:mainfrom
Couiz:feat/add-claude-opus-4-8

Conversation

@Couiz

@Couiz Couiz commented May 28, 2026

Copy link
Copy Markdown

Summary

Adds Claude Opus 4.8 across all four layers Hermes uses to know an Anthropic model.

  • hermes_cli/models.py — adds the model to OPENROUTER_MODELS (anthropic/claude-opus-4.8), _PROVIDER_MODELS["nous"], and the native _PROVIDER_MODELS["anthropic"] list (claude-opus-4-8).
  • agent/model_metadata.py — 1M context window for both claude-opus-4-8 and claude-opus-4.8, inserted before the 4.7 entries to avoid fuzzy-match collisions.
  • agent/anthropic_adapter.py — adds 4-8/4.8 to the substring gates so Opus 4.8 inherits the Opus 4.7 contract:
    • _XHIGH_EFFORT_SUBSTRINGSxhigh adaptive effort (not downgraded to max)
    • _ADAPTIVE_THINKING_SUBSTRINGS → adaptive thinking
    • _NO_SAMPLING_PARAMS_SUBSTRINGS → omits temperature/top_p/top_k (4.7+ returns 400 otherwise)
    • _ANTHROPIC_OUTPUT_LIMITS["claude-opus-4-8"] = 128_000
  • website/static/api/model-catalog.json — regenerated via scripts/build_model_catalog.py to keep the published manifest in sync with the curated lists.

Verification

  • Model ID confirmed live against the Anthropic API (GET /v1/models returns claude-opus-4-8, no dated suffix — same shape as claude-opus-4-7).
  • Adapter gates assert xhigh=True, adaptive=True, no-sampling=True for claude-opus-4-8, claude-opus-4.8, and anthropic/claude-opus-4.8.
  • Fuzzy-collision sanity: '4-8' in 'claude-opus-4-7' is False.

Test Plan

  • pytest tests/agent/test_anthropic_adapter.py tests/hermes_cli/test_models.py tests/hermes_cli/test_model_catalog.py tests/hermes_cli/test_model_validation.py334 passed
  • Manifest sync test (test_in_repo_lists_match_manifest) passes after regeneration

- hermes_cli/models.py: add to OpenRouter, Nous, and native Anthropic lists
- agent/model_metadata.py: 1M context for claude-opus-4-8/4.8
- agent/anthropic_adapter.py: 4-8/4.8 -> xhigh effort, adaptive thinking,
  no-sampling-params contract (inherits Opus 4.7 contract); 128k output limit
- website/static/api/model-catalog.json: regenerated manifest

Model ID verified live against Anthropic /v1/models (claude-opus-4-8).
@Couiz

Couiz commented May 28, 2026

Copy link
Copy Markdown
Author

Closing as superseded — #34003 ("feat: add claude-opus-4.8 and claude-opus-4.8-fast") landed on main first and covers everything here: identical adapter substring gates (_XHIGH_EFFORT_SUBSTRINGS, _ADAPTIVE_THINKING_SUBSTRINGS, _NO_SAMPLING_PARAMS_SUBSTRINGS), the 1M DEFAULT_CONTEXT_LENGTHS entries, the 128k output limit, and the curated model lists — plus the claude-opus-4.8-fast variant this PR didn't include. Nothing to add. Thanks!

@Couiz Couiz closed this May 28, 2026
@Couiz
Couiz deleted the feat/add-claude-opus-4-8 branch May 28, 2026 17:38
@alt-glitch alt-glitch added type/feature New feature or request P2 Medium — degraded but workaround exists comp/agent Core agent runtime: loop, agent_init, prompt builder, context-compression, responses endpoint comp/cli CLI entry point, hermes_cli/, setup wizard provider/anthropic Anthropic native Messages API labels May 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/agent Core agent runtime: loop, agent_init, prompt builder, context-compression, responses endpoint comp/cli CLI entry point, hermes_cli/, setup wizard P2 Medium — degraded but workaround exists provider/anthropic Anthropic native Messages API type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants