@loompad/cli 0.1.0 → 1.1.1
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/ARCHITECTURE.md +96 -11
- package/CHANGELOG.md +1042 -0
- package/README.md +1473 -44
- package/THIRD_PARTY_NOTICES.md +275 -0
- package/dist/adapters/antigravity-cli.d.ts +62 -0
- package/dist/adapters/antigravity-cli.js +258 -0
- package/dist/adapters/antigravity-cli.js.map +1 -0
- package/dist/adapters/base.d.ts +61 -9
- package/dist/adapters/base.js +266 -15
- package/dist/adapters/base.js.map +1 -1
- package/dist/adapters/bridges/antigravity.d.ts +9 -12
- package/dist/adapters/bridges/antigravity.js +9 -12
- package/dist/adapters/bridges/antigravity.js.map +1 -1
- package/dist/adapters/echo.d.ts +1 -0
- package/dist/adapters/echo.js +59 -3
- package/dist/adapters/echo.js.map +1 -1
- package/dist/adapters/grok.d.ts +7 -0
- package/dist/adapters/grok.js +20 -10
- package/dist/adapters/grok.js.map +1 -1
- package/dist/adapters/index.d.ts +5 -1
- package/dist/adapters/index.js +53 -7
- package/dist/adapters/index.js.map +1 -1
- package/dist/adapters/model.d.ts +137 -0
- package/dist/adapters/model.js +527 -0
- package/dist/adapters/model.js.map +1 -0
- package/dist/adapters/opencode.d.ts +101 -1
- package/dist/adapters/opencode.js +874 -98
- package/dist/adapters/opencode.js.map +1 -1
- package/dist/cli/doctor.d.ts +32 -0
- package/dist/cli/doctor.js +89 -4
- package/dist/cli/doctor.js.map +1 -1
- package/dist/cli/index.js +2651 -87
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/tui-model.js +3 -1
- package/dist/cli/tui-model.js.map +1 -1
- package/dist/cli/tui.js +44 -1
- package/dist/cli/tui.js.map +1 -1
- package/dist/cli/ui.d.ts +2 -0
- package/dist/cli/ui.js +13 -0
- package/dist/cli/ui.js.map +1 -1
- package/dist/core/ades.d.ts +32 -16
- package/dist/core/ades.js +57 -20
- package/dist/core/ades.js.map +1 -1
- package/dist/core/agent-state.d.ts +14 -0
- package/dist/core/agent-state.js +32 -0
- package/dist/core/agent-state.js.map +1 -0
- package/dist/core/approvals.d.ts +33 -0
- package/dist/core/approvals.js +29 -0
- package/dist/core/approvals.js.map +1 -0
- package/dist/core/backup.d.ts +19 -0
- package/dist/core/backup.js +86 -0
- package/dist/core/backup.js.map +1 -0
- package/dist/core/baton.d.ts +2 -2
- package/dist/core/baton.js.map +1 -1
- package/dist/core/brain-extract.d.ts +17 -0
- package/dist/core/brain-extract.js +28 -2
- package/dist/core/brain-extract.js.map +1 -1
- package/dist/core/brain-index.d.ts +71 -0
- package/dist/core/brain-index.js +204 -5
- package/dist/core/brain-index.js.map +1 -1
- package/dist/core/brain.d.ts +58 -2
- package/dist/core/brain.js +79 -1
- package/dist/core/brain.js.map +1 -1
- package/dist/core/chat-import.d.ts +71 -0
- package/dist/core/chat-import.js +419 -0
- package/dist/core/chat-import.js.map +1 -0
- package/dist/core/checkpoint.d.ts +107 -0
- package/dist/core/checkpoint.js +259 -0
- package/dist/core/checkpoint.js.map +1 -0
- package/dist/core/claude-cli.js +1 -1
- package/dist/core/claude-cli.js.map +1 -1
- package/dist/core/continuity/artifacts.d.ts +14 -0
- package/dist/core/continuity/artifacts.js +118 -0
- package/dist/core/continuity/artifacts.js.map +1 -0
- package/dist/core/continuity/capabilities.d.ts +65 -0
- package/dist/core/continuity/capabilities.js +129 -0
- package/dist/core/continuity/capabilities.js.map +1 -0
- package/dist/core/continuity/contracts.d.ts +352 -0
- package/dist/core/continuity/contracts.js +117 -0
- package/dist/core/continuity/contracts.js.map +1 -0
- package/dist/core/continuity/engine.d.ts +55 -0
- package/dist/core/continuity/engine.js +504 -0
- package/dist/core/continuity/engine.js.map +1 -0
- package/dist/core/continuity/store.d.ts +73 -0
- package/dist/core/continuity/store.js +438 -0
- package/dist/core/continuity/store.js.map +1 -0
- package/dist/core/conversations.d.ts +19 -0
- package/dist/core/conversations.js +87 -0
- package/dist/core/conversations.js.map +1 -0
- package/dist/core/crew-coordination.d.ts +6 -0
- package/dist/core/crew-coordination.js +24 -0
- package/dist/core/crew-coordination.js.map +1 -0
- package/dist/core/crew-policy.d.ts +18 -0
- package/dist/core/crew-policy.js +40 -0
- package/dist/core/crew-policy.js.map +1 -0
- package/dist/core/crew-protocol.d.ts +64 -0
- package/dist/core/crew-protocol.js +146 -0
- package/dist/core/crew-protocol.js.map +1 -0
- package/dist/core/crew-requests.d.ts +14 -0
- package/dist/core/crew-requests.js +22 -0
- package/dist/core/crew-requests.js.map +1 -0
- package/dist/core/crew.d.ts +395 -0
- package/dist/core/crew.js +1857 -0
- package/dist/core/crew.js.map +1 -0
- package/dist/core/digest.d.ts +40 -0
- package/dist/core/digest.js +94 -0
- package/dist/core/digest.js.map +1 -0
- package/dist/core/distill.js +3 -5
- package/dist/core/distill.js.map +1 -1
- package/dist/core/eventlog.d.ts +27 -25
- package/dist/core/eventlog.js +97 -150
- package/dist/core/eventlog.js.map +1 -1
- package/dist/core/events/contracts.d.ts +51 -0
- package/dist/core/events/contracts.js +2 -0
- package/dist/core/events/contracts.js.map +1 -0
- package/dist/core/events/jsonl-store.d.ts +23 -0
- package/dist/core/events/jsonl-store.js +90 -0
- package/dist/core/events/jsonl-store.js.map +1 -0
- package/dist/core/events/sqlite-store.d.ts +37 -0
- package/dist/core/events/sqlite-store.js +215 -0
- package/dist/core/events/sqlite-store.js.map +1 -0
- package/dist/core/forecast.d.ts +44 -0
- package/dist/core/forecast.js +46 -0
- package/dist/core/forecast.js.map +1 -0
- package/dist/core/free-pool.d.ts +65 -0
- package/dist/core/free-pool.js +171 -0
- package/dist/core/free-pool.js.map +1 -0
- package/dist/core/git.d.ts +30 -0
- package/dist/core/git.js +50 -2
- package/dist/core/git.js.map +1 -1
- package/dist/core/github-events.d.ts +53 -0
- package/dist/core/github-events.js +227 -0
- package/dist/core/github-events.js.map +1 -0
- package/dist/core/goal-lanes.d.ts +53 -0
- package/dist/core/goal-lanes.js +99 -0
- package/dist/core/goal-lanes.js.map +1 -0
- package/dist/core/hosted.d.ts +27 -0
- package/dist/core/hosted.js +50 -0
- package/dist/core/hosted.js.map +1 -0
- package/dist/core/http-server.d.ts +5 -0
- package/dist/core/http-server.js +8 -0
- package/dist/core/http-server.js.map +1 -0
- package/dist/core/invite-link.d.ts +31 -0
- package/dist/core/invite-link.js +45 -0
- package/dist/core/invite-link.js.map +1 -0
- package/dist/core/loops.d.ts +37 -0
- package/dist/core/loops.js +81 -0
- package/dist/core/loops.js.map +1 -0
- package/dist/core/mcp-catalog.d.ts +182 -0
- package/dist/core/mcp-catalog.js +431 -0
- package/dist/core/mcp-catalog.js.map +1 -0
- package/dist/core/mcp.d.ts +87 -0
- package/dist/core/mcp.js +181 -0
- package/dist/core/mcp.js.map +1 -0
- package/dist/core/memory.d.ts +1 -0
- package/dist/core/memory.js +5 -2
- package/dist/core/memory.js.map +1 -1
- package/dist/core/model-tools.d.ts +97 -0
- package/dist/core/model-tools.js +388 -0
- package/dist/core/model-tools.js.map +1 -0
- package/dist/core/notify.js +19 -1
- package/dist/core/notify.js.map +1 -1
- package/dist/core/orchestra.d.ts +635 -0
- package/dist/core/orchestra.js +2120 -0
- package/dist/core/orchestra.js.map +1 -0
- package/dist/core/permissions.d.ts +56 -0
- package/dist/core/permissions.js +122 -0
- package/dist/core/permissions.js.map +1 -0
- package/dist/core/preview-proxy.d.ts +70 -0
- package/dist/core/preview-proxy.js +563 -0
- package/dist/core/preview-proxy.js.map +1 -0
- package/dist/core/preview-shot.d.ts +46 -0
- package/dist/core/preview-shot.js +109 -0
- package/dist/core/preview-shot.js.map +1 -0
- package/dist/core/process.d.ts +36 -0
- package/dist/core/process.js +168 -0
- package/dist/core/process.js.map +1 -0
- package/dist/core/prompt-queue.d.ts +136 -0
- package/dist/core/prompt-queue.js +269 -0
- package/dist/core/prompt-queue.js.map +1 -0
- package/dist/core/prompts.d.ts +53 -0
- package/dist/core/prompts.js +127 -0
- package/dist/core/prompts.js.map +1 -0
- package/dist/core/proof.d.ts +82 -0
- package/dist/core/proof.js +216 -0
- package/dist/core/proof.js.map +1 -0
- package/dist/core/provider-text.d.ts +23 -0
- package/dist/core/provider-text.js +66 -0
- package/dist/core/provider-text.js.map +1 -0
- package/dist/core/providers.d.ts +152 -0
- package/dist/core/providers.js +343 -0
- package/dist/core/providers.js.map +1 -0
- package/dist/core/quota.d.ts +33 -0
- package/dist/core/quota.js +74 -0
- package/dist/core/quota.js.map +1 -0
- package/dist/core/recipes.d.ts +50 -0
- package/dist/core/recipes.js +99 -0
- package/dist/core/recipes.js.map +1 -0
- package/dist/core/registry.d.ts +54 -0
- package/dist/core/registry.js +62 -5
- package/dist/core/registry.js.map +1 -1
- package/dist/core/relay-client.d.ts +67 -0
- package/dist/core/relay-client.js +184 -0
- package/dist/core/relay-client.js.map +1 -0
- package/dist/core/relay-protocol.d.ts +140 -0
- package/dist/core/relay-protocol.js +189 -0
- package/dist/core/relay-protocol.js.map +1 -0
- package/dist/core/replay.d.ts +18 -0
- package/dist/core/replay.js +191 -0
- package/dist/core/replay.js.map +1 -0
- package/dist/core/review-triage.d.ts +41 -0
- package/dist/core/review-triage.js +124 -0
- package/dist/core/review-triage.js.map +1 -0
- package/dist/core/router.js +2 -2
- package/dist/core/router.js.map +1 -1
- package/dist/core/routes.d.ts +39 -3
- package/dist/core/routes.js +137 -4
- package/dist/core/routes.js.map +1 -1
- package/dist/core/run-command.d.ts +14 -0
- package/dist/core/run-command.js +45 -0
- package/dist/core/run-command.js.map +1 -0
- package/dist/core/runner-setup.d.ts +36 -0
- package/dist/core/runner-setup.js +114 -0
- package/dist/core/runner-setup.js.map +1 -0
- package/dist/core/search.js +0 -0
- package/dist/core/search.js.map +1 -1
- package/dist/core/semantic.d.ts +92 -0
- package/dist/core/semantic.js +227 -0
- package/dist/core/semantic.js.map +1 -0
- package/dist/core/servers.d.ts +115 -0
- package/dist/core/servers.js +305 -0
- package/dist/core/servers.js.map +1 -0
- package/dist/core/setup.js +64 -6
- package/dist/core/setup.js.map +1 -1
- package/dist/core/shield.d.ts +17 -0
- package/dist/core/shield.js +81 -0
- package/dist/core/shield.js.map +1 -0
- package/dist/core/shift.d.ts +69 -0
- package/dist/core/shift.js +120 -0
- package/dist/core/shift.js.map +1 -0
- package/dist/core/skill-install.d.ts +125 -0
- package/dist/core/skill-install.js +328 -0
- package/dist/core/skill-install.js.map +1 -0
- package/dist/core/skills.d.ts +116 -0
- package/dist/core/skills.js +223 -0
- package/dist/core/skills.js.map +1 -0
- package/dist/core/step-conditions.d.ts +65 -0
- package/dist/core/step-conditions.js +102 -0
- package/dist/core/step-conditions.js.map +1 -0
- package/dist/core/subagents.d.ts +45 -0
- package/dist/core/subagents.js +90 -0
- package/dist/core/subagents.js.map +1 -0
- package/dist/core/team-canon.d.ts +42 -0
- package/dist/core/team-canon.js +121 -0
- package/dist/core/team-canon.js.map +1 -0
- package/dist/core/team-crypto.d.ts +97 -0
- package/dist/core/team-crypto.js +175 -0
- package/dist/core/team-crypto.js.map +1 -0
- package/dist/core/team-hub.d.ts +514 -0
- package/dist/core/team-hub.js +964 -0
- package/dist/core/team-hub.js.map +1 -0
- package/dist/core/team-landing.d.ts +239 -0
- package/dist/core/team-landing.js +504 -0
- package/dist/core/team-landing.js.map +1 -0
- package/dist/core/team-leases.d.ts +44 -0
- package/dist/core/team-leases.js +145 -0
- package/dist/core/team-leases.js.map +1 -0
- package/dist/core/team-memory.d.ts +42 -0
- package/dist/core/team-memory.js +84 -0
- package/dist/core/team-memory.js.map +1 -0
- package/dist/core/team-policy.d.ts +85 -0
- package/dist/core/team-policy.js +191 -0
- package/dist/core/team-policy.js.map +1 -0
- package/dist/core/thread-md.d.ts +6 -0
- package/dist/core/thread-md.js +42 -0
- package/dist/core/thread-md.js.map +1 -0
- package/dist/core/turn-stats.d.ts +61 -0
- package/dist/core/turn-stats.js +124 -0
- package/dist/core/turn-stats.js.map +1 -0
- package/dist/core/updater.d.ts +73 -0
- package/dist/core/updater.js +153 -0
- package/dist/core/updater.js.map +1 -0
- package/dist/core/usage.d.ts +75 -0
- package/dist/core/usage.js +163 -0
- package/dist/core/usage.js.map +1 -0
- package/dist/core/windows-jobs.d.ts +15 -0
- package/dist/core/windows-jobs.js +170 -0
- package/dist/core/windows-jobs.js.map +1 -0
- package/dist/core/worktree-merge.d.ts +57 -0
- package/dist/core/worktree-merge.js +123 -0
- package/dist/core/worktree-merge.js.map +1 -0
- package/dist/core/worktree.d.ts +5 -0
- package/dist/core/worktree.js +45 -5
- package/dist/core/worktree.js.map +1 -1
- package/dist/core/worktrees.d.ts +6 -0
- package/dist/core/worktrees.js +21 -0
- package/dist/core/worktrees.js.map +1 -0
- package/dist/daemon/app-page.d.ts +0 -17
- package/dist/daemon/app-page.js +10 -6346
- package/dist/daemon/app-page.js.map +1 -1
- package/dist/daemon/auth.d.ts +24 -3
- package/dist/daemon/auth.js +66 -7
- package/dist/daemon/auth.js.map +1 -1
- package/dist/daemon/board.d.ts +7 -0
- package/dist/daemon/board.js +12 -1
- package/dist/daemon/board.js.map +1 -1
- package/dist/daemon/brand-icons.d.ts +6 -1
- package/dist/daemon/brand-icons.js +11 -3
- package/dist/daemon/brand-icons.js.map +1 -1
- package/dist/daemon/client.d.ts +665 -1
- package/dist/daemon/client.js +381 -3
- package/dist/daemon/client.js.map +1 -1
- package/dist/daemon/delivery.d.ts +34 -0
- package/dist/daemon/delivery.js +63 -0
- package/dist/daemon/delivery.js.map +1 -0
- package/dist/daemon/deploys.d.ts +62 -0
- package/dist/daemon/deploys.js +159 -0
- package/dist/daemon/deploys.js.map +1 -0
- package/dist/daemon/landing.d.ts +192 -0
- package/dist/daemon/landing.js +992 -0
- package/dist/daemon/landing.js.map +1 -0
- package/dist/daemon/onboard.d.ts +150 -0
- package/dist/daemon/onboard.js +390 -0
- package/dist/daemon/onboard.js.map +1 -0
- package/dist/daemon/proof.d.ts +70 -0
- package/dist/daemon/proof.js +172 -0
- package/dist/daemon/proof.js.map +1 -0
- package/dist/daemon/push.d.ts +19 -1
- package/dist/daemon/push.js +90 -3
- package/dist/daemon/push.js.map +1 -1
- package/dist/daemon/relay.d.ts +82 -0
- package/dist/daemon/relay.js +351 -0
- package/dist/daemon/relay.js.map +1 -0
- package/dist/daemon/routes/agent-discovery.d.ts +4 -0
- package/dist/daemon/routes/agent-discovery.js +29 -0
- package/dist/daemon/routes/agent-discovery.js.map +1 -0
- package/dist/daemon/routes/agent-settings.d.ts +4 -0
- package/dist/daemon/routes/agent-settings.js +94 -0
- package/dist/daemon/routes/agent-settings.js.map +1 -0
- package/dist/daemon/routes/agents.d.ts +4 -0
- package/dist/daemon/routes/agents.js +105 -0
- package/dist/daemon/routes/agents.js.map +1 -0
- package/dist/daemon/routes/alerts.d.ts +4 -0
- package/dist/daemon/routes/alerts.js +137 -0
- package/dist/daemon/routes/alerts.js.map +1 -0
- package/dist/daemon/routes/approvals.d.ts +4 -0
- package/dist/daemon/routes/approvals.js +40 -0
- package/dist/daemon/routes/approvals.js.map +1 -0
- package/dist/daemon/routes/assets.d.ts +3 -0
- package/dist/daemon/routes/assets.js +64 -0
- package/dist/daemon/routes/assets.js.map +1 -0
- package/dist/daemon/routes/board.d.ts +4 -0
- package/dist/daemon/routes/board.js +147 -0
- package/dist/daemon/routes/board.js.map +1 -0
- package/dist/daemon/routes/brain.d.ts +4 -0
- package/dist/daemon/routes/brain.js +270 -0
- package/dist/daemon/routes/brain.js.map +1 -0
- package/dist/daemon/routes/chats.d.ts +4 -0
- package/dist/daemon/routes/chats.js +249 -0
- package/dist/daemon/routes/chats.js.map +1 -0
- package/dist/daemon/routes/clients.d.ts +4 -0
- package/dist/daemon/routes/clients.js +49 -0
- package/dist/daemon/routes/clients.js.map +1 -0
- package/dist/daemon/routes/cloud.d.ts +4 -0
- package/dist/daemon/routes/cloud.js +46 -0
- package/dist/daemon/routes/cloud.js.map +1 -0
- package/dist/daemon/routes/config.d.ts +4 -0
- package/dist/daemon/routes/config.js +35 -0
- package/dist/daemon/routes/config.js.map +1 -0
- package/dist/daemon/routes/context.d.ts +51 -0
- package/dist/daemon/routes/context.js +2 -0
- package/dist/daemon/routes/context.js.map +1 -0
- package/dist/daemon/routes/crews.d.ts +4 -0
- package/dist/daemon/routes/crews.js +149 -0
- package/dist/daemon/routes/crews.js.map +1 -0
- package/dist/daemon/routes/files.d.ts +3 -0
- package/dist/daemon/routes/files.js +253 -0
- package/dist/daemon/routes/files.js.map +1 -0
- package/dist/daemon/routes/git.d.ts +4 -0
- package/dist/daemon/routes/git.js +96 -0
- package/dist/daemon/routes/git.js.map +1 -0
- package/dist/daemon/routes/history.d.ts +4 -0
- package/dist/daemon/routes/history.js +101 -0
- package/dist/daemon/routes/history.js.map +1 -0
- package/dist/daemon/routes/integrations-project.d.ts +3 -0
- package/dist/daemon/routes/integrations-project.js +103 -0
- package/dist/daemon/routes/integrations-project.js.map +1 -0
- package/dist/daemon/routes/integrations.d.ts +3 -0
- package/dist/daemon/routes/integrations.js +111 -0
- package/dist/daemon/routes/integrations.js.map +1 -0
- package/dist/daemon/routes/logs.d.ts +3 -0
- package/dist/daemon/routes/logs.js +40 -0
- package/dist/daemon/routes/logs.js.map +1 -0
- package/dist/daemon/routes/messages.d.ts +4 -0
- package/dist/daemon/routes/messages.js +60 -0
- package/dist/daemon/routes/messages.js.map +1 -0
- package/dist/daemon/routes/observability.d.ts +4 -0
- package/dist/daemon/routes/observability.js +247 -0
- package/dist/daemon/routes/observability.js.map +1 -0
- package/dist/daemon/routes/onboard.d.ts +12 -0
- package/dist/daemon/routes/onboard.js +67 -0
- package/dist/daemon/routes/onboard.js.map +1 -0
- package/dist/daemon/routes/orchestra.d.ts +4 -0
- package/dist/daemon/routes/orchestra.js +110 -0
- package/dist/daemon/routes/orchestra.js.map +1 -0
- package/dist/daemon/routes/pairing.d.ts +4 -0
- package/dist/daemon/routes/pairing.js +155 -0
- package/dist/daemon/routes/pairing.js.map +1 -0
- package/dist/daemon/routes/preview.d.ts +24 -0
- package/dist/daemon/routes/preview.js +122 -0
- package/dist/daemon/routes/preview.js.map +1 -0
- package/dist/daemon/routes/project-actions.d.ts +4 -0
- package/dist/daemon/routes/project-actions.js +53 -0
- package/dist/daemon/routes/project-actions.js.map +1 -0
- package/dist/daemon/routes/project-team.d.ts +4 -0
- package/dist/daemon/routes/project-team.js +201 -0
- package/dist/daemon/routes/project-team.js.map +1 -0
- package/dist/daemon/routes/projects.d.ts +14 -0
- package/dist/daemon/routes/projects.js +138 -0
- package/dist/daemon/routes/projects.js.map +1 -0
- package/dist/daemon/routes/prompts.d.ts +4 -0
- package/dist/daemon/routes/prompts.js +44 -0
- package/dist/daemon/routes/prompts.js.map +1 -0
- package/dist/daemon/routes/proof.d.ts +4 -0
- package/dist/daemon/routes/proof.js +22 -0
- package/dist/daemon/routes/proof.js.map +1 -0
- package/dist/daemon/routes/providers.d.ts +3 -0
- package/dist/daemon/routes/providers.js +60 -0
- package/dist/daemon/routes/providers.js.map +1 -0
- package/dist/daemon/routes/public.d.ts +4 -0
- package/dist/daemon/routes/public.js +64 -0
- package/dist/daemon/routes/public.js.map +1 -0
- package/dist/daemon/routes/queue.d.ts +4 -0
- package/dist/daemon/routes/queue.js +140 -0
- package/dist/daemon/routes/queue.js.map +1 -0
- package/dist/daemon/routes/routing.d.ts +4 -0
- package/dist/daemon/routes/routing.js +61 -0
- package/dist/daemon/routes/routing.js.map +1 -0
- package/dist/daemon/routes/runtime-handler.d.ts +2 -0
- package/dist/daemon/routes/runtime-handler.js +63 -0
- package/dist/daemon/routes/runtime-handler.js.map +1 -0
- package/dist/daemon/routes/search.d.ts +4 -0
- package/dist/daemon/routes/search.js +17 -0
- package/dist/daemon/routes/search.js.map +1 -0
- package/dist/daemon/routes/servers.d.ts +4 -0
- package/dist/daemon/routes/servers.js +133 -0
- package/dist/daemon/routes/servers.js.map +1 -0
- package/dist/daemon/routes/setup.d.ts +3 -0
- package/dist/daemon/routes/setup.js +50 -0
- package/dist/daemon/routes/setup.js.map +1 -0
- package/dist/daemon/routes/shift.d.ts +4 -0
- package/dist/daemon/routes/shift.js +30 -0
- package/dist/daemon/routes/shift.js.map +1 -0
- package/dist/daemon/routes/specs.d.ts +4 -0
- package/dist/daemon/routes/specs.js +57 -0
- package/dist/daemon/routes/specs.js.map +1 -0
- package/dist/daemon/routes/task-delivery.d.ts +4 -0
- package/dist/daemon/routes/task-delivery.js +38 -0
- package/dist/daemon/routes/task-delivery.js.map +1 -0
- package/dist/daemon/routes/team.d.ts +4 -0
- package/dist/daemon/routes/team.js +193 -0
- package/dist/daemon/routes/team.js.map +1 -0
- package/dist/daemon/routes/terminals.d.ts +4 -0
- package/dist/daemon/routes/terminals.js +87 -0
- package/dist/daemon/routes/terminals.js.map +1 -0
- package/dist/daemon/routes/tools.d.ts +4 -0
- package/dist/daemon/routes/tools.js +180 -0
- package/dist/daemon/routes/tools.js.map +1 -0
- package/dist/daemon/routes/updates.d.ts +4 -0
- package/dist/daemon/routes/updates.js +89 -0
- package/dist/daemon/routes/updates.js.map +1 -0
- package/dist/daemon/routes/voice.d.ts +4 -0
- package/dist/daemon/routes/voice.js +53 -0
- package/dist/daemon/routes/voice.js.map +1 -0
- package/dist/daemon/runner.d.ts +186 -0
- package/dist/daemon/runner.js +612 -0
- package/dist/daemon/runner.js.map +1 -0
- package/dist/daemon/runtime/accounting.d.ts +130 -0
- package/dist/daemon/runtime/accounting.js +303 -0
- package/dist/daemon/runtime/accounting.js.map +1 -0
- package/dist/daemon/runtime/agents.d.ts +16 -0
- package/dist/daemon/runtime/agents.js +71 -0
- package/dist/daemon/runtime/agents.js.map +1 -0
- package/dist/daemon/runtime/briefings.d.ts +134 -0
- package/dist/daemon/runtime/briefings.js +329 -0
- package/dist/daemon/runtime/briefings.js.map +1 -0
- package/dist/daemon/runtime/native-usage.d.ts +21 -0
- package/dist/daemon/runtime/native-usage.js +71 -0
- package/dist/daemon/runtime/native-usage.js.map +1 -0
- package/dist/daemon/runtime/queue.d.ts +94 -0
- package/dist/daemon/runtime/queue.js +222 -0
- package/dist/daemon/runtime/queue.js.map +1 -0
- package/dist/daemon/runtime/relay.d.ts +93 -0
- package/dist/daemon/runtime/relay.js +240 -0
- package/dist/daemon/runtime/relay.js.map +1 -0
- package/dist/daemon/runtime/turns.d.ts +202 -0
- package/dist/daemon/runtime/turns.js +663 -0
- package/dist/daemon/runtime/turns.js.map +1 -0
- package/dist/daemon/runtime-support.d.ts +76 -0
- package/dist/daemon/runtime-support.js +134 -0
- package/dist/daemon/runtime-support.js.map +1 -0
- package/dist/daemon/runtime.d.ts +739 -70
- package/dist/daemon/runtime.js +2751 -470
- package/dist/daemon/runtime.js.map +1 -1
- package/dist/daemon/server.d.ts +82 -55
- package/dist/daemon/server.js +674 -1435
- package/dist/daemon/server.js.map +1 -1
- package/dist/daemon/shift.d.ts +70 -0
- package/dist/daemon/shift.js +170 -0
- package/dist/daemon/shift.js.map +1 -0
- package/dist/daemon/specs.d.ts +92 -0
- package/dist/daemon/specs.js +285 -0
- package/dist/daemon/specs.js.map +1 -0
- package/dist/daemon/system.d.ts +208 -0
- package/dist/daemon/system.js +557 -0
- package/dist/daemon/system.js.map +1 -0
- package/dist/daemon/tasks.js +1 -1
- package/dist/daemon/team-brain.d.ts +136 -0
- package/dist/daemon/team-brain.js +659 -0
- package/dist/daemon/team-brain.js.map +1 -0
- package/dist/daemon/team-coordinator.d.ts +78 -0
- package/dist/daemon/team-coordinator.js +408 -0
- package/dist/daemon/team-coordinator.js.map +1 -0
- package/dist/daemon/team.d.ts +339 -0
- package/dist/daemon/team.js +1433 -0
- package/dist/daemon/team.js.map +1 -0
- package/dist/daemon/terminals.d.ts +22 -3
- package/dist/daemon/terminals.js +236 -16
- package/dist/daemon/terminals.js.map +1 -1
- package/dist/hub/client.d.ts +120 -0
- package/dist/hub/client.js +228 -0
- package/dist/hub/client.js.map +1 -0
- package/dist/hub/server.d.ts +32 -0
- package/dist/hub/server.js +180 -0
- package/dist/hub/server.js.map +1 -0
- package/dist/hub/supabase-client.d.ts +220 -0
- package/dist/hub/supabase-client.js +843 -0
- package/dist/hub/supabase-client.js.map +1 -0
- package/dist/observability/ask.d.ts +91 -0
- package/dist/observability/ask.js +179 -0
- package/dist/observability/ask.js.map +1 -0
- package/dist/observability/clickhouse.d.ts +33 -0
- package/dist/observability/clickhouse.js +48 -0
- package/dist/observability/clickhouse.js.map +1 -0
- package/dist/observability/decisions.d.ts +176 -0
- package/dist/observability/decisions.js +377 -0
- package/dist/observability/decisions.js.map +1 -0
- package/dist/observability/index.d.ts +89 -0
- package/dist/observability/index.js +348 -0
- package/dist/observability/index.js.map +1 -0
- package/dist/observability/insights.d.ts +151 -0
- package/dist/observability/insights.js +319 -0
- package/dist/observability/insights.js.map +1 -0
- package/dist/observability/logs-query.d.ts +82 -0
- package/dist/observability/logs-query.js +102 -0
- package/dist/observability/logs-query.js.map +1 -0
- package/dist/observability/logs.d.ts +72 -0
- package/dist/observability/logs.js +295 -0
- package/dist/observability/logs.js.map +1 -0
- package/dist/observability/metrics.d.ts +86 -0
- package/dist/observability/metrics.js +303 -0
- package/dist/observability/metrics.js.map +1 -0
- package/dist/observability/otlp.d.ts +127 -0
- package/dist/observability/otlp.js +242 -0
- package/dist/observability/otlp.js.map +1 -0
- package/dist/observability/snapshots.d.ts +43 -0
- package/dist/observability/snapshots.js +129 -0
- package/dist/observability/snapshots.js.map +1 -0
- package/dist/observability/triage.d.ts +49 -0
- package/dist/observability/triage.js +284 -0
- package/dist/observability/triage.js.map +1 -0
- package/dist/providers/adapter.d.ts +50 -0
- package/dist/providers/adapter.js +38 -0
- package/dist/providers/adapter.js.map +1 -0
- package/dist/providers/agent.d.ts +110 -0
- package/dist/providers/agent.js +487 -0
- package/dist/providers/agent.js.map +1 -0
- package/dist/providers/approvals.d.ts +24 -0
- package/dist/providers/approvals.js +78 -0
- package/dist/providers/approvals.js.map +1 -0
- package/dist/providers/attachments.d.ts +20 -0
- package/dist/providers/attachments.js +51 -0
- package/dist/providers/attachments.js.map +1 -0
- package/dist/providers/claude/adapter.d.ts +99 -0
- package/dist/providers/claude/adapter.js +790 -0
- package/dist/providers/claude/adapter.js.map +1 -0
- package/dist/providers/codex/adapter.d.ts +113 -0
- package/dist/providers/codex/adapter.js +881 -0
- package/dist/providers/codex/adapter.js.map +1 -0
- package/dist/providers/codex/instructions.d.ts +11 -0
- package/dist/providers/codex/instructions.js +154 -0
- package/dist/providers/codex/instructions.js.map +1 -0
- package/dist/providers/codex/rpc.d.ts +36 -0
- package/dist/providers/codex/rpc.js +104 -0
- package/dist/providers/codex/rpc.js.map +1 -0
- package/dist/providers/contracts.d.ts +339 -0
- package/dist/providers/contracts.js +19 -0
- package/dist/providers/contracts.js.map +1 -0
- package/dist/providers/directory.d.ts +70 -0
- package/dist/providers/directory.js +95 -0
- package/dist/providers/directory.js.map +1 -0
- package/dist/providers/errors.d.ts +47 -0
- package/dist/providers/errors.js +24 -0
- package/dist/providers/errors.js.map +1 -0
- package/dist/providers/index.d.ts +18 -0
- package/dist/providers/index.js +19 -0
- package/dist/providers/index.js.map +1 -0
- package/dist/providers/ingestion.d.ts +80 -0
- package/dist/providers/ingestion.js +330 -0
- package/dist/providers/ingestion.js.map +1 -0
- package/dist/providers/live.d.ts +22 -0
- package/dist/providers/live.js +56 -0
- package/dist/providers/live.js.map +1 -0
- package/dist/providers/process.d.ts +29 -0
- package/dist/providers/process.js +71 -0
- package/dist/providers/process.js.map +1 -0
- package/dist/providers/reaper.d.ts +33 -0
- package/dist/providers/reaper.js +65 -0
- package/dist/providers/reaper.js.map +1 -0
- package/dist/providers/service.d.ts +87 -0
- package/dist/providers/service.js +256 -0
- package/dist/providers/service.js.map +1 -0
- package/dist/sdk.d.ts +1 -1
- package/dist/sdk.js +1 -1
- package/dist/sdk.js.map +1 -1
- package/dist/types.d.ts +385 -6
- package/dist/types.js +1 -0
- package/dist/types.js.map +1 -1
- package/dist/version.d.ts +7 -0
- package/dist/version.js +16 -0
- package/dist/version.js.map +1 -0
- package/dist/web/app.css +4643 -0
- package/dist/web/app.js +22640 -0
- package/dist/web/app.js.map +7 -0
- package/dist/web/shell.html +39 -0
- package/docs/README.md +21 -0
- package/docs/SETUP.md +10 -0
- package/docs/adapters.md +21 -8
- package/docs/brain-continuity.md +186 -0
- package/docs/cloud.md +108 -0
- package/docs/crews.md +62 -0
- package/docs/design-system.md +31 -2
- package/docs/integration-notes.md +128 -20
- package/docs/loompad.md +105 -0
- package/docs/observability.md +220 -0
- package/docs/play-store.md +123 -0
- package/docs/proposals/agent-teams.md +249 -0
- package/docs/proposals/brain-continuity-implementation.md +468 -0
- package/docs/proposals/brain-session-continuity.md +623 -0
- package/docs/proposals/t3code-port.md +81 -0
- package/docs/proposals/t3code-reference.md +95 -0
- package/docs/refactoring/AGENT-TEAMS-PROGRESS.md +88 -0
- package/docs/refactoring/BOUNDARIES.md +120 -0
- package/docs/refactoring/BRAIN-AUDIT.md +176 -0
- package/docs/refactoring/BRAIN-NOTES.md +390 -0
- package/docs/refactoring/BRAIN-TODO.md +214 -0
- package/docs/refactoring/NOTES.md +129 -0
- package/docs/refactoring/T3-PORT-NOTES.md +165 -0
- package/docs/refactoring/T3-PORT-TODO.md +123 -0
- package/docs/refactoring/TODO.md +46 -0
- package/docs/refactoring/brain-benchmark-2026-09-28.json +48 -0
- package/docs/refactoring/brain-benchmark-audit-2026-09-28.json +48 -0
- package/docs/release-notes/v0.2.0.md +35 -0
- package/docs/release-notes/v0.2.1.md +59 -0
- package/docs/release-notes/v0.2.3.md +77 -0
- package/docs/release-notes/v0.2.4.md +128 -0
- package/docs/release-notes/v0.2.5.md +153 -0
- package/docs/release-notes/v0.2.6.md +62 -0
- package/docs/release-notes/v1.0.0.md +120 -0
- package/docs/release-notes/v1.0.1.md +77 -0
- package/docs/release-notes/v1.1.0.md +71 -0
- package/docs/release-notes/v1.1.1.md +38 -0
- package/docs/teams-architecture.md +697 -0
- package/docs/teams.md +171 -0
- package/docs/windows.md +85 -0
- package/package.json +22 -9
- package/dist/adapters/claude-code.d.ts +0 -26
- package/dist/adapters/claude-code.js +0 -209
- package/dist/adapters/claude-code.js.map +0 -1
- package/dist/adapters/codex.d.ts +0 -51
- package/dist/adapters/codex.js +0 -291
- package/dist/adapters/codex.js.map +0 -1
- package/docs/img/board-linear.png +0 -0
- package/docs/img/board-projects.png +0 -0
- package/docs/img/brain.png +0 -0
- package/docs/img/settings.png +0 -0
- package/docs/img/workspace.png +0 -0
|
@@ -0,0 +1,339 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Team Link — a member's daemon on a Loom Team Hub (docs/teams-architecture.md).
|
|
3
|
+
*
|
|
4
|
+
* Phase 1, "see each other". What it does, and the decision each part serves:
|
|
5
|
+
* - signs in (D4: a GitHub login), holds this device's keys, and the team
|
|
6
|
+
* keys it has been given (D5 via invite links, D6 via sealed envelopes)
|
|
7
|
+
* - shares projects opt-in, or by git remote matching a team repo (D8)
|
|
8
|
+
* - heartbeats every live session in shared projects: agent, state, branch,
|
|
9
|
+
* file globs in the clear; goal/task titles sealed (D2, D24 — intent, never
|
|
10
|
+
* prompts or transcripts)
|
|
11
|
+
* - publishes goal lifecycle to the team feed, and PR/check activity by
|
|
12
|
+
* polling `gh` when the team has no GitHub App (D7)
|
|
13
|
+
* - keeps a decrypted live view (members, presence, feed) for the UI
|
|
14
|
+
*
|
|
15
|
+
* State lives in ~/.loom/team.json (0600): hub session, device keys, team keys.
|
|
16
|
+
* The hub never holds a readable team key.
|
|
17
|
+
*/
|
|
18
|
+
import { type InviteFragment } from "../core/team-crypto.js";
|
|
19
|
+
import { type FeedIn, type HubClient, type PresenceIn } from "../core/team-hub.js";
|
|
20
|
+
import type { ProjectRuntime } from "./runtime.js";
|
|
21
|
+
import { Deploys } from "./deploys.js";
|
|
22
|
+
import { Landing, type Exec } from "./landing.js";
|
|
23
|
+
import { TeamBrain } from "./team-brain.js";
|
|
24
|
+
import { TeamCoordinator } from "./team-coordinator.js";
|
|
25
|
+
import { Runner, type JobPayload, type RunnerConfig } from "./runner.js";
|
|
26
|
+
/**
|
|
27
|
+
* The project's GitHub repo ("owner/name"): `git config loom.repo` when set (a
|
|
28
|
+
* mirror, or a remote that isn't github.com), else its origin remote.
|
|
29
|
+
*/
|
|
30
|
+
export declare function repoOf(dir: string): Promise<string | null>;
|
|
31
|
+
export interface TeamLinkHost {
|
|
32
|
+
/** Open project runtimes (only these can be shared/heartbeated). */
|
|
33
|
+
runtimes(): ProjectRuntime[];
|
|
34
|
+
/** Fan a team frame out to connected UIs. */
|
|
35
|
+
broadcast(frame: Record<string, unknown>): void;
|
|
36
|
+
/** Tests inject a hub; production builds an HttpHubClient from state. */
|
|
37
|
+
hubFactory?: (url: string, token: string) => HubClient;
|
|
38
|
+
/** Where team.json lives; defaults to ~/.loom/team.json. Tests run two members in one process. */
|
|
39
|
+
statePath?: string;
|
|
40
|
+
/** Tests swap `gh` for one-link onboarding's repo-access grant. */
|
|
41
|
+
gh?: (args: string[]) => Promise<string>;
|
|
42
|
+
/** Tests swap `gh` (and friends) for the landing flow (Phase 4). */
|
|
43
|
+
landingExec?: Exec;
|
|
44
|
+
landingRerunSettleMs?: number;
|
|
45
|
+
/** Tests: how long a landing turn waits for checks to show up on a fresh push (Phase 6). */
|
|
46
|
+
landingTrainSettleMs?: number;
|
|
47
|
+
/** Phase 5: open a directory as a project (a runner's per-goal clone), and close it again. */
|
|
48
|
+
openProject?(dir: string, name: string): Promise<ProjectRuntime>;
|
|
49
|
+
closeProject?(rt: ProjectRuntime): Promise<void>;
|
|
50
|
+
/** Tests: where a runner clones a repo from, and which agent kinds it offers. */
|
|
51
|
+
runnerCloneUrl?(repo: string): string;
|
|
52
|
+
runnerKinds?(): Promise<string[]>;
|
|
53
|
+
/** Tests: the runner's config instead of ~/.loom/runner.json. */
|
|
54
|
+
runnerConfig?(): RunnerConfig;
|
|
55
|
+
runnerAwayMs?: number;
|
|
56
|
+
/** `loom runner exec` inside a container: run this one job, then call done. */
|
|
57
|
+
runnerExec?: {
|
|
58
|
+
teamId: string;
|
|
59
|
+
jobId: string;
|
|
60
|
+
done(ok: boolean): void;
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
export declare class TeamLink {
|
|
64
|
+
private host;
|
|
65
|
+
private file;
|
|
66
|
+
private state;
|
|
67
|
+
private hubClient;
|
|
68
|
+
private views;
|
|
69
|
+
private unsubs;
|
|
70
|
+
private timers;
|
|
71
|
+
private live;
|
|
72
|
+
private logSubs;
|
|
73
|
+
private coordinators;
|
|
74
|
+
private brains;
|
|
75
|
+
private landings;
|
|
76
|
+
private deploys;
|
|
77
|
+
/** Phase 5: this daemon as a runner, when it's configured as one. */
|
|
78
|
+
runner: Runner | null;
|
|
79
|
+
/** Return jobs we asked for → the project whose goal comes home (D76). */
|
|
80
|
+
private pendingReturns;
|
|
81
|
+
private started;
|
|
82
|
+
constructor(host: TeamLinkHost);
|
|
83
|
+
start(): Promise<void>;
|
|
84
|
+
stop(): Promise<void>;
|
|
85
|
+
private hub;
|
|
86
|
+
private makeClient;
|
|
87
|
+
/** Refresh tokens rotate: the one in team.json must always be the newest, or the next start signs us out. */
|
|
88
|
+
private persistHostedSession;
|
|
89
|
+
/** Swap the hub client, closing a hosted one we replace (its refresh timer would race the new one's). */
|
|
90
|
+
private setHubClient;
|
|
91
|
+
/**
|
|
92
|
+
* Sign in to a hub. Hosted (no URL, "hosted", or `supabase:<url>`): GitHub
|
|
93
|
+
* OAuth in the browser, or a refresh token from a CLI that already did it.
|
|
94
|
+
* Self-hosted: as a GitHub login (defaults to the local `gh` user).
|
|
95
|
+
*/
|
|
96
|
+
signIn(url: string, opts?: {
|
|
97
|
+
github?: string;
|
|
98
|
+
secret?: string;
|
|
99
|
+
token?: string;
|
|
100
|
+
}): Promise<void>;
|
|
101
|
+
/** The hosted hub (D65): a Supabase session from GitHub OAuth, kept as its refresh token. */
|
|
102
|
+
private signInHosted;
|
|
103
|
+
private ensureDevice;
|
|
104
|
+
private device;
|
|
105
|
+
/** (Re)attach to the hub: every team we know, live subscriptions, and shared projects. */
|
|
106
|
+
connect(): Promise<void>;
|
|
107
|
+
/** Open any key envelopes sealed to this device we don't have yet (D6). */
|
|
108
|
+
private pullKeys;
|
|
109
|
+
private currentKey;
|
|
110
|
+
private attach;
|
|
111
|
+
private onHubEvent;
|
|
112
|
+
createTeam(name: string): Promise<{
|
|
113
|
+
id: string;
|
|
114
|
+
name: string;
|
|
115
|
+
}>;
|
|
116
|
+
/**
|
|
117
|
+
* An invite link: the token and the current team key ride the #fragment
|
|
118
|
+
* (D5) — never sent to any server, the join page included. `extra` makes it
|
|
119
|
+
* a one-link onboarding (daemon/onboard.ts): the repo to clone, the crews to
|
|
120
|
+
* set up, and whether joining grants push access to the repo.
|
|
121
|
+
*/
|
|
122
|
+
invite(teamId?: string, extra?: {
|
|
123
|
+
repo?: string;
|
|
124
|
+
project?: string;
|
|
125
|
+
crews?: InviteFragment["crews"];
|
|
126
|
+
grant?: boolean;
|
|
127
|
+
}): Promise<{
|
|
128
|
+
link: string;
|
|
129
|
+
expiresAt: number;
|
|
130
|
+
}>;
|
|
131
|
+
/**
|
|
132
|
+
* Is what a link asks for (the repo to clone, the crews to set up) what its
|
|
133
|
+
* inviter signed? Checked once we're on the team and can see the inviter's
|
|
134
|
+
* registered devices: anyone holding the link holds the team key, so only the
|
|
135
|
+
* device signature can't be forged. "unsigned" is a link from an older Loom —
|
|
136
|
+
* or one with the signature stripped, so it gets no more trust than a bad one.
|
|
137
|
+
*/
|
|
138
|
+
verifyInvite(inv: InviteFragment, teamId: string): "ok" | "unsigned" | "bad";
|
|
139
|
+
/** Signed in to this hub already? (A link names its hub.) */
|
|
140
|
+
signedInTo(hub: string): boolean;
|
|
141
|
+
/** This daemon's GitHub login on its hub. */
|
|
142
|
+
github(): string | null;
|
|
143
|
+
/** The teams this daemon is in, with the repos each shares. */
|
|
144
|
+
teams(): Array<{
|
|
145
|
+
id: string;
|
|
146
|
+
name: string;
|
|
147
|
+
repos: string[];
|
|
148
|
+
}>;
|
|
149
|
+
join(link: string, opts?: {
|
|
150
|
+
github?: string;
|
|
151
|
+
secret?: string;
|
|
152
|
+
token?: string;
|
|
153
|
+
}): Promise<{
|
|
154
|
+
id: string;
|
|
155
|
+
name: string;
|
|
156
|
+
alreadyMember?: boolean;
|
|
157
|
+
}>;
|
|
158
|
+
/**
|
|
159
|
+
* Remove a member, then rotate the key forward (D6): a new key, sealed to
|
|
160
|
+
* every remaining device. The removed member keeps what they already saw —
|
|
161
|
+
* nothing new is readable to them.
|
|
162
|
+
*/
|
|
163
|
+
removeMember(userId: string, teamId?: string): Promise<{
|
|
164
|
+
keyVersion: number;
|
|
165
|
+
}>;
|
|
166
|
+
/** When this daemon last rotated each team's key. */
|
|
167
|
+
private rotatedAt;
|
|
168
|
+
rotate(teamId?: string): Promise<{
|
|
169
|
+
keyVersion: number;
|
|
170
|
+
}>;
|
|
171
|
+
leave(teamId?: string): Promise<void>;
|
|
172
|
+
/**
|
|
173
|
+
* Someone redeemed an invite that promised repo access: add them as a
|
|
174
|
+
* collaborator with push, through this machine's `gh` (it's your repo, and
|
|
175
|
+
* your invite). GitHub sends them an invitation their Loom accepts.
|
|
176
|
+
*/
|
|
177
|
+
private grantJoiner;
|
|
178
|
+
private defaultTeam;
|
|
179
|
+
/** Share a project's repo with a team (D8: explicit opt-in). */
|
|
180
|
+
share(rt: ProjectRuntime, teamId?: string): Promise<{
|
|
181
|
+
repo: string;
|
|
182
|
+
teamId: string;
|
|
183
|
+
}>;
|
|
184
|
+
unshare(rt: ProjectRuntime): void;
|
|
185
|
+
/** Which team a project publishes to: its explicit share, else a team whose repo matches its remote (D8). */
|
|
186
|
+
private teamFor;
|
|
187
|
+
/** Whether the last call to the hub got through, and the error when it didn't. */
|
|
188
|
+
private hubOk;
|
|
189
|
+
private connected;
|
|
190
|
+
private noteHub;
|
|
191
|
+
/** The heartbeat timer: reconnect when the hub was down at start, then beat. */
|
|
192
|
+
private tick;
|
|
193
|
+
/** One heartbeat for every live session in every shared project; returns how many the hub took. */
|
|
194
|
+
beat(): Promise<number>;
|
|
195
|
+
private clearAllPresence;
|
|
196
|
+
private watchRuntimes;
|
|
197
|
+
/**
|
|
198
|
+
* Called by the daemon before it drops a runtime (config hot-reload, project
|
|
199
|
+
* removal, a runner's finished clone). Without it the closed runtime stayed
|
|
200
|
+
* pinned here — its landing loop ticking against a closed log — and the
|
|
201
|
+
* reopened one never got a coordinator, team brain or feed of its own.
|
|
202
|
+
*/
|
|
203
|
+
detachRuntime(projectId: string): void;
|
|
204
|
+
/** Called by the daemon when it opens a runtime. */
|
|
205
|
+
attachRuntime(rt: ProjectRuntime): void;
|
|
206
|
+
runnerConfig(): RunnerConfig;
|
|
207
|
+
/** Turn this daemon into a runner (or restart it with new settings). */
|
|
208
|
+
startRunner(patch?: Partial<RunnerConfig>): Promise<Record<string, unknown>>;
|
|
209
|
+
stopRunner(): Promise<void>;
|
|
210
|
+
private onJob;
|
|
211
|
+
/** A one-time link that makes another machine one of your runners (D74). Send it like a password. */
|
|
212
|
+
pairRunnerLink(): string;
|
|
213
|
+
/**
|
|
214
|
+
* On the runner box: take the pairing link's team keys, sign in as the same
|
|
215
|
+
* member (self-hosted: --secret; hosted: a refresh token from the paste-URL
|
|
216
|
+
* flow), register this device, and seal the keys to it.
|
|
217
|
+
*/
|
|
218
|
+
joinAsRunner(link: string, opts?: {
|
|
219
|
+
github?: string;
|
|
220
|
+
secret?: string;
|
|
221
|
+
token?: string;
|
|
222
|
+
shared?: boolean;
|
|
223
|
+
}): Promise<Record<string, unknown>>;
|
|
224
|
+
/** Revoke a runner: remove the device, then rotate every team's key (D74, D6). */
|
|
225
|
+
revokeRunner(deviceId: string): Promise<void>;
|
|
226
|
+
/** Runners that can take this project's goals, and the jobs in flight (decrypted). */
|
|
227
|
+
runnersView(rt: ProjectRuntime): Promise<{
|
|
228
|
+
runners: Array<Record<string, unknown>>;
|
|
229
|
+
jobs: Array<Record<string, unknown>>;
|
|
230
|
+
}>;
|
|
231
|
+
private jobShare;
|
|
232
|
+
/** Pick a runner: the one named, else my first online one. */
|
|
233
|
+
private pickRunner;
|
|
234
|
+
/** Start a new goal on a runner (D69, D73). */
|
|
235
|
+
startCrewOnRunner(rt: ProjectRuntime, id: string, text: string, runner?: string): Promise<{
|
|
236
|
+
jobId: string;
|
|
237
|
+
}>;
|
|
238
|
+
controlRunnerCrew(rt: ProjectRuntime, jobId: string, action: NonNullable<JobPayload["crewAction"]>["action"], text?: string, to?: string): Promise<{
|
|
239
|
+
jobId: string;
|
|
240
|
+
}>;
|
|
241
|
+
requestCrew(rt: ProjectRuntime, input: {
|
|
242
|
+
owner: string;
|
|
243
|
+
crew: string;
|
|
244
|
+
teammate: string;
|
|
245
|
+
text: string;
|
|
246
|
+
}): Promise<{
|
|
247
|
+
requestId: string;
|
|
248
|
+
}>;
|
|
249
|
+
answerCrewRequest(rt: ProjectRuntime, requestId: string, accept: boolean): Promise<{
|
|
250
|
+
delivery: string;
|
|
251
|
+
}>;
|
|
252
|
+
startOnRunner(rt: ProjectRuntime, g: {
|
|
253
|
+
goal: string;
|
|
254
|
+
orchestrator?: string;
|
|
255
|
+
workers?: string[];
|
|
256
|
+
plan?: boolean;
|
|
257
|
+
runner?: string;
|
|
258
|
+
}): Promise<{
|
|
259
|
+
jobId: string;
|
|
260
|
+
}>;
|
|
261
|
+
/** Move a running goal to a runner at a safe point (D75). */
|
|
262
|
+
continueOnRunner(rt: ProjectRuntime, runId: string, opts?: {
|
|
263
|
+
runner?: string;
|
|
264
|
+
graceMs?: number;
|
|
265
|
+
}): Promise<{
|
|
266
|
+
jobId: string;
|
|
267
|
+
}>;
|
|
268
|
+
/** The runner job currently holding a goal. */
|
|
269
|
+
private holderJob;
|
|
270
|
+
/** Bring a goal home from the runner (D76): the runner moves it out, this daemon imports it. */
|
|
271
|
+
bringBack(rt: ProjectRuntime, runId: string): Promise<{
|
|
272
|
+
jobId: string;
|
|
273
|
+
}>;
|
|
274
|
+
/** Land a goal that lives on a runner (the owner's click, carried as a job). */
|
|
275
|
+
landOnRunner(rt: ProjectRuntime, runId: string): Promise<{
|
|
276
|
+
jobId: string;
|
|
277
|
+
}>;
|
|
278
|
+
/** Phase 5 (D72): the project's deploy watch and release notes. */
|
|
279
|
+
deploysFor(rt: ProjectRuntime): Deploys;
|
|
280
|
+
/** One deploy poll per shared repo (the feed dedupes across members). */
|
|
281
|
+
pollDeploys(): Promise<number>;
|
|
282
|
+
/** Phase 4: the project's goal PRs — checks, fixes, review, landing, adopt. */
|
|
283
|
+
landingFor(rt: ProjectRuntime): Landing;
|
|
284
|
+
/** Phase 2: the project's team coordinator, created once and handed to its orchestra. */
|
|
285
|
+
coordinatorFor(rt: ProjectRuntime): TeamCoordinator;
|
|
286
|
+
/** Phase 3: the project's share of the team brain, created once and handed to its runtime. */
|
|
287
|
+
brainFor(rt: ProjectRuntime): TeamBrain;
|
|
288
|
+
/** Sync every open project's team brain (backfill, publish, canon). */
|
|
289
|
+
syncBrains(): Promise<void>;
|
|
290
|
+
private onProjectEvent;
|
|
291
|
+
pollGitHub(): Promise<number>;
|
|
292
|
+
/** Where a repo webhook posts for this team: the self-hosted hub's route, or the hosted hub's Edge Function. */
|
|
293
|
+
webhookUrl(teamId: string): string;
|
|
294
|
+
/**
|
|
295
|
+
* The team's webhook: its payload URL and secret (owners only; created on
|
|
296
|
+
* first ask, replaced with `rotate`), and with `install` a repo webhook made
|
|
297
|
+
* through `gh` for the events Loom maps. The repo defaults to the project's
|
|
298
|
+
* shared repo, or the team's only one.
|
|
299
|
+
*/
|
|
300
|
+
webhook(opts?: {
|
|
301
|
+
teamId?: string;
|
|
302
|
+
repo?: string;
|
|
303
|
+
install?: boolean;
|
|
304
|
+
rotate?: boolean;
|
|
305
|
+
rt?: ProjectRuntime;
|
|
306
|
+
}): Promise<{
|
|
307
|
+
teamId: string;
|
|
308
|
+
url: string;
|
|
309
|
+
secret: string;
|
|
310
|
+
repo: string | null;
|
|
311
|
+
events: string[];
|
|
312
|
+
installed?: {
|
|
313
|
+
id: number | null;
|
|
314
|
+
repo: string;
|
|
315
|
+
};
|
|
316
|
+
warning?: string;
|
|
317
|
+
}>;
|
|
318
|
+
status(): Record<string, unknown>;
|
|
319
|
+
private decryptPresence;
|
|
320
|
+
/** A lease for the UI: who, which goal/task (decrypted), what it covers, and its state. */
|
|
321
|
+
private decryptLease;
|
|
322
|
+
private decryptFeed;
|
|
323
|
+
private decryptEvent;
|
|
324
|
+
}
|
|
325
|
+
/**
|
|
326
|
+
* The live sessions in one project, as presence: busy roster agents and every
|
|
327
|
+
* orchestra task that is running or queued. Titles go in `intent` (sealed);
|
|
328
|
+
* everything in `presence` is plain metadata (D2, D24).
|
|
329
|
+
*/
|
|
330
|
+
export declare function sessionsOf(rt: ProjectRuntime, repo: string): Array<{
|
|
331
|
+
presence: Omit<PresenceIn, "deviceId">;
|
|
332
|
+
intent: Record<string, unknown>;
|
|
333
|
+
}>;
|
|
334
|
+
/**
|
|
335
|
+
* PR and check facts from one `gh pr list` row, as idempotent feed events. The
|
|
336
|
+
* mapping lives in core/github-events.ts, shared with the webhook receivers so
|
|
337
|
+
* polling and webhooks produce the same dedupe keys (D84).
|
|
338
|
+
*/
|
|
339
|
+
export declare function githubFeedEvents(repo: string, pr: Record<string, unknown>): FeedIn[];
|