Commit Graph

411 Commits

Author SHA1 Message Date
huanghuoguoguo cfa7c7b336 fix(tools): support skill mount root discovery 2026-07-19 22:46:01 +08:00
huanghuoguoguo 9f28d6949a fix(agent-runner): unify streamed completion delivery 2026-07-19 22:46:01 +08:00
huanghuoguoguo 8a7c3fcefe fix(agent-runner): aggregate non-streaming replies 2026-07-19 22:46:01 +08:00
huanghuoguoguo 54c872b74f fix(agent-runner): close sandbox skill authoring flow 2026-07-19 22:46:01 +08:00
huanghuoguoguo c55be79f9f fix(agent-runner): prepare local runner functional tests 2026-07-19 22:46:01 +08:00
huanghuoguoguo 1af106aa92 fix(agent-runner): validate clean marketplace onboarding 2026-07-19 22:46:01 +08:00
huanghuoguoguo d88d05e27c feat(agent-runner): enforce 4.x host-owned execution 2026-07-19 22:46:01 +08:00
huanghuoguoguo 9aa71d54e3 feat(agent-runner): finalize 4.x processor integration 2026-07-19 22:45:15 +08:00
huanghuoguoguo 0c0f5d8061 feat(wizard): start bot setup from scenarios 2026-07-19 22:44:08 +08:00
huanghuoguoguo 00fb6f8236 feat(agent-platform): productize bot event route testing 2026-07-19 22:44:08 +08:00
huanghuoguoguo 4cbb9415bf feat(agent-platform): show bot route runtime status 2026-07-19 22:44:08 +08:00
huanghuoguoguo ee11e97e86 feat(agent-platform): add bot route dry-run 2026-07-19 22:44:08 +08:00
Junyan Qin 7fb393b85b refactor: consolidate bot event routing 2026-07-19 22:44:07 +08:00
huanghuoguoguo 662627142e test(agent-runner): strengthen local agent e2e gate 2026-07-19 22:42:40 +08:00
Junyan Qin 1eef5d2344 fix: remove internal adapter terminology from UI 2026-07-19 22:42:40 +08:00
Junyan Qin 427e8b2873 fix: stabilize 4.11 branch runtime state 2026-07-19 22:42:40 +08:00
wangcham 84b3485e7e fix(platform): align eba event declarations 2026-07-19 22:41:31 +08:00
huanghuoguoguo b29ff78d7b fix(debug-chat): preserve websocket pipeline routing 2026-07-19 22:41:31 +08:00
huanghuoguoguo 517986bd10 feat(agent-runner): support scoped token counting 2026-07-19 22:41:31 +08:00
Junyan Qin 68d43834bd fix(adapters): add categories to telegram EBA manifest
The Telegram (EBA) manifest was missing spec.categories, so it fell
into the uncategorized/protocol bucket. Restore popular + global to
match the legacy telegram adapter.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-19 22:41:30 +08:00
Junyan Qin 9044f2d747 feat(adapters): mark EBA-superseded adapters as legacy and collapse them
The 12 old adapters that now have an EBA replacement are tagged
`spec.legacy: true` in their source manifests. Principle: don't delete,
de-emphasize.

