@rubytech/create-maxy-code 0.1.214 → 0.1.219
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/package.json +1 -1
- package/payload/platform/lib/mcp-eager/dist/index.d.ts +0 -55
- package/payload/platform/lib/mcp-eager/dist/index.d.ts.map +1 -1
- package/payload/platform/lib/mcp-eager/dist/index.js +0 -76
- package/payload/platform/lib/mcp-eager/dist/index.js.map +1 -1
- package/payload/platform/lib/mcp-eager/src/index.ts +0 -101
- package/payload/platform/plugins/admin/.claude-plugin/plugin.json +1 -1
- package/payload/platform/plugins/admin/PLUGIN.md +4 -1
- package/payload/platform/plugins/admin/hooks/__tests__/hook-emit-stale-lock-ttl.test.sh +102 -0
- package/payload/platform/plugins/admin/hooks/__tests__/post-tool-use-agent.test.sh +97 -1
- package/payload/platform/plugins/admin/hooks/__tests__/pre-tool-use-admin-tool-gate.test.sh +55 -74
- package/payload/platform/plugins/admin/hooks/lib/hook-emit.sh +58 -0
- package/payload/platform/plugins/admin/hooks/post-tool-use-agent.sh +100 -29
- package/payload/platform/plugins/admin/hooks/pre-tool-use.sh +0 -55
- package/payload/platform/plugins/admin/mcp/dist/__tests__/capabilities-here.test.d.ts +2 -0
- package/payload/platform/plugins/admin/mcp/dist/__tests__/capabilities-here.test.d.ts.map +1 -0
- package/payload/platform/plugins/admin/mcp/dist/__tests__/capabilities-here.test.js +130 -0
- package/payload/platform/plugins/admin/mcp/dist/__tests__/capabilities-here.test.js.map +1 -0
- package/payload/platform/plugins/admin/mcp/dist/index.js +63 -0
- package/payload/platform/plugins/admin/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/admin/mcp/dist/lib/catalogue-census.d.ts +14 -0
- package/payload/platform/plugins/admin/mcp/dist/lib/catalogue-census.d.ts.map +1 -0
- package/payload/platform/plugins/admin/mcp/dist/lib/catalogue-census.js +50 -0
- package/payload/platform/plugins/admin/mcp/dist/lib/catalogue-census.js.map +1 -0
- package/payload/platform/plugins/admin/mcp/dist/tools/capabilities-here.d.ts +28 -0
- package/payload/platform/plugins/admin/mcp/dist/tools/capabilities-here.d.ts.map +1 -0
- package/payload/platform/plugins/admin/mcp/dist/tools/capabilities-here.js +68 -0
- package/payload/platform/plugins/admin/mcp/dist/tools/capabilities-here.js.map +1 -0
- package/payload/platform/plugins/admin/skills/capabilities-here/SKILL.md +31 -0
- package/payload/platform/plugins/admin/skills/platform-architecture/SKILL.md +39 -30
- package/payload/platform/plugins/browser/mcp/dist/index.js +19 -19
- package/payload/platform/plugins/browser/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/docs/references/platform.md +28 -25
- package/payload/platform/plugins/docs/references/plugins-guide.md +2 -0
- package/payload/platform/plugins/email/mcp/dist/index.js +12 -12
- package/payload/platform/plugins/email/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/memory/mcp/dist/index.js +8 -8
- package/payload/platform/plugins/memory/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/url-get/mcp/dist/index.js +2 -2
- package/payload/platform/plugins/url-get/mcp/dist/index.js.map +1 -1
- package/payload/platform/scripts/check-architecture-skill-no-drift.mjs +89 -42
- package/payload/platform/scripts/check-roles-doc-completeness.mjs +96 -0
- package/payload/platform/scripts/check-specialist-tool-surface.mjs +1 -1
- package/payload/platform/services/claude-session-manager/dist/canonical-tool-names.generated.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/canonical-tool-names.generated.js +1 -0
- package/payload/platform/services/claude-session-manager/dist/canonical-tool-names.generated.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/http-server.d.ts +0 -14
- package/payload/platform/services/claude-session-manager/dist/http-server.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/http-server.js +54 -21
- package/payload/platform/services/claude-session-manager/dist/http-server.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/index.js +20 -9
- package/payload/platform/services/claude-session-manager/dist/index.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/jsonl-tail.d.ts +21 -0
- package/payload/platform/services/claude-session-manager/dist/jsonl-tail.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/jsonl-tail.js +118 -1
- package/payload/platform/services/claude-session-manager/dist/jsonl-tail.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/pty-spawner.d.ts +1 -1
- package/payload/platform/services/claude-session-manager/dist/pty-spawner.js +1 -1
- package/payload/platform/services/claude-session-manager/dist/rc-daemon.d.ts +28 -17
- package/payload/platform/services/claude-session-manager/dist/rc-daemon.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/rc-daemon.js +110 -60
- package/payload/platform/services/claude-session-manager/dist/rc-daemon.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/rc-life.d.ts +4 -0
- package/payload/platform/services/claude-session-manager/dist/rc-life.d.ts.map +1 -0
- package/payload/platform/services/claude-session-manager/dist/rc-life.js +16 -0
- package/payload/platform/services/claude-session-manager/dist/rc-life.js.map +1 -0
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.d.ts +80 -0
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.d.ts.map +1 -0
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.js +306 -0
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.js.map +1 -0
- package/payload/platform/services/claude-session-manager/dist/specialist-drift.d.ts +9 -0
- package/payload/platform/services/claude-session-manager/dist/specialist-drift.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/specialist-drift.js +6 -2
- package/payload/platform/services/claude-session-manager/dist/specialist-drift.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/systemd-scope.d.ts +12 -46
- package/payload/platform/services/claude-session-manager/dist/systemd-scope.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/systemd-scope.js +24 -73
- package/payload/platform/services/claude-session-manager/dist/systemd-scope.js.map +1 -1
- package/payload/platform/templates/agents/admin/IDENTITY.md +6 -4
- package/payload/platform/templates/specialists/agents/content-producer.md +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/index.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/index.js +4 -5
- package/payload/premium-plugins/writer-craft/mcp/dist/index.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/src/index.ts +4 -5
- package/payload/premium-plugins/writer-craft/lib/mcp-eager/dist/index.d.ts +0 -116
- package/payload/premium-plugins/writer-craft/lib/mcp-eager/dist/index.d.ts.map +0 -1
- package/payload/premium-plugins/writer-craft/lib/mcp-eager/dist/index.js +0 -125
- package/payload/premium-plugins/writer-craft/lib/mcp-eager/dist/index.js.map +0 -1
- package/payload/premium-plugins/writer-craft/lib/mcp-eager/package.json +0 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"systemd-scope.js","sourceRoot":"","sources":["../src/systemd-scope.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,6EAA6E;AAC7E,uEAAuE;AACvE,2EAA2E;AAC3E,uEAAuE;AACvE,wBAAwB;AACxB,EAAE;AACF,yEAAyE;AACzE,4EAA4E;AAC5E,yEAAyE;AACzE,yEAAyE;AACzE,0BAA0B;AAC1B,EAAE;AACF,uEAAuE;AACvE,wEAAwE;AACxE,sEAAsE;AACtE,wEAAwE;AACxE,uEAAuE;AACvE,uEAAuE;AACvE,4CAA4C;AAE5C,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAE9C;;gBAEgB;AAChB,MAAM,CAAC,MAAM,iBAAiB,GAAG,mBAAmB,CAAA;AAEpD;;;uDAGuD;AACvD,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAA;AAkBvC,MAAM,UAAU,sBAAsB,CAAC,IAAuB;IAC5D,MAAM,CAAC,GAAG,SAAS,CAAC,WAAW,EAAE,CAAC,GAAG,IAAI,CAAC,EAAE;QAC1C,QAAQ,EAAE,MAAM;QAChB,OAAO,EAAE,MAAM;KAChB,CAAC,CAAA;IACF,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AC,GAAG,EAAE,EAAE,CAAC,CAAA;IAClC,OAAO,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAA;AAC/C,CAAC;AAED;;qEAEqE;AACrE,MAAM,UAAU,4BAA4B;IAC1C,OAAO;;;;;;;;;CASR,CAAA;AACD,CAAC"}
|
|
@@ -12,7 +12,7 @@ Your job is to do useful work for the operator. How useful you can be depends on
|
|
|
12
12
|
|
|
13
13
|
Before your first message, do reconnaissance: read what is known about the operator and their business, today's calendar, active projects, open work, recent conversations. Infer the domain from the plugins and skills available. Then lead with what you found, and follow with a proposal suited to where the operator is in their day. Ask only the questions you could not answer through investigation. You are expected to drive the day, not solicit instructions for it.
|
|
14
14
|
|
|
15
|
-
When a turn needs you to ground a claim about what the product is, how the platform is built, how plugins or skills or specialists work, how install or deploy runs, or any other product-architecture fact, load the platform-architecture skill and answer from its body. Cite the source URL printed above the block you drew from.
|
|
15
|
+
When a turn needs you to ground a claim about what the product is, how the platform is built, how plugins or skills or specialists work, how install or deploy runs, or any other product-architecture fact, load the platform-architecture skill and answer from its body. Cite the source URL printed above the block you drew from. The platform-architecture skill is the install catalogue, not evidence of what is installed on this account. For questions about what is enabled here — which plugins are on, which specialists you can dispatch, which models are in use — call capabilities-here and answer from its JSON; never infer install state from the catalogue body.
|
|
16
16
|
|
|
17
17
|
## Before you act
|
|
18
18
|
|
|
@@ -20,6 +20,10 @@ You may not act on a request until you know what is being asked, what is in scop
|
|
|
20
20
|
|
|
21
21
|
Your roster of installed specialists is loaded alongside this file as part of your first-turn reconnaissance. The test for any deliverable is whether an installed specialist owns its type, not whether you judge the work short or single-step. A request to author or produce a document, report, marketing or other public-facing copy, or a published page is owned by content-producer when it is installed; dispatch it with the Agent tool and the matching subagent_type, and never write it inline from this seat while content-producer is installed. Other deliverable types route the same way to whichever specialist's dispatch rule names them. Writing or editing files directly from this seat is reserved for work no installed specialist's dispatch rule covers.
|
|
22
22
|
|
|
23
|
+
The canonical dispatch routes you should reach for first: graph writes (creating or trashing nodes, batch property changes across nodes) go to the specialist that owns graph writes; arbitrary file edits, shell work, and code changes go to coding-assistant or content-producer depending on whether the artifact is code or prose; web research and outside lookups go to research-assistant. The reason is context economy and tool specialization, not platform refusal; the platform stopped blocking these tools from this seat, so the bias has to come from you. A one-line property update against a node already in context, or a single Read against a file you need for routing the next dispatch, are the only in-context exceptions; everything more goes to a specialist.
|
|
24
|
+
|
|
25
|
+
When you dispatch a specialist, the brief states the outcome (what should be true when the specialist returns) plus the binding constraints (account, file scope, deadline, acceptance check). It does not name lines, anchors, or literal text to insert; deriving those is the specialist's job, because they own the tools that will run the change. Wrong shape: telling the specialist which file, which line range, and which CSS declaration to drop in. Right shape: "on the realagent-code site, the footer respects iOS safe-area-inset-bottom on mobile; the site's CSS is the only file in scope."
|
|
26
|
+
|
|
23
27
|
## Working from the graph
|
|
24
28
|
|
|
25
29
|
The graph is your brain. The first read of any turn that needs to know something is against the graph; outside lookups happen only after the graph has confirmed it does not hold the answer, and anything new an outside lookup produces is written back the same turn. Greetings and pure interaction turns do not need this loop. When something worth remembering comes out of a conversation, hand the write off to the specialist who owns graph writes; direct writes from this seat are reserved for one-line updates against a node already in context whose classification is unambiguous.
|
|
@@ -54,9 +58,7 @@ Specific patterns to avoid in every reply:
|
|
|
54
58
|
|
|
55
59
|
Run `skill-load skillName=plainly` on the first text-producing turn of every session. From then on, apply the skill's recursive plain-English pass to every prose reply you return to the operator before emitting it. This is a prime-directive prerogative that overrides every other formatting preference. The same contract carries on the public agent and every specialist; the operator gets it too.
|
|
56
60
|
|
|
57
|
-
The skill is the authority for the precision pass. The inline rules above under "How you sound" — translate jargon to plain English, the AI-tells list, the em-dash ban — are the always-on subset that holds before the skill is loaded; once it is loaded, the skill's fuller machinery (the read-aloud test, the new-to-the-topic test, the iterated rewrite) governs.
|
|
58
|
-
|
|
59
|
-
The pass applies to prose returned to the operator. It does NOT apply to structured tool arguments (IDs, option values, schema field names, cypher) — those are agent-to-machine payloads and pass through verbatim.
|
|
61
|
+
The skill is the authority for the precision pass. The inline rules above under "How you sound" — translate jargon to plain English, the AI-tells list, the em-dash ban — are the always-on subset that holds before the skill is loaded; once it is loaded, the skill's fuller machinery (the read-aloud test, the new-to-the-topic test, the iterated rewrite) governs. The pass applies to every prose reply returned to the operator, not only to explain or define requests; it does NOT apply to structured tool arguments (IDs, option values, schema field names, cypher), which are agent-to-machine payloads and pass through verbatim.
|
|
60
62
|
|
|
61
63
|
## Writing in the operator's voice
|
|
62
64
|
|
|
@@ -3,7 +3,7 @@ name: content-producer
|
|
|
3
3
|
description: "Author professional business documents (proposal, report, brief, memo, plan, case study, brochure), render PDFs, generate images, and publish static websites. Delegate when the operator asks for a written document, a PDF render, a generated image, or to publish a prepared website."
|
|
4
4
|
summary: "Produces visual output from your graph: generates images, renders pages to PDF, and hosts static websites you upload as a zip."
|
|
5
5
|
model: claude-sonnet-4-6
|
|
6
|
-
tools: Bash, Skill, mcp__plugin_memory_memory__memory-search, mcp__plugin_replicate_replicate__image-generate, mcp__plugin_browser_browser__browser-render, mcp__plugin_browser_browser__browser-navigate, mcp__plugin_browser_browser__browser-evaluate, mcp__plugin_browser_browser__browser-resize, mcp__plugin_browser_browser__browser-screenshot, mcp__plugin_browser_browser__browser-pdf-save, mcp__plugin_admin_admin__plugin-read, mcp__plugin_admin_admin__public-hostname, mcp__plugin_admin_admin__publish-site
|
|
6
|
+
tools: Bash, Read, Edit, Write, MultiEdit, Skill, mcp__plugin_memory_memory__memory-search, mcp__plugin_replicate_replicate__image-generate, mcp__plugin_browser_browser__browser-render, mcp__plugin_browser_browser__browser-navigate, mcp__plugin_browser_browser__browser-evaluate, mcp__plugin_browser_browser__browser-resize, mcp__plugin_browser_browser__browser-screenshot, mcp__plugin_browser_browser__browser-pdf-save, mcp__plugin_admin_admin__plugin-read, mcp__plugin_admin_admin__public-hostname, mcp__plugin_admin_admin__publish-site
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# Content Producer
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAMA,OAAO,EAAmB,gBAAgB,EAAuB,MAAM,8BAA8B,CAAC;AAkZtG,OAAO,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -3,7 +3,6 @@ initStderrTee("writer-craft");
|
|
|
3
3
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
4
4
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
5
5
|
import { z } from "zod";
|
|
6
|
-
import { withAdminGate } from "../../lib/mcp-eager/dist/index.js";
|
|
7
6
|
import { voiceTagContent, AUTHORSHIP_MODES } from "./tools/voice-tag-content.js";
|
|
8
7
|
import { voiceDistilProfile } from "./tools/voice-distil-profile.js";
|
|
9
8
|
import { voiceRetrieveConditioning } from "./tools/voice-retrieve-conditioning.js";
|
|
@@ -110,7 +109,7 @@ server.tool("voice-distil-profile", "Three-mode tool. mode='sample' (default) wa
|
|
|
110
109
|
.array(z.string())
|
|
111
110
|
.optional()
|
|
112
111
|
.describe("Optional for mode='write' after an amend sample. ElementIds the agent decided actually moved the profile. Each becomes a LEARNED_FROM edge from the persisted :VoiceProfile. Setting this routes the write through the amend-write path (no corpus walk, cadence bypassed)."),
|
|
113
|
-
},
|
|
112
|
+
}, async ({ userId, format, force, mode, styleCardYaml, nodeIds, amendedFromNodeIds }) => {
|
|
114
113
|
if (!accountId)
|
|
115
114
|
return refuseNoAccount("voice-distil-profile");
|
|
116
115
|
const resolvedUserId = userId ?? resolveUserId();
|
|
@@ -171,7 +170,7 @@ server.tool("voice-distil-profile", "Three-mode tool. mode='sample' (default) wa
|
|
|
171
170
|
isError: true,
|
|
172
171
|
};
|
|
173
172
|
}
|
|
174
|
-
})
|
|
173
|
+
});
|
|
175
174
|
server.tool("voice-retrieve-conditioning", "Return the operator's per-format style card and K voice-matched exemplars for a drafting brief. K=5 short-form (length='short'), K=15 long-form (length='long'). Token-budget bounded. format is required (the writing type: text|email|social-post|article|marketing-copy|note). Returns {styleCard, exemplars, status} where status is one of: 'ok' (profile and/or exemplars returned), 'no-data' (no profile exists and the corpus is empty), 'error' (the lookup failed — carries an error message). Drafting falls back to default register on both 'no-data' and 'error', but only 'no-data' means 'you have no voice profile yet' — never report no-profile on 'error'.", {
|
|
176
175
|
userId: z
|
|
177
176
|
.string()
|
|
@@ -188,7 +187,7 @@ server.tool("voice-retrieve-conditioning", "Return the operator's per-format sty
|
|
|
188
187
|
.describe("K-selector: short = K=5 (16k tokens, email/post); long = K=15 (96k tokens, brochure/prospectus). Defaults to short."),
|
|
189
188
|
register: z.string().optional().describe("Optional register hint"),
|
|
190
189
|
tokenBudget: z.number().int().positive().optional(),
|
|
191
|
-
},
|
|
190
|
+
}, async ({ userId, format, topic, length, register, tokenBudget }) => {
|
|
192
191
|
if (!accountId)
|
|
193
192
|
return refuseNoAccount("voice-retrieve-conditioning");
|
|
194
193
|
const resolvedUserId = userId ?? resolveUserId();
|
|
@@ -247,7 +246,7 @@ server.tool("voice-retrieve-conditioning", "Return the operator's per-format sty
|
|
|
247
246
|
],
|
|
248
247
|
};
|
|
249
248
|
}
|
|
250
|
-
})
|
|
249
|
+
});
|
|
251
250
|
server.tool("voice-record-feedback", "Capture an operator's edit on an agent draft. Writes :VoiceEdit linked to the per-format :VoiceProfile via :FEEDBACK_FOR. The calling agent supplies `intent` (one sentence describing what changed and what voice preference it reveals — Task 424) and `format` (the writing format of the draft).", {
|
|
252
251
|
userId: z.string().optional(),
|
|
253
252
|
format: zFormat.describe("Writing format of the draft being edited."),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"A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AAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE;iBAC9F;aACF;YACD,OAAO,EAAE,IAAI;SACd,CAAC;IACJ,CAAC;AACH,CAAC,CACF,CAAC;AAEF,MAAM,SAAS,GAAG,IAAI,oBAAoB,EAAE,CAAC;AAC7C,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;AAEhC,OAAO,CAAC,EAAE,CAAC,SAAS,EAAE,KAAK,IAAI,EAAE;IAC/B,MAAM,WAAW,EAAE,CAAC;IACpB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC;AAEH,0DAA0D;AAC1D,OAAO,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -4,7 +4,6 @@ initStderrTee("writer-craft");
|
|
|
4
4
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
5
5
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
6
6
|
import { z } from "zod";
|
|
7
|
-
import { withAdminGate } from "../../../../platform/lib/mcp-eager/dist/index.js";
|
|
8
7
|
import { voiceTagContent, AUTHORSHIP_MODES, type AuthorshipMode } from "./tools/voice-tag-content.js";
|
|
9
8
|
import { voiceDistilProfile } from "./tools/voice-distil-profile.js";
|
|
10
9
|
import { voiceRetrieveConditioning } from "./tools/voice-retrieve-conditioning.js";
|
|
@@ -141,7 +140,7 @@ server.tool(
|
|
|
141
140
|
"Optional for mode='write' after an amend sample. ElementIds the agent decided actually moved the profile. Each becomes a LEARNED_FROM edge from the persisted :VoiceProfile. Setting this routes the write through the amend-write path (no corpus walk, cadence bypassed).",
|
|
142
141
|
),
|
|
143
142
|
},
|
|
144
|
-
|
|
143
|
+
async ({ userId, format, force, mode, styleCardYaml, nodeIds, amendedFromNodeIds }) => {
|
|
145
144
|
if (!accountId) return refuseNoAccount("voice-distil-profile");
|
|
146
145
|
const resolvedUserId = userId ?? resolveUserId();
|
|
147
146
|
if (!resolvedUserId) {
|
|
@@ -203,7 +202,7 @@ server.tool(
|
|
|
203
202
|
isError: true,
|
|
204
203
|
};
|
|
205
204
|
}
|
|
206
|
-
}
|
|
205
|
+
},
|
|
207
206
|
);
|
|
208
207
|
|
|
209
208
|
server.tool(
|
|
@@ -226,7 +225,7 @@ server.tool(
|
|
|
226
225
|
register: z.string().optional().describe("Optional register hint"),
|
|
227
226
|
tokenBudget: z.number().int().positive().optional(),
|
|
228
227
|
},
|
|
229
|
-
|
|
228
|
+
async ({ userId, format, topic, length, register, tokenBudget }) => {
|
|
230
229
|
if (!accountId) return refuseNoAccount("voice-retrieve-conditioning");
|
|
231
230
|
const resolvedUserId = userId ?? resolveUserId();
|
|
232
231
|
if (!resolvedUserId) {
|
|
@@ -283,7 +282,7 @@ server.tool(
|
|
|
283
282
|
],
|
|
284
283
|
};
|
|
285
284
|
}
|
|
286
|
-
}
|
|
285
|
+
},
|
|
287
286
|
);
|
|
288
287
|
|
|
289
288
|
server.tool(
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* MCP eager-load helper.
|
|
3
|
-
*
|
|
4
|
-
* The Claude Code SDK marks every MCP tool as deferred-by-default: the model
|
|
5
|
-
* cannot invoke an MCP tool until it has first called `ToolSearch` to load
|
|
6
|
-
* the schema, which costs one extra turn per unique schema. The SDK's per-
|
|
7
|
-
* tool override is `_meta["anthropic/alwaysLoad"]: true` on the tool's
|
|
8
|
-
* `tools/list` entry, which `isDeferredTool` reads to flip the default.
|
|
9
|
-
*
|
|
10
|
-
* The MCP SDK exposes that channel only via `server.registerTool(name,
|
|
11
|
-
* config, handler)`; the older `server.tool(name, desc, schema, handler)`
|
|
12
|
-
* has no `_meta` parameter. This helper wraps the registerTool call so
|
|
13
|
-
* every plugin's index.ts can opt a tool into eager-load with one line
|
|
14
|
-
* matching the shape of the existing four-arg `server.tool` overload.
|
|
15
|
-
*
|
|
16
|
-
* Use for every tool that appears in `ADMIN_CORE_TOOLS` — the permission
|
|
17
|
-
* allow-list IS the curation per the CEO review. Tools the
|
|
18
|
-
* admin should not see should be removed from the allow-list, not merely
|
|
19
|
-
* left deferred.
|
|
20
|
-
*/
|
|
21
|
-
/** Wire-format metadata key the Claude Code SDK reads. */
|
|
22
|
-
export declare const ALWAYS_LOAD_META_KEY: "anthropic/alwaysLoad";
|
|
23
|
-
/**
|
|
24
|
-
* Admin-seat detection. The rc-daemon exports `MAXY_SESSION_ROLE=admin` and
|
|
25
|
-
* `MAXY_SPECIALIST=""` for the orchestrator process and its MCP plugin
|
|
26
|
-
* children; specialist spawns set `MAXY_SPECIALIST=<name>`. A plugin process
|
|
27
|
-
* inheriting the env can therefore decide at registration AND invocation
|
|
28
|
-
* time whether it is loaded inside the admin seat.
|
|
29
|
-
*
|
|
30
|
-
* Mirrors `isAdminSeat` in platform/plugins/admin/mcp/src/skill-resolution.ts
|
|
31
|
-
* — this is a duplicate at the library layer so plugins that cannot import
|
|
32
|
-
* from the admin plugin (a sibling, not a dependency) share the same rule.
|
|
33
|
-
*/
|
|
34
|
-
export declare function isAdminSeat(env?: NodeJS.ProcessEnv): boolean;
|
|
35
|
-
/**
|
|
36
|
-
* MCP refusal envelope returned when the admin seat invokes a specialist-
|
|
37
|
-
* owned tool. The text names the dispatch route so the model's next action
|
|
38
|
-
* is the `Agent` dispatch rather than a dead end.
|
|
39
|
-
*/
|
|
40
|
-
export declare function adminBlockedResponse(toolName: string, owner: string): {
|
|
41
|
-
content: {
|
|
42
|
-
type: "text";
|
|
43
|
-
text: string;
|
|
44
|
-
}[];
|
|
45
|
-
isError: true;
|
|
46
|
-
};
|
|
47
|
-
/**
|
|
48
|
-
* Wrap a tool handler so any admin-seat invocation short-circuits with the
|
|
49
|
-
* refusal envelope above and emits one `[admin-tool-gate]` line to stderr.
|
|
50
|
-
*
|
|
51
|
-
* Specialist seats pass through unchanged: this is the primitive Task 529
|
|
52
|
-
* defines for closing the in-message authoring path that Task 516 could
|
|
53
|
-
* not reach. The handler signature is preserved so existing call sites
|
|
54
|
-
* substitute `eagerTool(... handler)` for `eagerTool(... withAdminGate(name,
|
|
55
|
-
* owner, handler))` mechanically.
|
|
56
|
-
*/
|
|
57
|
-
export declare function withAdminGate<H extends (...args: any[]) => any>(toolName: string, owner: string, handler: H): H;
|
|
58
|
-
/**
|
|
59
|
-
* Loose structural type for any object exposing a `registerTool` method. The
|
|
60
|
-
* MCP SDK ships dual ESM/CJS packages with conditional exports, so importing
|
|
61
|
-
* the concrete `McpServer` type here would force every consumer to compile
|
|
62
|
-
* under the same resolution mode — they don't. Keep this contract minimal:
|
|
63
|
-
* we only need the method to exist; we cast internally to drive the
|
|
64
|
-
* upstream generic overloads which differ between SDK versions.
|
|
65
|
-
*/
|
|
66
|
-
type EagerCapableServer = {
|
|
67
|
-
registerTool: (...args: any[]) => any;
|
|
68
|
-
};
|
|
69
|
-
/**
|
|
70
|
-
* Local structural type for a Zod raw shape. We deliberately do NOT import
|
|
71
|
-
* `ZodRawShape` from zod itself — plugin workspaces ship pinned zod v3 in
|
|
72
|
-
* their nested `node_modules/zod`, while `platform/node_modules/zod` is v4,
|
|
73
|
-
* and the two `ZodRawShape` types are structurally incompatible (v4
|
|
74
|
-
* introduced the `_zod` brand on `ZodType`). A typed-by-value `unknown`
|
|
75
|
-
* member is enough: TypeScript treats it as compatible with both v3 and v4
|
|
76
|
-
* shapes, while still constraining the generic to "an object whose values
|
|
77
|
-
* are zod-like" so the caller's destructured handler args stay typed via
|
|
78
|
-
* the SDK's own overload resolution downstream.
|
|
79
|
-
*/
|
|
80
|
-
type LocalZodRawShape = Record<string, unknown>;
|
|
81
|
-
/**
|
|
82
|
-
* Register an MCP tool that the Claude Code SDK eager-loads into the
|
|
83
|
-
* model's prompt at session boot, bypassing the ToolSearch round-trip.
|
|
84
|
-
*
|
|
85
|
-
* Mirrors the four-arg `server.tool(name, description, inputSchema, handler)`
|
|
86
|
-
* call shape — the only overload in use across our plugins — so callers
|
|
87
|
-
* replace `server.tool(` with `eagerTool(server, ` mechanically.
|
|
88
|
-
*
|
|
89
|
-
* The helper deliberately does not constrain handler-arg types itself; the
|
|
90
|
-
* downstream `server.registerTool` invocation inside this function passes
|
|
91
|
-
* the shape through, and the upstream MCP SDK's overload (resolved against
|
|
92
|
-
* the consumer's own zod version) infers the handler args.
|
|
93
|
-
*/
|
|
94
|
-
export declare function eagerTool<Args extends LocalZodRawShape>(server: EagerCapableServer, name: string, description: string, inputSchema: Args, handler: (...args: any[]) => any): void;
|
|
95
|
-
/**
|
|
96
|
-
* Loose structural type for the legacy four-arg `server.tool(name, desc,
|
|
97
|
-
* schema, handler)` call shape — used when the admin seat must register a
|
|
98
|
-
* specialist-owned tool as deferred (not eager) so it does not appear in
|
|
99
|
-
* the admin's eager tool list.
|
|
100
|
-
*/
|
|
101
|
-
type DeferredCapableServer = {
|
|
102
|
-
tool: (name: string, description: string, inputSchema: any, handler: (...args: any[]) => any) => any;
|
|
103
|
-
};
|
|
104
|
-
/**
|
|
105
|
-
* Register a tool that is eager for specialists but deferred + admin-gated
|
|
106
|
-
* for the admin seat. The owning specialist name is named here so the
|
|
107
|
-
* refusal envelope (and the `[admin-tool-gate]` log line) carries it.
|
|
108
|
-
*
|
|
109
|
-
* Use for every tool whose owner is a specialist (database-operator, writer-
|
|
110
|
-
* craft, research-assistant, personal-assistant, content-producer). The
|
|
111
|
-
* admin seat sees the tool only via ToolSearch — and any invocation from the
|
|
112
|
-
* admin seat refuses with the dispatch hint.
|
|
113
|
-
*/
|
|
114
|
-
export declare function eagerToolGated<Args extends LocalZodRawShape>(server: EagerCapableServer & DeferredCapableServer, name: string, owner: string, description: string, inputSchema: Args, handler: (...args: any[]) => any): void;
|
|
115
|
-
export {};
|
|
116
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;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OAAO,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,KAAK,GAAG,CAAA;CAAE,CAAC;AAEtI;;;;;;;;;GASG;AACH,wBAAgB,cAAc,CAAC,IAAI,SAAS,gBAAgB,EAC1D,MAAM,EAAE,kBAAkB,GAAG,qBAAqB,EAClD,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,MAAM,EACb,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,IAAI,EAEjB,OAAO,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,GAC/B,IAAI,CAMN"}
|
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ALWAYS_LOAD_META_KEY = void 0;
|
|
4
|
-
exports.isAdminSeat = isAdminSeat;
|
|
5
|
-
exports.adminBlockedResponse = adminBlockedResponse;
|
|
6
|
-
exports.withAdminGate = withAdminGate;
|
|
7
|
-
exports.eagerTool = eagerTool;
|
|
8
|
-
exports.eagerToolGated = eagerToolGated;
|
|
9
|
-
/**
|
|
10
|
-
* MCP eager-load helper.
|
|
11
|
-
*
|
|
12
|
-
* The Claude Code SDK marks every MCP tool as deferred-by-default: the model
|
|
13
|
-
* cannot invoke an MCP tool until it has first called `ToolSearch` to load
|
|
14
|
-
* the schema, which costs one extra turn per unique schema. The SDK's per-
|
|
15
|
-
* tool override is `_meta["anthropic/alwaysLoad"]: true` on the tool's
|
|
16
|
-
* `tools/list` entry, which `isDeferredTool` reads to flip the default.
|
|
17
|
-
*
|
|
18
|
-
* The MCP SDK exposes that channel only via `server.registerTool(name,
|
|
19
|
-
* config, handler)`; the older `server.tool(name, desc, schema, handler)`
|
|
20
|
-
* has no `_meta` parameter. This helper wraps the registerTool call so
|
|
21
|
-
* every plugin's index.ts can opt a tool into eager-load with one line
|
|
22
|
-
* matching the shape of the existing four-arg `server.tool` overload.
|
|
23
|
-
*
|
|
24
|
-
* Use for every tool that appears in `ADMIN_CORE_TOOLS` — the permission
|
|
25
|
-
* allow-list IS the curation per the CEO review. Tools the
|
|
26
|
-
* admin should not see should be removed from the allow-list, not merely
|
|
27
|
-
* left deferred.
|
|
28
|
-
*/
|
|
29
|
-
/** Wire-format metadata key the Claude Code SDK reads. */
|
|
30
|
-
exports.ALWAYS_LOAD_META_KEY = "anthropic/alwaysLoad";
|
|
31
|
-
/**
|
|
32
|
-
* Admin-seat detection. The rc-daemon exports `MAXY_SESSION_ROLE=admin` and
|
|
33
|
-
* `MAXY_SPECIALIST=""` for the orchestrator process and its MCP plugin
|
|
34
|
-
* children; specialist spawns set `MAXY_SPECIALIST=<name>`. A plugin process
|
|
35
|
-
* inheriting the env can therefore decide at registration AND invocation
|
|
36
|
-
* time whether it is loaded inside the admin seat.
|
|
37
|
-
*
|
|
38
|
-
* Mirrors `isAdminSeat` in platform/plugins/admin/mcp/src/skill-resolution.ts
|
|
39
|
-
* — this is a duplicate at the library layer so plugins that cannot import
|
|
40
|
-
* from the admin plugin (a sibling, not a dependency) share the same rule.
|
|
41
|
-
*/
|
|
42
|
-
function isAdminSeat(env = process.env) {
|
|
43
|
-
return env.MAXY_SESSION_ROLE === "admin" && !(env.MAXY_SPECIALIST && env.MAXY_SPECIALIST.length > 0);
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* MCP refusal envelope returned when the admin seat invokes a specialist-
|
|
47
|
-
* owned tool. The text names the dispatch route so the model's next action
|
|
48
|
-
* is the `Agent` dispatch rather than a dead end.
|
|
49
|
-
*/
|
|
50
|
-
function adminBlockedResponse(toolName, owner) {
|
|
51
|
-
return {
|
|
52
|
-
content: [
|
|
53
|
-
{
|
|
54
|
-
type: "text",
|
|
55
|
-
text: `Tool \`${toolName}\` is owned by the \`${owner}\` specialist and is not callable from the admin seat. ` +
|
|
56
|
-
`Dispatch \`${owner}\` with the Agent tool and pass the work as the brief.`,
|
|
57
|
-
},
|
|
58
|
-
],
|
|
59
|
-
isError: true,
|
|
60
|
-
};
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* Wrap a tool handler so any admin-seat invocation short-circuits with the
|
|
64
|
-
* refusal envelope above and emits one `[admin-tool-gate]` line to stderr.
|
|
65
|
-
*
|
|
66
|
-
* Specialist seats pass through unchanged: this is the primitive Task 529
|
|
67
|
-
* defines for closing the in-message authoring path that Task 516 could
|
|
68
|
-
* not reach. The handler signature is preserved so existing call sites
|
|
69
|
-
* substitute `eagerTool(... handler)` for `eagerTool(... withAdminGate(name,
|
|
70
|
-
* owner, handler))` mechanically.
|
|
71
|
-
*/
|
|
72
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
73
|
-
function withAdminGate(toolName, owner, handler) {
|
|
74
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
75
|
-
const wrapped = ((...args) => {
|
|
76
|
-
if (isAdminSeat(process.env)) {
|
|
77
|
-
process.stderr.write(`[admin-tool-gate] role=admin tool=${toolName} decision=block reason=specialist-owned owner=${owner}\n`);
|
|
78
|
-
return adminBlockedResponse(toolName, owner);
|
|
79
|
-
}
|
|
80
|
-
return handler(...args);
|
|
81
|
-
});
|
|
82
|
-
return wrapped;
|
|
83
|
-
}
|
|
84
|
-
/**
|
|
85
|
-
* Register an MCP tool that the Claude Code SDK eager-loads into the
|
|
86
|
-
* model's prompt at session boot, bypassing the ToolSearch round-trip.
|
|
87
|
-
*
|
|
88
|
-
* Mirrors the four-arg `server.tool(name, description, inputSchema, handler)`
|
|
89
|
-
* call shape — the only overload in use across our plugins — so callers
|
|
90
|
-
* replace `server.tool(` with `eagerTool(server, ` mechanically.
|
|
91
|
-
*
|
|
92
|
-
* The helper deliberately does not constrain handler-arg types itself; the
|
|
93
|
-
* downstream `server.registerTool` invocation inside this function passes
|
|
94
|
-
* the shape through, and the upstream MCP SDK's overload (resolved against
|
|
95
|
-
* the consumer's own zod version) infers the handler args.
|
|
96
|
-
*/
|
|
97
|
-
function eagerTool(server, name, description, inputSchema,
|
|
98
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
99
|
-
handler) {
|
|
100
|
-
server.registerTool(name, {
|
|
101
|
-
description,
|
|
102
|
-
inputSchema,
|
|
103
|
-
_meta: { [exports.ALWAYS_LOAD_META_KEY]: true },
|
|
104
|
-
}, handler);
|
|
105
|
-
}
|
|
106
|
-
/**
|
|
107
|
-
* Register a tool that is eager for specialists but deferred + admin-gated
|
|
108
|
-
* for the admin seat. The owning specialist name is named here so the
|
|
109
|
-
* refusal envelope (and the `[admin-tool-gate]` log line) carries it.
|
|
110
|
-
*
|
|
111
|
-
* Use for every tool whose owner is a specialist (database-operator, writer-
|
|
112
|
-
* craft, research-assistant, personal-assistant, content-producer). The
|
|
113
|
-
* admin seat sees the tool only via ToolSearch — and any invocation from the
|
|
114
|
-
* admin seat refuses with the dispatch hint.
|
|
115
|
-
*/
|
|
116
|
-
function eagerToolGated(server, name, owner, description, inputSchema,
|
|
117
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
118
|
-
handler) {
|
|
119
|
-
if (isAdminSeat(process.env)) {
|
|
120
|
-
server.tool(name, description, inputSchema, withAdminGate(name, owner, handler));
|
|
121
|
-
return;
|
|
122
|
-
}
|
|
123
|
-
eagerTool(server, name, description, inputSchema, handler);
|
|
124
|
-
}
|
|
125
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAkCA,kCAEC;AAOD,oDAeC;AAaD,sCAgBC;AAuCD,8BAiBC;AAqBD,wCAcC;AAlLD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,0DAA0D;AAC7C,QAAA,oBAAoB,GAAG,sBAA+B,CAAC;AAEpE;;;;;;;;;;GAUG;AACH,SAAgB,WAAW,CAAC,MAAyB,OAAO,CAAC,GAAG;IAC9D,OAAO,GAAG,CAAC,iB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