Commit Graph

2390 Commits

Author SHA1 Message Date
scoootscooob 9acb4c8fbc Providers: fix kimi-coding thinking normalization 2026-03-24 10:58:03 -07:00
Vincent Koc f2475a7f70
fix(slack): improve interactive reply parity (#53389)
* fix(slack): improve interactive reply parity

* fix(slack): isolate reply interactions from plugins

* docs(changelog): note slack interactive parity fixes

* fix(slack): preserve preview text for local agent replies

* fix(agent): preserve directive text in local previews
2026-03-24 10:23:10 -07:00
Peter Steinberger 4518f6e820 test: speed up slack and telegram suites 2026-03-24 17:16:25 +00:00
Peter Steinberger b11f4835e2 fix: suppress only recent whatsapp group echoes (#53624) (thanks @w-sss) 2026-03-24 10:10:48 -07:00
w-sss 0d4b47a14e fix(whatsapp): filter fromMe messages in groups to prevent infinite loop (#53386) 2026-03-24 10:10:48 -07:00
Peter Steinberger ba95d43e3c
refactor: split feishu runtime and inspect secret resolution 2026-03-24 10:05:15 -07:00
Peter Steinberger 27448c3113
refactor(msteams): split reply and reflection helpers 2026-03-24 10:02:49 -07:00
Peter Steinberger 9f47892bef
refactor: centralize google API base URL handling 2026-03-24 10:01:22 -07:00
Peter Steinberger e727ad6898
fix(msteams): harden feedback reflection follow-ups 2026-03-24 09:50:04 -07:00
Han Pingtian a1cb302c20 Feishu: avoid CLI startup failure on unresolved SecretRef 2026-03-24 09:47:18 -07:00
Peter Steinberger 27b92f8335 test: speed up google and twitch suites 2026-03-24 16:26:58 +00:00
Peter Steinberger 332d2ebfe8 test: speed up whatsapp and signal suites 2026-03-24 16:26:58 +00:00
Peter Steinberger 5edba12f79 test: speed up discord slack telegram suites 2026-03-24 16:26:58 +00:00
Tak Hoffman 3e9ff16645
fix(discord): avoid bundling pi-ai runtime deps 2026-03-24 11:17:08 -05:00
Peter Steinberger 49ae71fa62 test: speed up signal and whatsapp extension suites 2026-03-24 15:57:16 +00:00
Peter Steinberger 86921b624c test: speed up telegram extension suites 2026-03-24 15:57:16 +00:00
Peter Steinberger a29b9f2c20 test: speed up slack extension suites 2026-03-24 15:57:16 +00:00
Peter Steinberger 1d4db9920d test: speed up discord extension suites 2026-03-24 15:57:16 +00:00
Peter Steinberger 781295c14b refactor: dedupe test and script helpers 2026-03-24 15:48:35 +00:00
David Guttman aa91000a5d
feat(discord): add autoThreadName 'generated' strategy (#43366)
* feat(discord): add autoThreadName 'generated' strategy

Adds async thread title generation for auto-created threads:
- autoThread: boolean - enables/disables auto-threading
- autoThreadName: 'message' | 'generated' - naming strategy
- 'generated' uses LLM to create concise 3-6 word titles
- Includes channel name/description context for better titles
- 10s timeout with graceful fallback

* Discord: support non-key auth for generated thread titles

* Discord: skip fallback auto-thread rename

* Discord: normalize generated thread title first content line

* Discord: split thread title generation helpers

* Discord: tidy thread title generation constants and order

* Discord: use runtime fallback model resolution for thread titles

* Discord: resolve thread-title model aliases

* Discord: fallback thread-title model selection to runtime defaults

* Agents: centralize simple completion runtime

* fix(discord): pass apiKey to complete() for thread title generation

The setRuntimeApiKey approach only works for full agent runs that use
authStorage.getApiKey(). The pi-ai complete() function expects apiKey
directly in options or falls back to env vars — it doesn't read from
authStorage.runtimeOverrides.

Fixes thread title generation for Claude/Anthropic users.

* fix(agents): return exchanged Copilot token from prepareSimpleCompletionModel

The recent thread-title fix (3346ba6) passes prepared.auth.apiKey to
complete(). For github-copilot, this was still the raw GitHub token
rather than the exchanged runtime token, causing auth failures.

Now setRuntimeApiKeyForCompletion returns the resolved token and
prepareSimpleCompletionModel includes it in auth.apiKey, so both the
authStorage path and direct apiKey pass-through work correctly.

* fix(agents): catch auth lookup exceptions in completion model prep

getApiKeyForModel can throw for credential issues (missing profile, etc).
Wrap in try/catch to return { error } for fail-soft handling rather than
propagating rejected promises to callers like thread title generation.

* Discord: strip markdown wrappers from generated thread titles

* Discord/agents: align thread-title model and local no-auth completion headers

* Tests: import fresh modules for mocked thread-title/simple-completion suites

* Agents: apply exchanged Copilot baseUrl in simple completions

* Discord: route thread runtime imports through plugin SDK

* Lockfile: add Discord pi-ai runtime dependency

* Lockfile: regenerate Discord pi-ai runtime dependency entries

* Agents: use published Copilot token runtime module

* Discord: refresh config baseline and lockfile

* Tests: split extension runs by isolation

* Discord: add changelog for generated thread titles (#43366) (thanks @davidguttman)

---------

Co-authored-by: Onur Solmaz <onur@textcortex.com>
Co-authored-by: Onur Solmaz <2453968+osolmaz@users.noreply.github.com>
2026-03-24 16:27:19 +01:00
Peter Steinberger d884676dd2 test: speed up whatsapp and shared test suites 2026-03-24 15:16:18 +00:00
Peter Steinberger 83bb647238 test: speed up telegram extension suites 2026-03-24 15:16:18 +00:00
Peter Steinberger db4572b459 test: speed up slack extension suites 2026-03-24 15:16:18 +00:00
Peter Steinberger 88f49c27a0 test: speed up discord extension suites 2026-03-24 15:16:18 +00:00
Harold Hunt 35de467b1a
Telegram: recover General topic bindings (#53699)
Merged via squash.

Prepared head SHA: 546f0c8134
Co-authored-by: huntharo <5617868+huntharo@users.noreply.github.com>
Co-authored-by: huntharo <5617868+huntharo@users.noreply.github.com>
Reviewed-by: @huntharo
2026-03-24 10:51:26 -04:00
Ayaan Zaidi 0a04ef494d fix: merge explicit reply config overrides onto fresh config 2026-03-24 18:52:04 +05:30
Peter Steinberger 60cd98a841 test: defer slack bolt interop for helper-only suites 2026-03-24 09:34:23 +00:00
Peter Steinberger b1b162fcdb test: harden threaded channel follow-ups 2026-03-24 09:24:29 +00:00
Peter Steinberger 43131dcc08 test: harden threaded shared-worker suites 2026-03-24 08:37:00 +00:00
Peter Steinberger fd0fa97952
refactor: centralize plugin install config policy 2026-03-23 23:07:40 -07:00
Peter Steinberger 0f84aac487 fix: stabilize matrix and teams ci assertions 2026-03-24 05:29:05 +00:00
Tao Xie 0b54b64fe7
fix(feishu): preserve docx block tree order (openclaw#40524)
Verified:
- pnpm install --frozen-lockfile
- pnpm build
- pnpm vitest run extensions/feishu/src/docx.test.ts

Co-authored-by: Tao Xie <7379039+TaoXieSZ@users.noreply.github.com>
2026-03-24 00:28:10 -05:00
Peter Steinberger ec7f564566 fix: clear production dependency advisories 2026-03-24 05:17:34 +00:00
Peter Steinberger ef6821a4ca fix: restore teams sdk adapter contracts 2026-03-24 05:17:34 +00:00
Sid Uppal cd90130877
msteams: implement Teams AI agent UX best practices (#51808)
Migrates the Teams extension from @microsoft/agents-hosting to the official Teams SDK (@microsoft/teams.apps + @microsoft/teams.api) and implements Microsoft's AI UX best practices for Teams agents.

- AI-generated label on all bot messages (Teams native badge + thumbs up/down)
- Streaming responses in 1:1 chats via Teams streaminfo protocol
- Welcome card with configurable prompt starters on bot install
- Feedback with reflective learning (negative feedback triggers background reflection)
- Typing indicators for personal + group chats (disabled for channels)
- Informative status updates (progress bar while LLM processes)
- JWT validation via Teams SDK createServiceTokenValidator
- User-Agent: teams.ts[apps]/<sdk-version> OpenClaw/<version> on outbound requests
- Fix copy-pasted image downloads (smba.trafficmanager.net auth allowlist)
- Pre-parse auth gate (reject unauthenticated requests before body parsing)
- Reflection dispatcher lifecycle fix (prevent leaked dispatchers)
- Colon-safe session filenames (Windows compatibility)
- Cooldown cache eviction (prevent unbounded memory growth)

Closes #51806
2026-03-23 22:03:39 -07:00
sudie-codes 6e970010f7
msteams: add message edit and delete support (#49925)
- Add edit/delete action handlers with toolContext.currentChannelId
  fallback for in-thread edits/deletes without explicit target
- Add editMessageMSTeams/deleteMessageMSTeams to channel runtime
- Add updateActivity/deleteActivity to SendContext and MSTeamsTurnContext
- Extend content param with text/content/message fallback chain
- Update test mocks for new SendContext shape

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 23:42:04 -05:00
sudie-codes 9f5d286caf
msteams: extract structured quote/reply context (#51647)
* msteams: extract structured quote/reply context from Teams HTML attachments

* msteams: address PR #51647 review feedback
2026-03-23 23:41:51 -05:00
Tak Hoffman 8c89d0e7cd
tests: add boundary coverage for media delivery (#53361)
* tests: add boundary coverage for media delivery

* tests: isolate telegram outbound adapter transport

* tests: harden telegram webhook certificate assertion

* tests: fix guardrail false positives on rebased branch
2026-03-23 23:37:34 -05:00
Peter Steinberger 483dc90f05 test: harden linux runtime smoke guards 2026-03-24 03:23:52 +00:00
Peter Steinberger a3f2fbf5a2
refactor: harden extension runtime-api seams 2026-03-23 19:39:20 -07:00
Peter Steinberger d8e77c423a test: isolate line jiti runtime smoke 2026-03-24 02:38:49 +00:00
Peter Steinberger 2be3c996fb test: alias all plugin-sdk subpaths in line smoke 2026-03-24 02:31:59 +00:00
Peter Steinberger d5917d37c5 test: allow line runtime api source fallback 2026-03-24 02:26:17 +00:00
Drickon 715b13547f
fix(line): pre-export clashing symbols to prevent jiti TypeError on startup (#53221)
* fix(line): pre-export clashing symbols to prevent jiti TypeError on startup

When jiti CJS-transforms extensions/line/runtime-api.ts, both
export * from "openclaw/plugin-sdk/line-runtime" and the subsequent
export * from individual source files attempt to define the same 13
symbols via Object.defineProperty with configurable:false. The second
call throws TypeError: Cannot redefine property.

The root cause is that src/plugin-sdk/line-runtime.ts re-exports
these symbols directly from the extension source files, creating a
circular path back to the same files that runtime-api.ts star-exports.

Fix: add named pre-exports for all symbols that plugin-sdk/line-runtime
re-exports from this extension. Named exports register in jiti's
_exportNames map at transform time; the star re-export's hasOwnProperty
guard then skips them, preventing the duplicate Object.defineProperty.

export * reordering cannot fix this: _exportNames is only populated
by named exports, not by export *, so the guard never fires regardless
of order.

This is the same class of bug as the Matrix plugin crash described in
issues #50868, #52780, and #52891, and uses the same fix pattern as
PR #50919.

* test: add LINE runtime-api Jiti regression (#53221) (thanks @Drickon)

* test: stabilize LINE Jiti regression (#53221) (thanks @Drickon)

* test: harden LINE Jiti regression (#53221) (thanks @Drickon)

* chore: retrigger PR checks (#53221)

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-03-23 19:13:25 -07:00
Vincent Koc 19295994f3 fix(ci): stabilize whatsapp extension checks 2026-03-23 15:50:19 -07:00
Vincent Koc 6f5df14308 test(whatsapp): preserve harness session exports 2026-03-23 15:50:19 -07:00
Vincent Koc 7b03502175 test(whatsapp): preserve media test module exports 2026-03-23 15:50:19 -07:00
Vincent Koc e87a64f8d0 test(whatsapp): preserve session exports in login coverage 2026-03-23 15:50:19 -07:00
Vincent Koc dad6018230 test(whatsapp): stabilize login coverage in shared workers 2026-03-23 15:50:19 -07:00
George Zhang ade0182ae0
feat(modelstudio): add standard (pay-as-you-go) DashScope endpoints for Qwen (#43878)
Add Standard API Key auth methods for China (dashscope.aliyuncs.com)
and Global/Intl (dashscope-intl.aliyuncs.com) pay-as-you-go endpoints
alongside the existing Coding Plan (subscription) endpoints.

Also updates group label to 'Qwen (Alibaba Cloud Model Studio)' and
fixes glm-4.7 -> glm-5 in Coding Plan note messages.

Co-authored-by: wenmeng zhou <wenmengzhou@users.noreply.github.com>
2026-03-23 14:35:19 -07:00