openclaw/src/secrets
Sid c9f0d6ac8e
feat(agents): support `thinkingDefault: "adaptive"` for Anthropic models (#31227)
* feat(agents): support `thinkingDefault: "adaptive"` for Anthropic models

Anthropic's Opus 4.6 and Sonnet 4.6 support adaptive thinking where the
model dynamically decides when and how much to think.  This is now
Anthropic's recommended mode and `budget_tokens` is deprecated on these
models.

Add "adaptive" as a valid thinking level:
- Config: `agents.defaults.thinkingDefault: "adaptive"`
- CLI: `/think adaptive` or `/think auto`
- Pi SDK mapping: "adaptive" → "medium" effort at the pi-agent-core
  layer, which the Anthropic provider translates to
  `thinking.type: "adaptive"` with `output_config.effort: "medium"`
- Provider fallbacks: OpenRouter and Google map "adaptive" to their
  respective "medium" equivalents

Closes #30880

Made-with: Cursor

* style(changelog): format changelog with oxfmt

* test(types): fix strict typing in runtime/plugin-context tests

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-03-02 03:52:02 +00:00
..
apply.test.ts fix: restore dm command and self-chat auth behavior 2026-02-26 18:49:16 +01:00
apply.ts fix: stabilize secrets land + docs note (#26155) (thanks @joshavant) 2026-02-26 14:47:22 +00:00
audit.test.ts test: harden flaky timeout and resolver specs 2026-03-01 21:30:07 +00:00
audit.ts fix: stabilize secrets land + docs note (#26155) (thanks @joshavant) 2026-02-26 14:47:22 +00:00
config-io.ts feat(secrets): replace migrate flow with audit/configure/apply 2026-02-26 14:47:22 +00:00
configure.ts fix(secrets): harden apply and audit plan handling 2026-02-26 14:47:22 +00:00
json-pointer.ts Secrets: preserve runtime snapshot source refs on write 2026-02-26 14:47:22 +00:00
plan.ts fix(secrets): harden plan target paths and ref-only auth profiles 2026-02-26 14:47:22 +00:00
provider-env-vars.ts Onboard: require explicit mode for env secret refs 2026-02-26 14:47:22 +00:00
ref-contract.ts feat(secrets): finalize mode rename and validated exec docs 2026-02-26 14:47:22 +00:00
resolve.test.ts test(secrets): cover skill migration and symlinked exec command flow 2026-02-26 14:47:22 +00:00
resolve.ts feat(secrets): allow opt-in symlink exec command paths 2026-02-26 14:47:22 +00:00
runtime.test.ts feat(agents): support `thinkingDefault: "adaptive"` for Anthropic models (#31227) 2026-03-02 03:52:02 +00:00
runtime.ts fix(secrets): normalize inline SecretRef token/key to tokenRef/keyRef in runtime snapshot (#31047) 2026-03-02 03:34:23 +00:00
shared.ts feat(secrets): replace migrate flow with audit/configure/apply 2026-02-26 14:47:22 +00:00