Josh Lehman
c52df32878
refactor: move bundled replay policy ownership into plugins ( #60452 )
...
* refactor: move bundled replay policy ownership into plugins
* test: preserve replay fallback until providers adopt hooks
* test: cover response replay branches for ollama and zai
---------
Co-authored-by: Shakker <shakkerdroid@gmail.com>
2026-04-03 19:08:10 +01:00
Josh Lehman
799c6f40aa
refactor: move provider replay runtime ownership into plugins ( #60126 )
...
* refactor: move provider replay runtime ownership into plugins
* fix(provider-runtime): address review followups
---------
Co-authored-by: Vincent Koc <vincentkoc@ieee.org>
2026-04-03 23:14:37 +09:00
Josh Lehman
71346940ad
refactor: add provider replay runtime hook surfaces ( #59143 )
...
Merged via squash.
Prepared head SHA: 56b41e87a5
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
2026-04-01 13:45:41 -07:00
Kunal Karmakar
34b0a19a16
fix: use azure-openai-responses for Azure custom providers ( #50851 ) (thanks @kunalk16)
...
* Add azure-openai-responses
* Unit tests update for updated API
* Add entry for PR #50851
* Add comma to address PR comment
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
* Address PR comment on sanitization of output
* Address review comment
* Revert commits
* Revert commit
* Update changelog stating Azure OpenAI only
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
* Add references
* Address PR comment on sanitization of output
* Address review comment
* Revert commits
* Revert commit
* Address PR comment on sanitization of output
* Address review comment
* Revert commits
* Revert commit
* Fix generated file
* Add azure openai responses to OPENAI_RESPONSES_APIS
* Add azure openai responses to createParallelToolCallsWrapper
* Adding azure openai responses to attempt.ts
* Add azure openai responses to google.ts
* Address PR comment on sanitization of output
* Revert commit
* Address PR comment on sanitization of output
* Revert commit
* Address PR comment on sanitization of output
* Revert commit
* Fix changelog
* Fix linting
* fix: cover azure responses wrapper path (#50851 ) (thanks @kunalk16)
---------
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-30 16:17:03 +05:30
助爪
5c5c64b612
Deduplicate repeated tool call IDs for OpenAI-compatible APIs ( #40996 )
...
Merged via squash.
Prepared head SHA: 38d8048359
Co-authored-by: xaeon2026 <264572156+xaeon2026@users.noreply.github.com>
Co-authored-by: frankekn <4488090+frankekn@users.noreply.github.com>
Reviewed-by: @frankekn
2026-03-15 19:46:07 +08:00
Frank Yang
5ca0233db0
fix(agents): drop Anthropic thinking blocks on replay ( #44843 )
...
* agents: drop Anthropic thinking blocks on replay
* fix: extend anthropic replay sanitization openclaw#44429 thanks @jmcte
* fix: extend anthropic replay sanitization openclaw#44843 thanks @jmcte
* test: add bedrock replay sanitization coverage openclaw#44843
* test: cover anthropic provider drop-thinking hints openclaw#44843
---------
Co-authored-by: johnmteneyckjr <john.m.teneyck@gmail.com>
2026-03-13 16:57:56 +08:00
Peter Steinberger
ef2541ceb3
refactor: centralize transcript provider quirks
2026-03-08 18:26:35 +00:00
Peter Steinberger
b41bcb08a2
refactor: expand provider capability registry
2026-03-08 16:22:52 +00:00
Peter Steinberger
eba9dcc67a
Refactor release hardening follow-ups ( #39959 )
...
* build: fail fast on stale host-env swift policy
* build: sync generated host env swift policy
* build: guard bundled extension root dependency gaps
* refactor: centralize provider capability quirks
* test: table-drive provider regression coverage
* fix: block merge when prep branch has unpushed commits
* refactor: simplify models config merge preservation
2026-03-08 14:49:58 +00:00
Varun Chopra
097c588a6b
transcript-policy: use named Set for anthropic signature-excluded providers
2026-03-08 14:16:21 +00:00
Varun Chopra
2bf53c2cb6
transcript-policy: don't preserve thinking signatures for kimi-coding ( #39798 )
2026-03-08 14:16:21 +00:00
Peter Steinberger
f304ca09b1
fix(agents): sanitize strict openai-compatible turn ordering from #39252 (thanks @scoootscooob)
...
Co-authored-by: scoootscooob <zhentongfan@gmail.com>
2026-03-07 23:42:19 +00:00
Sid
591264ef52
fix(agents): set preserveSignatures to isAnthropic in resolveTranscriptPolicy ( #32813 )
...
Merged via squash.
Prepared head SHA: f522d21ca5
Co-authored-by: Sid-Qin <201593046+Sid-Qin@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
2026-03-05 11:55:06 -08:00
bmendonca3
a6489ab5e9
fix(agents): cap openai-completions tool call ids to provider-safe format ( #31947 )
...
Co-authored-by: bmendonca3 <bmendonca3@users.noreply.github.com>
2026-03-02 18:08:20 +00:00
Ben Marvell
252079f001
fix(agents): repair orphaned tool results for OpenAI after history truncation
...
repairToolUseResultPairing was gated behind !isOpenAi, skipping orphaned
tool_result cleanup for OpenAI providers. When limitHistoryTurns truncated
conversation history, tool_result messages whose matching tool_call was
before the truncation point survived and were sent as function_call_output
items with stale call_id references. OpenAI rejects these with:
"No tool call found for function call output with call_id ..."
Enable the repair universally — all providers need it after truncation.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
(cherry picked from commit 97b065aa6e )
2026-02-24 04:33:50 +00:00
JackyWay
792bd6195c
fix: recognize Bedrock as Anthropic-compatible in transcript policy
...
(cherry picked from commit 3b5154081c )
2026-02-24 04:33:50 +00:00
John Fawcett
13f32e2f7d
feat: Add Kilo Gateway provider ( #20212 )
...
* feat: Add Kilo Gateway provider
Add support for Kilo Gateway as a model provider, similar to OpenRouter.
Kilo Gateway provides a unified API that routes requests to many models
behind a single endpoint and API key.
Changes:
- Add kilocode provider option to auth-choice and onboarding flows
- Add KILOCODE_API_KEY environment variable support
- Add kilocode/ model prefix handling in model-auth and extra-params
- Add provider documentation in docs/providers/kilocode.md
- Update model-providers.md with Kilo Gateway section
- Add design doc for the integration
* kilocode: add provider tests and normalize onboard auth-choice registration
* kilocode: register in resolveImplicitProviders so models appear in provider filter
* kilocode: update base URL from /api/openrouter/ to /api/gateway/
* docs: fix formatting in kilocode docs
* fix: address PR review — remove kilocode from cacheRetention, fix stale model refs and CLI name in docs, fix TS2742
* docs: fix stale refs in design doc — Moltbot to OpenClaw, MoltbotConfig to OpenClawConfig, remove extra-params section, fix doc path
* fix: use resolveAgentModelPrimaryValue for AgentModelConfig union type
---------
Co-authored-by: Mark IJbema <mark@kilocode.ai>
2026-02-23 23:29:27 +00:00
Peter Steinberger
9757d2bb64
fix(agents): normalize strict openai-compatible turn ordering
...
Co-authored-by: liuwenyong1985 <48443240+liuwenyong1985@users.noreply.github.com>
2026-02-23 12:44:23 +00:00
Peter Steinberger
382fe8009a
refactor!: remove google-antigravity provider support
2026-02-23 05:20:14 +01:00
echoVic
9176571ec1
fix(gemini): sanitize thoughtSignatures for native Google provider
...
Native Google Gemini provider was accumulating 2K-8K tokens of Base64
thoughtSignature blobs per turn, causing premature context overflow.
The sanitizer was only enabled for OpenRouter Gemini, not native Google.
Fixes #23392
2026-02-22 12:24:53 +01:00
jackheuberger
feccac6723
fix: sanitize thinking blocks for GitHub Copilot Claude models (openclaw#19459) thanks @jackheuberger
...
Verified:
- pnpm build
- pnpm check
- pnpm test:macmini
Co-authored-by: jackheuberger <12731288+jackheuberger@users.noreply.github.com>
Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
2026-02-20 19:48:09 -06:00
Peter Steinberger
b8b43175c5
style: align formatting with oxfmt 0.33
2026-02-18 01:34:35 +00:00
Peter Steinberger
31f9be126c
style: run oxfmt and fix gate failures
2026-02-18 01:29:02 +00:00
cpojer
d0cb8c19b2
chore: wtf.
2026-02-17 13:36:48 +09:00
Sebastian
ed11e93cf2
chore(format)
2026-02-16 23:20:16 -05:00
cpojer
90ef2d6bdf
chore: Update formatting.
2026-02-17 09:18:40 +09:00
the sun gif man
68ea063958
🤖 fix: preserve openai reasoning replay ids ( #17792 )
...
What:
- disable tool-call id sanitization for OpenAI/OpenAI Codex transcript policy
- gate id sanitization in image sanitizer to full mode only
- keep orphan reasoning downgrade scoped to OpenAI model-switch replay path
- update transcript policy, session-history, sanitizer, and reasoning replay tests
- document OpenAI model-switch orphan-reasoning cleanup behavior in transcript hygiene reference
Why:
- OpenAI Responses replay depends on canonical call_id|fc_id pairings for reasoning followers
- strict id rewriting in OpenAI path breaks follower matching and triggers rs_* orphan 400s
- limiting scope avoids behavior expansion while fixing the identified regression
Tests:
- pnpm vitest run src/agents/transcript-policy.test.ts src/agents/pi-embedded-runner.sanitize-session-history.test.ts src/agents/openai-responses.reasoning-replay.test.ts
- pnpm vitest run --config vitest.e2e.config.ts src/agents/transcript-policy.e2e.test.ts src/agents/pi-embedded-runner.sanitize-session-history.e2e.test.ts src/agents/pi-embedded-helpers.sanitize-session-messages-images.removes-empty-assistant-text-blocks-but-preserves.e2e.test.ts src/agents/pi-embedded-helpers.sanitizeuserfacingtext.e2e.test.ts
- pnpm lint
- pnpm format:check
- pnpm check:docs
- pnpm test (fails in current macOS bash 3.2 env at test/git-hooks-pre-commit.integration.test.ts: mapfile not found)
2026-02-15 22:45:01 -08:00
JINNYEONG KIM
94763cd87d
Fix OpenAI/Codex tool call id sanitization for transcript policy ( #15279 )
2026-02-13 11:39:51 +00:00
0xRain
1d2c5783fd
fix(agents): enable tool call ID sanitization for Anthropic provider ( #13830 )
...
Co-authored-by: 0xRaini <0xRaini@users.noreply.github.com>
2026-02-12 08:42:24 +09:00
cpojer
f06dd8df06
chore: Enable "experimentalSortImports" in Oxfmt and reformat all imorts.
2026-02-01 10:03:47 +09:00
cpojer
5ceff756e1
chore: Enable "curly" rule to avoid single-statement if confusion/errors.
2026-01-31 16:19:20 +09:00
hlbbbbbbb
2496056886
fix(minimax): use correct API endpoint and format
...
MiniMax has updated their API. The previous configuration used an
incorrect endpoint (api.minimax.io/anthropic) with anthropic-messages
format, which no longer works.
Changes:
- Update MINIMAX_API_BASE_URL to https://api.minimax.chat/v1
- Change API format from anthropic-messages to openai-completions
- Remove minimax from isAnthropicApi check in transcript-policy
This fixes the issue where MiniMax API calls return no results.
2026-01-27 19:48:38 -06:00
Peter Steinberger
2424404fb4
docs: add transcript hygiene reference
2026-01-23 01:34:21 +00:00
Peter Steinberger
db0235a26a
fix: gate transcript sanitization by provider
2026-01-23 00:42:45 +00:00