crow-central-agency 0.25.15 → 0.26.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/README.md +4 -1
- package/dist/_shared/index.js +2 -2
- package/dist/_shared/schemas/agent-runtime-state.schema.js +9 -0
- package/dist/_shared/schemas/agent.schema.js +100 -21
- package/dist/_shared/schemas/permission.schema.js +2 -1
- package/dist/_shared/schemas/system-capabilities.schema.js +7 -0
- package/dist/_shared/schemas/websocket.schema.js +1 -1
- package/dist/_shared/utils/resolve-model.js +2 -1
- package/dist/bootstrap.js +31 -50
- package/dist/config/constants.js +2 -0
- package/dist/config/env.js +5 -0
- package/dist/core/store/file-object-store-provider.js +2 -1
- package/dist/core/store/folder-file-store-provider.js +2 -1
- package/dist/mcp/agents/agents-mcp-server.js +7 -13
- package/dist/mcp/agents/get-last-agent-message.js +1 -1
- package/dist/mcp/agents/super-agent-mcp-server.js +8 -7
- package/dist/mcp/artifacts/artifacts-mcp-server.js +17 -39
- package/dist/mcp/audio/audio-mcp-server.js +5 -10
- package/dist/mcp/claude-mcp-adapter.js +28 -0
- package/dist/mcp/copilot-mcp-adapter.js +42 -0
- package/dist/mcp/crow-mcp-manager-utils.js +10 -0
- package/dist/mcp/crow-mcp-manager.js +51 -66
- package/dist/mcp/feed/feed-mcp-server.js +10 -21
- package/dist/mcp/gmail/gmail-mcp-server.js +25 -72
- package/dist/mcp/google-calendar/google-calendar-mcp-server.js +15 -36
- package/dist/mcp/google-contacts/google-contacts-mcp-server.js +8 -16
- package/dist/mcp/places/places-mcp-server.js +7 -22
- package/dist/mcp/reminders/reminders-mcp-server.js +10 -20
- package/dist/mcp/tasks/super-tasks-mcp-server.js +9 -13
- package/dist/mcp/tasks/tasks-mcp-server.js +7 -13
- package/dist/public/assets/arc-LKCA62S1.js +1 -0
- package/dist/public/assets/architecture-7EHR7CIX-zH1TbhTt.js +1 -0
- package/dist/public/assets/architectureDiagram-3BPJPVTR-CK5BMF1A.js +36 -0
- package/dist/public/assets/blockDiagram-GPEHLZMM-CNTMGL7i.js +132 -0
- package/dist/public/assets/{c4Diagram-AAUBKEIU-CfNw2F8Y.js → c4Diagram-AAUBKEIU-DgNu6oJg.js} +6 -6
- package/dist/public/assets/channel-B8gxUeqY.js +1 -0
- package/dist/public/assets/chunk-2J33WTMH-D8RFUR7M.js +1 -0
- package/dist/public/assets/chunk-4BX2VUAB-l28MUHiw.js +1 -0
- package/dist/public/assets/chunk-55IACEB6-qE2fLYWo.js +1 -0
- package/dist/public/assets/{chunk-727SXJPM-BfeyHhX3.js → chunk-727SXJPM-B8PRCIMl.js} +6 -6
- package/dist/public/assets/chunk-AQP2D5EJ-CDkzHEGb.js +231 -0
- package/dist/public/assets/{chunk-FMBD7UC4-BmSnKVIn.js → chunk-FMBD7UC4-BAyYRcn7.js} +1 -1
- package/dist/public/assets/chunk-ND2GUHAM-DoPlQyZt.js +1 -0
- package/dist/public/assets/chunk-QZHKN3VN-C32y4CkX.js +1 -0
- package/dist/public/assets/classDiagram-4FO5ZUOK-DH4gfYvh.js +1 -0
- package/dist/public/assets/classDiagram-v2-Q7XG4LA2-DH4gfYvh.js +1 -0
- package/dist/public/assets/cose-bilkent-S5V4N54A-DR9FRq6C.js +1 -0
- package/dist/public/assets/{cytoscape.esm-C8j07I8O.js → cytoscape.esm-DRHT7IHm.js} +2 -2
- package/dist/public/assets/dagre-BM42HDAG-Ce0KEoX3.js +4 -0
- package/dist/public/assets/{dagre-CdwzCXQr.js → dagre-Bx709z4p.js} +1 -1
- package/dist/public/assets/diagram-2AECGRRQ-wgIS8rW7.js +43 -0
- package/dist/public/assets/diagram-5GNKFQAL-pHAvTjDc.js +10 -0
- package/dist/public/assets/diagram-KO2AKTUF-nLJ2bAVV.js +3 -0
- package/dist/public/assets/diagram-LMA3HP47-CIrdymsD.js +24 -0
- package/dist/public/assets/diagram-OG6HWLK6-DKwaiowJ.js +24 -0
- package/dist/public/assets/erDiagram-TEJ5UH35-Z3nVlY_z.js +85 -0
- package/dist/public/assets/eventmodeling-FCH6USID-BptPyCTT.js +1 -0
- package/dist/public/assets/flowDiagram-I6XJVG4X-C26I_a5o.js +162 -0
- package/dist/public/assets/ganttDiagram-6RSMTGT7-0UGQgnfu.js +292 -0
- package/dist/public/assets/gitGraph-WXDBUCRP-D_VL05ra.js +1 -0
- package/dist/public/assets/gitGraphDiagram-PVQCEYII-_--Gzz1h.js +106 -0
- package/dist/public/assets/index-B36l7vHE.js +732 -0
- package/dist/public/assets/index-DdDKmqq6.css +1 -0
- package/dist/public/assets/info-J43DQDTF-Cm1wY6Nx.js +1 -0
- package/dist/public/assets/infoDiagram-5YYISTIA-CJpFz_PZ.js +2 -0
- package/dist/public/assets/{ishikawaDiagram-YF4QCWOH-CTHFJ3PY.js → ishikawaDiagram-YF4QCWOH-Cv3wIcZA.js} +6 -6
- package/dist/public/assets/{journeyDiagram-JHISSGLW-f1neaHqp.js → journeyDiagram-JHISSGLW-PfUWHugP.js} +6 -6
- package/dist/public/assets/kanban-definition-UN3LZRKU-BmLyUwuA.js +89 -0
- package/dist/public/assets/linear-Da3F7V4b.js +1 -0
- package/dist/public/assets/mermaid-parser.core-7Ey7SEGP.js +161 -0
- package/dist/public/assets/{mindmap-definition-RKZ34NQL-BE67pK4Q.js → mindmap-definition-RKZ34NQL-qbrrivB7.js} +30 -30
- package/dist/public/assets/{ordinal-BDTCIhXR.js → ordinal-hYBb2elL.js} +1 -1
- package/dist/public/assets/packet-YPE3B663-GOR4bfOj.js +1 -0
- package/dist/public/assets/pie-LRSECV5Y-D4D0Pa0z.js +1 -0
- package/dist/public/assets/pieDiagram-4H26LBE5-BH62GO3E.js +30 -0
- package/dist/public/assets/{quadrantDiagram-W4KKPZXB-B6zQ9hKH.js → quadrantDiagram-W4KKPZXB-CHrUks1Q.js} +6 -6
- package/dist/public/assets/radar-GUYGQ44K-BRGEU-xO.js +1 -0
- package/dist/public/assets/requirementDiagram-4Y6WPE33-OqjULFTW.js +84 -0
- package/dist/public/assets/sankeyDiagram-5OEKKPKP--kcBt1SK.js +40 -0
- package/dist/public/assets/sequenceDiagram-3UESZ5HK-ChkuxTQ9.js +162 -0
- package/dist/public/assets/stateDiagram-AJRCARHV-DphBd-H5.js +1 -0
- package/dist/public/assets/stateDiagram-v2-BHNVJYJU-_O2Xui-T.js +1 -0
- package/dist/public/assets/timeline-definition-PNZ67QCA-B-rBCMtQ.js +120 -0
- package/dist/public/assets/treeView-BLDUP644-y-i1DlhL.js +1 -0
- package/dist/public/assets/treemap-LRROVOQU-EMtKLq4-.js +1 -0
- package/dist/public/assets/vennDiagram-CIIHVFJN-Dg_9pO6d.js +34 -0
- package/dist/public/assets/wardley-L42UT6IY--JXBaJ-Y.js +1 -0
- package/dist/public/assets/wardleyDiagram-YWT4CUSO-8rZjOpIv.js +78 -0
- package/dist/public/assets/{xychartDiagram-2RQKCTM6-Ca_INdQE.js → xychartDiagram-2RQKCTM6-C8Zipv7z.js} +7 -7
- package/dist/public/index.html +2 -16
- package/dist/routes/agent.routes.js +7 -12
- package/dist/routes/system.routes.js +6 -1
- package/dist/runner/agent-runner-factory.js +13 -0
- package/dist/runner/agent-runner.js +70 -197
- package/dist/runner/agent-runner.types.js +5 -1
- package/dist/runner/claude-code-agent-runner.js +217 -0
- package/dist/runner/github-copilot-agent-runner.js +361 -0
- package/dist/runner/github-copilot-stream-processor.js +244 -0
- package/dist/runner/stream-processor.js +100 -60
- package/dist/services/agent-registry.js +73 -12
- package/dist/services/copilot/copilot-client-manager.js +96 -0
- package/dist/services/runtime/agent-runtime-manager.js +92 -31
- package/dist/services/session/github-copilot-session-transformer.js +103 -0
- package/dist/services/session/session-manager.js +82 -36
- package/dist/services/session/session-message-transformer.js +50 -14
- package/dist/utils/fs-utils.js +28 -0
- package/dist/utils/message-template.js +9 -2
- package/package.json +10 -6
- package/dist/public/assets/arc-CsY_zjlK.js +0 -1
- package/dist/public/assets/architecture-7EHR7CIX-tMtXFVEB.js +0 -1
- package/dist/public/assets/architectureDiagram-3BPJPVTR-9TvRi97E.js +0 -36
- package/dist/public/assets/array-BCJ35G43.js +0 -1
- package/dist/public/assets/blockDiagram-GPEHLZMM-DoCXJ5ls.js +0 -132
- package/dist/public/assets/channel-Dd0F8Asv.js +0 -1
- package/dist/public/assets/chunk-2J33WTMH-3331Pgxl.js +0 -1
- package/dist/public/assets/chunk-3OPIFGDE-BKv-wmbR.js +0 -62
- package/dist/public/assets/chunk-4BX2VUAB-BMyZq3AL.js +0 -1
- package/dist/public/assets/chunk-4EGX6M5U-sKH2Isf8.js +0 -1
- package/dist/public/assets/chunk-55IACEB6-KxLP_rA2.js +0 -1
- package/dist/public/assets/chunk-5DO6E6H7-DVriMWxp.js +0 -1
- package/dist/public/assets/chunk-5ZQYHXKU-DPF6Nbp6.js +0 -2
- package/dist/public/assets/chunk-AQP2D5EJ-C-KYUGz_.js +0 -231
- package/dist/public/assets/chunk-BR22UD5L-BCm2xrxa.js +0 -1
- package/dist/public/assets/chunk-BSJP7CBP-BR3QhkOV.js +0 -1
- package/dist/public/assets/chunk-CSCIHK7Q-DLKpWijG.js +0 -123
- package/dist/public/assets/chunk-FHYWG6QK-B_z4diOF.js +0 -1
- package/dist/public/assets/chunk-KSCS5N6A-lSKMV-28.js +0 -10
- package/dist/public/assets/chunk-L5ZTLDWV-CGRen0bj.js +0 -1
- package/dist/public/assets/chunk-MPE355IW-BrU23f3r.js +0 -1
- package/dist/public/assets/chunk-MZUSXYTE-BGj-wpbJ.js +0 -1
- package/dist/public/assets/chunk-N66VUXT2-Bx9F_D4P.js +0 -1
- package/dist/public/assets/chunk-ND2GUHAM-8gjQJdQa.js +0 -1
- package/dist/public/assets/chunk-NNHCCRGN-DSaPFNsL.js +0 -159
- package/dist/public/assets/chunk-NZK2D7GU-N89m32gx.js +0 -1
- package/dist/public/assets/chunk-O5CBEL6O-PSoVuMlj.js +0 -70
- package/dist/public/assets/chunk-PUPMXCY4-C2l0dHY4.js +0 -1
- package/dist/public/assets/chunk-QZHKN3VN-a8z_MdJs.js +0 -1
- package/dist/public/assets/chunk-UIBZB4QT-DXVjm6Jo.js +0 -1
- package/dist/public/assets/chunk-WCWK7LTN-zc10zcLo.js +0 -1
- package/dist/public/assets/classDiagram-4FO5ZUOK-C9w3agu_.js +0 -1
- package/dist/public/assets/classDiagram-v2-Q7XG4LA2-CpUKoJ52.js +0 -1
- package/dist/public/assets/cose-bilkent-S5V4N54A-DOWSzIsN.js +0 -1
- package/dist/public/assets/dagre-BM42HDAG-Ce7Ld63g.js +0 -4
- package/dist/public/assets/diagram-2AECGRRQ-o3S-oIto.js +0 -43
- package/dist/public/assets/diagram-5GNKFQAL-kwodm072.js +0 -10
- package/dist/public/assets/diagram-KO2AKTUF-DAUGVDbr.js +0 -3
- package/dist/public/assets/diagram-LMA3HP47-CvBO5s9j.js +0 -24
- package/dist/public/assets/diagram-OG6HWLK6-DMYgoLxd.js +0 -24
- package/dist/public/assets/dist-BfHOg9lx.js +0 -1
- package/dist/public/assets/erDiagram-TEJ5UH35-BVbecP6k.js +0 -85
- package/dist/public/assets/eventmodeling-FCH6USID-Cmphiy0Z.js +0 -1
- package/dist/public/assets/flowDiagram-I6XJVG4X-C0GEOwl9.js +0 -162
- package/dist/public/assets/ganttDiagram-6RSMTGT7-CaDG38zZ.js +0 -292
- package/dist/public/assets/gitGraph-WXDBUCRP-CABAU2x_.js +0 -1
- package/dist/public/assets/gitGraphDiagram-PVQCEYII-CL-N79e7.js +0 -106
- package/dist/public/assets/index-CzCZcpyx.js +0 -470
- package/dist/public/assets/index-EsNd-fN-.css +0 -1
- package/dist/public/assets/info-J43DQDTF-CtHtznhp.js +0 -1
- package/dist/public/assets/infoDiagram-5YYISTIA-B1j6nD2W.js +0 -2
- package/dist/public/assets/kanban-definition-UN3LZRKU-RUmbIteU.js +0 -89
- package/dist/public/assets/line-RIsgg21t.js +0 -1
- package/dist/public/assets/linear-751DW27F.js +0 -1
- package/dist/public/assets/mermaid-parser.core-CcqYIDrD.js +0 -4
- package/dist/public/assets/packet-YPE3B663-DmtvbI4l.js +0 -1
- package/dist/public/assets/path-CIRGLb_6.js +0 -1
- package/dist/public/assets/pie-LRSECV5Y-Y82O9nng.js +0 -1
- package/dist/public/assets/pieDiagram-4H26LBE5-oiJiLU45.js +0 -30
- package/dist/public/assets/radar-GUYGQ44K-BHcHsGeF.js +0 -1
- package/dist/public/assets/requirementDiagram-4Y6WPE33-968MHQeI.js +0 -84
- package/dist/public/assets/rough.esm-C6nrIGLg.js +0 -1
- package/dist/public/assets/sankeyDiagram-5OEKKPKP-DPJgtc19.js +0 -40
- package/dist/public/assets/sequenceDiagram-3UESZ5HK-DyGfAwkb.js +0 -162
- package/dist/public/assets/src-g536F3ys.js +0 -1
- package/dist/public/assets/stateDiagram-AJRCARHV-WNH3snb9.js +0 -1
- package/dist/public/assets/stateDiagram-v2-BHNVJYJU-3TPuvzdl.js +0 -1
- package/dist/public/assets/timeline-definition-PNZ67QCA-C7Qsj2Nv.js +0 -120
- package/dist/public/assets/treeView-BLDUP644-Cmu4mPLp.js +0 -1
- package/dist/public/assets/treemap-LRROVOQU-_N62KlUg.js +0 -1
- package/dist/public/assets/vennDiagram-CIIHVFJN-DPuyKEPT.js +0 -34
- package/dist/public/assets/wardley-L42UT6IY-DWSXD3L4.js +0 -1
- package/dist/public/assets/wardleyDiagram-YWT4CUSO-2wV-C8AE.js +0 -78
- /package/dist/public/assets/{defaultLocale-CIS5GEjP.js → defaultLocale-C8Fc0cco.js} +0 -0
- /package/dist/public/assets/{graphlib-B0DVs0bw.js → graphlib-B8gBHxth.js} +0 -0
- /package/dist/public/assets/{init-BMBYmmUa.js → init-D6jRqBbL.js} +0 -0
- /package/dist/public/assets/{katex-pVJiI_rc.js → katex-C4eR7coU.js} +0 -0
package/README.md
CHANGED
|
@@ -6,7 +6,8 @@ Use it to build research crews, monitoring watchdogs, content pipelines, support
|
|
|
6
6
|
|
|
7
7
|
## Features
|
|
8
8
|
|
|
9
|
-
- **Multi-agent dashboard** - run many
|
|
9
|
+
- **Multi-agent dashboard** - run many agents in parallel, each with its own workspace, model, persona, and tool set. Agents can be backed by Claude Code or GitHub Copilot.
|
|
10
|
+
- **GitHub Copilot agents** - alongside Claude Code, agents can run on the GitHub Copilot SDK using your Copilot subscription. Enabled by default; toggle off with `DISABLE_GITHUB_COPILOT`.
|
|
10
11
|
- **Agent coordination** - compose agents into layered relationships that produce and share artifacts, adaptable to a wide range of workflows and scenarios.
|
|
11
12
|
- **Flexible triggers** - ad-hoc chat, assigned tasks, reminders, or scheduled prompts on configurable day-of-week / time-of-day windows.
|
|
12
13
|
- **Rich configuration** - per-agent MCP servers, permission modes, Discord bots, RSS feeds (with optional LLM summarization), and AI-assisted persona / `AGENT.md` generation.
|
|
@@ -98,6 +99,8 @@ See `.env.example` for the full list, including:
|
|
|
98
99
|
- `CROW_SYSTEM_AGENT_NAME` — display name for the built-in Crow system agent (default: `Crow`).
|
|
99
100
|
- `STATIC_PATH` — override the directory served as frontend assets (auto-detected from the published bundle).
|
|
100
101
|
- `CLAUDE_CLI_PATH` — explicit path to the Claude Code CLI binary when it is not on `PATH`.
|
|
102
|
+
- `DISABLE_GITHUB_COPILOT` — set to `true` (or `1`) to skip starting the Copilot SDK client at boot, so GitHub Copilot is reported unavailable everywhere. Defaults to `false`.
|
|
103
|
+
- `COPILOT_CLI_PATH` — override the Copilot CLI runtime the SDK spawns (read directly by `@github/copilot-sdk`); leave unset to use the bundled runtime.
|
|
101
104
|
- `CLOSED_TASK_RETENTION_DAYS` — how long to keep closed tasks before pruning on startup (default: `30`).
|
|
102
105
|
- `FEED_ITEM_RETENTION_DAYS` / `FEED_REFRESH_IN_MINUTES` — feed item retention window and refresh cadence.
|
|
103
106
|
- `TEXT_GENERATION_*` — optional OpenAI-compatible endpoint that enables the AI-assisted persona / `AGENT.md` generation features in the agent editor.
|
package/dist/_shared/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { CLAUDE_MODELS, CLAUDE_CODE_MODEL_OPTIONS,
|
|
1
|
+
export { CLAUDE_MODELS, GITHUB_COPILOT_MODELS, CLAUDE_CODE_MODEL_OPTIONS, ModelOptionSchema, CLAUDE_DEFAULT_MODEL, COPILOT_DEFAULT_MODEL, AgentIdSchema, AgentConfigSchema, AgentConfigTemplateSchema, CreateAgentInputSchema, UpdateAgentInputSchema, ToolConfigSchema, PermissionModeSchema, SettingSourceSchema, DiscoveredSkillSchema, LoopConfigSchema, ConfiguredFeedSchema, MAX_LOOP_TIMES, PERMISSION_MODE, SETTING_SOURCE, DEFAULT_SETTING_SOURCES, TOOL_MODE, DEFAULT_CLAUDE_CODE_AVAILABLE_TOOLS, DEFAULT_GITHUB_COPILOT_AVAILABLE_TOOLS, DEFAULT_AVAILABLE_TOOLS_BY_TYPE, SUBAGENT_TOOL_NAME, AGENT_TYPE, } from "./schemas/agent.schema.js";
|
|
2
2
|
export { SchedulerTimeSchema, DAY_OF_WEEK, DayOfWeekSchema, TimeModeSchema, TIME_MODE, } from "./schemas/scheduler.schema.js";
|
|
3
3
|
export { createApiSuccessSchema, ApiErrorSchema, } from "./schemas/api-response.schema.js";
|
|
4
|
-
export { SessionUsageSchema, PendingPermissionInfoSchema, AgentRuntimeStateSchema, AgentActivitySchema, AGENT_ACTIVITY_TYPE, AGENT_STATUS, } from "./schemas/agent-runtime-state.schema.js";
|
|
4
|
+
export { SessionUsageSchema, PendingPermissionInfoSchema, PendingInstructionReminderSchema, AgentRuntimeStateSchema, AgentActivitySchema, AGENT_ACTIVITY_TYPE, AGENT_STATUS, } from "./schemas/agent-runtime-state.schema.js";
|
|
5
5
|
export { ClientMessageSchema, ServerMessageSchema, SendMessageSchema, InjectMessageSchema, PermissionResponseWsSchema, AgentTextWsMessageSchema, AgentActivityWsMessageSchema, AgentResultWsMessageSchema, AgentStatusWsMessageSchema, AgentCreatedWsMessageSchema, AgentUpdatedWsMessageSchema, AgentDeletedWsMessageSchema, AgentUsageWsMessageSchema, PermissionRequestWsMessageSchema, PermissionCancelledWsMessageSchema, ErrorWsMessageSchema, AgentMessageWsMessageSchema, AgentToolProgressWsMessageSchema, TaskAddedWsMessageSchema, TaskUpdatedWsMessageSchema, TaskAssignedWsMessageSchema, TaskStateChangedWsMessageSchema, TaskDeletedWsMessageSchema, CircleCreatedWsMessageSchema, CircleUpdatedWsMessageSchema, CircleDeletedWsMessageSchema, RelationshipCreatedWsMessageSchema, RelationshipDeletedWsMessageSchema, CLIENT_MESSAGE_TYPE, SERVER_MESSAGE_TYPE, } from "./schemas/websocket.schema.js";
|
|
6
6
|
export { PERMISSION_DECISION, PermissionRequestSchema, PermissionResponseSchema, } from "./schemas/permission.schema.js";
|
|
7
7
|
export { AgentMessageSchema, MessageAnnotationSchema, AGENT_MESSAGE_ROLE, AGENT_MESSAGE_TYPE, } from "./schemas/agent-message.schema.js";
|
|
@@ -56,6 +56,14 @@ export const PendingPermissionInfoSchema = z.object({
|
|
|
56
56
|
input: z.record(z.string(), z.unknown()).optional(),
|
|
57
57
|
decisionReason: z.string().optional(),
|
|
58
58
|
});
|
|
59
|
+
/**
|
|
60
|
+
* One-shot flags marking which instruction sources changed since the agent's last turn.
|
|
61
|
+
* Set when persona/AGENT.md is edited and cleared after the next turn injects a reminder.
|
|
62
|
+
*/
|
|
63
|
+
export const PendingInstructionReminderSchema = z.object({
|
|
64
|
+
persona: z.boolean().optional(),
|
|
65
|
+
agentMd: z.boolean().optional(),
|
|
66
|
+
});
|
|
59
67
|
/**
|
|
60
68
|
* Agent runtime state - maintained by the runtime manager per agent.
|
|
61
69
|
*/
|
|
@@ -72,5 +80,6 @@ export const AgentRuntimeStateSchema = z.object({
|
|
|
72
80
|
lastGmailCheckTimestamp: z.number().optional(),
|
|
73
81
|
lastError: z.string().optional(),
|
|
74
82
|
pendingPermissions: z.array(PendingPermissionInfoSchema).optional(),
|
|
83
|
+
pendingInstructionReminder: PendingInstructionReminderSchema.optional(),
|
|
75
84
|
});
|
|
76
85
|
//# sourceMappingURL=agent-runtime-state.schema.js.map
|
|
@@ -5,17 +5,38 @@ export const CLAUDE_MODELS = {
|
|
|
5
5
|
HAIKU: "claude-haiku-4-5",
|
|
6
6
|
SONNET: "claude-sonnet-4-6",
|
|
7
7
|
SONNET_4_5: "claude-sonnet-4-5",
|
|
8
|
-
OPUS: "claude-opus-4-
|
|
8
|
+
OPUS: "claude-opus-4-8",
|
|
9
|
+
OPUS_4_7: "claude-opus-4-7",
|
|
9
10
|
OPUS_4_6: "claude-opus-4-6",
|
|
10
11
|
OPUS_4_5: "claude-opus-4-5",
|
|
12
|
+
FABLE: "claude-fable-5",
|
|
11
13
|
};
|
|
14
|
+
export const GITHUB_COPILOT_MODELS = {
|
|
15
|
+
AUTO: "auto",
|
|
16
|
+
HAIKU: "claude-haiku-4.5",
|
|
17
|
+
SONNET: "claude-sonnet-4.6",
|
|
18
|
+
OPUS: "claude-opus-4.8",
|
|
19
|
+
GPT_5_5: "gpt-5.5",
|
|
20
|
+
GPT_5_4: "gpt-5.4",
|
|
21
|
+
GPT_5_3_CODEX: "gpt-5.3-codex",
|
|
22
|
+
GPT_5_4_MINI: "gpt-5.4-mini",
|
|
23
|
+
GPT_5_MINI: "gpt-5-mini",
|
|
24
|
+
};
|
|
25
|
+
/** A selectable agent model, surfaced to the editor's model picker. */
|
|
26
|
+
export const ModelOptionSchema = z.object({
|
|
27
|
+
value: z.string(),
|
|
28
|
+
label: z.string(),
|
|
29
|
+
});
|
|
12
30
|
export const CLAUDE_CODE_MODEL_OPTIONS = [
|
|
13
31
|
{ value: CLAUDE_MODELS.SONNET, label: "Claude Sonnet 4.6" },
|
|
14
|
-
{ value: CLAUDE_MODELS.OPUS, label: "Claude Opus 4.
|
|
32
|
+
{ value: CLAUDE_MODELS.OPUS, label: "Claude Opus 4.8" },
|
|
33
|
+
{ value: CLAUDE_MODELS.OPUS_4_7, label: "Claude Opus 4.7" },
|
|
15
34
|
{ value: CLAUDE_MODELS.HAIKU, label: "Claude Haiku 4.5" },
|
|
35
|
+
{ value: CLAUDE_MODELS.FABLE, label: "Claude Fable 5" },
|
|
16
36
|
];
|
|
17
37
|
/** Default model for new agents */
|
|
18
|
-
export const
|
|
38
|
+
export const CLAUDE_DEFAULT_MODEL = CLAUDE_MODELS.SONNET;
|
|
39
|
+
export const COPILOT_DEFAULT_MODEL = GITHUB_COPILOT_MODELS.AUTO;
|
|
19
40
|
/**
|
|
20
41
|
* Tool configuration modes for agent tool availability.
|
|
21
42
|
*/
|
|
@@ -28,32 +49,63 @@ export const TOOL_MODE = {
|
|
|
28
49
|
/** The SDK tool name used to launch a subagent */
|
|
29
50
|
export const SUBAGENT_TOOL_NAME = "Agent";
|
|
30
51
|
/**
|
|
31
|
-
* Default
|
|
52
|
+
* Default builtin tool catalog for Claude Code agents.
|
|
32
53
|
*/
|
|
33
|
-
export const
|
|
54
|
+
export const DEFAULT_CLAUDE_CODE_AVAILABLE_TOOLS = [
|
|
34
55
|
"AskUserQuestion",
|
|
35
56
|
"Bash",
|
|
57
|
+
"CronCreate",
|
|
58
|
+
"CronDelete",
|
|
59
|
+
"CronList",
|
|
60
|
+
"Edit",
|
|
61
|
+
"EnterPlanMode",
|
|
62
|
+
"EnterWorktree",
|
|
63
|
+
"ExitPlanMode",
|
|
64
|
+
"ExitWorktree",
|
|
36
65
|
"Glob",
|
|
37
66
|
"Grep",
|
|
67
|
+
"LSP",
|
|
68
|
+
"Monitor",
|
|
69
|
+
"NotebookEdit",
|
|
70
|
+
"PowerShell",
|
|
71
|
+
"PushNotification",
|
|
38
72
|
"Read",
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"WebSearch",
|
|
73
|
+
"RemoteTrigger",
|
|
74
|
+
"ScheduleWakeup",
|
|
75
|
+
"Skill",
|
|
43
76
|
"Task",
|
|
77
|
+
"TaskCreate",
|
|
78
|
+
"TaskGet",
|
|
79
|
+
"TaskList",
|
|
44
80
|
"TaskOutput",
|
|
45
81
|
"TaskStop",
|
|
46
|
-
"
|
|
47
|
-
"NotebookEdit",
|
|
48
|
-
"Skill",
|
|
49
|
-
"EnterPlanMode",
|
|
50
|
-
"ExitPlanMode",
|
|
51
|
-
"EnterWorktree",
|
|
52
|
-
"ExitWorktree",
|
|
53
|
-
"CronCreate",
|
|
54
|
-
"CronDelete",
|
|
55
|
-
"CronList",
|
|
82
|
+
"TaskUpdate",
|
|
56
83
|
"ToolSearch",
|
|
84
|
+
"WebFetch",
|
|
85
|
+
"WebSearch",
|
|
86
|
+
"Workflow",
|
|
87
|
+
"Write",
|
|
88
|
+
];
|
|
89
|
+
/**
|
|
90
|
+
* Default builtin tool catalog for GitHub Copilot agents.
|
|
91
|
+
*/
|
|
92
|
+
export const DEFAULT_GITHUB_COPILOT_AVAILABLE_TOOLS = [
|
|
93
|
+
"bash",
|
|
94
|
+
"write_bash",
|
|
95
|
+
"read_bash",
|
|
96
|
+
"stop_bash",
|
|
97
|
+
"list_bash",
|
|
98
|
+
"view",
|
|
99
|
+
"create",
|
|
100
|
+
"edit",
|
|
101
|
+
"web_fetch",
|
|
102
|
+
"report_intent",
|
|
103
|
+
"fetch_copilot_cli_documentation",
|
|
104
|
+
"skill",
|
|
105
|
+
"ask_user",
|
|
106
|
+
"grep",
|
|
107
|
+
"glob",
|
|
108
|
+
"task",
|
|
57
109
|
];
|
|
58
110
|
/**
|
|
59
111
|
* Setting sources matching SDK SettingSource type.
|
|
@@ -83,6 +135,13 @@ export const PERMISSION_MODE = {
|
|
|
83
135
|
};
|
|
84
136
|
export const AGENT_TYPE = {
|
|
85
137
|
CLAUDE_CODE: "CLAUDE_CODE",
|
|
138
|
+
GITHUB_COPILOT: "GITHUB_COPILOT",
|
|
139
|
+
};
|
|
140
|
+
export const AgentTypeSchema = z.enum([AGENT_TYPE.CLAUDE_CODE, AGENT_TYPE.GITHUB_COPILOT]);
|
|
141
|
+
/** Default builtin tool catalog per provider, used to seed new agents and the editor's tool picker. */
|
|
142
|
+
export const DEFAULT_AVAILABLE_TOOLS_BY_TYPE = {
|
|
143
|
+
[AGENT_TYPE.CLAUDE_CODE]: DEFAULT_CLAUDE_CODE_AVAILABLE_TOOLS,
|
|
144
|
+
[AGENT_TYPE.GITHUB_COPILOT]: DEFAULT_GITHUB_COPILOT_AVAILABLE_TOOLS,
|
|
86
145
|
};
|
|
87
146
|
export const AgentIdSchema = z.uuid();
|
|
88
147
|
/** Maximum number of time entries allowed in a loop config */
|
|
@@ -107,6 +166,21 @@ export const PermissionModeSchema = z.enum([
|
|
|
107
166
|
PERMISSION_MODE.DONT_ASK,
|
|
108
167
|
]);
|
|
109
168
|
export const SettingSourceSchema = z.enum([SETTING_SOURCE.USER, SETTING_SOURCE.PROJECT, SETTING_SOURCE.LOCAL]);
|
|
169
|
+
export const DiscoveredSkillSchema = z.object({
|
|
170
|
+
name: z.string(),
|
|
171
|
+
source: z.string(),
|
|
172
|
+
});
|
|
173
|
+
export const SettingSourceConfigSchema = z.object({
|
|
174
|
+
disableFileHooks: z.boolean().optional(),
|
|
175
|
+
instructionSources: z.array(z.string()).optional(),
|
|
176
|
+
disabledInstructionSources: z.array(z.string()).optional(),
|
|
177
|
+
discoveredSkills: z.array(DiscoveredSkillSchema).optional(),
|
|
178
|
+
disabledSkills: z.array(z.string()).optional(),
|
|
179
|
+
});
|
|
180
|
+
export const SettingSourceConfigInputSchema = SettingSourceConfigSchema.omit({
|
|
181
|
+
instructionSources: true,
|
|
182
|
+
discoveredSkills: true,
|
|
183
|
+
});
|
|
110
184
|
/**
|
|
111
185
|
* Tool configuration for agent
|
|
112
186
|
*/
|
|
@@ -125,14 +199,15 @@ export const AgentVoiceConfigSchema = z.object({
|
|
|
125
199
|
*/
|
|
126
200
|
export const AgentConfigSchema = z.object({
|
|
127
201
|
id: AgentIdSchema,
|
|
128
|
-
type:
|
|
202
|
+
type: AgentTypeSchema.default(AGENT_TYPE.CLAUDE_CODE),
|
|
129
203
|
name: z.string().min(1).max(64),
|
|
130
204
|
description: z.string().optional(),
|
|
131
205
|
workspace: z.string().min(1).optional(),
|
|
132
206
|
persona: z.string().optional(),
|
|
133
|
-
model: z.string().default(
|
|
207
|
+
model: z.string().default(CLAUDE_DEFAULT_MODEL),
|
|
134
208
|
permissionMode: PermissionModeSchema.default(PERMISSION_MODE.DEFAULT),
|
|
135
209
|
settingSources: z.array(SettingSourceSchema).default([...DEFAULT_SETTING_SOURCES]),
|
|
210
|
+
settingSourceConfig: SettingSourceConfigSchema.optional(),
|
|
136
211
|
availableTools: z.array(z.string()).optional(),
|
|
137
212
|
toolConfig: ToolConfigSchema.default({ mode: TOOL_MODE.UNRESTRICTED }),
|
|
138
213
|
agentVoiceConfig: AgentVoiceConfigSchema.optional(),
|
|
@@ -157,6 +232,7 @@ export const AgentConfigSchema = z.object({
|
|
|
157
232
|
* Input for creating a new agent - only required fields
|
|
158
233
|
*/
|
|
159
234
|
export const CreateAgentInputSchema = z.object({
|
|
235
|
+
type: AgentTypeSchema.default(AGENT_TYPE.CLAUDE_CODE),
|
|
160
236
|
name: z.string().min(1).max(50),
|
|
161
237
|
description: z.string().optional(),
|
|
162
238
|
workspace: z.string().min(1).optional(),
|
|
@@ -164,6 +240,7 @@ export const CreateAgentInputSchema = z.object({
|
|
|
164
240
|
model: z.string().optional(),
|
|
165
241
|
permissionMode: PermissionModeSchema.optional(),
|
|
166
242
|
settingSources: z.array(SettingSourceSchema).optional(),
|
|
243
|
+
settingSourceConfig: SettingSourceConfigInputSchema.optional(),
|
|
167
244
|
toolConfig: ToolConfigSchema.optional(),
|
|
168
245
|
agentVoiceConfig: AgentVoiceConfigSchema.optional(),
|
|
169
246
|
mcpServerIds: z.array(z.string()).optional(),
|
|
@@ -186,6 +263,7 @@ export const UpdateAgentInputSchema = z.object({
|
|
|
186
263
|
model: z.string().optional(),
|
|
187
264
|
permissionMode: PermissionModeSchema.optional(),
|
|
188
265
|
settingSources: z.array(SettingSourceSchema).optional(),
|
|
266
|
+
settingSourceConfig: SettingSourceConfigInputSchema.optional(),
|
|
189
267
|
toolConfig: ToolConfigSchema.optional(),
|
|
190
268
|
agentVoiceConfig: AgentVoiceConfigSchema.optional(),
|
|
191
269
|
mcpServerIds: z.array(z.string()).optional(),
|
|
@@ -199,6 +277,7 @@ export const UpdateAgentInputSchema = z.object({
|
|
|
199
277
|
agentMd: z.string().optional(),
|
|
200
278
|
});
|
|
201
279
|
export const AgentConfigTemplateSchema = AgentConfigSchema.pick({
|
|
280
|
+
type: true,
|
|
202
281
|
description: true,
|
|
203
282
|
workspace: true,
|
|
204
283
|
persona: true,
|
|
@@ -3,6 +3,7 @@ import { z } from "zod";
|
|
|
3
3
|
export const PERMISSION_DECISION = {
|
|
4
4
|
ALLOW: "allow",
|
|
5
5
|
DENY: "deny",
|
|
6
|
+
ALLOW_ALWAYS: "allow_always",
|
|
6
7
|
};
|
|
7
8
|
/**
|
|
8
9
|
* Schema for a permission request broadcast to clients
|
|
@@ -19,6 +20,6 @@ export const PermissionRequestSchema = z.object({
|
|
|
19
20
|
*/
|
|
20
21
|
export const PermissionResponseSchema = z.object({
|
|
21
22
|
requestId: z.string(),
|
|
22
|
-
decision: z.enum([PERMISSION_DECISION.ALLOW, PERMISSION_DECISION.DENY]),
|
|
23
|
+
decision: z.enum([PERMISSION_DECISION.ALLOW, PERMISSION_DECISION.DENY, PERMISSION_DECISION.ALLOW_ALWAYS]),
|
|
23
24
|
});
|
|
24
25
|
//# sourceMappingURL=permission.schema.js.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
+
import { ModelOptionSchema } from "./agent.schema.js";
|
|
2
3
|
/**
|
|
3
4
|
* Server-side feature flags surfaced to the UI so it can enable/disable
|
|
4
5
|
* features whose backing services are configured via environment variables.
|
|
@@ -8,5 +9,11 @@ export const SystemCapabilitiesSchema = z.object({
|
|
|
8
9
|
audioGeneration: z.boolean(),
|
|
9
10
|
/** True when the chat-completion text generation provider is configured (powers persona / AGENT.md generation). */
|
|
10
11
|
textGeneration: z.boolean(),
|
|
12
|
+
/** True when the shared Copilot SDK client started successfully (Copilot agents can run). */
|
|
13
|
+
copilotAvailable: z.boolean(),
|
|
14
|
+
/** Models selectable for Claude Code agents. */
|
|
15
|
+
claudeSupportedModels: z.array(ModelOptionSchema),
|
|
16
|
+
/** Models selectable for Copilot agents, fetched from the SDK; empty when Copilot is unavailable. */
|
|
17
|
+
copilotSupportedModels: z.array(ModelOptionSchema),
|
|
11
18
|
});
|
|
12
19
|
//# sourceMappingURL=system-capabilities.schema.js.map
|
|
@@ -56,7 +56,7 @@ export const PermissionResponseWsSchema = z.object({
|
|
|
56
56
|
type: z.literal("permission_response"),
|
|
57
57
|
agentId: z.string(),
|
|
58
58
|
toolUseId: z.string(),
|
|
59
|
-
decision: z.enum([PERMISSION_DECISION.ALLOW, PERMISSION_DECISION.DENY]),
|
|
59
|
+
decision: z.enum([PERMISSION_DECISION.ALLOW, PERMISSION_DECISION.DENY, PERMISSION_DECISION.ALLOW_ALWAYS]),
|
|
60
60
|
message: z.string().optional(),
|
|
61
61
|
});
|
|
62
62
|
export const ClientMessageSchema = z.discriminatedUnion("type", [
|
|
@@ -7,8 +7,9 @@ export const MODEL_ALIASES = {
|
|
|
7
7
|
[CLAUDE_MODELS.OPUS_4_5]: CLAUDE_MODELS.OPUS,
|
|
8
8
|
[CLAUDE_MODELS.OPUS_4_6]: CLAUDE_MODELS.OPUS,
|
|
9
9
|
};
|
|
10
|
+
export const COPILOT_MODEL_ALIASES = {};
|
|
10
11
|
/** Resolve a potentially retired model ID to its current successor. */
|
|
11
12
|
export function resolveModel(model) {
|
|
12
|
-
return MODEL_ALIASES[model] ?? model;
|
|
13
|
+
return MODEL_ALIASES[model] ?? COPILOT_MODEL_ALIASES[model] ?? model;
|
|
13
14
|
}
|
|
14
15
|
//# sourceMappingURL=resolve-model.js.map
|
package/dist/bootstrap.js
CHANGED
|
@@ -8,18 +8,18 @@ import { registerAgentRoutes } from "./routes/agent.routes.js";
|
|
|
8
8
|
import { AgentRegistry } from "./services/agent-registry.js";
|
|
9
9
|
import { AgentRuntimeManager } from "./services/runtime/agent-runtime-manager.js";
|
|
10
10
|
import { SessionManager } from "./services/session/session-manager.js";
|
|
11
|
+
import { CopilotClientManager } from "./services/copilot/copilot-client-manager.js";
|
|
11
12
|
import { WsBroadcaster } from "./services/ws-broadcaster.js";
|
|
12
13
|
import { ArtifactManager } from "./services/artifact/artifact-manager.js";
|
|
13
14
|
import { PlacesManager } from "./services/places/places-manager.js";
|
|
14
15
|
import { setupWebSocket } from "./server/setup-websocket.js";
|
|
15
16
|
import { registerArtifactRoutes } from "./routes/artifact.routes.js";
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import { CROW_SYSTEM_AGENT_ID, CROW_TASK_DISPATCHER_AGENT_ID } from "./_shared/index.js";
|
|
17
|
+
import { getArtifactsMcpServerDefinition } from "./mcp/artifacts/artifacts-mcp-server.js";
|
|
18
|
+
import { getAgentsMcpServerDefinition } from "./mcp/agents/agents-mcp-server.js";
|
|
19
|
+
import { getSuperAgentMcpServerDefinition } from "./mcp/agents/super-agent-mcp-server.js";
|
|
20
|
+
import { getTasksMcpServerDefinition } from "./mcp/tasks/tasks-mcp-server.js";
|
|
21
|
+
import { getSuperTasksMcpServerDefinition } from "./mcp/tasks/super-tasks-mcp-server.js";
|
|
22
|
+
import { getRemindersMcpServerDefinition } from "./mcp/reminders/reminders-mcp-server.js";
|
|
23
23
|
import { FileObjectStoreProvider } from "./core/store/file-object-store-provider.js";
|
|
24
24
|
import { CrowScheduler } from "./services/crow-scheduler.js";
|
|
25
25
|
import { SystemSettingsManager } from "./services/system-settings-manager.js";
|
|
@@ -54,15 +54,15 @@ import { FolderFileStoreProvider } from "./core/store/folder-file-store-provider
|
|
|
54
54
|
import { SimplyFeedManager } from "./feed/simply-feed-manager.js";
|
|
55
55
|
import { registerFeedRoutes } from "./routes/feed.routes.js";
|
|
56
56
|
import { registerSystemSettingsRoutes } from "./routes/system-settings.routes.js";
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
57
|
+
import { getFeedMcpServerDefinition } from "./mcp/feed/feed-mcp-server.js";
|
|
58
|
+
import { getAudioMcpServerDefinition } from "./mcp/audio/audio-mcp-server.js";
|
|
59
59
|
import { ConnectorManager } from "./connectors/connector-manager.js";
|
|
60
60
|
import { GoogleConnector } from "./connectors/google-connector.js";
|
|
61
61
|
import { registerConnectorsRoutes } from "./routes/connectors.routes.js";
|
|
62
|
-
import { getGmailMcpServerDefinition
|
|
63
|
-
import { getGoogleCalendarMcpServerDefinition
|
|
64
|
-
import { getGoogleContactsMcpServerDefinition
|
|
65
|
-
import { getPlacesMcpServerDefinition
|
|
62
|
+
import { getGmailMcpServerDefinition } from "./mcp/gmail/gmail-mcp-server.js";
|
|
63
|
+
import { getGoogleCalendarMcpServerDefinition } from "./mcp/google-calendar/google-calendar-mcp-server.js";
|
|
64
|
+
import { getGoogleContactsMcpServerDefinition } from "./mcp/google-contacts/google-contacts-mcp-server.js";
|
|
65
|
+
import { getPlacesMcpServerDefinition } from "./mcp/places/places-mcp-server.js";
|
|
66
66
|
/**
|
|
67
67
|
* Bootstrap the application - create services with constructor deps, start server.
|
|
68
68
|
* No event wiring here - services own their own listeners.
|
|
@@ -91,7 +91,9 @@ export async function bootstrap(options) {
|
|
|
91
91
|
const placesManager = new PlacesManager();
|
|
92
92
|
const connectorManager = new ConnectorManager(storeProvider, registry, crowScheduler);
|
|
93
93
|
connectorManager.registerConnector(new GoogleConnector());
|
|
94
|
-
const
|
|
94
|
+
const copilotClientManager = new CopilotClientManager();
|
|
95
|
+
await copilotClientManager.initialize();
|
|
96
|
+
const sessionManager = new SessionManager(storeProvider, copilotClientManager);
|
|
95
97
|
const messageQueue = new MessageQueueManager();
|
|
96
98
|
const mcpManager = new CrowMcpManager(storeProvider, systemSettingsManager, registry);
|
|
97
99
|
await mcpManager.initialize();
|
|
@@ -120,41 +122,19 @@ export async function bootstrap(options) {
|
|
|
120
122
|
await discordBotManager.initialize();
|
|
121
123
|
const discordRoutine = createDiscordRoutine(discordBotManager, runtimeManager);
|
|
122
124
|
routineManager.addRoutine(discordRoutine);
|
|
123
|
-
// Register MCP
|
|
124
|
-
mcpManager.registerMcpServer(
|
|
125
|
-
mcpManager.registerMcpServer(
|
|
126
|
-
mcpManager.registerMcpServer(
|
|
127
|
-
mcpManager.registerMcpServer(
|
|
128
|
-
mcpManager.registerMcpServer(
|
|
129
|
-
mcpManager.registerMcpServer(
|
|
130
|
-
mcpManager.registerMcpServer(
|
|
131
|
-
mcpManager.registerMcpServer(
|
|
132
|
-
|
|
133
|
-
mcpManager.registerMcpServer(
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
isConfigurable: gmailMcpDefinition.isConfigurable,
|
|
137
|
-
displayName: gmailMcpDefinition.displayName,
|
|
138
|
-
});
|
|
139
|
-
const googleCalendarMcpDefinition = getGoogleCalendarMcpServerDefinition(connectorManager, sensorManager);
|
|
140
|
-
mcpManager.registerMcpServer(GOOGLE_CALENDAR_MCP_SERVER_NAME, googleCalendarMcpDefinition.serverFactory, {
|
|
141
|
-
hasRequiredConnections: googleCalendarMcpDefinition.hasRequiredConnections,
|
|
142
|
-
getConnectionProfiles: googleCalendarMcpDefinition.getConnectionProfiles,
|
|
143
|
-
isConfigurable: googleCalendarMcpDefinition.isConfigurable,
|
|
144
|
-
displayName: googleCalendarMcpDefinition.displayName,
|
|
145
|
-
});
|
|
146
|
-
const googleContactsMcpDefinition = getGoogleContactsMcpServerDefinition(connectorManager, sensorManager);
|
|
147
|
-
mcpManager.registerMcpServer(GOOGLE_CONTACTS_MCP_SERVER_NAME, googleContactsMcpDefinition.serverFactory, {
|
|
148
|
-
hasRequiredConnections: googleContactsMcpDefinition.hasRequiredConnections,
|
|
149
|
-
getConnectionProfiles: googleContactsMcpDefinition.getConnectionProfiles,
|
|
150
|
-
isConfigurable: googleContactsMcpDefinition.isConfigurable,
|
|
151
|
-
displayName: googleContactsMcpDefinition.displayName,
|
|
152
|
-
});
|
|
153
|
-
const placesMcpDefinition = getPlacesMcpServerDefinition(placesManager);
|
|
154
|
-
mcpManager.registerMcpServer(PLACES_MCP_SERVER_NAME, placesMcpDefinition.serverFactory, {
|
|
155
|
-
isConfigurable: placesMcpDefinition.isConfigurable,
|
|
156
|
-
displayName: placesMcpDefinition.displayName,
|
|
157
|
-
});
|
|
125
|
+
// Register built-in MCP servers
|
|
126
|
+
mcpManager.registerMcpServer(getArtifactsMcpServerDefinition(artifactManager, registry, circleManager, sensorManager));
|
|
127
|
+
mcpManager.registerMcpServer(getAgentsMcpServerDefinition(registry, runtimeManager, taskManager));
|
|
128
|
+
mcpManager.registerMcpServer(getTasksMcpServerDefinition(taskManager, circleManager, sensorManager));
|
|
129
|
+
mcpManager.registerMcpServer(getFeedMcpServerDefinition(registry, feedManager, sensorManager, systemSettingsManager));
|
|
130
|
+
mcpManager.registerMcpServer(getAudioMcpServerDefinition(registry, artifactManager));
|
|
131
|
+
mcpManager.registerMcpServer(getSuperTasksMcpServerDefinition(taskManager, registry, circleManager, sensorManager));
|
|
132
|
+
mcpManager.registerMcpServer(getSuperAgentMcpServerDefinition(registry, runtimeManager, sessionManager));
|
|
133
|
+
mcpManager.registerMcpServer(getRemindersMcpServerDefinition(crowScheduler, sensorManager));
|
|
134
|
+
mcpManager.registerMcpServer(getGmailMcpServerDefinition(connectorManager, sensorManager));
|
|
135
|
+
mcpManager.registerMcpServer(getGoogleCalendarMcpServerDefinition(connectorManager, sensorManager));
|
|
136
|
+
mcpManager.registerMcpServer(getGoogleContactsMcpServerDefinition(connectorManager, sensorManager));
|
|
137
|
+
mcpManager.registerMcpServer(getPlacesMcpServerDefinition(placesManager));
|
|
158
138
|
await runtimeManager.startRecovery();
|
|
159
139
|
// Start scheduler
|
|
160
140
|
crowScheduler.start();
|
|
@@ -164,7 +144,7 @@ export async function bootstrap(options) {
|
|
|
164
144
|
await setupWebSocket(server, broadcaster, runtimeManager);
|
|
165
145
|
await registerAuthRoutes(server);
|
|
166
146
|
await registerHealthRoutes(server);
|
|
167
|
-
await registerSystemRoutes(server);
|
|
147
|
+
await registerSystemRoutes(server, copilotClientManager);
|
|
168
148
|
await registerAgentRoutes(server, registry, runtimeManager, sessionManager, storeProvider, connectorManager, mcpManager);
|
|
169
149
|
await registerArtifactRoutes(server, artifactManager);
|
|
170
150
|
await registerTaskRoutes(server, taskManager, registry);
|
|
@@ -185,6 +165,7 @@ export async function bootstrap(options) {
|
|
|
185
165
|
crowScheduler.stop();
|
|
186
166
|
await discordBotManager.destroy();
|
|
187
167
|
await server.close();
|
|
168
|
+
await copilotClientManager.dispose();
|
|
188
169
|
await shutdownTelemetry();
|
|
189
170
|
process.exit(0);
|
|
190
171
|
};
|
package/dist/config/constants.js
CHANGED
|
@@ -15,6 +15,8 @@ export const WS_HEARTBEAT_INTERVAL_MS = 30 * 1000;
|
|
|
15
15
|
export const ARTIFACT_TIMESTAMP_WINDOW_MS = 5 * 60 * 1000;
|
|
16
16
|
/** Default message sent to the agent when a tool permission is denied without a typed response */
|
|
17
17
|
export const DEFAULT_PERMISSION_DENY_MESSAGE = "Permission denied by user";
|
|
18
|
+
/** Denial reason used when an agent runs with permission prompting suppressed (Claude "dontAsk" mode). */
|
|
19
|
+
export const PERMISSION_USER_UNAVAILABLE_MESSAGE = "Permission denied: no user is available to approve this request";
|
|
18
20
|
/** Subdirectory name under CROW_SYSTEM_PATH for per-agent folders */
|
|
19
21
|
export const AGENTS_DIR_NAME = "agents";
|
|
20
22
|
/** Subdirectory name under CROW_SYSTEM_PATH for per-circle folders */
|
package/dist/config/env.js
CHANGED
|
@@ -10,6 +10,10 @@ function getOptional(key, defaultValue) {
|
|
|
10
10
|
function getOptionalNumber(key, defaultValue) {
|
|
11
11
|
return process.env[key] ? parseInt(process.env[key], 10) : defaultValue;
|
|
12
12
|
}
|
|
13
|
+
function getBoolean(key) {
|
|
14
|
+
const value = process.env[key]?.trim().toLowerCase();
|
|
15
|
+
return value === "true" || value === "1";
|
|
16
|
+
}
|
|
13
17
|
function expandPath(filePath) {
|
|
14
18
|
if (filePath.startsWith("~")) {
|
|
15
19
|
return path.join(os.homedir(), filePath.slice(1));
|
|
@@ -52,6 +56,7 @@ export const env = {
|
|
|
52
56
|
STATIC_PATH: expandPath(getOptional("STATIC_PATH") ?? DEFAULT_STATIC_DIR),
|
|
53
57
|
CROW_SYSTEM_AGENT_NAME: getOptional("CROW_SYSTEM_AGENT_NAME"),
|
|
54
58
|
CLAUDE_CLI_PATH: getOptional("CLAUDE_CLI_PATH"),
|
|
59
|
+
DISABLE_GITHUB_COPILOT: getBoolean("DISABLE_GITHUB_COPILOT"),
|
|
55
60
|
CLOSED_TASK_RETENTION_DAYS: getOptionalNumber("CLOSED_TASK_RETENTION_DAYS", 30),
|
|
56
61
|
FEED_ITEM_RETENTION_DAYS: getOptionalNumber("FEED_ITEM_RETENTION_DAYS", 30),
|
|
57
62
|
FEED_REFRESH_IN_MINUTES: getOptionalNumber("FEED_REFRESH_IN_MINUTES"),
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
import path from "node:path";
|
|
10
10
|
import { logger } from "../../utils/logger.js";
|
|
11
|
-
import { readJsonFile, writeJsonFile, assertWithinBase, deleteFile } from "../../utils/fs-utils.js";
|
|
11
|
+
import { readJsonFile, writeJsonFile, assertWithinBase, deleteFile, removeEmptyAncestors, } from "../../utils/fs-utils.js";
|
|
12
12
|
import { APP_ERROR_CODES } from "../error/app-error.types.js";
|
|
13
13
|
import { AppError } from "../error/app-error.js";
|
|
14
14
|
import { STORE_QUERY_OPERATORS, } from "./object-store.types.js";
|
|
@@ -86,6 +86,7 @@ export class FileObjectStoreProvider {
|
|
|
86
86
|
await this.serializedWithResult(state, async () => {
|
|
87
87
|
state.data.clear();
|
|
88
88
|
await deleteFile(state.filePath);
|
|
89
|
+
await removeEmptyAncestors(path.dirname(state.filePath), this.basePath);
|
|
89
90
|
this.tables.delete(table);
|
|
90
91
|
});
|
|
91
92
|
}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import path from "node:path";
|
|
9
9
|
import { logger } from "../../utils/logger.js";
|
|
10
|
-
import { readJsonFile, writeJsonFile, assertWithinBase, ensureDir, listFiles, deleteFile, removeDir, statFile, } from "../../utils/fs-utils.js";
|
|
10
|
+
import { readJsonFile, writeJsonFile, assertWithinBase, ensureDir, listFiles, deleteFile, removeDir, removeEmptyAncestors, statFile, } from "../../utils/fs-utils.js";
|
|
11
11
|
import { APP_ERROR_CODES } from "../error/app-error.types.js";
|
|
12
12
|
import { AppError } from "../error/app-error.js";
|
|
13
13
|
import { isValidStoreEntry } from "./store-entry-utils.js";
|
|
@@ -91,6 +91,7 @@ export class FolderFileStoreProvider {
|
|
|
91
91
|
const dirPath = path.join(this.basePath, table);
|
|
92
92
|
assertWithinBase(dirPath, this.basePath);
|
|
93
93
|
await removeDir(dirPath);
|
|
94
|
+
await removeEmptyAncestors(path.dirname(dirPath), this.basePath);
|
|
94
95
|
this.initializedTables.delete(table);
|
|
95
96
|
}
|
|
96
97
|
async getMany(table, keys) {
|
|
@@ -1,20 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { defineMcpTool } from "../crow-mcp-manager-utils.js";
|
|
2
2
|
import { getListAgentsToolConfig } from "./list-agents.js";
|
|
3
3
|
import { getInvokeAgentToolConfig } from "./invoke-agent.js";
|
|
4
4
|
export const CROW_AGENTS_MCP_SERVER_NAME = "crow-agents";
|
|
5
|
-
export function
|
|
6
|
-
|
|
7
|
-
const invokeAgent = getInvokeAgentToolConfig(agentId, registry, runtimeManager, taskManager);
|
|
8
|
-
return createSdkMcpServer({
|
|
5
|
+
export function getAgentsMcpServerDefinition(registry, runtimeManager, taskManager) {
|
|
6
|
+
return {
|
|
9
7
|
name: CROW_AGENTS_MCP_SERVER_NAME,
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}),
|
|
14
|
-
tool(invokeAgent.name, invokeAgent.description, invokeAgent.inputSchema, invokeAgent.handler, {
|
|
15
|
-
annotations: invokeAgent.annotations,
|
|
16
|
-
}),
|
|
8
|
+
getTools: (agentId) => [
|
|
9
|
+
defineMcpTool(getListAgentsToolConfig(agentId, registry)),
|
|
10
|
+
defineMcpTool(getInvokeAgentToolConfig(agentId, registry, runtimeManager, taskManager)),
|
|
17
11
|
],
|
|
18
|
-
}
|
|
12
|
+
};
|
|
19
13
|
}
|
|
20
14
|
//# sourceMappingURL=agents-mcp-server.js.map
|
|
@@ -27,7 +27,7 @@ export function getLastAgentMessageToolConfig(agentId, registry, runtimeManager,
|
|
|
27
27
|
}
|
|
28
28
|
try {
|
|
29
29
|
const workspace = registry.resolveWorkspace(targetAgent);
|
|
30
|
-
const messages = await sessionManager.loadMessages(state.sessionId, workspace);
|
|
30
|
+
const messages = await sessionManager.loadMessages(targetAgent.type, state.sessionId, workspace);
|
|
31
31
|
let lastAssistantMessage;
|
|
32
32
|
for (let index = messages.length - 1; index >= 0; index--) {
|
|
33
33
|
if (messages[index].role === AGENT_MESSAGE_ROLE.AGENT) {
|
|
@@ -2,16 +2,17 @@
|
|
|
2
2
|
* Super-agent MCP server — privileged tools available only to the Crow system agent.
|
|
3
3
|
* Provides tools for inspecting other agents' state and messages.
|
|
4
4
|
*/
|
|
5
|
-
import {
|
|
5
|
+
import { CROW_SYSTEM_AGENT_ID } from "../../_shared/index.js";
|
|
6
|
+
import { defineMcpTool } from "../crow-mcp-manager-utils.js";
|
|
6
7
|
import { getLastAgentMessageToolConfig } from "./get-last-agent-message.js";
|
|
7
8
|
export const CROW_SUPER_AGENT_MCP_SERVER_NAME = "crow-super-agent";
|
|
8
|
-
export function
|
|
9
|
-
|
|
10
|
-
return createSdkMcpServer({
|
|
9
|
+
export function getSuperAgentMcpServerDefinition(registry, runtimeManager, sessionManager) {
|
|
10
|
+
return {
|
|
11
11
|
name: CROW_SUPER_AGENT_MCP_SERVER_NAME,
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
allowedAgentIds: [CROW_SYSTEM_AGENT_ID],
|
|
13
|
+
getTools: (agentId) => [
|
|
14
|
+
defineMcpTool(getLastAgentMessageToolConfig(agentId, registry, runtimeManager, sessionManager)),
|
|
14
15
|
],
|
|
15
|
-
}
|
|
16
|
+
};
|
|
16
17
|
}
|
|
17
18
|
//# sourceMappingURL=super-agent-mcp-server.js.map
|