- sources/*.yaml (aiocqhttp, dingtalk, discord, kook, lark,
  officialaccount, qqofficial, slack, telegram, wecom, wecombot,
  wecomcs): add spec.legacy: true
- Adapter / IChooseAdapterEntity types: add optional legacy flag
- BotForm adapter Select: split legacy adapters into a collapsed,
  grayscale group at the bottom with an explanatory hint; auto-expand
  when the bot already uses a legacy adapter
- Wizard platform picker: same collapsed legacy section
- i18n: legacyAdapters / legacyAdaptersHint (zh-Hans, en-US)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-19 22:41:30 +08:00
Junyan Qin 7d801cfb68 feat(eba): consolidate event bindings, fix command.tsx pointer-events
- Replace legacy pipeline binding card + RoutingRulesEditor with unified
  EventBindingsEditor; remove use_pipeline_uuid/pipeline_routing_rules
  from bot form schema and API update handler
- Add _augment_event_data() to botmgr for filter virtual fields
  (message_text, message_element_types, chat_type)
- Add alembic migration 0009: migrate use_pipeline_uuid and
  pipeline_routing_rules into event_bindings on first run
- Fix command.tsx: data-[disabled] -> data-[disabled=true] so cmdk 1.x
  items (data-disabled=false) are not pointer-events:none
- EventBindingsEditor: onSelect on CommandItems, filter conditions panel,
  disabled bindings section, dnd reorder
- i18n: add filter/condition keys for zh-Hans and en-US
- Update tests to match new bot service behavior

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-19 22:41:30 +08:00
huanghuoguoguo 5bda2167bd test(agent): cover pluginized agent runner runtime 2026-07-19 22:41:30 +08:00
Junyan Qin 27b43c1731 feat(agent): add event orchestration surface 2026-07-19 22:41:30 +08:00
huanghuoguoguo a64fb976c3 refactor(tools): unify tool-detail normalization in ToolManager
Drop the PluginToolLoader.get_tool() override that returned a raw
ComponentManifest, so every loader's get_tool() now returns a uniform
resource_tool.LLMTool (PluginToolLoader.get_tools() already did this
conversion). This removes the only source of tool-shape heterogeneity.

- ToolManager.get_tool_schema(): drop the ComponentManifest-vs-LLMTool branch
- ToolManager.get_tool_detail(): new host-level shape {name, description,
  human_desc, parameters}
- handler.py GET_TOOL_DETAIL: call tool_mgr.get_tool_detail(); delete the
  handler-local _build_tool_detail + _i18n_to_dict/_i18n_to_text adapters and
  the litellm TODO
- ToolLookupResult is now just LLMTool

The dropped label/spec fields were not consumed by any runner (local-agent
build_llm_tool and external harnesses use only name/description/parameters).
2026-07-19 22:41:30 +08:00
huanghuoguoguo ae0faa425a refactor(plugin): split agent-runner action handlers out of handler.py
Extract the AgentRunner Protocol v1 host-side surface from the giant
RuntimeConnectionHandler.__init__ into sibling modules using a registration-
function pattern (behavior-preserving; @h.action == @self.action):

- agent_run_support.py: shared constants + authorization/scope/projection helpers
- agent_pull_actions.py: register(h) for history/event pull APIs
- agent_runner_actions.py: register(h) for run/runtime/stats/claim lifecycle
- agent_state_actions.py: register(h) for steering/state APIs

__init__ now calls the three register(self) functions. handler.py keeps the
pre-existing plugin/llm/vector/knowledge handlers, get_prompt/call_tool/
get_tool_detail (coupled to retained helpers), shared helpers, and outbound
methods; it re-imports _validate_agent_run_session so external imports keep
working. handler.py: 4066 -> 1871 lines.

test_state_api_auth.py: repoint get_session_registry patch targets to
agent_run_support (the lookup moved modules). 385 agent unit tests pass; ruff clean.
2026-07-19 22:41:30 +08:00
huanghuoguoguo 5f65f962c5 feat(skill): unify skill activation as authorized tools
Expose skill tools (activate/register_skill/native exec) like native tools
instead of gating them behind the skill_authoring capability:
- toolmgr.get_all_tools drops include_skill_authoring; SkillToolLoader
  self-gates on sandbox + skill_mgr
- preproc drops the include_skill_authoring branch; pipeline-bound skills
  and the skills resource gate on skill_mgr presence

Persist activated skills into host.activated_skills conversation state so
they survive across runs (host writes at activate; last-write-wins); drop
the dead restore_activated_skills helper.

Prefill ToolResource.parameters host-side (tool_mgr.get_tool_schema) so
runners build LLM tools without per-tool get_tool_detail round-trips.

Align agent-runner-pluginization design docs to the all-tool model.
2026-07-19 22:41:30 +08:00
huanghuoguoguo cb9930c9e4 feat(agent-runner): add plugin runner host integration 2026-07-19 22:41:30 +08:00
wangcham 1167d9e951 feat(kook): add eba adapter 2026-07-19 22:40:16 +08:00
WangCham 7b2698f476 feat(platform): add slack eba adapter 2026-07-19 22:40:16 +08:00
WangCham adfd88e477 feat(platform): add qqofficial eba adapter 2026-07-19 22:40:16 +08:00
WangCham 67e2d19459 feat(officialaccount): add eba adapter 2026-07-19 22:40:16 +08:00
WangCham 377d96ea4f feat(platform): add wecom customer service eba adapter 2026-07-19 22:40:16 +08:00
WangCham 1caabd4193 feat(platform): add wecom eba adapters 2026-07-19 22:40:16 +08:00
Junyan Qin 1919733daf feat(platform): add lark eba adapter 2026-07-19 22:39:15 +08:00
Junyan Qin 9161ed6ae2 feat(platform): add dingtalk eba adapter 2026-07-19 22:39:15 +08:00
Junyan Qin f105343efe feat: complete eba adapter acceptance path 2026-07-19 22:38:10 +08:00
Junyan Qin 3f7a97e541 feat: migrate aiocqhttp adapter to eba 2026-07-19 22:38:10 +08:00
Junyan Qin e04c8b65a5 feat: add discord eba adapter 2026-07-19 22:38:10 +08:00
Junyan Qin 7a12f93019 test: expand telegram eba api coverage 2026-07-19 22:38:10 +08:00
Junyan Qin 6c7d3cd204 feat: route telegram eba events to plugins 2026-07-19 22:38:10 +08:00
Junyan Qin 11d721d255 fix: handle telegram eba non-message updates 2026-07-19 22:38:10 +08:00
RockChinQ 1d40c9b995 refactor: improve component loading logic and add resource directory check 2026-07-19 22:38:10 +08:00
RockChinQ 45679a4629 feat: Telegram EBA adapter - full implementation
- TelegramAdapter inherits AbstractPlatformAdapter with all capabilities
- TelegramEventConverter handles all Update types: message, edited_message,
  chat_member, my_chat_member, callback_query, message_reaction
- TelegramAPIMixin implements: edit_message, delete_message, forward_message,
  get_group_info, get_group_member_list/info, get_user_info, get_file_url,
  mute/unmute/kick_member, leave_group
- PLATFORM_API_MAP for call_platform_api: pin/unpin message, set chat title/desc,
  get admins, send chat action, create invite link, answer callback query
- Full backward compat: legacy FriendMessage/GroupMessage listeners still work
- Preserves all existing functionality: stream output, markdown card, forum topics
- Old sources/telegram.py untouched for gradual migration
2026-07-19 22:38:09 +08:00
Hyu 48952206db fix(lark): keep connection lookup off event loop
Move the Lark SDK synchronous connection URL lookup off the main asyncio loop, serialize reconnects, and cover the incident with a non-blocking regression test.
2026-07-15 19:53:48 +08:00
hedging8563 e5f0ffd960 feat(provider): add TokenLab requester (#2326) 2026-07-15 18:10:05 +08:00
advancer-young c7720b126d fix(mcp): reconnect session when timeout (#2340) (#2340)
Co-authored-by: yang.xiang <yang.xiang@advancegroup.com>
2026-07-15 18:09:47 +08:00
advancer-young 1d15798e5f feat(lark): support render markdown table in lark message (#2338) (#2338)
Co-authored-by: yang.xiang <yang.xiang@advancegroup.com>
2026-07-15 18:09:16 +08:00
WierJZ bd87bb453c fix(dingtalk): avoid blocking event loop on connection open (#2337) 2026-07-15 18:04:42 +08:00
DongXiaoming c53b800267 fix(provider): strip think tags for MiniMax-M3 and other OpenAI-compatible models (#2330)
* fix(provider): strip think tags for MiniMax-M3 and other OpenAI-compatible models

MiniMax-M3 (and other OpenAI-compatible providers) emit chain-of-thought
reasoning directly in the content field wrapped in  tags, instead
of using a separate reasoning_content field or the legacy CRETIRE_REASONING
markers. The existing remove_think logic only handled CRETIRE_* tags, so
think blocks leaked into user-visible output even when remove_think was enabled.

- Add _ThinkStripState: a stateful filter that correctly handles  tags
  split across streaming chunk boundaries.
- Add _strip_think classmethod with regex patterns for both  and
  CRETIRE_* tags.
- Wire think_state into invoke_llm_stream so deltas are filtered before
  reaching the accumulator.
- Add remove_think safety net in _StreamAccumulator so the final message
  from tool-call rounds also gets stripped.
- Fix remove_think resolution to use defensive nested .get() so
  pipelines missing output.misc don't raise AttributeError.

* fix(litellmchat): add missing _CLOSE_TAG class attribute on _ThinkStripState

* fix(provider): handle think stripping across LiteLLM paths

---------

Co-authored-by: WangCham <651122857@qq.com>
2026-07-15 10:54:41 +08:00