Commit Graph

3898 Commits

Author SHA1 Message Date
Peter Steinberger
a92fbf7d40 test: dedupe remaining agent test seams 2026-03-26 16:14:45 +00:00
Peter Steinberger
bac603a63e test: share subagent and policy test fixtures 2026-03-26 16:04:34 +00:00
Peter Steinberger
c4048aea41 test: share msteams monitor and pi runner fixtures 2026-03-26 15:40:51 +00:00
Peter Steinberger
5e78232bc5 test: share pi compaction fixtures 2026-03-26 15:19:32 +00:00
Peter Steinberger
a4a00aa1da feat: pluginize cli inference backends 2026-03-26 15:11:15 +00:00
Saurabh Mishra
6fbe9dd935 fix: surface provider-specific rate limit error message (#54433) (#54512)
Merged via squash.

Prepared head SHA: 755cff833c
Co-authored-by: bugkill3r <2924124+bugkill3r@users.noreply.github.com>
Co-authored-by: altaywtf <9790196+altaywtf@users.noreply.github.com>
Reviewed-by: @altaywtf
2026-03-26 15:16:06 +03:00
Jacob Tomlinson
d9810811b6 fix(agents): enforce session_status guard after sessionId resolution (#55105)
* fix(agents): enforce visibility guard after sessionId resolution in session_status

When a sessionId (rather than an explicit agent key) is passed to the
session_status tool, the sessionId resolution block rewrites
requestedKeyRaw to an explicit "agent:..." key.  The subsequent
visibility guard check at line 375 tested
`!requestedKeyRaw.startsWith("agent:")`, which was now always false
after resolution — skipping the visibility check entirely.

This meant a sandboxed agent could bypass visibility restrictions by
providing a sessionId instead of an explicit session key.

Fix: use the original `isExplicitAgentKey` flag (captured before
resolution) instead of re-checking the dynamic requestedKeyRaw.
This ensures the visibility guard runs for sessionId inputs while
still skipping the redundant check for inputs that were already
validated at the earlier explicit-key check (lines 281-286).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* test: cover session status sessionId guard

* test: align parent sessionId guard coverage

---------

Co-authored-by: Kevin Sheng <shenghuikevin@github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 11:34:22 +00:00
pomelo
dad68d319b Remove Qwen OAuth integration (qwen-portal-auth) (#52709)
* Remove Qwen OAuth integration (qwen-portal-auth)

Qwen OAuth via portal.qwen.ai is being deprecated by the Qwen team due
to traffic impact on their primary Qwen Code user base. Users should
migrate to the officially supported Model Studio (Alibaba Cloud Coding
Plan) provider instead.

Ref: https://github.com/openclaw/openclaw/issues/49557

- Delete extensions/qwen-portal-auth/ plugin entirely
- Remove qwen-portal from onboarding auth choices, provider aliases,
  auto-enable list, bundled plugin defaults, and pricing cache
- Remove Qwen CLI credential sync (external-cli-sync, cli-credentials)
- Remove QWEN_OAUTH_MARKER from model auth markers
- Update docs/providers/qwen.md to redirect to Model Studio
- Update model-providers docs (EN + zh-CN) to remove Qwen OAuth section
- Regenerate config and plugin-sdk baselines
- Update all affected tests

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

* Clean up residual qwen-portal references after OAuth removal

* Add migration hint for deprecated qwen-portal OAuth provider

* fix: finish qwen oauth removal follow-up

---------

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
Co-authored-by: Frank Yang <frank.ekn@gmail.com>
2026-03-26 16:32:34 +08:00
kevinlin-openai
432d5f863c fix: add slack upload-file action (#54987) (thanks @kevinlin-openai)
* feat(slack): add upload-file action

Co-authored-by: Codex <noreply@openai.com>

* fix(slack): guard upload-file routing

Co-authored-by: Codex <noreply@openai.com>

* fix(slack): tighten upload-file validation

---------

Co-authored-by: kevinlin-openai <kevin@dendron.so>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-26 13:37:58 +05:30
Nyanako
d72cc7a380 fix: route codex responses over websocket and preserve tool warnings (#53702) (thanks @Nanako0129)
* fix: route codex responses over websocket and suppress gated core tool warnings

* fix: rebase codex websocket patch onto main

* fix: preserve explicit alsoAllow warnings (#53702) (thanks @Nanako0129)

---------

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-26 12:28:17 +05:30
Tyler Yust
00e932a83c fix: restore inbound image embedding for CLI routed BlueBubbles turns (#51373)
* fix(cli): hydrate prompt image refs for inbound media

* Agents: harden CLI prompt image hydration (#51373)

* test: fix CLI prompt image hydration helper mocks
2026-03-26 15:47:44 +09:00
George Zhang
6cbd2d36f8 Revert "feat: add video generation core infrastructure and extend image generation parameters (#53681)" (#54943)
This reverts commit 4cb8dde894.
2026-03-25 23:00:14 -07:00
Ted Li
76ff0d9298 fix: restore image-tool generic provider fallback (#54858) (thanks @MonkeyLeeT)
* Image tool: restore generic provider fallback

* Image tool: cover multi-image generic fallback

* test: tighten minimax-portal image fallback coverage

* fix: restore image-tool generic provider fallback (#54858) (thanks @MonkeyLeeT)

---------

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-26 10:07:43 +05:30
xieyongliang
4cb8dde894 feat: add video generation core infrastructure and extend image generation parameters (#53681)
* feat: add video generation core infrastructure and extend image generation parameters

Add full video generation capability to OpenClaw core:

- New `video_generate` agent tool with support for prompt, duration, aspect ratio,
  resolution, seed, watermark, I2V (first/last frame), camerafixed, and draft mode
- New `VideoGenerationProvider` plugin SDK type and `registerVideoGenerationProvider` API
- New `src/video-generation/` module (types, runtime with fallback, provider registry)
- New `openclaw/plugin-sdk/video-generation` export for external plugins
- 200MB max file size for generated videos (vs default 5MB for images)

Extend image generation with additional parameters:
- `seed`, `watermark`, `guidanceScale`, `optimizePrompt`, `providerOptions`
- New `readBooleanParam()` helper in tool common utilities

Update plugin registry, contracts, and all test mocks to include
`videoGenerationProviders` and `videoGenerationProviderIds`.

Made-with: Cursor

* fix: validate aspect ratio against target provider when model override is set

* cleanup: remove redundant ?? undefined from video/image generate tools

* chore: regenerate plugin SDK API baseline after video generation additions

---------

Co-authored-by: yongliang.xie <yongliang.xie@bytedance.com>
2026-03-25 18:45:06 -07:00
adzendo
19d91aaa8f fix: make buttons schema optional in message tool (#54418)
Merged via squash.

Prepared head SHA: 0805c095e9
Co-authored-by: adzendo <246828680+adzendo@users.noreply.github.com>
Co-authored-by: altaywtf <9790196+altaywtf@users.noreply.github.com>
Reviewed-by: @altaywtf
2026-03-26 02:43:15 +03:00
Tak Hoffman
79fbcfc03b fix(ci): restore main green 2026-03-25 16:17:42 -05:00
Nimrod Gutman
501190d2e8 refactor(sandbox): remove tool policy facade (#54684)
* refactor(sandbox): remove tool policy facade

* fix(sandbox): harden blocked-tool guidance

* fix(sandbox): avoid control-char guidance leaks

* fix: harden sandbox blocked-tool guidance (#54684) (thanks @ngutman)
2026-03-25 23:03:24 +02:00
Jared
c6d8318d07 Trigger preflight compaction from transcript estimates when usage is stale (#49479)
Merged via squash.

Prepared head SHA: 8d214b708b
Co-authored-by: jared596 <37019497+jared596@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
2026-03-25 13:22:16 -07:00
Joseph Krug
d81593c6e2 fix: trigger compaction on LLM timeout with high context usage (#46417)
Merged via squash.

Prepared head SHA: 619bc4c1fa
Co-authored-by: joeykrug <5925937+joeykrug@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
2026-03-25 12:51:36 -07:00
kiranvk2011
84401223c7 fix: per-model cooldown scope, stepped backoff, and user-facing rate-limit message (#49834)
Merged via squash.

Prepared head SHA: 7c488c070c
Co-authored-by: kiranvk-2011 <91108465+kiranvk-2011@users.noreply.github.com>
Co-authored-by: altaywtf <9790196+altaywtf@users.noreply.github.com>
Reviewed-by: @altaywtf
2026-03-25 22:03:49 +03:00
Andrii Furmanets
89c4c674d1 fix(compaction): surface safeguard cancel reasons and clarify /compact skips (#51072)
Merged via squash.

Prepared head SHA: f1dbef0443
Co-authored-by: afurm <6375192+afurm@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
2026-03-25 11:03:22 -07:00
chenxingzhen
4ae4d1fabe fix: mid-turn 429 rate limit silent no-reply and context engine registration failure (#50930)
Merged via squash.

Prepared head SHA: eea7800df3
Co-authored-by: infichen <13826604+infichen@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
2026-03-25 10:43:08 -07:00
Jackal Xin
2de32fbf14 fix: reconcile session compaction count after late compaction success (#45493)
Merged via squash.

Prepared head SHA: d0715a5555
Co-authored-by: jackal092927 <3854860+jackal092927@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
2026-03-25 10:00:41 -07:00
liyuan97
e2e9f979ca feat(minimax): add image generation provider and trim model catalog to M2.7 (#54487)
* feat(minimax): add image generation and TTS providers, trim TUI model list

Register MiniMax image-01 and speech-2.8 models as plugin providers for
the image_generate and TTS tools. Both resolve CN/global base URLs from
the configured model endpoint origin.

- Image generation: base64 response, aspect-ratio support, image-to-image
  via subject_reference, registered for minimax and minimax-portal
- TTS: speech-2.8-turbo (default) and speech-2.8-hd, hex-encoded audio,
  voice listing via get_voice API, telephony PCM support
- Add MiniMax to TTS auto-detection cascade (after ElevenLabs, before
  Microsoft) and TTS config section
- Remove MiniMax-VL-01, M2, M2.1, M2.5 and variants from TUI picker;
  keep M2.7 and M2.7-highspeed only (backend routing unchanged)

* feat(minimax): trim legacy model catalog to M2.7 only

Cherry-picked from temp/feat/minimax-trim-legacy-models (949ed28).
Removes MiniMax-VL-01, M2, M2.1, M2.5 and variants from the model
catalog, model order, modern model matchers, OAuth config, docs, and
tests. Keeps only M2.7 and M2.7-highspeed.

Conflicts resolved:
- provider-catalog.ts: removed MINIMAX_TUI_MODELS filter (no longer
  needed since source array is now M2.7-only)
- index.ts: kept image generation + speech provider registrations
  (added by this branch), moved media understanding registrations
  earlier (as intended by the cherry-picked commit)

* fix(minimax): update discovery contract test to reflect M2.7-only catalog

Cherry-picked from temp/feat/minimax-trim-legacy-models (2c750cb).

* feat(minimax): add web search provider and register in plugin entry

* fix(minimax): resolve OAuth credentials for TTS speech provider

* MiniMax: remove web search and TTS providers

* fix(minimax): throw on empty images array after generation failure

* feat(minimax): add image generation provider and trim catalog to M2.7 (#54487) (thanks @liyuan97)

---------

Co-authored-by: tars90percent <tars@minimaxi.com>
Co-authored-by: George Zhang <georgezhangtj97@gmail.com>
2026-03-25 09:29:35 -07:00
Nimrod Gutman
edb5123f26 fix(sandbox): honor sandbox alsoAllow and explicit re-allows (#54492)
* fix(sandbox): honor effective sandbox alsoAllow policy

* fix(sandbox): prefer resolved sandbox context policy

* fix: honor sandbox alsoAllow policy (#54492) (thanks @ngutman)
2026-03-25 16:51:13 +02:00
Peter Steinberger
c92002e1de fix(media): align outbound media access with fs policy 2026-03-25 05:50:21 -07:00
Peter Steinberger
d363af8c13 refactor(auth): separate profile ids from email metadata 2026-03-25 04:24:46 -07:00
Liu Yuan
419824729a fix: fail loud when PTY cursor mode is unknown (#51490) (thanks @liuy)
* fix(process): auto-detect PTY cursor key mode for send-keys

When a PTY session sends smkx (\x1b[?1h) or rmkx (\x1b[?1l) to switch
cursor key mode, send-keys now detects this and encodes cursor keys
accordingly.

- smkx/rmkx detection in handleStdout before sanitizeBinaryOutput
- cursorKeyMode stored in ProcessSession
- encodeKeySequence accepts cursorKeyMode parameter
- DECCKM_SS3_KEYS for application mode (arrows + home/end)
- CSI sequences for normal mode
- Modified keys (including alt) always use xterm modifier scheme
- Extract detectCursorKeyMode for unit testing
- Use lastIndexOf to find last toggle in chunk (later one wins)

Fixes #51488

* fix: fail loud when PTY cursor mode is unknown (#51490) (thanks @liuy)

* style: format process send-keys guard (#51490) (thanks @liuy)

---------

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-25 15:51:27 +05:30
w-sss
247f82119c fix: improve Telegram 403 membership delivery errors (#53635) (thanks @w-sss)
* fix(telegram): improve error messages for 403 bot not member errors

- Detect 403 'bot is not a member' errors specifically
- Provide actionable guidance for users to fix the issue
- Fixes #48273 where outbound sendMessage fails with 403

Root cause:
When a Telegram bot tries to send a message to a channel/group it's not
a member of, the API returns 403 'bot is not a member of the channel chat'.
The error message was not clear about how to fix this.

Fix:
1. Detect 403 errors in wrapTelegramChatNotFoundError
2. Provide clear error message explaining the issue
3. Suggest adding the bot to the channel/group

* fix(telegram): fix regex precedence for 403 error detection

- Group alternatives correctly: /403.*(bot.*not.*member|bot was blocked)/i
- Require 403 for both alternatives (previously bot.*blocked matched any error)
- Update error message to cover both scenarios
- Fixes Greptile review feedback

* fix(telegram): correct regex alternation precedence for 403 errors

- Fix: /403.*(bot.*not.*member|bot was blocked)/ → /403.*(bot.*not.*member|bot.*blocked)/
- Ensures 403 requirement applies to both alternatives
- Fixes Greptile review comment on PR #48650

* fix(telegram): add 'bot was kicked' to 403 error regex and message

* fix(telegram): preserve membership delivery errors

* fix: improve Telegram 403 membership delivery errors (#53635) (thanks @w-sss)

---------

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-25 10:59:29 +05:30
Josh Avant
10161c2d79 Plugins: enforce terminal hook decision semantics for tool/message guards (#54241)
* Plugins: enforce terminal hook decision policies

* Tests: assert terminal hook behavior in integration paths

* Docs: clarify terminal hook decision semantics

* Docs: add hook guard semantics to plugin guides

* Tests: isolate outbound format label expectations

* changelog

Signed-off-by: joshavant <830519+joshavant@users.noreply.github.com>

---------

Signed-off-by: joshavant <830519+joshavant@users.noreply.github.com>
2026-03-25 00:11:13 -05:00
dongdong
5a5c5d4cde fix: refresh DeepSeek pricing to current V3.2 rates (#54143) (thanks @arkyu2077)
* fix: add actual DeepSeek API pricing to model catalog

Replace zero-cost placeholder with real pricing from DeepSeek docs:
- deepseek-chat (V3): /bin/bash.27/1M input, .10/1M output, /bin/bash.07 cache read
- deepseek-reasoner (R1): /bin/bash.55/1M input, .19/1M output, /bin/bash.14 cache read

Fixes #54134

* fix: refresh DeepSeek pricing to current V3.2 rates

* fix: refresh DeepSeek pricing to current V3.2 rates (#54143) (thanks @arkyu2077)

---------

Co-authored-by: Jasmine Zhang <jasminezhang@192.168.1.75>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-25 10:34:03 +05:30
kevinten10
c00372e559 fix(agents): correct ClawHub URL in system prompt
Change clawhub.com to clawhub.ai in agent system prompt.
The .com domain is incorrect and doesn't point to the real ClawHub.

Fixes #54154
2026-03-25 10:10:37 +05:30
Tak Hoffman
df58b4f5fb fix: prefer deterministic session id resume targets 2026-03-24 21:18:40 -05:00
Tak Hoffman
9c7823350b feat: add /tools runtime availability view (#54088)
* test(memory): lock qmd status counts regression

* feat: make /tools show what the agent can use right now

* fix: sync web ui slash commands with the shared registry

* feat: add profile and unavailable counts to /tools

* refine: keep /tools focused on available tools

* fix: resolve /tools review regressions

* fix: honor model compat in /tools inventory

* fix: sync generated protocol models for /tools

* fix: restore canonical slash command names

* fix: avoid ci lint drift in google helper exports

* perf: stop computing unused /tools unavailable counts

* docs: clarify /tools runtime behavior
2026-03-24 21:09:51 -05:00
Tak Hoffman
fb04801ed7 fix: enforce sandbox visibility for session_status ids 2026-03-24 21:05:25 -05:00
Tak Hoffman
2c1d16e261 fix: drop spawned visibility list caps 2026-03-24 20:52:05 -05:00
Tak Hoffman
6651511e90 fix: verify exact spawned session visibility 2026-03-24 20:39:00 -05:00
Vincent Koc
2069e124a9 chore(agents): normalize pi embedded runner imports 2026-03-24 18:06:24 -07:00
Vincent Koc
d10669629d feat(gateway): make openai compatibility agent-first 2026-03-24 18:06:24 -07:00
Tak Hoffman
6eaff70b55 fix: ignore moved child rows in subagent announces 2026-03-24 19:47:36 -05:00
Tak Hoffman
e6db1dde45 fix: hide moved subagents from stale command targets 2026-03-24 19:15:47 -05:00
Peter Steinberger
f6205de73a refactor: split feishu helpers and tests 2026-03-24 17:12:25 -07:00
Peter Steinberger
5cdb50abe6 refactor: unify Google Generative AI normalization 2026-03-24 17:09:11 -07:00
Peter Steinberger
561acd1675 test: tighten shared card schema coverage 2026-03-24 17:04:07 -07:00
Tak Hoffman
639706f298 fix: ignore moved child rows in subagent status 2026-03-24 18:57:42 -05:00
Peter Steinberger
d4fda79ff7 fix: add merged message tool schema guardrail (#53715) (thanks @lndyzwdxhs) 2026-03-24 16:53:56 -07:00
Tak Hoffman
e48a0b80a8 fix: ignore moved subagent children on stale parents 2026-03-24 18:46:37 -05:00
Aria
63b0036248 fix: normalize baseUrl for custom Google Generative AI providers
Custom providers using `api: "google-generative-ai"` (e.g. a paid
Google tier) resolved in the model picker but failed at runtime with
HTTP 404 because the base URL lacked the required `/v1beta` path
segment and provider normalization was gated on the provider key
being exactly `"google"`.

Two targeted fixes, both keyed on the semantic `api` field rather
than provider name strings:

1. `models-config.providers.ts` — change the normalization gate from
   `normalizedKey === "google"` to
   `normalizedProvider?.api === "google-generative-ai"` and add
   `normalizeGoogleBaseUrl()` to ensure the canonical `/v1beta` suffix.

2. `pi-embedded-runner/model.ts` — apply
   `normalizeGoogleGenerativeAiBaseUrl()` in three resolution paths
   (`applyConfiguredProviderOverrides`, `buildInlineProviderModels`,
   fallback model construction) so the base URL is corrected at
   runtime regardless of how the model was discovered.

No changes to name-only call sites (`model-selection`,
`live-model-filter`, `model-forward-compat`); those paths are not
required for custom provider resolution and broadening their provider
checks would incorrectly capture unrelated providers like
`google-antigravity`.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 16:42:56 -07:00
Peter Steinberger
6f6468027a refactor: dedupe test and runtime seams 2026-03-24 23:33:30 +00:00
Tak Hoffman
907b5254f6 fix: ignore stale rows in subagent kill cascade 2026-03-24 18:12:48 -05:00