mirror of
https://github.com/vxcontrol/pentagi.git
synced 2026-11-06 14:04:49 +00:00
Makes adaptive-thinking models usable safely and adds Opus 4.7/4.8 to the catalog so they are selectable and configurable. - middleware: strip temperature/top_p/top_k and set thinking.display=summarized when rewriting to adaptive. Opus 4.7+ reject sampling params (AWS: "no longer supported", 400) and default display to "omitted" (empty reasoning text). - models.yml: add us.anthropic.claude-opus-4-7 and us.anthropic.claude-opus-4-8, plus a ModelReasoningInfo capability descriptor (mode + allowed efforts) on the adaptive models (4.6/4.7/4.8/sonnet-4.6). - provider backstop: force adaptive for adaptive-only models (Opus 4.7/4.8) regardless of agent config, so selecting them cannot 400 on budget thinking. The capability descriptor is the single source of truth (no model-name regex). Verified: unit tests cover the body rewrite (sampling strip + display); a live Bedrock run of the adaptive path on us.anthropic.claude-opus-4-6-v1 passed 21/23 (the 2 failures were 429 throttling, not the mechanism). Opus 4.7/4.8 could not be exercised live -- this AWS account lacks model access (403), not a code issue; their correctness rests on the AWS docs + the 4.6 live run + unit tests. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>