aec-agent 1.0.1 → 1.0.4
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/dist/agent-core.d.ts +123 -3
- package/dist/agent-core.d.ts.map +1 -1
- package/dist/agent-core.js +219 -23
- package/dist/agent-core.js.map +1 -1
- package/dist/components/artifact-hub/artifact-hub.d.ts +11 -1
- package/dist/components/artifact-hub/artifact-hub.d.ts.map +1 -1
- package/dist/components/artifact-hub/artifact-hub.js +21 -1
- package/dist/components/artifact-hub/artifact-hub.js.map +1 -1
- package/dist/components/channel-platform-hub/adapter-kit.d.ts +51 -0
- package/dist/components/channel-platform-hub/adapter-kit.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/adapter-kit.js +153 -0
- package/dist/components/channel-platform-hub/adapter-kit.js.map +1 -0
- package/dist/components/channel-platform-hub/channel-platform-hub.d.ts +34 -0
- package/dist/components/channel-platform-hub/channel-platform-hub.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/channel-platform-hub.js +52 -0
- package/dist/components/channel-platform-hub/channel-platform-hub.js.map +1 -0
- package/dist/components/channel-platform-hub/discord/discord-adapter.d.ts +57 -0
- package/dist/components/channel-platform-hub/discord/discord-adapter.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/discord/discord-adapter.js +412 -0
- package/dist/components/channel-platform-hub/discord/discord-adapter.js.map +1 -0
- package/dist/components/channel-platform-hub/slack/slack-adapter.d.ts +56 -0
- package/dist/components/channel-platform-hub/slack/slack-adapter.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/slack/slack-adapter.js +349 -0
- package/dist/components/channel-platform-hub/slack/slack-adapter.js.map +1 -0
- package/dist/components/channel-platform-hub/slack/slack-mrkdwn.d.ts +3 -0
- package/dist/components/channel-platform-hub/slack/slack-mrkdwn.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/slack/slack-mrkdwn.js +70 -0
- package/dist/components/channel-platform-hub/slack/slack-mrkdwn.js.map +1 -0
- package/dist/components/channel-platform-hub/teams/teams-adapter.d.ts +51 -0
- package/dist/components/channel-platform-hub/teams/teams-adapter.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/teams/teams-adapter.js +333 -0
- package/dist/components/channel-platform-hub/teams/teams-adapter.js.map +1 -0
- package/dist/components/channel-platform-hub/telegram/telegram-adapter.d.ts +46 -0
- package/dist/components/channel-platform-hub/telegram/telegram-adapter.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/telegram/telegram-adapter.js +304 -0
- package/dist/components/channel-platform-hub/telegram/telegram-adapter.js.map +1 -0
- package/dist/components/channel-platform-hub/telegram/telegram-markdown.d.ts +3 -0
- package/dist/components/channel-platform-hub/telegram/telegram-markdown.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/telegram/telegram-markdown.js +87 -0
- package/dist/components/channel-platform-hub/telegram/telegram-markdown.js.map +1 -0
- package/dist/components/channel-platform-hub/types.d.ts +290 -0
- package/dist/components/channel-platform-hub/types.d.ts.map +1 -0
- package/dist/components/channel-platform-hub/types.js +23 -0
- package/dist/components/channel-platform-hub/types.js.map +1 -0
- package/dist/components/event-handler/event-dispatcher.d.ts +28 -3
- package/dist/components/event-handler/event-dispatcher.d.ts.map +1 -1
- package/dist/components/event-handler/event-dispatcher.js +77 -13
- package/dist/components/event-handler/event-dispatcher.js.map +1 -1
- package/dist/components/event-handler/events.d.ts +316 -15
- package/dist/components/event-handler/events.d.ts.map +1 -1
- package/dist/components/event-handler/events.js +94 -2
- package/dist/components/event-handler/events.js.map +1 -1
- package/dist/components/event-handler/types.d.ts +26 -0
- package/dist/components/event-handler/types.d.ts.map +1 -1
- package/dist/components/group-hub/group-hub.d.ts +117 -0
- package/dist/components/group-hub/group-hub.d.ts.map +1 -0
- package/dist/components/group-hub/group-hub.js +334 -0
- package/dist/components/group-hub/group-hub.js.map +1 -0
- package/dist/components/group-hub/group-turns.d.ts +109 -0
- package/dist/components/group-hub/group-turns.d.ts.map +1 -0
- package/dist/components/group-hub/group-turns.js +834 -0
- package/dist/components/group-hub/group-turns.js.map +1 -0
- package/dist/components/group-hub/member-prompt.d.ts +28 -0
- package/dist/components/group-hub/member-prompt.d.ts.map +1 -0
- package/dist/components/group-hub/member-prompt.js +111 -0
- package/dist/components/group-hub/member-prompt.js.map +1 -0
- package/dist/components/group-hub/recipients.d.ts +10 -0
- package/dist/components/group-hub/recipients.d.ts.map +1 -0
- package/dist/components/group-hub/recipients.js +83 -0
- package/dist/components/group-hub/recipients.js.map +1 -0
- package/dist/components/group-hub/thread.d.ts +57 -0
- package/dist/components/group-hub/thread.d.ts.map +1 -0
- package/dist/components/group-hub/thread.js +126 -0
- package/dist/components/group-hub/thread.js.map +1 -0
- package/dist/components/group-hub/types.d.ts +277 -0
- package/dist/components/group-hub/types.d.ts.map +1 -0
- package/dist/components/group-hub/types.js +51 -0
- package/dist/components/group-hub/types.js.map +1 -0
- package/dist/components/llm-provider-hub/providers/anthropic-provider.d.ts.map +1 -1
- package/dist/components/llm-provider-hub/providers/anthropic-provider.js +22 -2
- package/dist/components/llm-provider-hub/providers/anthropic-provider.js.map +1 -1
- package/dist/components/llm-provider-hub/providers/bedrock-provider.d.ts.map +1 -1
- package/dist/components/llm-provider-hub/providers/bedrock-provider.js +15 -3
- package/dist/components/llm-provider-hub/providers/bedrock-provider.js.map +1 -1
- package/dist/components/llm-provider-hub/providers/model-info-mappers.d.ts.map +1 -1
- package/dist/components/llm-provider-hub/providers/model-info-mappers.js +27 -0
- package/dist/components/llm-provider-hub/providers/model-info-mappers.js.map +1 -1
- package/dist/components/llm-provider-hub/providers/openai-compatible-provider.d.ts.map +1 -1
- package/dist/components/llm-provider-hub/providers/openai-compatible-provider.js +10 -3
- package/dist/components/llm-provider-hub/providers/openai-compatible-provider.js.map +1 -1
- package/dist/components/llm-provider-hub/providers/openai-subscription-provider.d.ts +1 -0
- package/dist/components/llm-provider-hub/providers/openai-subscription-provider.d.ts.map +1 -1
- package/dist/components/llm-provider-hub/providers/openai-subscription-provider.js +35 -3
- package/dist/components/llm-provider-hub/providers/openai-subscription-provider.js.map +1 -1
- package/dist/components/llm-provider-hub/types.d.ts +20 -0
- package/dist/components/llm-provider-hub/types.d.ts.map +1 -1
- package/dist/components/llm-provider-hub/types.js +5 -0
- package/dist/components/llm-provider-hub/types.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/agent-loop.d.ts +87 -8
- package/dist/components/multi-agent-orchestration/agent/agent-loop/agent-loop.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/agent-loop.js +465 -62
- package/dist/components/multi-agent-orchestration/agent/agent-loop/agent-loop.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/compactor.d.ts +14 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/compactor.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/compactor.js +25 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/compactor.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/counter.d.ts +14 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/counter.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/counter.js +14 -22
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/counter.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/harness-executor.d.ts +41 -3
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/harness-executor.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/harness-executor.js +152 -44
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/harness-executor.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/run-trace.d.ts +15 -0
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/run-trace.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/run-trace.js +35 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/run-trace.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/summarizer.d.ts +10 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/summarizer.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/summarizer.js +39 -6
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/summarizer.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/summarizer.types.d.ts +2 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/components/summarizer.types.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/context-usage.d.ts +47 -0
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/context-usage.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/context-usage.js +61 -0
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/context-usage.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/memory-recall.d.ts +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/memory-recall.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/memory-recall.js +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/functions/memory-recall.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/types.d.ts +131 -8
- package/dist/components/multi-agent-orchestration/agent/agent-loop/types.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/types.js +17 -1
- package/dist/components/multi-agent-orchestration/agent/agent-loop/types.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent.d.ts +101 -15
- package/dist/components/multi-agent-orchestration/agent/agent.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/agent.js +415 -44
- package/dist/components/multi-agent-orchestration/agent/agent.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-manager.d.ts +245 -1
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-manager.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-manager.js +1583 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-manager.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-prompts.d.ts +76 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-prompts.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-prompts.js +236 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/channel-prompts.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/text.d.ts +15 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/text.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/text.js +80 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/text.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-stream.d.ts +13 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-stream.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-stream.js +41 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-stream.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-view.d.ts +69 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-view.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-view.js +210 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/turn-view.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/types.d.ts +76 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/types.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/types.js +7 -0
- package/dist/components/multi-agent-orchestration/agent/channel-manager/types.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/built-in-commands.d.ts +37 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/built-in-commands.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/built-in-commands.js +544 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/built-in-commands.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/command-manager.d.ts +75 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/command-manager.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/command-manager.js +299 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/command-manager.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/parse.d.ts +17 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/parse.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/parse.js +19 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/parse.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/types.d.ts +197 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/types.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/types.js +3 -0
- package/dist/components/multi-agent-orchestration/agent/command-manager/types.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/context-manager/context-manager.d.ts +37 -1
- package/dist/components/multi-agent-orchestration/agent/context-manager/context-manager.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/context-manager/context-manager.js +54 -2
- package/dist/components/multi-agent-orchestration/agent/context-manager/context-manager.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation-manager.d.ts +118 -14
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation-manager.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation-manager.js +239 -50
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation-manager.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation.d.ts +34 -0
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation.js +74 -0
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/conversation.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/turn-gate.d.ts +49 -0
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/turn-gate.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/turn-gate.js +171 -0
- package/dist/components/multi-agent-orchestration/agent/conversation-manager/turn-gate.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/clock.d.ts +43 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/clock.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/clock.js +116 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/clock.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/internal-events.d.ts +17 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/internal-events.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/internal-events.js +93 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/internal-events.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/job-manager.d.ts +208 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/job-manager.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/job-manager.js +1207 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/job-manager.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/rules.d.ts +129 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/rules.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/rules.js +598 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/rules.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/schedule.d.ts +15 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/schedule.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/schedule.js +113 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/schedule.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/timers.d.ts +8 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/timers.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/timers.js +33 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/timers.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/types.d.ts +495 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/types.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/types.js +50 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/types.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/webhook.d.ts +37 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/webhook.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/webhook.js +157 -0
- package/dist/components/multi-agent-orchestration/agent/job-manager/webhook.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/memory-system/components/dreaming.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/memory-system/components/dreaming.js +17 -3
- package/dist/components/multi-agent-orchestration/agent/memory-system/components/dreaming.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/memory-system/components/memory.d.ts +7 -0
- package/dist/components/multi-agent-orchestration/agent/memory-system/components/memory.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/memory-system/components/memory.js +189 -30
- package/dist/components/multi-agent-orchestration/agent/memory-system/components/memory.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/memory-system/memory-system.d.ts +17 -0
- package/dist/components/multi-agent-orchestration/agent/memory-system/memory-system.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/memory-system/memory-system.js +51 -0
- package/dist/components/multi-agent-orchestration/agent/memory-system/memory-system.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/model-manager/model-manager.d.ts +5 -0
- package/dist/components/multi-agent-orchestration/agent/model-manager/model-manager.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/model-manager/model-manager.js +16 -0
- package/dist/components/multi-agent-orchestration/agent/model-manager/model-manager.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/secret-manager/secret-manager.d.ts +41 -0
- package/dist/components/multi-agent-orchestration/agent/secret-manager/secret-manager.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/secret-manager/secret-manager.js +98 -0
- package/dist/components/multi-agent-orchestration/agent/secret-manager/secret-manager.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/secret-manager/types.d.ts +37 -0
- package/dist/components/multi-agent-orchestration/agent/secret-manager/types.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/secret-manager/types.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/skill-manager/skill-manager.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/skill-manager/skill-manager.js +1 -0
- package/dist/components/multi-agent-orchestration/agent/skill-manager/skill-manager.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/brief.d.ts +21 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/brief.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/brief.js +113 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/brief.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/child-loop.d.ts +52 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/child-loop.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/child-loop.js +63 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/child-loop.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/semaphore.d.ts +18 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/semaphore.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/semaphore.js +56 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/semaphore.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/subagent-manager.d.ts +128 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/subagent-manager.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/subagent-manager.js +661 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/subagent-manager.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/types.d.ts +307 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/types.d.ts.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/types.js +60 -0
- package/dist/components/multi-agent-orchestration/agent/subagent-manager/types.js.map +1 -0
- package/dist/components/multi-agent-orchestration/agent/tool-manager/tool-manager.d.ts +14 -3
- package/dist/components/multi-agent-orchestration/agent/tool-manager/tool-manager.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/tool-manager/tool-manager.js +18 -5
- package/dist/components/multi-agent-orchestration/agent/tool-manager/tool-manager.js.map +1 -1
- package/dist/components/multi-agent-orchestration/agent/types.d.ts +84 -1
- package/dist/components/multi-agent-orchestration/agent/types.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/multi-agent-orchestration.d.ts +11 -4
- package/dist/components/multi-agent-orchestration/multi-agent-orchestration.d.ts.map +1 -1
- package/dist/components/multi-agent-orchestration/multi-agent-orchestration.js +72 -4
- package/dist/components/multi-agent-orchestration/multi-agent-orchestration.js.map +1 -1
- package/dist/components/persistence-hub/default-stores/memory-channel-store.d.ts +11 -0
- package/dist/components/persistence-hub/default-stores/memory-channel-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-channel-store.js +33 -0
- package/dist/components/persistence-hub/default-stores/memory-channel-store.js.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-group-store.d.ts +21 -0
- package/dist/components/persistence-hub/default-stores/memory-group-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-group-store.js +62 -0
- package/dist/components/persistence-hub/default-stores/memory-group-store.js.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-job-store.d.ts +31 -0
- package/dist/components/persistence-hub/default-stores/memory-job-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-job-store.js +234 -0
- package/dist/components/persistence-hub/default-stores/memory-job-store.js.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-secret-store.d.ts +12 -0
- package/dist/components/persistence-hub/default-stores/memory-secret-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-secret-store.js +38 -0
- package/dist/components/persistence-hub/default-stores/memory-secret-store.js.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-session-store.d.ts.map +1 -1
- package/dist/components/persistence-hub/default-stores/memory-session-store.js +7 -0
- package/dist/components/persistence-hub/default-stores/memory-session-store.js.map +1 -1
- package/dist/components/persistence-hub/default-stores/memory-subagent-run-store.d.ts +10 -0
- package/dist/components/persistence-hub/default-stores/memory-subagent-run-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-subagent-run-store.js +30 -0
- package/dist/components/persistence-hub/default-stores/memory-subagent-run-store.js.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-subagent-type-store.d.ts +9 -0
- package/dist/components/persistence-hub/default-stores/memory-subagent-type-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/default-stores/memory-subagent-type-store.js +17 -0
- package/dist/components/persistence-hub/default-stores/memory-subagent-type-store.js.map +1 -0
- package/dist/components/persistence-hub/persistence-hub.d.ts +41 -0
- package/dist/components/persistence-hub/persistence-hub.d.ts.map +1 -1
- package/dist/components/persistence-hub/persistence-hub.js +41 -0
- package/dist/components/persistence-hub/persistence-hub.js.map +1 -1
- package/dist/components/persistence-hub/types/channel-store.d.ts +12 -0
- package/dist/components/persistence-hub/types/channel-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/types/channel-store.js +2 -0
- package/dist/components/persistence-hub/types/channel-store.js.map +1 -0
- package/dist/components/persistence-hub/types/group-store.d.ts +27 -0
- package/dist/components/persistence-hub/types/group-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/types/group-store.js +2 -0
- package/dist/components/persistence-hub/types/group-store.js.map +1 -0
- package/dist/components/persistence-hub/types/job-store.d.ts +112 -0
- package/dist/components/persistence-hub/types/job-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/types/job-store.js +2 -0
- package/dist/components/persistence-hub/types/job-store.js.map +1 -0
- package/dist/components/persistence-hub/types/secret-store.d.ts +18 -0
- package/dist/components/persistence-hub/types/secret-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/types/secret-store.js +2 -0
- package/dist/components/persistence-hub/types/secret-store.js.map +1 -0
- package/dist/components/persistence-hub/types/session-store.d.ts +5 -0
- package/dist/components/persistence-hub/types/session-store.d.ts.map +1 -1
- package/dist/components/persistence-hub/types/subagent-run-store.d.ts +11 -0
- package/dist/components/persistence-hub/types/subagent-run-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/types/subagent-run-store.js +2 -0
- package/dist/components/persistence-hub/types/subagent-run-store.js.map +1 -0
- package/dist/components/persistence-hub/types/subagent-type-store.d.ts +9 -0
- package/dist/components/persistence-hub/types/subagent-type-store.d.ts.map +1 -0
- package/dist/components/persistence-hub/types/subagent-type-store.js +2 -0
- package/dist/components/persistence-hub/types/subagent-type-store.js.map +1 -0
- package/dist/components/sandbox-hub/docker/docker-sandbox.d.ts +4 -1
- package/dist/components/sandbox-hub/docker/docker-sandbox.d.ts.map +1 -1
- package/dist/components/sandbox-hub/docker/docker-sandbox.js +398 -1
- package/dist/components/sandbox-hub/docker/docker-sandbox.js.map +1 -1
- package/dist/components/sandbox-hub/docker/sandbox-helper.d.ts.map +1 -1
- package/dist/components/sandbox-hub/docker/sandbox-helper.js +386 -5
- package/dist/components/sandbox-hub/docker/sandbox-helper.js.map +1 -1
- package/dist/components/sandbox-hub/host/host-sandbox.d.ts +16 -0
- package/dist/components/sandbox-hub/host/host-sandbox.d.ts.map +1 -1
- package/dist/components/sandbox-hub/host/host-sandbox.js +283 -2
- package/dist/components/sandbox-hub/host/host-sandbox.js.map +1 -1
- package/dist/components/sandbox-hub/sandbox-hub.d.ts +9 -0
- package/dist/components/sandbox-hub/sandbox-hub.d.ts.map +1 -1
- package/dist/components/sandbox-hub/sandbox-hub.js +18 -0
- package/dist/components/sandbox-hub/sandbox-hub.js.map +1 -1
- package/dist/components/sandbox-hub/traced-sandbox.d.ts.map +1 -1
- package/dist/components/sandbox-hub/traced-sandbox.js +32 -0
- package/dist/components/sandbox-hub/traced-sandbox.js.map +1 -1
- package/dist/components/sandbox-hub/types/sandbox.d.ts +106 -1
- package/dist/components/sandbox-hub/types/sandbox.d.ts.map +1 -1
- package/dist/components/sandbox-hub/types/sandbox.js +0 -13
- package/dist/components/sandbox-hub/types/sandbox.js.map +1 -1
- package/dist/components/secret-hub/envelope.d.ts +48 -0
- package/dist/components/secret-hub/envelope.d.ts.map +1 -0
- package/dist/components/secret-hub/envelope.js +157 -0
- package/dist/components/secret-hub/envelope.js.map +1 -0
- package/dist/components/secret-hub/rules.d.ts +33 -0
- package/dist/components/secret-hub/rules.d.ts.map +1 -0
- package/dist/components/secret-hub/rules.js +142 -0
- package/dist/components/secret-hub/rules.js.map +1 -0
- package/dist/components/secret-hub/secret-hub-provider.d.ts +61 -0
- package/dist/components/secret-hub/secret-hub-provider.d.ts.map +1 -0
- package/dist/components/secret-hub/secret-hub-provider.js +73 -0
- package/dist/components/secret-hub/secret-hub-provider.js.map +1 -0
- package/dist/components/secret-hub/secret-hub.d.ts +102 -0
- package/dist/components/secret-hub/secret-hub.d.ts.map +1 -0
- package/dist/components/secret-hub/secret-hub.js +267 -0
- package/dist/components/secret-hub/secret-hub.js.map +1 -0
- package/dist/components/secret-hub/types.d.ts +77 -0
- package/dist/components/secret-hub/types.d.ts.map +1 -0
- package/dist/components/secret-hub/types.js +23 -0
- package/dist/components/secret-hub/types.js.map +1 -0
- package/dist/components/skill-hub/built-in-skills/essential-skills.d.ts +1 -1
- package/dist/components/skill-hub/built-in-skills/essential-skills.d.ts.map +1 -1
- package/dist/components/skill-hub/built-in-skills/essential-skills.js +7 -2
- package/dist/components/skill-hub/built-in-skills/essential-skills.js.map +1 -1
- package/dist/components/skill-hub/built-in-skills/watch-and-notify.d.ts +3 -0
- package/dist/components/skill-hub/built-in-skills/watch-and-notify.d.ts.map +1 -0
- package/dist/components/skill-hub/built-in-skills/watch-and-notify.js +94 -0
- package/dist/components/skill-hub/built-in-skills/watch-and-notify.js.map +1 -0
- package/dist/components/skill-hub/skill-hub.d.ts +9 -1
- package/dist/components/skill-hub/skill-hub.d.ts.map +1 -1
- package/dist/components/skill-hub/skill-hub.js +11 -1
- package/dist/components/skill-hub/skill-hub.js.map +1 -1
- package/dist/components/subagent-hub/built-in-types.d.ts +3 -0
- package/dist/components/subagent-hub/built-in-types.d.ts.map +1 -0
- package/dist/components/subagent-hub/built-in-types.js +24 -0
- package/dist/components/subagent-hub/built-in-types.js.map +1 -0
- package/dist/components/subagent-hub/subagent-hub.d.ts +41 -0
- package/dist/components/subagent-hub/subagent-hub.d.ts.map +1 -0
- package/dist/components/subagent-hub/subagent-hub.js +158 -0
- package/dist/components/subagent-hub/subagent-hub.js.map +1 -0
- package/dist/components/subagent-hub/types.d.ts +40 -0
- package/dist/components/subagent-hub/types.d.ts.map +1 -0
- package/dist/components/subagent-hub/types.js +8 -0
- package/dist/components/subagent-hub/types.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/artifacts/artifact-helpers.d.ts +4 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/artifact-helpers.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/artifact-helpers.js +4 -0
- package/dist/components/tool-hub/built-in-tools/artifacts/artifact-helpers.js.map +1 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/save-artifact-tool.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/save-artifact-tool.js +4 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/save-artifact-tool.js.map +1 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/update-artifact-tool.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/update-artifact-tool.js +4 -1
- package/dist/components/tool-hub/built-in-tools/artifacts/update-artifact-tool.js.map +1 -1
- package/dist/components/tool-hub/built-in-tools/jobs/create-job-tools.d.ts +10 -0
- package/dist/components/tool-hub/built-in-tools/jobs/create-job-tools.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/jobs/create-job-tools.js +13 -0
- package/dist/components/tool-hub/built-in-tools/jobs/create-job-tools.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/jobs/job-tool-helpers.d.ts +60 -0
- package/dist/components/tool-hub/built-in-tools/jobs/job-tool-helpers.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/jobs/job-tool-helpers.js +240 -0
- package/dist/components/tool-hub/built-in-tools/jobs/job-tool-helpers.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/jobs/list-jobs-tool.d.ts +14 -0
- package/dist/components/tool-hub/built-in-tools/jobs/list-jobs-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/jobs/list-jobs-tool.js +36 -0
- package/dist/components/tool-hub/built-in-tools/jobs/list-jobs-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/jobs/manage-job-tool.d.ts +32 -0
- package/dist/components/tool-hub/built-in-tools/jobs/manage-job-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/jobs/manage-job-tool.js +458 -0
- package/dist/components/tool-hub/built-in-tools/jobs/manage-job-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/create-preview-tools.d.ts +9 -0
- package/dist/components/tool-hub/built-in-tools/preview/create-preview-tools.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/create-preview-tools.js +20 -0
- package/dist/components/tool-hub/built-in-tools/preview/create-preview-tools.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/list-apps-tool.d.ts +12 -0
- package/dist/components/tool-hub/built-in-tools/preview/list-apps-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/list-apps-tool.js +57 -0
- package/dist/components/tool-hub/built-in-tools/preview/list-apps-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/open-in-app-tool.d.ts +15 -0
- package/dist/components/tool-hub/built-in-tools/preview/open-in-app-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/open-in-app-tool.js +80 -0
- package/dist/components/tool-hub/built-in-tools/preview/open-in-app-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-helpers.d.ts +53 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-helpers.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-helpers.js +100 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-helpers.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-tool.d.ts +14 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-tool.js +63 -0
- package/dist/components/tool-hub/built-in-tools/preview/preview-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/service-tools.d.ts +33 -0
- package/dist/components/tool-hub/built-in-tools/preview/service-tools.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/preview/service-tools.js +180 -0
- package/dist/components/tool-hub/built-in-tools/preview/service-tools.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/create-secret-tools.d.ts +6 -0
- package/dist/components/tool-hub/built-in-tools/secrets/create-secret-tools.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/create-secret-tools.js +9 -0
- package/dist/components/tool-hub/built-in-tools/secrets/create-secret-tools.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/list-secrets-tool.d.ts +12 -0
- package/dist/components/tool-hub/built-in-tools/secrets/list-secrets-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/list-secrets-tool.js +30 -0
- package/dist/components/tool-hub/built-in-tools/secrets/list-secrets-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/manage-secret-tool.d.ts +22 -0
- package/dist/components/tool-hub/built-in-tools/secrets/manage-secret-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/manage-secret-tool.js +113 -0
- package/dist/components/tool-hub/built-in-tools/secrets/manage-secret-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/secret-tool-helpers.d.ts +9 -0
- package/dist/components/tool-hub/built-in-tools/secrets/secret-tool-helpers.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/secrets/secret-tool-helpers.js +29 -0
- package/dist/components/tool-hub/built-in-tools/secrets/secret-tool-helpers.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/subagents/spawn-subagent-tool.d.ts +27 -0
- package/dist/components/tool-hub/built-in-tools/subagents/spawn-subagent-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/subagents/spawn-subagent-tool.js +112 -0
- package/dist/components/tool-hub/built-in-tools/subagents/spawn-subagent-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/web/http-request-tool.d.ts +43 -0
- package/dist/components/tool-hub/built-in-tools/web/http-request-tool.d.ts.map +1 -0
- package/dist/components/tool-hub/built-in-tools/web/http-request-tool.js +234 -0
- package/dist/components/tool-hub/built-in-tools/web/http-request-tool.js.map +1 -0
- package/dist/components/tool-hub/built-in-tools/web/web-extract-tool.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/web/web-extract-tool.js +2 -0
- package/dist/components/tool-hub/built-in-tools/web/web-extract-tool.js.map +1 -1
- package/dist/components/tool-hub/built-in-tools/web/web-search-tool.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/web/web-search-tool.js +2 -0
- package/dist/components/tool-hub/built-in-tools/web/web-search-tool.js.map +1 -1
- package/dist/components/tool-hub/built-in-tools/workspace/run-code-tool.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/workspace/run-code-tool.js +9 -1
- package/dist/components/tool-hub/built-in-tools/workspace/run-code-tool.js.map +1 -1
- package/dist/components/tool-hub/built-in-tools/workspace/terminal-tool.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/workspace/terminal-tool.js +9 -2
- package/dist/components/tool-hub/built-in-tools/workspace/terminal-tool.js.map +1 -1
- package/dist/components/tool-hub/built-in-tools/workspace/workspace-helpers.d.ts +17 -0
- package/dist/components/tool-hub/built-in-tools/workspace/workspace-helpers.d.ts.map +1 -1
- package/dist/components/tool-hub/built-in-tools/workspace/workspace-helpers.js +29 -0
- package/dist/components/tool-hub/built-in-tools/workspace/workspace-helpers.js.map +1 -1
- package/dist/components/tool-hub/tool-links.d.ts +9 -0
- package/dist/components/tool-hub/tool-links.d.ts.map +1 -0
- package/dist/components/tool-hub/tool-links.js +11 -0
- package/dist/components/tool-hub/tool-links.js.map +1 -0
- package/dist/components/tool-hub/types.d.ts +101 -1
- package/dist/components/tool-hub/types.d.ts.map +1 -1
- package/dist/index.d.ts +109 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +68 -0
- package/dist/index.js.map +1 -1
- package/dist/kernel/errors/channel-error.d.ts +24 -0
- package/dist/kernel/errors/channel-error.d.ts.map +1 -0
- package/dist/kernel/errors/channel-error.js +15 -0
- package/dist/kernel/errors/channel-error.js.map +1 -0
- package/dist/kernel/errors/command-error.d.ts +12 -0
- package/dist/kernel/errors/command-error.d.ts.map +1 -0
- package/dist/kernel/errors/command-error.js +11 -0
- package/dist/kernel/errors/command-error.js.map +1 -0
- package/dist/kernel/errors/group-error.d.ts +15 -0
- package/dist/kernel/errors/group-error.d.ts.map +1 -0
- package/dist/kernel/errors/group-error.js +10 -0
- package/dist/kernel/errors/group-error.js.map +1 -0
- package/dist/kernel/errors/job-error.d.ts +23 -0
- package/dist/kernel/errors/job-error.d.ts.map +1 -0
- package/dist/kernel/errors/job-error.js +15 -0
- package/dist/kernel/errors/job-error.js.map +1 -0
- package/dist/kernel/errors/secret-error.d.ts +19 -0
- package/dist/kernel/errors/secret-error.d.ts.map +1 -0
- package/dist/kernel/errors/secret-error.js +10 -0
- package/dist/kernel/errors/secret-error.js.map +1 -0
- package/dist/kernel/errors/session-error.d.ts +5 -1
- package/dist/kernel/errors/session-error.d.ts.map +1 -1
- package/dist/kernel/errors/session-error.js.map +1 -1
- package/dist/kernel/errors/subagent-error.d.ts +19 -0
- package/dist/kernel/errors/subagent-error.d.ts.map +1 -0
- package/dist/kernel/errors/subagent-error.js +10 -0
- package/dist/kernel/errors/subagent-error.js.map +1 -0
- package/dist/kernel/interfaces/kernel.d.ts +15 -0
- package/dist/kernel/interfaces/kernel.d.ts.map +1 -1
- package/dist/kernel/types.d.ts +80 -1
- package/dist/kernel/types.d.ts.map +1 -1
- package/dist/testing/fake-channel.d.ts +60 -0
- package/dist/testing/fake-channel.d.ts.map +1 -0
- package/dist/testing/fake-channel.js +135 -0
- package/dist/testing/fake-channel.js.map +1 -0
- package/dist/testing/in-memory-sandbox.d.ts +4 -1
- package/dist/testing/in-memory-sandbox.d.ts.map +1 -1
- package/dist/testing/in-memory-sandbox.js +63 -3
- package/dist/testing/in-memory-sandbox.js.map +1 -1
- package/dist/testing/mock-session-store.d.ts.map +1 -1
- package/dist/testing/mock-session-store.js +7 -0
- package/dist/testing/mock-session-store.js.map +1 -1
- package/package.json +2 -1
- package/dist/components/multi-agent-orchestration/agent/scheduled-job-manager/scheduled-job-manager.d.ts +0 -38
- package/dist/components/multi-agent-orchestration/agent/scheduled-job-manager/scheduled-job-manager.d.ts.map +0 -1
- package/dist/components/multi-agent-orchestration/agent/scheduled-job-manager/scheduled-job-manager.js +0 -155
- package/dist/components/multi-agent-orchestration/agent/scheduled-job-manager/scheduled-job-manager.js.map +0 -1
- package/dist/components/multi-agent-orchestration/agent/scheduled-job-manager/types.d.ts +0 -27
- package/dist/components/multi-agent-orchestration/agent/scheduled-job-manager/types.d.ts.map +0 -1
- package/dist/components/multi-agent-orchestration/agent/scheduled-job-manager/types.js.map +0 -1
- /package/dist/components/multi-agent-orchestration/agent/{scheduled-job-manager → secret-manager}/types.js +0 -0
|
@@ -14,6 +14,23 @@
|
|
|
14
14
|
// held open; closing it kills the command's whole
|
|
15
15
|
// process group. stdout starts with "AEC-OK\n" or
|
|
16
16
|
// "AEC-ERR {json}\n", followed by the command output.
|
|
17
|
+
// node helper.js readraw raw bytes (A-124): one JSON request on stdin; stdout is
|
|
18
|
+
// "AEC-OK {json}\n" (path, size, modifiedAt, offset,
|
|
19
|
+
// length) followed by exactly `length` file bytes, or
|
|
20
|
+
// "AEC-ERR {json}\n".
|
|
21
|
+
// node helper.js writeraw raw bytes (A-124): a JSON header line on stdin, then the
|
|
22
|
+
// file's bytes until stdin ends; one JSON response line
|
|
23
|
+
// on stdout, like a file operation. The bytes go to a temp
|
|
24
|
+
// file that is renamed into place only when all arrived.
|
|
25
|
+
// node helper.js connect a TCP connection (A-124 phase 2): a JSON header line
|
|
26
|
+
// { port } on stdin; stdout is "AEC-OK\n" or "AEC-ERR
|
|
27
|
+
// {json}\n", then stdin/stdout are piped to/from
|
|
28
|
+
// 127.0.0.1:<port> (or ::1) until either side closes.
|
|
29
|
+
//
|
|
30
|
+
// Services (A-124 phase 2) are file operations too (svcstart, svcstop, svclist,
|
|
31
|
+
// svclogs): a service runs detached in its own process group and outlives the call;
|
|
32
|
+
// its record, log and exit code live in /tmp/aec-services/<agent key>/ (tmpfs, so a
|
|
33
|
+
// container restart forgets them, as it ends the processes).
|
|
17
34
|
//
|
|
18
35
|
// Plain JavaScript (no template literals — this file embeds it in one), no
|
|
19
36
|
// dependencies, Node >= 18. Images used for sandboxes must provide `node`.
|
|
@@ -26,6 +43,7 @@ const posix = require("path").posix;
|
|
|
26
43
|
const crypto = require("crypto");
|
|
27
44
|
const cp = require("child_process");
|
|
28
45
|
const os = require("os");
|
|
46
|
+
const net = require("net");
|
|
29
47
|
|
|
30
48
|
class OpError extends Error {
|
|
31
49
|
constructor(code, message) { super(message); this.code = code; }
|
|
@@ -325,24 +343,211 @@ const ops = {
|
|
|
325
343
|
},
|
|
326
344
|
};
|
|
327
345
|
|
|
346
|
+
// --- Services (A-124 phase 2) ---
|
|
347
|
+
|
|
348
|
+
const SERVICE_NAME = /^[a-z0-9][a-z0-9-]{0,39}$/;
|
|
349
|
+
|
|
350
|
+
function serviceDir(workingDir) {
|
|
351
|
+
return "/tmp/aec-services/" + crypto.createHash("sha256").update(workingDir).digest("hex").slice(0, 16);
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
function sleep(ms) { return new Promise((resolve) => setTimeout(resolve, ms)); }
|
|
355
|
+
|
|
356
|
+
function alive(pid) {
|
|
357
|
+
try { process.kill(pid, 0); return true; } catch (e) { return e.code === "EPERM"; }
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
// Can a TCP connection be made to the port (IPv4 loopback, then IPv6)?
|
|
361
|
+
function probe(port) {
|
|
362
|
+
const tryHost = (host) => new Promise((resolve) => {
|
|
363
|
+
const s = net.connect({ host: host, port: port });
|
|
364
|
+
const done = (ok) => { s.destroy(); resolve(ok); };
|
|
365
|
+
s.setTimeout(500, () => done(false));
|
|
366
|
+
s.once("connect", () => done(true));
|
|
367
|
+
s.once("error", () => done(false));
|
|
368
|
+
});
|
|
369
|
+
return tryHost("127.0.0.1").then((ok) => ok || tryHost("::1"));
|
|
370
|
+
}
|
|
371
|
+
|
|
372
|
+
function portFree(port) {
|
|
373
|
+
return new Promise((resolve) => {
|
|
374
|
+
const srv = net.createServer();
|
|
375
|
+
srv.once("error", () => resolve(false));
|
|
376
|
+
srv.listen(port, "127.0.0.1", () => srv.close(() => resolve(true)));
|
|
377
|
+
});
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
// The name of a service request: it is joined into file names, so only the plain form passes.
|
|
381
|
+
function serviceName(q) {
|
|
382
|
+
if (!SERVICE_NAME.test(q.name || "")) fail("invalid_argument", "Service names are lower-case letters, digits and dashes (at most 40)");
|
|
383
|
+
return q.name;
|
|
384
|
+
}
|
|
385
|
+
|
|
386
|
+
function readRecord(dir, name) {
|
|
387
|
+
try { return JSON.parse(fs.readFileSync(posix.join(dir, name + ".json"), "utf8")); } catch (_) { return null; }
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
async function describe(dir, rec) {
|
|
391
|
+
let status = "exited";
|
|
392
|
+
let exitCode;
|
|
393
|
+
if (alive(rec.pid)) {
|
|
394
|
+
status = (await probe(rec.port)) ? "listening" : "starting";
|
|
395
|
+
} else {
|
|
396
|
+
try {
|
|
397
|
+
const text = fs.readFileSync(posix.join(dir, rec.name + ".exit"), "utf8").trim();
|
|
398
|
+
exitCode = text === "" ? null : Number(text);
|
|
399
|
+
} catch (_) { exitCode = null; }
|
|
400
|
+
}
|
|
401
|
+
const out = { name: rec.name, command: rec.command, cwd: rec.cwd, port: rec.port, status: status, startedAt: rec.startedAt };
|
|
402
|
+
if (status === "exited") out.exitCode = exitCode;
|
|
403
|
+
return out;
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
function listRecords(dir) {
|
|
407
|
+
let names = [];
|
|
408
|
+
try { names = fs.readdirSync(dir); } catch (_) { return []; }
|
|
409
|
+
return names.filter((n) => n.endsWith(".json")).sort().map((n) => readRecord(dir, n.slice(0, -5))).filter(Boolean);
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
const serviceOps = {
|
|
413
|
+
async svcstart(q) {
|
|
414
|
+
serviceName(q);
|
|
415
|
+
if (typeof q.command !== "string" || q.command.trim() === "") fail("invalid_argument", "command must be a non-empty string");
|
|
416
|
+
const cwd = realPath(q.cwd, q.roots);
|
|
417
|
+
let st;
|
|
418
|
+
try { st = fs.statSync(cwd); } catch (e) { throw fsError(e, q.cwd); }
|
|
419
|
+
if (!st.isDirectory()) fail("invalid_path", "\"" + q.cwd + "\" is not a directory");
|
|
420
|
+
const dir = serviceDir(q.workingDir);
|
|
421
|
+
fs.mkdirSync(dir, { recursive: true });
|
|
422
|
+
const records = listRecords(dir);
|
|
423
|
+
const running = records.filter((r) => alive(r.pid));
|
|
424
|
+
if (running.some((r) => r.name === q.name)) fail("conflict", "A service named \"" + q.name + "\" is already running \u2014 stop it first");
|
|
425
|
+
if (running.length >= q.maxServices) {
|
|
426
|
+
fail("policy_denied", "At most " + q.maxServices + " services may run at once \u2014 stop one first (" + running.map((r) => r.name).join(", ") + ")");
|
|
427
|
+
}
|
|
428
|
+
let port = q.port;
|
|
429
|
+
if (port != null) {
|
|
430
|
+
if (!(await portFree(port))) fail("conflict", "Port " + port + " is already in use in the sandbox");
|
|
431
|
+
} else {
|
|
432
|
+
for (let i = 0; i < 50 && port == null; i++) {
|
|
433
|
+
const candidate = 20000 + Math.floor(Math.random() * 10000);
|
|
434
|
+
if (await portFree(candidate)) port = candidate;
|
|
435
|
+
}
|
|
436
|
+
if (port == null) fail("environment_unavailable", "No free port found in the sandbox");
|
|
437
|
+
}
|
|
438
|
+
const log = posix.join(dir, q.name + ".log");
|
|
439
|
+
const exitFile = posix.join(dir, q.name + ".exit");
|
|
440
|
+
try { fs.unlinkSync(exitFile); } catch (_) {}
|
|
441
|
+
const fd = fs.openSync(log, "w");
|
|
442
|
+
const env = {
|
|
443
|
+
PATH: process.env.PATH || "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
|
|
444
|
+
HOME: process.env.HOME || "/tmp",
|
|
445
|
+
LANG: "C.UTF-8",
|
|
446
|
+
};
|
|
447
|
+
Object.assign(env, q.env || {});
|
|
448
|
+
env.PORT = String(port);
|
|
449
|
+
env.AEC_CMD = q.command;
|
|
450
|
+
env.AEC_EXIT = exitFile;
|
|
451
|
+
// The wrapper records the exit code; the service gets its own process group (detached)
|
|
452
|
+
// and outlives this helper (the container's init reaps it).
|
|
453
|
+
const child = cp.spawn("/bin/sh", ["-c", "eval \"$AEC_CMD\"; echo $? > \"$AEC_EXIT\""], {
|
|
454
|
+
cwd: cwd, env: env, detached: true, stdio: ["ignore", fd, fd],
|
|
455
|
+
});
|
|
456
|
+
child.unref();
|
|
457
|
+
fs.closeSync(fd);
|
|
458
|
+
const rec = { name: q.name, command: q.command, cwd: cwd, port: port, pid: child.pid, startedAt: Date.now() };
|
|
459
|
+
fs.writeFileSync(posix.join(dir, q.name + ".json"), JSON.stringify(rec));
|
|
460
|
+
return describe(dir, rec);
|
|
461
|
+
},
|
|
462
|
+
|
|
463
|
+
async svcstop(q) {
|
|
464
|
+
const dir = serviceDir(q.workingDir);
|
|
465
|
+
const rec = readRecord(dir, serviceName(q));
|
|
466
|
+
if (!rec) return null;
|
|
467
|
+
if (alive(rec.pid)) {
|
|
468
|
+
try { process.kill(-rec.pid, "SIGTERM"); } catch (_) {}
|
|
469
|
+
for (let i = 0; i < 30 && alive(rec.pid); i++) await sleep(100);
|
|
470
|
+
if (alive(rec.pid)) { try { process.kill(-rec.pid, "SIGKILL"); } catch (_) {} await sleep(100); }
|
|
471
|
+
}
|
|
472
|
+
return describe(dir, rec);
|
|
473
|
+
},
|
|
474
|
+
|
|
475
|
+
async svclist(q) {
|
|
476
|
+
const dir = serviceDir(q.workingDir);
|
|
477
|
+
const out = [];
|
|
478
|
+
for (const rec of listRecords(dir)) out.push(await describe(dir, rec));
|
|
479
|
+
return out;
|
|
480
|
+
},
|
|
481
|
+
|
|
482
|
+
svclogs(q) {
|
|
483
|
+
const dir = serviceDir(q.workingDir);
|
|
484
|
+
if (!readRecord(dir, serviceName(q))) fail("not_found", "There is no service named \"" + q.name + "\"");
|
|
485
|
+
const p = posix.join(dir, q.name + ".log");
|
|
486
|
+
let size = 0;
|
|
487
|
+
try { size = fs.statSync(p).size; } catch (_) { return { name: q.name, text: "", truncated: false }; }
|
|
488
|
+
const start = Math.max(0, size - q.maxBytes);
|
|
489
|
+
const buf = Buffer.alloc(size - start);
|
|
490
|
+
const fd = fs.openSync(p, "r");
|
|
491
|
+
try { fs.readSync(fd, buf, 0, buf.length, start); } finally { fs.closeSync(fd); }
|
|
492
|
+
return { name: q.name, text: buf.toString("utf8"), truncated: start > 0 };
|
|
493
|
+
},
|
|
494
|
+
};
|
|
495
|
+
Object.assign(ops, serviceOps);
|
|
496
|
+
|
|
328
497
|
function runOperation() {
|
|
329
498
|
const chunks = [];
|
|
330
499
|
process.stdin.on("data", (c) => chunks.push(c));
|
|
331
500
|
process.stdin.on("end", () => {
|
|
332
|
-
|
|
501
|
+
const answer = (response) => process.stdout.write(JSON.stringify(response) + "\n", () => process.exit(0));
|
|
502
|
+
const failed = (e) => {
|
|
503
|
+
const err = fsError(e, "operation");
|
|
504
|
+
answer({ ok: false, code: err.code, message: err.message });
|
|
505
|
+
};
|
|
333
506
|
try {
|
|
334
507
|
const q = JSON.parse(Buffer.concat(chunks).toString("utf8"));
|
|
335
508
|
const op = Object.prototype.hasOwnProperty.call(ops, q.op) ? ops[q.op] : null;
|
|
336
509
|
if (!op) fail("invalid_argument", "Unknown operation " + q.op);
|
|
337
|
-
|
|
510
|
+
// A-124 phase 2: service operations are async.
|
|
511
|
+
Promise.resolve(op(q)).then((result) => answer({ ok: true, result: result }), failed);
|
|
338
512
|
} catch (e) {
|
|
339
|
-
|
|
340
|
-
response = { ok: false, code: err.code, message: err.message };
|
|
513
|
+
failed(e);
|
|
341
514
|
}
|
|
342
|
-
process.stdout.write(JSON.stringify(response) + "\n", () => process.exit(0));
|
|
343
515
|
});
|
|
344
516
|
}
|
|
345
517
|
|
|
518
|
+
function runConnect() {
|
|
519
|
+
let header = Buffer.alloc(0);
|
|
520
|
+
let socket = null;
|
|
521
|
+
process.stdin.on("data", (chunk) => {
|
|
522
|
+
if (socket) { socket.write(chunk); return; }
|
|
523
|
+
header = Buffer.concat([header, chunk]);
|
|
524
|
+
const nl = header.indexOf(10);
|
|
525
|
+
if (nl === -1) return;
|
|
526
|
+
const q = JSON.parse(header.subarray(0, nl).toString("utf8"));
|
|
527
|
+
const rest = header.subarray(nl + 1);
|
|
528
|
+
process.stdin.pause();
|
|
529
|
+
const open = (host, fallback) => {
|
|
530
|
+
const s = net.connect({ host: host, port: q.port });
|
|
531
|
+
s.once("connect", () => {
|
|
532
|
+
socket = s;
|
|
533
|
+
process.stdout.write("AEC-OK\n");
|
|
534
|
+
if (rest.length) s.write(rest);
|
|
535
|
+
s.on("data", (d) => { if (!process.stdout.write(d)) { s.pause(); process.stdout.once("drain", () => s.resume()); } });
|
|
536
|
+
s.on("end", () => process.stdout.write("", () => process.exit(0)));
|
|
537
|
+
s.on("error", () => process.exit(0));
|
|
538
|
+
process.stdin.resume();
|
|
539
|
+
});
|
|
540
|
+
s.once("error", (e) => {
|
|
541
|
+
if (socket) return;
|
|
542
|
+
if (fallback) { open(fallback, null); return; }
|
|
543
|
+
process.stdout.write("AEC-ERR " + JSON.stringify({ code: "not_found", message: "Nothing listens on port " + q.port + " in the sandbox (" + (e.code || e.message) + ")" }) + "\n", () => process.exit(0));
|
|
544
|
+
});
|
|
545
|
+
};
|
|
546
|
+
open("127.0.0.1", "::1");
|
|
547
|
+
});
|
|
548
|
+
process.stdin.on("end", () => { if (socket) socket.end(); else process.exit(0); });
|
|
549
|
+
}
|
|
550
|
+
|
|
346
551
|
function runExec() {
|
|
347
552
|
let header = "";
|
|
348
553
|
let started = false;
|
|
@@ -436,7 +641,183 @@ function runExec() {
|
|
|
436
641
|
}
|
|
437
642
|
}
|
|
438
643
|
|
|
644
|
+
// Parent folder of a file about to be written: created when missing (unless createDirs is false).
|
|
645
|
+
function ensureParent(parent, createDirs) {
|
|
646
|
+
let parentStat = null;
|
|
647
|
+
try { parentStat = fs.statSync(parent); } catch (e) {
|
|
648
|
+
if (e.code !== "ENOENT") throw fsError(e, parent);
|
|
649
|
+
}
|
|
650
|
+
if (!parentStat) {
|
|
651
|
+
if (createDirs === false) fail("not_found", "Directory \"" + parent + "\" does not exist");
|
|
652
|
+
try { fs.mkdirSync(parent, { recursive: true }); } catch (e) { throw fsError(e, parent); }
|
|
653
|
+
} else if (!parentStat.isDirectory()) {
|
|
654
|
+
fail("invalid_path", "\"" + parent + "\" is not a directory");
|
|
655
|
+
}
|
|
656
|
+
}
|
|
657
|
+
|
|
658
|
+
function runReadRaw() {
|
|
659
|
+
const chunks = [];
|
|
660
|
+
process.stdin.on("data", (c) => chunks.push(c));
|
|
661
|
+
process.stdin.on("end", () => {
|
|
662
|
+
let q;
|
|
663
|
+
let real;
|
|
664
|
+
let st;
|
|
665
|
+
try {
|
|
666
|
+
q = JSON.parse(Buffer.concat(chunks).toString("utf8"));
|
|
667
|
+
real = realPath(q.path, q.roots);
|
|
668
|
+
try { st = fs.statSync(real); } catch (e) { throw fsError(e, q.path); }
|
|
669
|
+
if (!st.isFile()) fail("invalid_path", "\"" + q.path + "\" is a " + typeOf(st) + ", not a file");
|
|
670
|
+
} catch (e) {
|
|
671
|
+
const err = fsError(e, q && q.path ? q.path : "operation");
|
|
672
|
+
process.stdout.write("AEC-ERR " + JSON.stringify({ code: err.code, message: err.message }) + "\n", () => process.exit(0));
|
|
673
|
+
return;
|
|
674
|
+
}
|
|
675
|
+
const offset = Math.min(Math.max(0, Math.floor(q.offset || 0)), st.size);
|
|
676
|
+
const rest = st.size - offset;
|
|
677
|
+
const length = q.length == null ? rest : Math.min(Math.max(0, Math.floor(q.length)), rest);
|
|
678
|
+
const head = { path: real, size: st.size, modifiedAt: Math.round(st.mtimeMs), offset: offset, length: length };
|
|
679
|
+
process.stdout.write("AEC-OK " + JSON.stringify(head) + "\n");
|
|
680
|
+
if (length === 0) {
|
|
681
|
+
process.stdout.write("", () => process.exit(0));
|
|
682
|
+
return;
|
|
683
|
+
}
|
|
684
|
+
const src = fs.createReadStream(real, { start: offset, end: offset + length - 1 });
|
|
685
|
+
src.on("error", () => process.exit(1));
|
|
686
|
+
src.on("data", (d) => {
|
|
687
|
+
if (!process.stdout.write(d)) {
|
|
688
|
+
src.pause();
|
|
689
|
+
process.stdout.once("drain", () => src.resume());
|
|
690
|
+
}
|
|
691
|
+
});
|
|
692
|
+
src.on("end", () => process.stdout.write("", () => process.exit(0)));
|
|
693
|
+
});
|
|
694
|
+
}
|
|
695
|
+
|
|
696
|
+
// writeraw: a JSON header line on stdin, then the file's bytes as frames - a 4-byte
|
|
697
|
+
// big-endian length and that many bytes; a zero-length frame ends the upload and puts
|
|
698
|
+
// the file in place (temp file renamed). stdin closing before that end frame (the client
|
|
699
|
+
// was killed, the upload broke off) discards the temp file: a partial file never goes
|
|
700
|
+
// into place. The answer is one JSON line on stdout.
|
|
701
|
+
function runWriteRaw() {
|
|
702
|
+
let header = Buffer.alloc(0);
|
|
703
|
+
let q = null;
|
|
704
|
+
let real = null;
|
|
705
|
+
let existing = null;
|
|
706
|
+
let tmp = null;
|
|
707
|
+
let fd = null;
|
|
708
|
+
let bytes = 0;
|
|
709
|
+
let answered = false;
|
|
710
|
+
// What is left of the current frame, and the bytes of a length not complete yet.
|
|
711
|
+
let remaining = 0;
|
|
712
|
+
let prefix = Buffer.alloc(0);
|
|
713
|
+
const hash = crypto.createHash("sha256");
|
|
714
|
+
|
|
715
|
+
const answer = (response) => {
|
|
716
|
+
if (answered) return;
|
|
717
|
+
answered = true;
|
|
718
|
+
process.stdout.write(JSON.stringify(response) + "\n", () => process.exit(0));
|
|
719
|
+
};
|
|
720
|
+
const abort = (e) => {
|
|
721
|
+
if (fd !== null) { try { fs.closeSync(fd); } catch (_) {} fd = null; }
|
|
722
|
+
if (tmp) { try { fs.unlinkSync(tmp); } catch (_) {} tmp = null; }
|
|
723
|
+
const err = fsError(e, q && q.path ? q.path : "operation");
|
|
724
|
+
answer({ ok: false, code: err.code, message: err.message });
|
|
725
|
+
};
|
|
726
|
+
const begin = () => {
|
|
727
|
+
real = realPath(q.path, q.roots);
|
|
728
|
+
try { existing = fs.lstatSync(real); } catch (e) {
|
|
729
|
+
if (e.code !== "ENOENT" && e.code !== "ENOTDIR") throw fsError(e, q.path);
|
|
730
|
+
}
|
|
731
|
+
if (existing && !existing.isFile()) fail("invalid_path", "\"" + q.path + "\" is a " + typeOf(existing));
|
|
732
|
+
if (existing && q.exclusive) fail("conflict", "\"" + q.path + "\" already exists");
|
|
733
|
+
const parent = posix.dirname(real);
|
|
734
|
+
ensureParent(parent, q.createDirs);
|
|
735
|
+
tmp = posix.join(parent, ".aec-write-" + process.pid + "-" + crypto.randomBytes(4).toString("hex"));
|
|
736
|
+
try { fd = fs.openSync(tmp, "wx", existing ? existing.mode & 0o7777 : 0o644); } catch (e) { tmp = null; throw fsError(e, q.path); }
|
|
737
|
+
};
|
|
738
|
+
const take = (chunk) => {
|
|
739
|
+
if (chunk.length === 0) return;
|
|
740
|
+
bytes += chunk.length;
|
|
741
|
+
if (bytes > q.maxBytes) fail("too_large", "\"" + q.path + "\" is larger than the limit of " + q.maxBytes + " bytes");
|
|
742
|
+
hash.update(chunk);
|
|
743
|
+
let done = 0;
|
|
744
|
+
try {
|
|
745
|
+
while (done < chunk.length) done += fs.writeSync(fd, chunk, done, chunk.length - done);
|
|
746
|
+
} catch (e) { throw fsError(e, q.path); }
|
|
747
|
+
};
|
|
748
|
+
|
|
749
|
+
// The upload is complete: the temp file goes into place.
|
|
750
|
+
const commit = () => {
|
|
751
|
+
fs.closeSync(fd);
|
|
752
|
+
fd = null;
|
|
753
|
+
if (q.exclusive) {
|
|
754
|
+
let exists = false;
|
|
755
|
+
try { fs.lstatSync(real); exists = true; } catch (_) {}
|
|
756
|
+
if (exists) fail("conflict", "\"" + q.path + "\" already exists");
|
|
757
|
+
}
|
|
758
|
+
try { fs.renameSync(tmp, real); } catch (e) { throw fsError(e, q.path); }
|
|
759
|
+
tmp = null;
|
|
760
|
+
answer({ ok: true, result: { path: real, bytes: bytes, sha256: hash.digest("hex"), created: !existing } });
|
|
761
|
+
};
|
|
762
|
+
// Frames: the bytes of a frame go to take(); the zero-length frame commits.
|
|
763
|
+
const feed = (buf) => {
|
|
764
|
+
let i = 0;
|
|
765
|
+
while (i < buf.length) {
|
|
766
|
+
if (remaining > 0) {
|
|
767
|
+
const n = Math.min(remaining, buf.length - i);
|
|
768
|
+
take(buf.subarray(i, i + n));
|
|
769
|
+
remaining -= n;
|
|
770
|
+
i += n;
|
|
771
|
+
continue;
|
|
772
|
+
}
|
|
773
|
+
const got = Math.min(4 - prefix.length, buf.length - i);
|
|
774
|
+
prefix = Buffer.concat([prefix, buf.subarray(i, i + got)]);
|
|
775
|
+
i += got;
|
|
776
|
+
if (prefix.length < 4) return;
|
|
777
|
+
remaining = prefix.readUInt32BE(0);
|
|
778
|
+
prefix = Buffer.alloc(0);
|
|
779
|
+
if (remaining === 0) {
|
|
780
|
+
commit();
|
|
781
|
+
return;
|
|
782
|
+
}
|
|
783
|
+
}
|
|
784
|
+
};
|
|
785
|
+
|
|
786
|
+
process.stdin.on("data", (chunk) => {
|
|
787
|
+
if (answered) return;
|
|
788
|
+
try {
|
|
789
|
+
if (q) {
|
|
790
|
+
feed(chunk);
|
|
791
|
+
return;
|
|
792
|
+
}
|
|
793
|
+
header = Buffer.concat([header, chunk]);
|
|
794
|
+
const nl = header.indexOf(10);
|
|
795
|
+
if (nl === -1) {
|
|
796
|
+
if (header.length > 1048576) fail("invalid_argument", "Request header too long");
|
|
797
|
+
return;
|
|
798
|
+
}
|
|
799
|
+
q = JSON.parse(header.subarray(0, nl).toString("utf8"));
|
|
800
|
+
const rest = header.subarray(nl + 1);
|
|
801
|
+
header = null;
|
|
802
|
+
begin();
|
|
803
|
+
feed(rest);
|
|
804
|
+
} catch (e) { abort(e); }
|
|
805
|
+
});
|
|
806
|
+
// stdin closed before the end frame: the upload broke off (the client was killed, the
|
|
807
|
+
// body failed), so nothing goes into place.
|
|
808
|
+
process.stdin.on("end", () => {
|
|
809
|
+
if (answered) return;
|
|
810
|
+
try {
|
|
811
|
+
if (!q) fail("invalid_argument", "Missing request header");
|
|
812
|
+
fail("cancelled", "The upload ended before it was complete (" + bytes + " bytes received)");
|
|
813
|
+
} catch (e) { abort(e); }
|
|
814
|
+
});
|
|
815
|
+
}
|
|
816
|
+
|
|
439
817
|
if (process.argv[2] === "exec") runExec();
|
|
818
|
+
else if (process.argv[2] === "readraw") runReadRaw();
|
|
819
|
+
else if (process.argv[2] === "writeraw") runWriteRaw();
|
|
820
|
+
else if (process.argv[2] === "connect") runConnect();
|
|
440
821
|
else runOperation();
|
|
441
822
|
`;
|
|
442
823
|
//# sourceMappingURL=sandbox-helper.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sandbox-helper.js","sourceRoot":"","sources":["../../../../src/components/sandbox-hub/docker/sandbox-helper.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,+EAA+E;AAC/E,gFAAgF;AAChF,2CAA2C;AAC3C,EAAE;AACF,8EAA8E;AAC9E,8EAA8E;AAC9E,6EAA6E;AAC7E,2EAA2E;AAC3E,EAAE;AACF,wEAAwE;AACxE,8DAA8D;AAC9D,+EAA+E;AAC/E,6EAA6E;AAC7E,6EAA6E;AAC7E,iFAAiF;AACjF,EAAE;AACF,2EAA2E;AAC3E,2EAA2E;AAC3E,8EAA8E;AAE9E,mDAAmD;AACnD,MAAM,CAAC,MAAM,WAAW,GAAG,qBAAqB,CAAC;AAEjD,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAAA
|
|
1
|
+
{"version":3,"file":"sandbox-helper.js","sourceRoot":"","sources":["../../../../src/components/sandbox-hub/docker/sandbox-helper.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,+EAA+E;AAC/E,gFAAgF;AAChF,2CAA2C;AAC3C,EAAE;AACF,8EAA8E;AAC9E,8EAA8E;AAC9E,6EAA6E;AAC7E,2EAA2E;AAC3E,EAAE;AACF,wEAAwE;AACxE,8DAA8D;AAC9D,+EAA+E;AAC/E,6EAA6E;AAC7E,6EAA6E;AAC7E,iFAAiF;AACjF,qFAAqF;AACrF,gFAAgF;AAChF,iFAAiF;AACjF,iDAAiD;AACjD,sFAAsF;AACtF,mFAAmF;AACnF,sFAAsF;AACtF,oFAAoF;AACpF,kFAAkF;AAClF,iFAAiF;AACjF,4EAA4E;AAC5E,iFAAiF;AACjF,EAAE;AACF,gFAAgF;AAChF,oFAAoF;AACpF,oFAAoF;AACpF,6DAA6D;AAC7D,EAAE;AACF,2EAA2E;AAC3E,2EAA2E;AAC3E,8EAA8E;AAE9E,mDAAmD;AACnD,MAAM,CAAC,MAAM,WAAW,GAAG,qBAAqB,CAAC;AAEjD,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8wBtC,CAAC"}
|
|
@@ -1,4 +1,17 @@
|
|
|
1
|
+
import type { ChildProcess } from "node:child_process";
|
|
1
2
|
import type { Sandbox, SandboxCapability, SandboxLimits, SandboxTraits, SandboxView } from "../types/sandbox.js";
|
|
3
|
+
/** A-124 phase 2: one service of a host sandbox (in server memory; it ends with the server). */
|
|
4
|
+
interface HostService {
|
|
5
|
+
name: string;
|
|
6
|
+
command: string;
|
|
7
|
+
cwd: string;
|
|
8
|
+
port: number;
|
|
9
|
+
child: ChildProcess;
|
|
10
|
+
startedAt: number;
|
|
11
|
+
log: string;
|
|
12
|
+
exited: boolean;
|
|
13
|
+
exitCode: number | null;
|
|
14
|
+
}
|
|
2
15
|
export declare class HostSandbox implements Sandbox {
|
|
3
16
|
readonly id: string;
|
|
4
17
|
readonly traits: SandboxTraits;
|
|
@@ -18,5 +31,8 @@ export declare class HostSandbox implements Sandbox {
|
|
|
18
31
|
dispose(opts?: {
|
|
19
32
|
removeData?: boolean;
|
|
20
33
|
}): Promise<void>;
|
|
34
|
+
/** A-124 phase 2: the services of every agent, keyed "<workingDir>\n<name>". */
|
|
35
|
+
readonly services: Map<string, HostService>;
|
|
21
36
|
}
|
|
37
|
+
export {};
|
|
22
38
|
//# sourceMappingURL=host-sandbox.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"host-sandbox.d.ts","sourceRoot":"","sources":["../../../../src/components/sandbox-hub/host/host-sandbox.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"host-sandbox.d.ts","sourceRoot":"","sources":["../../../../src/components/sandbox-hub/host/host-sandbox.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAevD,OAAO,KAAK,EAcV,OAAO,EACP,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,WAAW,EASZ,MAAM,qBAAqB,CAAC;AAiC7B,gGAAgG;AAChG,UAAU,WAAW;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,YAAY,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CACzB;AAmID,qBAAa,WAAY,YAAW,OAAO;IAKvC,QAAQ,CAAC,EAAE,EAAE,MAAM;IACnB,QAAQ,CAAC,MAAM,EAAE,aAAa;IAC9B,QAAQ,CAAC,MAAM,EAAE,aAAa;IAC9B,mDAAmD;IACnD,QAAQ,CAAC,IAAI,EAAE,MAAM;IARvB,QAAQ,CAAC,YAAY,EAAE,WAAW,CAAC,iBAAiB,CAAC,CAA6B;IAClF,QAAQ,UAAS;IAEjB,YACW,EAAE,EAAE,MAAM,EACV,MAAM,EAAE,aAAa,EACrB,MAAM,EAAE,aAAa;IAC9B,mDAAmD;IAC1C,IAAI,EAAE,MAAM,EACnB;IAEJ,gEAAgE;IAChE,MAAM,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAG9B;IAEK,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,CASpD;IAEK,MAAM,IAAI,OAAO,CAAC,OAAO,GAAG,aAAa,CAAC,CAG/C;IAEK,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAEpD;IAEK,OAAO,CAAC,IAAI,CAAC,EAAE;QAAE,UAAU,CAAC,EAAE,OAAO,CAAA;KAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAM5D;IAED,gFAAgF;IAChF,QAAQ,CAAC,QAAQ,2BAAkC;CACpD"}
|