Commit Graph

2221 Commits

Author SHA1 Message Date
Peter Steinberger
f64e4fd8cf test: split agents vitest shards 2026-04-28 02:58:24 +01:00
Peter Steinberger
fe1c7fae99 test: catch transitive gateway cold imports 2026-04-28 02:58:06 +01:00
Peter Steinberger
1945389374 test: expose provider media test helpers 2026-04-28 02:52:30 +01:00
Peter Steinberger
7f3dead335 perf: keep gateway cold paths out of startup 2026-04-28 02:50:32 +01:00
Peter Steinberger
152b9856eb test(ci): update support boundary expectations 2026-04-28 02:38:31 +01:00
Peter Steinberger
7d4da9c610 fix(plugins): ignore inherited npm dry-run for runtime deps 2026-04-28 02:36:48 +01:00
Peter Steinberger
43a73d6a31 refactor: separate bundled channel schema surface 2026-04-28 02:31:21 +01:00
Peter Steinberger
d35ada2f54 refactor: relocate channel contract helpers 2026-04-28 02:14:08 +01:00
Peter Steinberger
4e63f710f1 fix(ci): restore plugin install and tooling checks 2026-04-28 02:09:28 +01:00
Peter Steinberger
dc4512ad0c refactor: split channel target test helpers 2026-04-28 02:03:15 +01:00
Peter Steinberger
75e126ef6a perf: improve gateway startup diagnostics 2026-04-28 01:48:00 +01:00
Peter Steinberger
45a84b5f95 refactor: expose channel contract test helpers 2026-04-28 01:45:58 +01:00
Peter Steinberger
56875c4d32 refactor: split generic plugin test fixtures 2026-04-28 01:21:39 +01:00
Peter Steinberger
f34b41f198 refactor: split plugin sdk test helpers 2026-04-28 01:14:19 +01:00
Peter Steinberger
e27c32b9b0 refactor(plugin-sdk): publish route helpers 2026-04-28 01:13:01 +01:00
Peter Steinberger
0294aebe6f feat(providers): add DeepInfra provider plugin (#73038)
* feat(providers): add DeepInfra provider plugin

* feat(deepinfra): add media provider surfaces

* fix(deepinfra): satisfy provider boundary checks

* docs: add gitcrawl maintainer skill

* test: include deepinfra in live media sweeps

* fix: remove stale tts contract import
2026-04-28 01:12:54 +01:00
Peter Steinberger
8057561cee refactor: promote plugin test helpers to sdk 2026-04-28 00:55:11 +01:00
Peter Steinberger
49d069cd94 test: distinguish release live shard partitions 2026-04-28 00:54:28 +01:00
Peter Steinberger
b90f29d313 ci: split native live release shards 2026-04-28 00:49:10 +01:00
Peter Steinberger
90b6665ded refactor: move plugin api test helper to sdk 2026-04-28 00:24:54 +01:00
Peter Steinberger
f71f5bc586 fix: repair packaged plugin runtime mirrors 2026-04-28 00:23:38 +01:00
Peter Steinberger
0df6e5a473 refactor: expose plugin test helpers via sdk 2026-04-27 23:45:26 +01:00
Olamiposi
c51e315f3a docs: clarify messaging vs full tool profiles (#39954)
* docs: clarify messaging vs full tool profiles

* docs: normalize tools.profile references

* docs: clarify messaging and full tool profiles

---------

Co-authored-by: vincentkoc <25068+vincentkoc@users.noreply.github.com>
2026-04-27 15:44:17 -07:00
neilofneils404
482ff924ef fix: pass directories to provider stream wrappers (#67843)
* fix: pass directories to provider stream wrappers

* fix: pass directories to provider stream wrappers

---------

Co-authored-by: neilofneils404 <258699186+neilofneils404@users.noreply.github.com>
Co-authored-by: vincentkoc <25068+vincentkoc@users.noreply.github.com>
2026-04-27 15:43:38 -07:00
Peter Steinberger
39e3d8d31d ci: shard release validation reruns 2026-04-27 23:38:13 +01:00
Peter Steinberger
bf4306d1b0 refactor: route plugin test helpers through sdk 2026-04-27 23:12:21 +01:00
Peter Steinberger
d7dcd0e21e test: stabilize release validation lanes 2026-04-27 23:00:45 +01:00
Peter Steinberger
8599fdda4a test: keep extension mocks on sdk seams 2026-04-27 22:55:09 +01:00
Peter Steinberger
46ba8e7cce feat(plugin-sdk): expose extension test seams 2026-04-27 22:34:21 +01:00
Peter Steinberger
662de55e07 refactor: expose extension sdk boundary seams 2026-04-27 21:58:48 +01:00
Peter Steinberger
f2ba8ca927 test: stabilize bundled channel docker smoke 2026-04-27 21:48:26 +01:00
Peter Steinberger
59faa023fe fix(gateway): unblock sidecar startup 2026-04-27 21:34:44 +01:00
Peter Steinberger
08e7561972 ci: broaden extension boundary guards 2026-04-27 21:02:53 +01:00
Peter Steinberger
f0000ab72d refactor(plugin-sdk): split infra runtime barrel 2026-04-27 20:50:35 +01:00
Peter Steinberger
9645fe72c6 test: harden release validation live shards 2026-04-27 20:45:25 +01:00
Peter Steinberger
31e529f000 ci: guard extension wildcard reexports 2026-04-27 20:34:35 +01:00
Peter Steinberger
54e13d4910 ci: split release validation slow shards 2026-04-27 20:30:17 +01:00
Vincent Koc
d0be08a9a4 fix(github): action manual Barnacle triage labels
Human-applied Barnacle triage candidate labels now trigger the intended auto-response while bot-applied heuristic candidates remain passive.
2026-04-27 11:44:47 -07:00
Vincent Koc
1497425b8d fix(gateway): trim startup config imports 2026-04-27 11:34:24 -07:00
Peter Steinberger
8f8ba8af40 test: harden live release validation flakes 2026-04-27 18:32:31 +01:00
Peter Steinberger
04b5dd097d test: skip bootstrap in release validation onboarding 2026-04-27 17:01:52 +01:00
Peter Steinberger
56fa69a48a fix(ci): pin yuanbao official channel catalog source 2026-04-27 16:28:56 +01:00
Peter Steinberger
32bbb5b18f test: harden release validation smokes 2026-04-27 16:28:44 +01:00
cxy
5ccf179a34 feat(qqbot): group chat support, C2C streaming, chunked media upload, and architecture refactor (#70624)
* feat(qqbot): implement unified media upload handling and introduce chunked upload support

This commit enhances the media upload functionality by introducing a unified `sendMedia` method that consolidates the previous separate methods for sending images, voice messages, videos, and files. Key changes include:

- Added `uploadChunked` function for future chunked media uploads, currently marked as not implemented.
- Introduced `MediaSource` abstraction to handle various media types (URLs, base64, local files, buffers) uniformly.
- Updated existing media handling logic to utilize the new `sendMedia` method, ensuring consistent media processing across different types.
- Enhanced error handling and validation for media uploads, including MIME type checks and file size limits.

These changes aim to streamline the media upload process and prepare for future enhancements in handling larger files through chunked uploads.

* feat(qqbot): enhance media upload capabilities with chunked upload support

This commit updates the media upload functionality by implementing chunked upload support for larger files. Key changes include:

- Revised the `SKILL.md` documentation to clarify media file size limits and local file path requirements.
- Introduced a new test suite for the chunked media upload functionality, ensuring robust error handling and upload processes.
- Updated the media handling logic to enforce per-file-type upload ceilings, allowing for seamless integration of chunked uploads.
- Enhanced error handling for daily upload limits, providing user-friendly messages when limits are exceeded.

These improvements aim to streamline the media upload process and accommodate larger files effectively.

* feat(qqbot): add C2C streaming API support for message delivery

This commit introduces support for the QQ C2C official `stream_messages` API, enabling single-message typing-style updates. Key changes include:

- Updated the configuration schema to include a new `c2cStreamApi` boolean option for enabling the C2C streaming API.
- Enhanced the `QQBotAccountConfig` interface to accommodate the new streaming option.
- Implemented a `StreamingController` to manage the lifecycle of C2C stream messages, ensuring proper handling of media tags and message boundaries.
- Updated the outbound dispatch logic to utilize the new streaming capabilities, allowing for more dynamic message delivery in one-to-one chats.

These enhancements aim to improve the responsiveness and interactivity of message delivery within the QQBot framework.

* feat(qqbot): implement group chat support and unify adapter/DI architecture

- Implement group message history tracking with pending history buffer
  (record on skip, render on @-mention reply)
- Add mention detection and gating: explicit @bot, implicit quote-reply,
  ignoreOtherMentions, configurable activation mode (mention/always)
- Add group activation resolution with session store persistence
- Add message queue with per-peer FIFO and group message merging
  (batch multiple rapid messages into one merged payload)
- Add deliver debounce to merge rapid outbound text bursts into
  single messages, with media flush and maxWait cap
- Add group config resolution: per-group prompt, history limit,
  wildcard and specific group overrides
- Enrich history attachments with local paths from processAttachments
  so that history context renders downloaded paths instead of ephemeral
  QQ CDN URLs

- Merge ports/ directory into adapter/ as single entry point
- Expand EngineAdapters to 5 required ports: history, mentionGate,
  audioConvert, outboundAudio, commands
- Remove global register/get singletons in favor of constructor
  injection and one-time init
- Add createEngineAdapters() in bridge/gateway.ts as single assembly point

- Extract monolithic buildInboundContext into 11 discrete stages:
  access, content, quote, refidx, group-gate, envelope, assembly
- Extract group chat modules: history, mention, activation,
  message-gating, deliver-debounce
- Extract config/group.ts, utils/attachment-tags.ts

* feat(qqbot): add /bot-streaming command for C2C message streaming control

This commit introduces the `/bot-streaming` command, allowing users to enable or disable streaming for message delivery in C2C chats. Key changes include:

- Implementation of the `isStreamingConfigEnabled` function to check the current streaming configuration.
- Command handler for `/bot-streaming` that provides usage instructions and manages the streaming state.
- Updates to the command's response messages to inform users of the current streaming status and how to toggle it.

These enhancements aim to improve user experience by providing a straightforward way to manage streaming message delivery in private chats.

* feat(qqbot): extract interaction handler and add remote config query/update support

- Extract INTERACTION_CREATE handler from gateway.ts into a dedicated
  interaction-handler.ts module for better separation of concerns
- Add config query (type=2001) and config update (type=2002) interaction
  branches that read/write claw_cfg via runtime.config API
- Register INTERACTION intent (1<<26) in FULL_INTENTS to receive
  INTERACTION_CREATE events from the gateway
- Add InteractionType constants (CONFIG_QUERY, CONFIG_UPDATE)
- Extend GatewayPluginRuntime with optional config API (loadConfig,
  writeConfigFile) for interaction handler access
- Add QQBotAccountConfigView interface for typed config field access
- Extend acknowledgeInteraction to accept optional data payload for
  rich ACK responses (e.g. claw_cfg snapshot)
- Export getFrameworkVersion from slash-commands-impl for version
  reporting in config snapshots
- Remove unused eslint-disable directive in streaming-media-send.ts

* feat(qqbot): enhance account management and logging capabilities

- Introduced `toGatewayAccount` function to map resolved QQBot accounts to the engine's gateway account structure.
- Added `persistAccountCredentialSnapshot` function to streamline credential backup during gateway events.
- Updated the `qqbotPlugin` to utilize the new account mapping and credential persistence functions, improving the handling of account data.
- Enhanced logging functionality by modifying the `EngineLogger` interface to support metadata in log messages.
- Implemented new commands for managing logs and clearing storage, providing users with better control over their data and system resources.
- Registered multiple built-in commands for improved user interaction, including `/bot-logs` for exporting logs and `/bot-clear-storage` for managing downloaded files.
- Updated configuration schemas to reflect new options and improve clarity for users.

* fix(qqbot): resolve oxlint errors and update raw-fetch allowlist

- Replace unnecessary `else` after `return` in outbound-media-send.ts (6 occurrences)
- Use `Number.parseInt` instead of global `parseInt` in outbound.ts and streaming-media-send.ts
- Use `Number.isNaN` instead of global `isNaN` in register-basic.ts
- Prefer `**` over `Math.pow` in media-chunked.ts
- Convert interface with call signature to function type in commands.port.ts
- Update api-client.ts allowlist line number (108→124) and add media-chunked.ts:552 to raw-fetch allowlist

* docs(qqbot): translate streaming-c2c.ts header comments to English

* feat(qqbot): add voiceMediaTypes

* feat: restore dispatch changes

* fix(qqbot): align test files with updated engine interfaces after rebase

- inbound-attachments.test: replace removed registerAudioConvertAdapter
  with AudioConvertPort, pass audioConvert in ProcessContext
- inbound-pipeline.self-echo.test: add required adapters field to
  InboundPipelineDeps mock (history, mentionGate, audioConvert,
  outboundAudio, commands)
- outbound-dispatch.test: add required skipped field to InboundContext

* fix(qqbot): update test assertions to match refactored engine interfaces

- inbound-pipeline.self-echo.test: self-echo blocking was moved upstream;
  update test to expect non-blocked pipeline behavior
- outbound-dispatch.test: TTS voice path now uses unified sendMedia
  instead of sendVoiceMessage; add sendMedia mock and update assertion
- format-ref-entry.test: attachment format changed from [image: ...]
  to MEDIA: tag syntax via renderAttachmentTags; update expected output

* refactor(qqbot): migrate from deprecated config API to current/replaceConfigFile

Replace all usages of deprecated runtime config methods:
- loadConfig() → current()
- writeConfigFile(cfg) → replaceConfigFile({ nextConfig, afterWrite })

Updated files:
- bridge/narrowing.ts: writeOpenClawConfigThroughRuntime
- adapter/commands.port.ts: ApproveRuntimeGetter type signature
- commands/builtin/register-approve.ts: loadExecConfig, writeExecConfig, reset
- commands/builtin/register-streaming.ts: config read/write
- gateway/interaction-handler.ts: config query/update handlers
- gateway/types.ts: GatewayPluginRuntime.config interface

* feat(qqbot): update package.json

* fix(qqbot): replace deprecated config-runtime import with config-types subpath

Bundled plugin lint requires focused plugin-sdk subpaths.
- gateway.ts: openclaw/plugin-sdk/config-runtime → config-types
- narrowing.ts: openclaw/plugin-sdk/config-runtime → config-types

* feat(qqbot): group chat support, C2C streaming, chunked media upload, and architecture refactor (#70624) (thanks @cxyhhhhh)

---------

Co-authored-by: Bobby <zkd8907@live.com>
Co-authored-by: sliverp <870080352@qq.com>
2026-04-27 23:19:12 +08:00
loongfay
3120401f53 feat(channel) yuanbao (#72756)
* feat(channel) yuanbao

* feat(channel) yuanbao

* docs(changelog): note Yuanbao channel plugin (#72756) (thanks @loongfay)

---------

Co-authored-by: loongzhao <loongzhao@tencent.com>
Co-authored-by: sliverp <870080352@qq.com>
2026-04-27 23:04:33 +08:00
Peter Steinberger
9090457da7 test(plugin-sdk): use narrow config runtime mocks 2026-04-27 15:14:02 +01:00
Peter Steinberger
4336a7f3a9 refactor(plugin-sdk): narrow config runtime imports 2026-04-27 14:58:32 +01:00
Peter Steinberger
1ed6d04014 ci: guard plugin sdk wildcard reexports 2026-04-27 14:52:21 +01:00
Peter Steinberger
0f996ad4b0 ci: enforce changelog attribution policy in pr gates 2026-04-27 14:33:59 +01:00
Peter Steinberger
6ced6bc4a3 ci: satisfy live shard lint 2026-04-27 14:29:41 +01:00