@zhin.js/agent 0.1.31 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +42 -2
- package/lib/builtin/memory-search-tool.d.ts +2 -0
- package/lib/builtin/memory-search-tool.d.ts.map +1 -0
- package/lib/builtin/memory-search-tool.js +61 -0
- package/lib/builtin/memory-search-tool.js.map +1 -0
- package/lib/builtin/memory-upsert-tool.d.ts +2 -0
- package/lib/builtin/memory-upsert-tool.d.ts.map +1 -0
- package/lib/builtin/memory-upsert-tool.js +75 -0
- package/lib/builtin/memory-upsert-tool.js.map +1 -0
- package/lib/builtin/orchestration-tools.d.ts +7 -0
- package/lib/builtin/orchestration-tools.d.ts.map +1 -0
- package/lib/builtin/orchestration-tools.js +283 -0
- package/lib/builtin/orchestration-tools.js.map +1 -0
- package/lib/builtin/run-deferred-task-tool.d.ts +1 -1
- package/lib/builtin/run-deferred-task-tool.d.ts.map +1 -1
- package/lib/builtin/run-deferred-task-tool.js +1 -1
- package/lib/builtin/run-deferred-task-tool.js.map +1 -1
- package/lib/builtin/run-spec-dry-run-tool.d.ts +6 -0
- package/lib/builtin/run-spec-dry-run-tool.d.ts.map +1 -0
- package/lib/builtin/run-spec-dry-run-tool.js +51 -0
- package/lib/builtin/run-spec-dry-run-tool.js.map +1 -0
- package/lib/builtin/run-validation-spec-tool.d.ts +8 -0
- package/lib/builtin/run-validation-spec-tool.d.ts.map +1 -0
- package/lib/builtin/run-validation-spec-tool.js +44 -0
- package/lib/builtin/run-validation-spec-tool.js.map +1 -0
- package/lib/builtin/spawn-task-tool.d.ts +1 -1
- package/lib/builtin/spawn-task-tool.d.ts.map +1 -1
- package/lib/builtin/spawn-task-tool.js +53 -1
- package/lib/builtin/spawn-task-tool.js.map +1 -1
- package/lib/builtin-tools.d.ts +2 -0
- package/lib/builtin-tools.d.ts.map +1 -1
- package/lib/builtin-tools.js +6 -0
- package/lib/builtin-tools.js.map +1 -1
- package/lib/create-agent-session.d.ts +16 -0
- package/lib/create-agent-session.d.ts.map +1 -0
- package/lib/create-agent-session.js +15 -0
- package/lib/create-agent-session.js.map +1 -0
- package/lib/discovery/agents.d.ts +5 -0
- package/lib/discovery/agents.d.ts.map +1 -1
- package/lib/discovery/agents.js +7 -0
- package/lib/discovery/agents.js.map +1 -1
- package/lib/discovery/skills.d.ts +1 -1
- package/lib/discovery/skills.d.ts.map +1 -1
- package/lib/discovery/skills.js +2 -9
- package/lib/discovery/skills.js.map +1 -1
- package/lib/discovery/utils.d.ts +7 -1
- package/lib/discovery/utils.d.ts.map +1 -1
- package/lib/discovery/utils.js +66 -5
- package/lib/discovery/utils.js.map +1 -1
- package/lib/index.d.ts +17 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +11 -1
- package/lib/index.js.map +1 -1
- package/lib/init/activate-ai-database-storage.d.ts.map +1 -1
- package/lib/init/activate-ai-database-storage.js +23 -1
- package/lib/init/activate-ai-database-storage.js.map +1 -1
- package/lib/init/create-zhin-agent.d.ts.map +1 -1
- package/lib/init/create-zhin-agent.js +69 -7
- package/lib/init/create-zhin-agent.js.map +1 -1
- package/lib/init/introspection-args.d.ts +34 -0
- package/lib/init/introspection-args.d.ts.map +1 -0
- package/lib/init/introspection-args.js +71 -0
- package/lib/init/introspection-args.js.map +1 -0
- package/lib/init/introspection-collectors.d.ts +21 -0
- package/lib/init/introspection-collectors.d.ts.map +1 -0
- package/lib/init/introspection-collectors.js +74 -0
- package/lib/init/introspection-collectors.js.map +1 -0
- package/lib/init/introspection-commands-format.d.ts +1 -1
- package/lib/init/introspection-commands-format.js +4 -4
- package/lib/init/introspection-commands-format.js.map +1 -1
- package/lib/init/introspection-output.d.ts +6 -0
- package/lib/init/introspection-output.d.ts.map +1 -0
- package/lib/init/introspection-output.js +52 -0
- package/lib/init/introspection-output.js.map +1 -0
- package/lib/init/introspection-pagination.d.ts +14 -0
- package/lib/init/introspection-pagination.d.ts.map +1 -0
- package/lib/init/introspection-pagination.js +33 -0
- package/lib/init/introspection-pagination.js.map +1 -0
- package/lib/init/introspection-rest.d.ts +24 -0
- package/lib/init/introspection-rest.d.ts.map +1 -0
- package/lib/init/introspection-rest.js +65 -0
- package/lib/init/introspection-rest.js.map +1 -0
- package/lib/init/management-command-guard.d.ts +9 -0
- package/lib/init/management-command-guard.d.ts.map +1 -0
- package/lib/init/management-command-guard.js +20 -0
- package/lib/init/management-command-guard.js.map +1 -0
- package/lib/init/register-agent-mesh-mcp.d.ts +2 -0
- package/lib/init/register-agent-mesh-mcp.d.ts.map +1 -0
- package/lib/init/register-agent-mesh-mcp.js +13 -0
- package/lib/init/register-agent-mesh-mcp.js.map +1 -0
- package/lib/init/register-ai-trigger.d.ts.map +1 -1
- package/lib/init/register-ai-trigger.js +29 -4
- package/lib/init/register-ai-trigger.js.map +1 -1
- package/lib/init/register-builtin-tools.d.ts.map +1 -1
- package/lib/init/register-builtin-tools.js +12 -8
- package/lib/init/register-builtin-tools.js.map +1 -1
- package/lib/init/register-db-models.d.ts.map +1 -1
- package/lib/init/register-db-models.js +5 -2
- package/lib/init/register-db-models.js.map +1 -1
- package/lib/init/register-db-upgrade.d.ts.map +1 -1
- package/lib/init/register-db-upgrade.js +20 -1
- package/lib/init/register-db-upgrade.js.map +1 -1
- package/lib/init/register-group-session-passive.d.ts +3 -0
- package/lib/init/register-group-session-passive.d.ts.map +1 -0
- package/lib/init/register-group-session-passive.js +55 -0
- package/lib/init/register-group-session-passive.js.map +1 -0
- package/lib/init/register-introspection-commands.d.ts.map +1 -1
- package/lib/init/register-introspection-commands.js +14 -7
- package/lib/init/register-introspection-commands.js.map +1 -1
- package/lib/init/register-management-tools.d.ts +1 -1
- package/lib/init/register-management-tools.d.ts.map +1 -1
- package/lib/init/register-management-tools.js +74 -44
- package/lib/init/register-management-tools.js.map +1 -1
- package/lib/init/upgrade-agent-db-schema.d.ts +41 -0
- package/lib/init/upgrade-agent-db-schema.d.ts.map +1 -0
- package/lib/init/upgrade-agent-db-schema.js +170 -0
- package/lib/init/upgrade-agent-db-schema.js.map +1 -0
- package/lib/init.d.ts.map +1 -1
- package/lib/init.js +4 -0
- package/lib/init.js.map +1 -1
- package/lib/mcp-client/connection.d.ts.map +1 -1
- package/lib/mcp-client/connection.js +1 -0
- package/lib/mcp-client/connection.js.map +1 -1
- package/lib/mcp-client/index.d.ts.map +1 -1
- package/lib/mcp-client/index.js +7 -1
- package/lib/mcp-client/index.js.map +1 -1
- package/lib/mcp-server/agent-mesh-tools.d.ts +8 -0
- package/lib/mcp-server/agent-mesh-tools.d.ts.map +1 -0
- package/lib/mcp-server/agent-mesh-tools.js +138 -0
- package/lib/mcp-server/agent-mesh-tools.js.map +1 -0
- package/lib/media/deliver-subagent-result.d.ts +7 -0
- package/lib/media/deliver-subagent-result.d.ts.map +1 -1
- package/lib/media/deliver-subagent-result.js +3 -1
- package/lib/media/deliver-subagent-result.js.map +1 -1
- package/lib/media/media-normalize.d.ts +2 -0
- package/lib/media/media-normalize.d.ts.map +1 -1
- package/lib/media/media-normalize.js +89 -0
- package/lib/media/media-normalize.js.map +1 -1
- package/lib/memory-entry-registry.d.ts +7 -0
- package/lib/memory-entry-registry.d.ts.map +1 -0
- package/lib/memory-entry-registry.js +8 -0
- package/lib/memory-entry-registry.js.map +1 -0
- package/lib/monitoring/metrics.d.ts +16 -0
- package/lib/monitoring/metrics.d.ts.map +1 -1
- package/lib/monitoring/metrics.js +47 -0
- package/lib/monitoring/metrics.js.map +1 -1
- package/lib/orchestration-memory-hook.d.ts +3 -0
- package/lib/orchestration-memory-hook.d.ts.map +1 -0
- package/lib/orchestration-memory-hook.js +22 -0
- package/lib/orchestration-memory-hook.js.map +1 -0
- package/lib/orchestration-runtime-registry.d.ts +14 -0
- package/lib/orchestration-runtime-registry.d.ts.map +1 -0
- package/lib/orchestration-runtime-registry.js +15 -0
- package/lib/orchestration-runtime-registry.js.map +1 -0
- package/lib/orchestrator/agent-dispatcher.d.ts +38 -3
- package/lib/orchestrator/agent-dispatcher.d.ts.map +1 -1
- package/lib/orchestrator/agent-dispatcher.js +209 -13
- package/lib/orchestrator/agent-dispatcher.js.map +1 -1
- package/lib/orchestrator/delegation-processor.d.ts +34 -0
- package/lib/orchestrator/delegation-processor.d.ts.map +1 -0
- package/lib/orchestrator/delegation-processor.js +146 -0
- package/lib/orchestrator/delegation-processor.js.map +1 -0
- package/lib/orchestrator/mission-milestone-notify.d.ts +17 -0
- package/lib/orchestrator/mission-milestone-notify.d.ts.map +1 -0
- package/lib/orchestrator/mission-milestone-notify.js +49 -0
- package/lib/orchestrator/mission-milestone-notify.js.map +1 -0
- package/lib/orchestrator/mission-negotiation.d.ts +17 -0
- package/lib/orchestrator/mission-negotiation.d.ts.map +1 -0
- package/lib/orchestrator/mission-negotiation.js +89 -0
- package/lib/orchestrator/mission-negotiation.js.map +1 -0
- package/lib/orchestrator/mission-patch-acl.d.ts +9 -0
- package/lib/orchestrator/mission-patch-acl.d.ts.map +1 -0
- package/lib/orchestrator/mission-patch-acl.js +29 -0
- package/lib/orchestrator/mission-patch-acl.js.map +1 -0
- package/lib/orchestrator/mission-runner.d.ts +24 -0
- package/lib/orchestrator/mission-runner.d.ts.map +1 -0
- package/lib/orchestrator/mission-runner.js +179 -0
- package/lib/orchestrator/mission-runner.js.map +1 -0
- package/lib/orchestrator/mission-spec.d.ts +44 -0
- package/lib/orchestrator/mission-spec.d.ts.map +1 -0
- package/lib/orchestrator/mission-spec.js +121 -0
- package/lib/orchestrator/mission-spec.js.map +1 -0
- package/lib/orchestrator/mission-state.d.ts +48 -0
- package/lib/orchestrator/mission-state.d.ts.map +1 -0
- package/lib/orchestrator/mission-state.js +66 -0
- package/lib/orchestrator/mission-state.js.map +1 -0
- package/lib/orchestrator/orchestration-repository.d.ts +85 -0
- package/lib/orchestrator/orchestration-repository.d.ts.map +1 -0
- package/lib/orchestrator/orchestration-repository.js +325 -0
- package/lib/orchestrator/orchestration-repository.js.map +1 -0
- package/lib/orchestrator/orchestration-service.d.ts +58 -0
- package/lib/orchestrator/orchestration-service.d.ts.map +1 -0
- package/lib/orchestrator/orchestration-service.js +221 -0
- package/lib/orchestrator/orchestration-service.js.map +1 -0
- package/lib/orchestrator/remote-agent-registry.d.ts +34 -0
- package/lib/orchestrator/remote-agent-registry.d.ts.map +1 -0
- package/lib/orchestrator/remote-agent-registry.js +150 -0
- package/lib/orchestrator/remote-agent-registry.js.map +1 -0
- package/lib/orchestrator/remote-task-executor.d.ts +10 -0
- package/lib/orchestrator/remote-task-executor.d.ts.map +1 -0
- package/lib/orchestrator/remote-task-executor.js +142 -0
- package/lib/orchestrator/remote-task-executor.js.map +1 -0
- package/lib/orchestrator/remote-task-poller.d.ts +17 -0
- package/lib/orchestrator/remote-task-poller.d.ts.map +1 -0
- package/lib/orchestrator/remote-task-poller.js +81 -0
- package/lib/orchestrator/remote-task-poller.js.map +1 -0
- package/lib/orchestrator/task-queue.d.ts +18 -3
- package/lib/orchestrator/task-queue.d.ts.map +1 -1
- package/lib/orchestrator/task-queue.js +52 -6
- package/lib/orchestrator/task-queue.js.map +1 -1
- package/lib/orchestrator/types.d.ts +3 -2
- package/lib/orchestrator/types.d.ts.map +1 -1
- package/lib/plugin-loop-hooks.d.ts +32 -0
- package/lib/plugin-loop-hooks.d.ts.map +1 -0
- package/lib/plugin-loop-hooks.js +69 -0
- package/lib/plugin-loop-hooks.js.map +1 -0
- package/lib/security/anomaly-detection.d.ts +2 -0
- package/lib/security/anomaly-detection.d.ts.map +1 -1
- package/lib/security/anomaly-detection.js +4 -0
- package/lib/security/anomaly-detection.js.map +1 -1
- package/lib/security/audit-logger.d.ts.map +1 -1
- package/lib/security/audit-logger.js +1 -0
- package/lib/security/audit-logger.js.map +1 -1
- package/lib/security/budget-limiter.d.ts +3 -0
- package/lib/security/budget-limiter.d.ts.map +1 -1
- package/lib/security/budget-limiter.js +17 -0
- package/lib/security/budget-limiter.js.map +1 -1
- package/lib/security/file-role-policy.js +1 -1
- package/lib/security/file-role-policy.js.map +1 -1
- package/lib/security/index.d.ts +4 -0
- package/lib/security/index.d.ts.map +1 -1
- package/lib/security/index.js +20 -3
- package/lib/security/index.js.map +1 -1
- package/lib/security/network-policy.d.ts +2 -0
- package/lib/security/network-policy.d.ts.map +1 -1
- package/lib/security/network-policy.js +4 -0
- package/lib/security/network-policy.js.map +1 -1
- package/lib/security/sandbox-enhanced.d.ts +3 -0
- package/lib/security/sandbox-enhanced.d.ts.map +1 -1
- package/lib/security/sandbox-enhanced.js +41 -16
- package/lib/security/sandbox-enhanced.js.map +1 -1
- package/lib/security/sandbox.d.ts +2 -3
- package/lib/security/sandbox.d.ts.map +1 -1
- package/lib/security/sandbox.js +39 -20
- package/lib/security/sandbox.js.map +1 -1
- package/lib/service.d.ts +7 -0
- package/lib/service.d.ts.map +1 -1
- package/lib/service.js +13 -0
- package/lib/service.js.map +1 -1
- package/lib/session-tree-runtime-registry.d.ts +20 -0
- package/lib/session-tree-runtime-registry.d.ts.map +1 -0
- package/lib/session-tree-runtime-registry.js +25 -0
- package/lib/session-tree-runtime-registry.js.map +1 -0
- package/lib/subagent-artifact.d.ts +7 -0
- package/lib/subagent-artifact.d.ts.map +1 -0
- package/lib/subagent-artifact.js +26 -0
- package/lib/subagent-artifact.js.map +1 -0
- package/lib/subagent-parent-context.d.ts +9 -0
- package/lib/subagent-parent-context.d.ts.map +1 -0
- package/lib/subagent-parent-context.js +50 -0
- package/lib/subagent-parent-context.js.map +1 -0
- package/lib/subagent-preset.d.ts +10 -0
- package/lib/subagent-preset.d.ts.map +1 -0
- package/lib/subagent-preset.js +44 -0
- package/lib/subagent-preset.js.map +1 -0
- package/lib/subagent-prompt.d.ts +7 -0
- package/lib/subagent-prompt.d.ts.map +1 -0
- package/lib/subagent-prompt.js +14 -0
- package/lib/subagent-prompt.js.map +1 -0
- package/lib/subagent.d.ts +19 -0
- package/lib/subagent.d.ts.map +1 -1
- package/lib/subagent.js +140 -36
- package/lib/subagent.js.map +1 -1
- package/lib/task-executor.d.ts.map +1 -1
- package/lib/task-executor.js +10 -2
- package/lib/task-executor.js.map +1 -1
- package/lib/typing-indicator/adapter-integration.d.ts +7 -3
- package/lib/typing-indicator/adapter-integration.d.ts.map +1 -1
- package/lib/typing-indicator/adapter-integration.js +30 -6
- package/lib/typing-indicator/adapter-integration.js.map +1 -1
- package/lib/typing-indicator/index.d.ts +28 -3
- package/lib/typing-indicator/index.d.ts.map +1 -1
- package/lib/typing-indicator/index.js +104 -6
- package/lib/typing-indicator/index.js.map +1 -1
- package/lib/typing-indicator/integration.d.ts.map +1 -1
- package/lib/typing-indicator/integration.js +7 -2
- package/lib/typing-indicator/integration.js.map +1 -1
- package/lib/zhin-agent/agent-loop-turn.d.ts +2 -1
- package/lib/zhin-agent/agent-loop-turn.d.ts.map +1 -1
- package/lib/zhin-agent/agent-loop-turn.js +45 -4
- package/lib/zhin-agent/agent-loop-turn.js.map +1 -1
- package/lib/zhin-agent/branch-summarization-runtime.d.ts +16 -0
- package/lib/zhin-agent/branch-summarization-runtime.d.ts.map +1 -0
- package/lib/zhin-agent/branch-summarization-runtime.js +58 -0
- package/lib/zhin-agent/branch-summarization-runtime.js.map +1 -0
- package/lib/zhin-agent/compaction-runtime.d.ts +25 -0
- package/lib/zhin-agent/compaction-runtime.d.ts.map +1 -0
- package/lib/zhin-agent/compaction-runtime.js +78 -0
- package/lib/zhin-agent/compaction-runtime.js.map +1 -0
- package/lib/zhin-agent/config.d.ts +21 -4
- package/lib/zhin-agent/config.d.ts.map +1 -1
- package/lib/zhin-agent/config.js +24 -0
- package/lib/zhin-agent/config.js.map +1 -1
- package/lib/zhin-agent/deferred-auto-continue.d.ts +11 -0
- package/lib/zhin-agent/deferred-auto-continue.d.ts.map +1 -0
- package/lib/zhin-agent/deferred-auto-continue.js +41 -0
- package/lib/zhin-agent/deferred-auto-continue.js.map +1 -0
- package/lib/zhin-agent/deferred-delivery.d.ts +4 -0
- package/lib/zhin-agent/deferred-delivery.d.ts.map +1 -1
- package/lib/zhin-agent/deferred-delivery.js +7 -1
- package/lib/zhin-agent/deferred-delivery.js.map +1 -1
- package/lib/zhin-agent/index.d.ts +20 -3
- package/lib/zhin-agent/index.d.ts.map +1 -1
- package/lib/zhin-agent/index.js +125 -6
- package/lib/zhin-agent/index.js.map +1 -1
- package/lib/zhin-agent/persist-deferred-context.d.ts +5 -0
- package/lib/zhin-agent/persist-deferred-context.d.ts.map +1 -0
- package/lib/zhin-agent/persist-deferred-context.js +40 -0
- package/lib/zhin-agent/persist-deferred-context.js.map +1 -0
- package/lib/zhin-agent/prompt-builder.d.ts.map +1 -1
- package/lib/zhin-agent/prompt-builder.js +5 -0
- package/lib/zhin-agent/prompt-builder.js.map +1 -1
- package/lib/zhin-agent/prompt-controller.d.ts +1 -0
- package/lib/zhin-agent/prompt-controller.d.ts.map +1 -1
- package/lib/zhin-agent/prompt-controller.js +12 -0
- package/lib/zhin-agent/prompt-controller.js.map +1 -1
- package/lib/zhin-agent/prompt-templates.d.ts +2 -0
- package/lib/zhin-agent/prompt-templates.d.ts.map +1 -1
- package/lib/zhin-agent/prompt-templates.js +11 -0
- package/lib/zhin-agent/prompt-templates.js.map +1 -1
- package/lib/zhin-agent/prompt.d.ts.map +1 -1
- package/lib/zhin-agent/prompt.js +6 -1
- package/lib/zhin-agent/prompt.js.map +1 -1
- package/lib/zhin-agent/session-io.d.ts +16 -4
- package/lib/zhin-agent/session-io.d.ts.map +1 -1
- package/lib/zhin-agent/session-io.js +46 -13
- package/lib/zhin-agent/session-io.js.map +1 -1
- package/lib/zhin-agent/session-tree-commands.d.ts +5 -0
- package/lib/zhin-agent/session-tree-commands.d.ts.map +1 -0
- package/lib/zhin-agent/session-tree-commands.js +44 -0
- package/lib/zhin-agent/session-tree-commands.js.map +1 -0
- package/lib/zhin-agent/tool-orchestration.d.ts.map +1 -1
- package/lib/zhin-agent/tool-orchestration.js +13 -24
- package/lib/zhin-agent/tool-orchestration.js.map +1 -1
- package/lib/zhin-agent/tool-search-orchestrator.d.ts.map +1 -1
- package/lib/zhin-agent/tool-search-orchestrator.js +13 -0
- package/lib/zhin-agent/tool-search-orchestrator.js.map +1 -1
- package/lib/zhin-agent/turn-pipeline.d.ts +2 -0
- package/lib/zhin-agent/turn-pipeline.d.ts.map +1 -1
- package/lib/zhin-agent/turn-pipeline.js +30 -21
- package/lib/zhin-agent/turn-pipeline.js.map +1 -1
- package/lib/zhin-agent/turn-user-message.d.ts +8 -0
- package/lib/zhin-agent/turn-user-message.d.ts.map +1 -0
- package/lib/zhin-agent/turn-user-message.js +10 -0
- package/lib/zhin-agent/turn-user-message.js.map +1 -0
- package/lib/zhin-agent/zhin-agent-private.d.ts +6 -0
- package/lib/zhin-agent/zhin-agent-private.d.ts.map +1 -1
- package/lib/zhin-agent/zhin-agent-private.js.map +1 -1
- package/package.json +4 -3
package/README.md
CHANGED
|
@@ -18,7 +18,8 @@ Zhin AI Agent 组合层:在 `@zhin.js/core` 的类型与 Provider 之上,提
|
|
|
18
18
|
- 📦 **上下文与记忆**:`ContextRepository`(`agent_messages`)、`AgentSessionStore`、`ImTranscriptStore`(`im_transcripts` + `chat_history`);辅助:`ContextManager`、`ConversationMemory`、`UserProfileStore`
|
|
19
19
|
- ⏰ **跟进与定时**:`FollowUpManager`、`PersistentCronEngine`、cron 工具
|
|
20
20
|
- 🔧 **内置工具**:bash、read_file、write_file、ask_user、web_search、`chat_history`(按关键词/最近条数查 `im_transcripts`)等
|
|
21
|
-
- 📐
|
|
21
|
+
- 📐 **Compaction(ADR 0010)**:生产 `agentLoop` 接线 L1 micro + L2 LLM;IM `/compact`;yaml `ai.agent.compaction`
|
|
22
|
+
- 🌳 **会话树**:`parent_id` + `active_leaf`;IM `/tree`、`/reset`;branch summarization;Console `GET/POST /api/agent/sessions/...`
|
|
22
23
|
- 🪝 **Hook 系统**:`registerAIHook`、`triggerAIHook` 等
|
|
23
24
|
|
|
24
25
|
## 依赖关系
|
|
@@ -128,7 +129,7 @@ declare module '@zhin.js/core' {
|
|
|
128
129
|
|
|
129
130
|
默认**不**注册 `@modelcontextprotocol/server-memory`;设 `ai.memoryMcp: true` 启用(`data/knowledge-graph.jsonl`)。另可通过 `ai.mcpServers`(或 `ctx.agent.addMcp`)注册更多 Server;每次 AI 回合前懒连接,`mcp_{server}_{tool}` 并入 ZhinAgent 工具池。需可选安装 `@modelcontextprotocol/sdk`(peer dependency)。
|
|
130
131
|
|
|
131
|
-
|
|
132
|
+
**记忆**:默认 **文件三层**(`ai.memory` → `data/memory/`);内置 `read_memory` / `write_memory` 已移除。`ai.memoryMcp: true` 时另注册 MCP 图谱(弃用路径)。工作区 `AGENTS.md` / `TOOLS.md` 由 bootstrap 注入。
|
|
132
133
|
|
|
133
134
|
```yaml
|
|
134
135
|
ai:
|
|
@@ -234,6 +235,33 @@ ai:
|
|
|
234
235
|
model: mimo-v2.5-pro
|
|
235
236
|
```
|
|
236
237
|
|
|
238
|
+
## Provider 与模型列表
|
|
239
|
+
|
|
240
|
+
`AIService` 构造时:
|
|
241
|
+
|
|
242
|
+
1. 按 `ai.providers.<别名>` 实例化 Provider(须配置 `api`,如 `openai-completions`)。
|
|
243
|
+
2. `registerLlmApiFromProviders`:**未写 `models` 的 provider** 在 ApiRegistry 注册为空白名单,由后台 `ModelRegistry.discover()` 填充 `provider.models`;**写了 `models`** 则用 yaml 白名单。
|
|
244
|
+
3. `createZhinAgent` 启动时 `loadCache()` 先恢复上次发现结果,再异步刷新 `/v1/models`。
|
|
245
|
+
|
|
246
|
+
`agents.<name>.model`(如 `mimo-v2.5-pro`)须在发现列表中,或在中转 API 的 `/v1/models` 响应里出现;无需为每个模型手写 yaml,除非要锁定白名单。
|
|
247
|
+
|
|
248
|
+
```yaml
|
|
249
|
+
ai:
|
|
250
|
+
providers:
|
|
251
|
+
openai-main:
|
|
252
|
+
api: openai-completions
|
|
253
|
+
baseUrl: ${OPENAI_BASE_URL}
|
|
254
|
+
apiKey: ${OPENAI_API_KEY}
|
|
255
|
+
# models 省略 → 自动 GET /v1/models
|
|
256
|
+
cloudflare-flash:
|
|
257
|
+
api: cloudflare-workers-ai
|
|
258
|
+
models: ["@cf/zai-org/glm-4.7-flash"] # 显式列表
|
|
259
|
+
agents:
|
|
260
|
+
zhin:
|
|
261
|
+
provider: openai-main
|
|
262
|
+
model: mimo-v2.5-pro
|
|
263
|
+
```
|
|
264
|
+
|
|
237
265
|
## Model harness
|
|
238
266
|
|
|
239
267
|
按 provider / model 覆盖 Agent 循环默认参数(当前主要为 **`maxIterations`**)。
|
|
@@ -262,6 +290,18 @@ ai:
|
|
|
262
290
|
|
|
263
291
|
增补内置默认值:在 `model-harness.ts` 增加 `ModelHarnessRow` 并附测试;YAML 只做覆盖,不替代 TS 约定层。
|
|
264
292
|
|
|
293
|
+
## IM 管理命令
|
|
294
|
+
|
|
295
|
+
由 `register-management-tools.ts` / `register-introspection-commands.ts` 注册(master / 有权限用户):
|
|
296
|
+
|
|
297
|
+
| 类别 | 命令 |
|
|
298
|
+
|------|------|
|
|
299
|
+
| 会话 | `/compact` · `/tree` · `/tree N` · `/reset` |
|
|
300
|
+
| 运维 | `/models` · `/health` |
|
|
301
|
+
| 内省 | `/cmd` · `/bots` · `/bindings` · `/tools` · `/mcp` |
|
|
302
|
+
|
|
303
|
+
zhin-package CLI:`zhin packages`(`basic/cli`)。详见 [ADR 0010](../../docs/adr/0010-pi-coding-agent-harness-alignment.md)。
|
|
304
|
+
|
|
265
305
|
## 开发
|
|
266
306
|
|
|
267
307
|
### 项目结构
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"memory-search-tool.d.ts","sourceRoot":"","sources":["../../src/builtin/memory-search-tool.ts"],"names":[],"mappings":"AAoEA,wBAAgB,sBAAsB,sDAErC"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { resolveIMSessionIdFromToolContext } from '@zhin.js/ai';
|
|
2
|
+
import { parseMemoryTags } from '@zhin.js/ai';
|
|
3
|
+
import { BuiltinBaseTool } from './builtin-base-tool.js';
|
|
4
|
+
import { getMemoryEntryRepository } from '../memory-entry-registry.js';
|
|
5
|
+
const PARAMS = {
|
|
6
|
+
type: 'object',
|
|
7
|
+
properties: {
|
|
8
|
+
query: { type: 'string', description: '检索关键词或短语' },
|
|
9
|
+
scope: {
|
|
10
|
+
type: 'string',
|
|
11
|
+
enum: ['global', 'platform', 'session', 'user'],
|
|
12
|
+
description: '可选:限定记忆范围',
|
|
13
|
+
},
|
|
14
|
+
limit: { type: 'number', description: '最多返回条数(默认 5)' },
|
|
15
|
+
},
|
|
16
|
+
required: ['query'],
|
|
17
|
+
};
|
|
18
|
+
function sessionScopeKey(ctx) {
|
|
19
|
+
return resolveIMSessionIdFromToolContext({
|
|
20
|
+
platform: ctx.platform || '',
|
|
21
|
+
botId: ctx.botId || '',
|
|
22
|
+
scope: ctx.scope,
|
|
23
|
+
sceneId: ctx.sceneId || '',
|
|
24
|
+
senderId: ctx.senderId || '',
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
class MemorySearchTool extends BuiltinBaseTool {
|
|
28
|
+
name = 'memory_search';
|
|
29
|
+
description = '在语义记忆库中检索与 query 相关的事实条目(memory_entries)。';
|
|
30
|
+
parameters = PARAMS;
|
|
31
|
+
keywords = ['memory', 'recall', 'remember', '记忆', '回忆'];
|
|
32
|
+
async run(args, context) {
|
|
33
|
+
const repo = getMemoryEntryRepository();
|
|
34
|
+
if (!repo)
|
|
35
|
+
return '语义记忆未启用(ai.memory.semantic.enabled)或未初始化数据库。';
|
|
36
|
+
const query = String(args.query ?? '').trim();
|
|
37
|
+
if (!query)
|
|
38
|
+
return '请提供 query';
|
|
39
|
+
const scope = typeof args.scope === 'string' ? args.scope : undefined;
|
|
40
|
+
const limit = typeof args.limit === 'number' ? args.limit : 5;
|
|
41
|
+
const scopeKey = scope === 'session' && context ? sessionScopeKey(context) : undefined;
|
|
42
|
+
const hits = await repo.search({
|
|
43
|
+
query,
|
|
44
|
+
scope: scope,
|
|
45
|
+
scope_key: scopeKey,
|
|
46
|
+
limit,
|
|
47
|
+
});
|
|
48
|
+
if (!hits.length)
|
|
49
|
+
return `未找到与 "${query}" 相关的记忆条目。`;
|
|
50
|
+
const lines = hits.map((e) => {
|
|
51
|
+
const tags = parseMemoryTags(e.tags);
|
|
52
|
+
return `- [${e.scope}${e.scope_key ? `:${e.scope_key}` : ''}] ${e.key}=${e.content}`
|
|
53
|
+
+ (tags.length ? ` (tags: ${tags.join(', ')})` : '');
|
|
54
|
+
});
|
|
55
|
+
return `找到 ${hits.length} 条记忆:\n${lines.join('\n')}`;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
export function createMemorySearchTool() {
|
|
59
|
+
return new MemorySearchTool().toTool();
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=memory-search-tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"memory-search-tool.js","sourceRoot":"","sources":["../../src/builtin/memory-search-tool.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,iCAAiC,EAAE,MAAM,aAAa,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAC9C,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,wBAAwB,EAAE,MAAM,6BAA6B,CAAC;AAEvE,MAAM,MAAM,GAAyB;IACnC,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,UAAU,EAAE;QAClD,KAAK,EAAE;YACL,IAAI,EAAE,QAAQ;YACd,IAAI,EAAE,CAAC,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,CAAC;YAC/C,WAAW,EAAE,WAAW;SACzB;QACD,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE;KACvD;IACD,QAAQ,EAAE,CAAC,OAAO,CAAC;CACpB,CAAC;AAEF,SAAS,eAAe,CAAC,GA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I,CAAC,MAAM,CAAC;YAC7B,KAAK;YACL,KAAK,EAAE,KAA+D;YACtE,SAAS,EAAE,QAAQ;YACnB,KAAK;SACN,CAAC,CAAC;QAEH,IAAI,CAAC,IAAI,CAAC,MAAM;YAAE,OAAO,SAAS,KAAK,YAAY,CAAC;QAEpD,MAAM,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE;YAC3B,MAAM,IAAI,GAAG,eAAe,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;YACrC,OAAO,MAAM,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC,OAAO,EAAE;kBAChF,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,WAAW,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;QACzD,CAAC,CAAC,CAAC;QACH,OAAO,MAAM,IAAI,CAAC,MAAM,UAAU,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC;IACvD,CAAC;CACF;AAED,MAAM,UAAU,sBAAsB;IACpC,OAAO,IAAI,gBAAgB,EAAE,CAAC,MAAM,EAAE,CAAC;AACzC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"memory-upsert-tool.d.ts","sourceRoot":"","sources":["../../src/builtin/memory-upsert-tool.ts"],"names":[],"mappings":"AAkFA,wBAAgB,sBAAsB,sDAErC"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { resolveIMSessionIdFromToolContext } from '@zhin.js/ai';
|
|
2
|
+
import { BuiltinBaseTool } from './builtin-base-tool.js';
|
|
3
|
+
import { getMemoryEntryRepository } from '../memory-entry-registry.js';
|
|
4
|
+
const PARAMS = {
|
|
5
|
+
type: 'object',
|
|
6
|
+
properties: {
|
|
7
|
+
key: { type: 'string', description: '记忆键(如 capability:hard_orchestration_v1)' },
|
|
8
|
+
content: { type: 'string', description: '记忆内容(简短事实陈述)' },
|
|
9
|
+
scope: {
|
|
10
|
+
type: 'string',
|
|
11
|
+
enum: ['global', 'platform', 'session', 'user'],
|
|
12
|
+
description: '范围,默认 global',
|
|
13
|
+
},
|
|
14
|
+
tags: {
|
|
15
|
+
type: 'array',
|
|
16
|
+
items: { type: 'string' },
|
|
17
|
+
description: '可选标签',
|
|
18
|
+
},
|
|
19
|
+
source: { type: 'string', description: '来源说明(如 skill:memory-consolidate)' },
|
|
20
|
+
confidence: { type: 'number', description: '置信度 0–1,默认 1' },
|
|
21
|
+
},
|
|
22
|
+
required: ['key', 'content'],
|
|
23
|
+
};
|
|
24
|
+
function sessionScopeKey(ctx) {
|
|
25
|
+
return resolveIMSessionIdFromToolContext({
|
|
26
|
+
platform: ctx.platform || '',
|
|
27
|
+
botId: ctx.botId || '',
|
|
28
|
+
scope: ctx.scope,
|
|
29
|
+
sceneId: ctx.sceneId || '',
|
|
30
|
+
senderId: ctx.senderId || '',
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
class MemoryUpsertTool extends BuiltinBaseTool {
|
|
34
|
+
name = 'memory_upsert';
|
|
35
|
+
description = '写入或更新一条语义记忆(memory_entries),供 memory_search 召回。';
|
|
36
|
+
parameters = PARAMS;
|
|
37
|
+
keywords = ['memory', 'remember', 'store', '记忆', '记住'];
|
|
38
|
+
async run(args, context) {
|
|
39
|
+
const repo = getMemoryEntryRepository();
|
|
40
|
+
if (!repo)
|
|
41
|
+
return '语义记忆未启用(ai.memory.semantic.enabled)或未初始化数据库。';
|
|
42
|
+
const key = String(args.key ?? '').trim();
|
|
43
|
+
const content = String(args.content ?? '').trim();
|
|
44
|
+
if (!key || !content)
|
|
45
|
+
return '请提供 key 与 content';
|
|
46
|
+
const scope = (typeof args.scope === 'string' ? args.scope : 'global');
|
|
47
|
+
let scopeKey = '';
|
|
48
|
+
if (scope === 'session' && context) {
|
|
49
|
+
scopeKey = sessionScopeKey(context);
|
|
50
|
+
}
|
|
51
|
+
else if (scope === 'platform' && context?.platform) {
|
|
52
|
+
scopeKey = context.platform;
|
|
53
|
+
}
|
|
54
|
+
else if (scope === 'user' && context?.senderId) {
|
|
55
|
+
scopeKey = context.senderId;
|
|
56
|
+
}
|
|
57
|
+
const tags = Array.isArray(args.tags) ? args.tags.map(String) : undefined;
|
|
58
|
+
const source = typeof args.source === 'string' ? args.source : 'tool:memory_upsert';
|
|
59
|
+
const confidence = typeof args.confidence === 'number' ? args.confidence : 1;
|
|
60
|
+
const record = await repo.upsert({
|
|
61
|
+
scope,
|
|
62
|
+
scope_key: scopeKey,
|
|
63
|
+
key,
|
|
64
|
+
content,
|
|
65
|
+
tags,
|
|
66
|
+
source,
|
|
67
|
+
confidence,
|
|
68
|
+
});
|
|
69
|
+
return `已写入记忆 ${record.id}: [${record.scope}] ${record.key}=${record.content}`;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
export function createMemoryUpsertTool() {
|
|
73
|
+
return new MemoryUpsertTool().toTool();
|
|
74
|
+
}
|
|
75
|
+
//# sourceMappingURL=memory-upsert-tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"memory-upsert-tool.js","sourceRoot":"","sources":["../../src/builtin/memory-upsert-tool.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,iCAAiC,EAAE,MAAM,aAAa,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,wBAAwB,EAAE,MAAM,6BAA6B,CAAC;AAGvE,MAAM,MAAM,GAAyB;IACnC,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,GAAG,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,yCAAyC,EAAE;QAC/E,OAAO,EAAE,EAAE,IAAI,EAAE,QAA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AAG,MAAM,IAAI,CAAC,MAAM,CAAC;YAC/B,KAAK;YACL,SAAS,EAAE,QAAQ;YACnB,GAAG;YACH,OAAO;YACP,IAAI;YACJ,MAAM;YACN,UAAU;SACX,CAAC,CAAC;QAEH,OAAO,SAAS,MAAM,CAAC,EAAE,MAAM,MAAM,CAAC,KAAK,KAAK,MAAM,CAAC,GAAG,IAAI,MAAM,CAAC,OAAO,EAAE,CAAC;IACjF,CAAC;CACF;AAED,MAAM,UAAU,sBAAsB;IACpC,OAAO,IAAI,gBAAgB,EAAE,CAAC,MAAM,EAAE,CAAC;AACzC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Project director orchestration tools — Agent Mesh hard orchestration v1.
|
|
3
|
+
*/
|
|
4
|
+
import type { AgentTool, ToolContext } from '@zhin.js/core';
|
|
5
|
+
export declare function createOrchestrationTools(context: ToolContext): AgentTool[];
|
|
6
|
+
export declare const ORCHESTRATION_TOOL_NAMES: readonly ["orchestration_start", "orchestration_add_task", "orchestration_status", "orchestration_complete", "orchestration_retry_task", "orchestration_skip_task", "orchestration_patch_state"];
|
|
7
|
+
//# sourceMappingURL=orchestration-tools.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orchestration-tools.d.ts","sourceRoot":"","sources":["../../src/builtin/orchestration-tools.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAoC,MAAM,eAAe,CAAC;AAyR9F,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,WAAW,GAAG,SAAS,EAAE,CAU1E;AAED,eAAO,MAAM,wBAAwB,kMAQ3B,CAAC"}
|
|
@@ -0,0 +1,283 @@
|
|
|
1
|
+
import { resolveIMSessionIdFromToolContext } from '@zhin.js/ai';
|
|
2
|
+
import { BuiltinBaseTool } from './builtin-base-tool.js';
|
|
3
|
+
import { getOrchestrationService, } from '../orchestrator/orchestration-service.js';
|
|
4
|
+
import { writeOrchestrationRunSummaryToMemory } from '../orchestration-memory-hook.js';
|
|
5
|
+
function sessionKeyFromContext(ctx) {
|
|
6
|
+
return resolveIMSessionIdFromToolContext({
|
|
7
|
+
platform: ctx.platform || '',
|
|
8
|
+
botId: ctx.botId || '',
|
|
9
|
+
scope: ctx.scope,
|
|
10
|
+
sceneId: ctx.sceneId || '',
|
|
11
|
+
senderId: ctx.senderId || '',
|
|
12
|
+
});
|
|
13
|
+
}
|
|
14
|
+
function requireService() {
|
|
15
|
+
const svc = getOrchestrationService();
|
|
16
|
+
if (!svc)
|
|
17
|
+
throw new Error('OrchestrationService 未初始化');
|
|
18
|
+
return svc;
|
|
19
|
+
}
|
|
20
|
+
function formatRunStatus(runId, snapshot) {
|
|
21
|
+
if (!snapshot)
|
|
22
|
+
return `Run ${runId} 不存在`;
|
|
23
|
+
const lines = [
|
|
24
|
+
`# Run ${snapshot.run.id}`,
|
|
25
|
+
`status: ${snapshot.run.status}`,
|
|
26
|
+
`title: ${snapshot.run.title}`,
|
|
27
|
+
`template: ${snapshot.run.template || '(none)'}`,
|
|
28
|
+
`session: ${snapshot.run.session_key}`,
|
|
29
|
+
'',
|
|
30
|
+
'## Tasks',
|
|
31
|
+
];
|
|
32
|
+
for (const t of snapshot.tasks) {
|
|
33
|
+
lines.push(`- [${t.status}] ${t.id} (${t.role}) ${t.name}`
|
|
34
|
+
+ (t.executor_kind === 'remote' ? ` remote:${t.remote_agent_id}` : '')
|
|
35
|
+
+ (t.depends_on && t.depends_on !== '[]' ? ` deps:${t.depends_on}` : ''));
|
|
36
|
+
if (t.result_summary)
|
|
37
|
+
lines.push(` result: ${t.result_summary.slice(0, 200)}`);
|
|
38
|
+
if (t.error)
|
|
39
|
+
lines.push(` error: ${t.error.slice(0, 200)}`);
|
|
40
|
+
}
|
|
41
|
+
if (snapshot.run.mission_state_json?.trim()) {
|
|
42
|
+
try {
|
|
43
|
+
const ms = JSON.parse(snapshot.run.mission_state_json);
|
|
44
|
+
lines.push('', '## Mission State');
|
|
45
|
+
lines.push(`phase: ${ms.phase}`);
|
|
46
|
+
if (ms.validation_spec_paths?.length) {
|
|
47
|
+
lines.push(`spec_paths: ${ms.validation_spec_paths.join(', ')}`);
|
|
48
|
+
}
|
|
49
|
+
if (ms.last_validation) {
|
|
50
|
+
lines.push(`last_validation: passed=${ms.last_validation.passed} failed=${ms.last_validation.failed}`);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
catch {
|
|
54
|
+
// ignore invalid mission state
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
return lines.join('\n');
|
|
58
|
+
}
|
|
59
|
+
const START_PARAMS = {
|
|
60
|
+
type: 'object',
|
|
61
|
+
properties: {
|
|
62
|
+
title: { type: 'string', description: 'Run 标题' },
|
|
63
|
+
remote_validator: {
|
|
64
|
+
type: 'string',
|
|
65
|
+
description: '可选:Validate 跑在 remote:<agentId>',
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
};
|
|
69
|
+
const ADD_TASK_PARAMS = {
|
|
70
|
+
type: 'object',
|
|
71
|
+
properties: {
|
|
72
|
+
run_id: { type: 'string', description: '编排 run ID' },
|
|
73
|
+
name: { type: 'string', description: '任务名称' },
|
|
74
|
+
description: { type: 'string', description: '任务描述' },
|
|
75
|
+
role: {
|
|
76
|
+
type: 'string',
|
|
77
|
+
enum: ['planner', 'subtask', 'reviewer', 'researcher', 'executor', 'worker', 'validator'],
|
|
78
|
+
description: 'Agent 角色',
|
|
79
|
+
},
|
|
80
|
+
goal: { type: 'string', description: '任务目标' },
|
|
81
|
+
depends_on: {
|
|
82
|
+
type: 'array',
|
|
83
|
+
items: { type: 'string' },
|
|
84
|
+
description: '依赖任务 ID 列表',
|
|
85
|
+
},
|
|
86
|
+
executor: {
|
|
87
|
+
type: 'string',
|
|
88
|
+
description: 'local 或 remote:<agentId>',
|
|
89
|
+
},
|
|
90
|
+
context: { type: 'object', description: '结构化上下文(JSON)' },
|
|
91
|
+
},
|
|
92
|
+
required: ['run_id', 'name'],
|
|
93
|
+
};
|
|
94
|
+
const RUN_ID_PARAMS = {
|
|
95
|
+
type: 'object',
|
|
96
|
+
properties: {
|
|
97
|
+
run_id: { type: 'string', description: '编排 run ID' },
|
|
98
|
+
force: { type: 'boolean', description: '强制关闭(忽略未完成节点)' },
|
|
99
|
+
},
|
|
100
|
+
required: ['run_id'],
|
|
101
|
+
};
|
|
102
|
+
const TASK_ID_PARAMS = {
|
|
103
|
+
type: 'object',
|
|
104
|
+
properties: {
|
|
105
|
+
task_id: { type: 'string', description: '任务 ID' },
|
|
106
|
+
reason: { type: 'string', description: 'skip 原因' },
|
|
107
|
+
},
|
|
108
|
+
required: ['task_id'],
|
|
109
|
+
};
|
|
110
|
+
const PATCH_STATE_PARAMS = {
|
|
111
|
+
type: 'object',
|
|
112
|
+
properties: {
|
|
113
|
+
run_id: { type: 'string', description: '编排 run ID' },
|
|
114
|
+
patch: { type: 'object', description: 'Mission State 部分更新(JSON)' },
|
|
115
|
+
},
|
|
116
|
+
required: ['run_id', 'patch'],
|
|
117
|
+
};
|
|
118
|
+
class OrchestrationPatchStateTool extends BuiltinBaseTool {
|
|
119
|
+
name = 'orchestration_patch_state';
|
|
120
|
+
description = '更新 Mission State(missions Broadcast 共享状态;按 phase ACL 校验)。';
|
|
121
|
+
parameters = PATCH_STATE_PARAMS;
|
|
122
|
+
async run(args) {
|
|
123
|
+
const svc = requireService();
|
|
124
|
+
const runId = String(args.run_id ?? '');
|
|
125
|
+
if (!runId)
|
|
126
|
+
return '请提供 run_id';
|
|
127
|
+
const patch = args.patch;
|
|
128
|
+
if (!patch || typeof patch !== 'object')
|
|
129
|
+
return '请提供 patch 对象';
|
|
130
|
+
try {
|
|
131
|
+
const next = await svc.patchMissionState(runId, patch);
|
|
132
|
+
if (!next)
|
|
133
|
+
return `Run ${runId} 不存在`;
|
|
134
|
+
return `Mission State 已更新:phase=${next.phase} spec_paths=${next.validation_spec_paths.length}`;
|
|
135
|
+
}
|
|
136
|
+
catch (err) {
|
|
137
|
+
return err instanceof Error ? err.message : String(err);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
class OrchestrationStartTool extends BuiltinBaseTool {
|
|
142
|
+
sessionContext;
|
|
143
|
+
name = 'orchestration_start';
|
|
144
|
+
description = '创建 Mission 编排 run(missions 五阶段 DAG);MissionRunner 自动推进。';
|
|
145
|
+
parameters = START_PARAMS;
|
|
146
|
+
constructor(sessionContext) {
|
|
147
|
+
super();
|
|
148
|
+
this.sessionContext = sessionContext;
|
|
149
|
+
this.tags.push('orchestration', 'director');
|
|
150
|
+
}
|
|
151
|
+
async run(args) {
|
|
152
|
+
const svc = requireService();
|
|
153
|
+
const sessionKey = sessionKeyFromContext(this.sessionContext);
|
|
154
|
+
const title = typeof args.title === 'string' ? args.title : undefined;
|
|
155
|
+
const remoteValidator = typeof args.remote_validator === 'string'
|
|
156
|
+
? args.remote_validator.replace(/^remote:/, '')
|
|
157
|
+
: undefined;
|
|
158
|
+
const snapshot = await svc.startRun({ sessionKey, title, remoteValidator });
|
|
159
|
+
const { isMissionsTemplate } = await import('../orchestrator/mission-state.js');
|
|
160
|
+
if (isMissionsTemplate({ template: snapshot.run.template })) {
|
|
161
|
+
const { getMissionRunner } = await import('../orchestrator/mission-runner.js');
|
|
162
|
+
const runner = getMissionRunner();
|
|
163
|
+
if (runner) {
|
|
164
|
+
void runner.notifyRunStarted(snapshot.run.id, sessionKey);
|
|
165
|
+
void runner.advanceRun(snapshot.run.id);
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
const tpl = snapshot.run.template || '(custom)';
|
|
169
|
+
return (`编排 run 已创建:${snapshot.run.id}\n`
|
|
170
|
+
+ `template: ${tpl}\n`
|
|
171
|
+
+ `session: ${sessionKey}\n`
|
|
172
|
+
+ `tasks: ${snapshot.tasks.map((t) => `${t.id}(${t.role})`).join(', ') || '(empty)'}\n`
|
|
173
|
+
+ (snapshot.tasks.length
|
|
174
|
+
? 'MissionRunner 将自动推进;无需手动 spawn_task。'
|
|
175
|
+
: '使用 orchestration_add_task 添加节点。'));
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
class OrchestrationAddTaskTool extends BuiltinBaseTool {
|
|
179
|
+
name = 'orchestration_add_task';
|
|
180
|
+
description = '向 run 添加 DAG 节点(role、depends_on、executor)。';
|
|
181
|
+
parameters = ADD_TASK_PARAMS;
|
|
182
|
+
async run(args) {
|
|
183
|
+
const svc = requireService();
|
|
184
|
+
const runId = String(args.run_id ?? '');
|
|
185
|
+
if (!runId)
|
|
186
|
+
return '请提供 run_id';
|
|
187
|
+
const input = {
|
|
188
|
+
runId,
|
|
189
|
+
name: String(args.name ?? 'task'),
|
|
190
|
+
description: typeof args.description === 'string' ? args.description : undefined,
|
|
191
|
+
role: typeof args.role === 'string' ? args.role : undefined,
|
|
192
|
+
goal: typeof args.goal === 'string' ? args.goal : undefined,
|
|
193
|
+
dependsOn: Array.isArray(args.depends_on) ? args.depends_on.map(String) : undefined,
|
|
194
|
+
executor: typeof args.executor === 'string'
|
|
195
|
+
? args.executor
|
|
196
|
+
: undefined,
|
|
197
|
+
context: args.context && typeof args.context === 'object'
|
|
198
|
+
? args.context
|
|
199
|
+
: undefined,
|
|
200
|
+
};
|
|
201
|
+
const task = await svc.addTask(input);
|
|
202
|
+
return `任务已添加:${task.id} (${task.role}) status=${task.status}`;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
class OrchestrationStatusTool extends BuiltinBaseTool {
|
|
206
|
+
name = 'orchestration_status';
|
|
207
|
+
description = '查询 run 及 DAG 任务状态。';
|
|
208
|
+
parameters = RUN_ID_PARAMS;
|
|
209
|
+
async run(args) {
|
|
210
|
+
const svc = requireService();
|
|
211
|
+
const runId = String(args.run_id ?? '');
|
|
212
|
+
if (!runId)
|
|
213
|
+
return '请提供 run_id';
|
|
214
|
+
const snapshot = await svc.getStatus(runId);
|
|
215
|
+
return formatRunStatus(runId, snapshot);
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
class OrchestrationCompleteTool extends BuiltinBaseTool {
|
|
219
|
+
name = 'orchestration_complete';
|
|
220
|
+
description = '关闭编排 run(默认要求无 pending/running 节点)。';
|
|
221
|
+
parameters = RUN_ID_PARAMS;
|
|
222
|
+
async run(args) {
|
|
223
|
+
const svc = requireService();
|
|
224
|
+
const runId = String(args.run_id ?? '');
|
|
225
|
+
if (!runId)
|
|
226
|
+
return '请提供 run_id';
|
|
227
|
+
const result = await svc.completeRun(runId, args.force === true);
|
|
228
|
+
if (result.ok) {
|
|
229
|
+
const snapshot = await svc.getStatus(runId);
|
|
230
|
+
if (snapshot)
|
|
231
|
+
await writeOrchestrationRunSummaryToMemory(snapshot);
|
|
232
|
+
}
|
|
233
|
+
return result.message;
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
class OrchestrationRetryTaskTool extends BuiltinBaseTool {
|
|
237
|
+
name = 'orchestration_retry_task';
|
|
238
|
+
description = '将 failed 任务重置为 pending,解锁下游。';
|
|
239
|
+
parameters = TASK_ID_PARAMS;
|
|
240
|
+
async run(args) {
|
|
241
|
+
const svc = requireService();
|
|
242
|
+
const taskId = String(args.task_id ?? '');
|
|
243
|
+
if (!taskId)
|
|
244
|
+
return '请提供 task_id';
|
|
245
|
+
const result = await svc.retryTask(taskId);
|
|
246
|
+
return result.message;
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
class OrchestrationSkipTaskTool extends BuiltinBaseTool {
|
|
250
|
+
name = 'orchestration_skip_task';
|
|
251
|
+
description = '跳过 failed/pending 任务(记录 reason),解锁下游。';
|
|
252
|
+
parameters = TASK_ID_PARAMS;
|
|
253
|
+
async run(args) {
|
|
254
|
+
const svc = requireService();
|
|
255
|
+
const taskId = String(args.task_id ?? '');
|
|
256
|
+
if (!taskId)
|
|
257
|
+
return '请提供 task_id';
|
|
258
|
+
const reason = typeof args.reason === 'string' ? args.reason : 'skipped by director';
|
|
259
|
+
const result = await svc.skipTask(taskId, reason);
|
|
260
|
+
return result.message;
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
export function createOrchestrationTools(context) {
|
|
264
|
+
return [
|
|
265
|
+
new OrchestrationStartTool(context).toTool(),
|
|
266
|
+
new OrchestrationAddTaskTool().toTool(),
|
|
267
|
+
new OrchestrationStatusTool().toTool(),
|
|
268
|
+
new OrchestrationCompleteTool().toTool(),
|
|
269
|
+
new OrchestrationRetryTaskTool().toTool(),
|
|
270
|
+
new OrchestrationSkipTaskTool().toTool(),
|
|
271
|
+
new OrchestrationPatchStateTool().toTool(),
|
|
272
|
+
];
|
|
273
|
+
}
|
|
274
|
+
export const ORCHESTRATION_TOOL_NAMES = [
|
|
275
|
+
'orchestration_start',
|
|
276
|
+
'orchestration_add_task',
|
|
277
|
+
'orchestration_status',
|
|
278
|
+
'orchestration_complete',
|
|
279
|
+
'orchestration_retry_task',
|
|
280
|
+
'orchestration_skip_task',
|
|
281
|
+
'orchestration_patch_state',
|
|
282
|
+
];
|
|
283
|
+
//# sourceMappingURL=orchestration-tools.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orchestration-tools.js","sourceRoot":"","sources":["../../src/builtin/orchestration-tools.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,iCAAiC,EAAE,MAAM,aAAa,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAEzD,OAAO,EACL,uBAAuB,GAExB,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,oCAAoC,EAAE,MAAM,iCAAiC,CAAC;AAGvF,SAAS,qBAAqB,CAAC,GAAgB;IAC7C,OAAO,iCAAiC,CAAC;QACvC,QAAQ,EAAE,GAAG,CAAC,QAAQ,IAAI,EAAE;QAC5B,KAAK,EAAE,GAAG,CAAC,KAAK,IAAI,EAAE;QACtB,KAAK,EAAE,GAAG,CAAC,KAAK;QAChB,OAAO,EAAE,GAAG,CAAC,OAAO,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C,MAAM,wBAAwB,GAAG;IACtC,qBAAqB;IACrB,wBAAwB;IACxB,sBAAsB;IACtB,wBAAwB;IACxB,0BAA0B;IAC1B,yBAAyB;IACzB,2BAA2B;CACnB,CAAC"}
|
|
@@ -12,7 +12,7 @@ export interface RunDeferredTaskToolOptions {
|
|
|
12
12
|
export declare class RunDeferredTaskBuiltinTool extends BuiltinBaseTool {
|
|
13
13
|
private readonly opts;
|
|
14
14
|
readonly name = "run_deferred_task";
|
|
15
|
-
readonly description = "\u5728\u9694\u79BB\u7684 Worker \u5B50 Agent \u4E2D\
|
|
15
|
+
readonly description = "\u5728\u9694\u79BB\u7684 Worker \u5B50 Agent \u4E2D\u540C\u6B65\u6267\u884C deferred \u5DE5\u5177\u4EFB\u52A1\uFF08github/mcp/\u63D2\u4EF6\u7B49\uFF09\u3002Worker \u5B8C\u6210\u540E\u5C06\u7ED3\u679C\u4F5C\u4E3A\u5DE5\u5177\u8FD4\u56DE\u503C\u4EA4\u8FD8\u4E3B Agent\uFF0C\u7531\u4E3B Agent \u5728\u540C\u4E00\u8F6E\u5BF9\u8BDD\u4E2D\u7EE7\u7EED\u7F16\u6392\u6216\u603B\u7ED3\u56DE\u590D\u7528\u6237\u3002\u8FD9\u662F\u8C03\u7528 deferred \u80FD\u529B\u7684\u552F\u4E00\u5165\u53E3";
|
|
16
16
|
readonly parameters: ToolParametersSchema<Record<string, any>>;
|
|
17
17
|
readonly kind = "meta";
|
|
18
18
|
readonly executionTimeoutMs: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run-deferred-task-tool.d.ts","sourceRoot":"","sources":["../../src/builtin/run-deferred-task-tool.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,IAAI,EAAE,oBAAoB,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC5E,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAEzD,eAAO,MAAM,4BAA4B,EAAE,oBAa1C,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AAE,0BAA0B,GAAG,IAAI,CAEhF"}
|
|
@@ -16,7 +16,7 @@ export const RUN_DEFERRED_TASK_PARAMETERS = {
|
|
|
16
16
|
export class RunDeferredTaskBuiltinTool extends BuiltinBaseTool {
|
|
17
17
|
opts;
|
|
18
18
|
name = 'run_deferred_task';
|
|
19
|
-
description = '在隔离的 Worker 子 Agent
|
|
19
|
+
description = '在隔离的 Worker 子 Agent 中同步执行 deferred 工具任务(github/mcp/插件等)。Worker 完成后将结果作为工具返回值交还主 Agent,由主 Agent 在同一轮对话中继续编排或总结回复用户。这是调用 deferred 能力的唯一入口';
|
|
20
20
|
parameters = RUN_DEFERRED_TASK_PARAMETERS;
|
|
21
21
|
kind = 'meta';
|
|
22
22
|
executionTimeoutMs;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run-deferred-task-tool.js","sourceRoot":"","sources":["../../src/builtin/run-deferred-task-tool.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAEzD,MAAM,CAAC,MAAM,4BAA4B,GAAyB;IAChE,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,IAAI,EAAE;YACJ,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,iCAAiC;SAC/C;QACD,UAAU,EAAE;YACV,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,yCAAyC;SACvD;KACF;IACD,QAAQ,EAAE,CAAC,MAAM,CAAC;CACnB,CAAC;AAQF,MAAM,OAAO,0BAA2B,SAAQ,eAAe;IAQhC;IAPpB,IAAI,GAAG,mBAAmB,CAAC;IAC3B,WAAW,GAClB,
|
|
1
|
+
{"version":3,"file":"run-deferred-task-tool.js","sourceRoot":"","sources":["../../src/builtin/run-deferred-task-tool.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAEzD,MAAM,CAAC,MAAM,4BAA4B,GAAyB;IAChE,IAAI,EAAE,QAAQ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