@rubytech/create-maxy-code 0.1.265 → 0.1.267
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +16 -0
- package/package.json +1 -1
- package/payload/platform/lib/models/dist/index.d.ts +1 -1
- package/payload/platform/lib/models/dist/index.d.ts.map +1 -1
- package/payload/platform/lib/models/dist/index.js +5 -2
- package/payload/platform/lib/models/dist/index.js.map +1 -1
- package/payload/platform/lib/models/src/index.ts +5 -2
- package/payload/platform/neo4j/schema.cypher +13 -0
- package/payload/platform/package-lock.json +16 -0
- package/payload/platform/package.json +3 -2
- package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-search.test.js +9 -9
- package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-search.test.js.map +1 -1
- package/payload/platform/plugins/admin/skills/platform-architecture/SKILL.md +11 -3
- package/payload/platform/plugins/admin/skills/public-agent-manager/SKILL.md +2 -2
- package/payload/platform/plugins/business-assistant/PLUGIN.md +1 -5
- package/payload/platform/plugins/docs/references/admin-ui.md +1 -1
- package/payload/platform/plugins/docs/references/voice-mirror-guide.md +9 -1
- 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 +36 -1
- package/payload/platform/services/claude-session-manager/dist/http-server.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/rc-daemon.d.ts +10 -0
- 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 +59 -0
- package/payload/platform/services/claude-session-manager/dist/rc-daemon.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.d.ts +19 -0
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.d.ts.map +1 -0
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.js +31 -0
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.js.map +1 -0
- package/payload/platform/services/whatsapp-channel/package.json +20 -0
- package/payload/platform/templates/account.json +1 -1
- package/payload/platform/templates/specialists/agents/content-producer.md +1 -1
- package/payload/platform/templates/specialists/agents/librarian.md +1 -1
- package/payload/platform/templates/specialists/agents/research-assistant.md +1 -1
- package/payload/premium-plugins/venture-studio/skills/investor-data-room/SKILL.md +1 -1
- package/payload/premium-plugins/writer-craft/PLUGIN.md +4 -4
- package/payload/premium-plugins/writer-craft/mcp/dist/index.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/index.js +44 -9
- package/payload/premium-plugins/writer-craft/mcp/dist/index.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/lib/voice-corpus.d.ts +31 -0
- package/payload/premium-plugins/writer-craft/mcp/dist/lib/voice-corpus.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/lib/voice-corpus.js +28 -0
- package/payload/premium-plugins/writer-craft/mcp/dist/lib/voice-corpus.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-distil-profile.d.ts +7 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-distil-profile.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-distil-profile.js +93 -44
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-distil-profile.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-ingest-session-text.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-ingest-session-text.js +1 -0
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-ingest-session-text.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-record-feedback.d.ts +7 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-record-feedback.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-record-feedback.js +14 -3
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-record-feedback.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-retrieve-conditioning.d.ts +22 -8
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-retrieve-conditioning.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-retrieve-conditioning.js +93 -84
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-retrieve-conditioning.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-tag-content.d.ts +18 -0
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-tag-content.d.ts.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-tag-content.js +32 -3
- package/payload/premium-plugins/writer-craft/mcp/dist/tools/voice-tag-content.js.map +1 -1
- package/payload/premium-plugins/writer-craft/mcp/scripts/smoke.mjs +35 -2
- package/payload/premium-plugins/writer-craft/mcp/src/index.ts +52 -10
- package/payload/premium-plugins/writer-craft/mcp/src/lib/voice-corpus.ts +39 -0
- package/payload/premium-plugins/writer-craft/mcp/src/tools/voice-distil-profile.ts +108 -44
- package/payload/premium-plugins/writer-craft/mcp/src/tools/voice-ingest-session-text.ts +1 -0
- package/payload/premium-plugins/writer-craft/mcp/src/tools/voice-record-feedback.ts +24 -4
- package/payload/premium-plugins/writer-craft/mcp/src/tools/voice-retrieve-conditioning.ts +136 -102
- package/payload/premium-plugins/writer-craft/mcp/src/tools/voice-tag-content.ts +45 -3
- package/payload/premium-plugins/writer-craft/skills/voice-mirror/SKILL.md +34 -23
- package/payload/server/{chunk-SOLVVUST.js → chunk-W4EM7RK4.js} +2 -0
- package/payload/server/maxy-edge.js +1 -1
- package/payload/server/server.js +345 -14
- package/payload/platform/plugins/business-assistant/references/quote-engine.md +0 -122
- package/payload/platform/plugins/business-assistant/references/quote-generation.md +0 -94
- package/payload/platform/plugins/business-assistant/references/quoting.md +0 -85
- package/payload/platform/plugins/business-assistant/skills/pricing-method/SKILL.md +0 -78
- package/payload/platform/plugins/business-assistant/skills/pricing-method/references/learning-from-history.md +0 -51
- package/payload/platform/plugins/business-assistant/skills/pricing-method/references/maintenance.md +0 -32
- package/payload/platform/plugins/business-assistant/skills/pricing-method/references/manual-definition.md +0 -42
- package/payload/platform/plugins/business-assistant/skills/pricing-method/references/verification.md +0 -37
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
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
|
-
model: claude-opus-4-8
|
|
5
|
+
model: claude-opus-4-8[1m]
|
|
6
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
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: librarian
|
|
3
3
|
description: "Ingest documents (PDF, text, web pages), conversation transcripts (WhatsApp, Telegram, iMessage, Slack, meeting minutes), and LinkedIn exports into the memory graph. Delegate when the operator hands you a file or transcript that should land in the graph."
|
|
4
4
|
summary: "Owns foreground ingest of documents, conversation transcripts, and external archives into the memory graph."
|
|
5
|
-
model: claude-
|
|
5
|
+
model: claude-opus-4-8[1m]
|
|
6
6
|
tools: mcp__plugin_memory_memory__memory-ingest-extract, mcp__plugin_memory_memory__memory-ingest, mcp__plugin_memory_memory__memory-ingest-web, mcp__plugin_memory_memory__memory-archive-write, mcp__plugin_memory_memory__memory-write, mcp__plugin_memory_memory__memory-update, mcp__plugin_memory_memory__memory-edge, mcp__plugin_memory_memory__memory-search, mcp__plugin_memory_memory__conversation-archive-list-chunks, mcp__plugin_memory_memory__conversation-archive-derive-insights, mcp__plugin_memory_memory__conversation-archive-enrich-rejection, mcp__plugin_contacts_contacts__contact-create, mcp__plugin_work_work__work-create, mcp__plugin_url-get_url-get__url-get, Read, Bash, Skill, WebFetch
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: research-assistant
|
|
3
3
|
description: "Deep research on the web, knowledge management, and writing structured summaries with citations from multiple sources. Delegate when the operator wants you to research a topic, read web pages, combine findings into a summary, or reorganise stored knowledge."
|
|
4
4
|
summary: "Researches topics online, manages your knowledge graph, and produces supporting visuals."
|
|
5
|
-
model: claude-opus-4-
|
|
5
|
+
model: claude-opus-4-8[1m]
|
|
6
6
|
tools: WebSearch, WebFetch, Skill, mcp__plugin_memory_memory__memory-search, mcp__plugin_memory_memory__memory-write, mcp__plugin_memory_memory__memory-reindex, mcp__plugin_replicate_replicate__image-generate, mcp__plugin_browser_browser__browser-render, mcp__plugin_url-get_url-get__url-get
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -117,7 +117,7 @@ References: `references/data-room-structure.md` for the section-by-section purpo
|
|
|
117
117
|
|
|
118
118
|
## Stage 3 — Business plan synthesis
|
|
119
119
|
|
|
120
|
-
**Before drafting any narrative prose**, call `voice-retrieve-conditioning` with `format: "article"`, `length: "long"`, and `topic` set to the venture's domain (e.g. "AI estate-agent operating system"). When the tool returns a non-null `styleCard
|
|
120
|
+
**Before drafting any narrative prose**, call `voice-retrieve-conditioning` with `format: "article"`, `length: "long"`, `scope: "org"`, and `topic` set to the venture's domain (e.g. "AI estate-agent operating system"). An investor document goes out under the venture's name, so it uses the **house voice** (`scope: "org"`), not any one founder's personal voice. When the tool returns a non-null `styleCard` (`status` of `ok` or `fallback-org`), condition every prose section on the style card and exemplars so the business plan reads as the house's own writing, not generic VC boilerplate. When `status` is `no-data` or `error`, draft in the formal-yet-direct register implied by the section purpose statements without further conditioning. Emit narration `[investor-data-room] voice-mirror styleCardBytes=<n> exemplars=<k>` when conditioning was applied.
|
|
121
121
|
|
|
122
122
|
Generate `01-narrative/business-plan.md` with **16 sections** following the canonical structure:
|
|
123
123
|
|
|
@@ -106,10 +106,10 @@ Voice-mirror introduces five deterministic plugin tools. They route writes throu
|
|
|
106
106
|
|
|
107
107
|
| Tool | Purpose |
|
|
108
108
|
|------|---------|
|
|
109
|
-
| `voice-tag-content` | Stamp `authorshipMode ∈ {human-only, human-led-agent-assisted, agent-led-human-reviewed, agent-only, unknown}
|
|
110
|
-
| `voice-distil-profile` | Three modes. `mode='sample'` (default) walks the
|
|
111
|
-
| `voice-retrieve-conditioning` | Return `{styleCard, exemplars[]}` for a drafting brief. Requires `brief.format` (one of the six corpus formats). K=5 short-form (`brief.length:'short'`), K=15 long-form (`brief.length:'long'`). Token-budget bounded.
|
|
112
|
-
| `voice-record-feedback` | Capture an operator edit on an agent draft as a `:VoiceEdit {format}` with a Haiku-summarised `intent`, linked back to the
|
|
109
|
+
| `voice-tag-content` | Stamp `authorshipMode ∈ {human-only, human-led-agent-assisted, agent-led-human-reviewed, agent-only, unknown}`, `format ∈ {text, email, social-post, article, note, marketing-copy}`, and `voiceAuthor` on one or many `:KnowledgeDocument | :Message | :SocialPost` nodes (email threads live as `:KnowledgeDocument {source:'email'}` since Task 321). Bulk-mode for backfill batches. `format` is required. `author` is optional — omit to attribute to the tagging operator (Task 676). |
|
|
110
|
+
| `voice-distil-profile` | Three modes, scope-aware (Task 676: `scope='personal'` default walks one author; `scope='org'` walks the whole account onto the business). `mode='sample'` (default) walks the `human-only` corpus for the given `format`/`scope` and returns exemplars + recent edit intents for the agent to compose a style card; cadence-guarded (≥20% growth or ≥30 days). `mode='amend'` (Task 472) reads only `nodeIds` plus the existing `:VoiceProfile.styleCard` so the agent can decide whether named documents move the profile — operator-initiated, no cadence guard. `mode='write'` persists the YAML card; supply `amendedFromNodeIds` to attribute the write to specific documents (bypasses cadence + corpus walk). Trashed nodes are excluded from every walk. Omit `format` on `'sample'` to enumerate all formats in that scope's corpus and distil each. |
|
|
111
|
+
| `voice-retrieve-conditioning` | Return `{styleCard, exemplars[], status}` for a drafting brief. Requires `brief.format` (one of the six corpus formats). `brief.scope` (default `personal`) picks personal vs org voice; a personal request with no personal profile falls back to the org profile (`status='fallback-org'`, Task 676). K=5 short-form (`brief.length:'short'`), K=15 long-form (`brief.length:'long'`). Token-budget bounded. `status ∈ {ok, fallback-org, no-data, error}`. |
|
|
112
|
+
| `voice-record-feedback` | Capture an operator edit on an agent draft as a `:VoiceEdit {format, scope}` with a Haiku-summarised `intent`, linked back to the scoped per-format `:VoiceProfile` via `:FEEDBACK_FOR` (org edits → org profile; editor preserved via `:AUTHORED`, Task 676). Requires `format`. |
|
|
113
113
|
| `voice-ingest-session-text` | Write operator turns from the current session as `:Message {format:'text', authorshipMode:'human-only'}` corpus nodes. The agent reads its own operator turns from context and passes them as `turns`. Deduplicates via SHA256 `contentHash`. Invoked on demand by the voice-mirror skill when the operator asks to capture this session's voice. |
|
|
114
114
|
|
|
115
115
|
The non-voice skills continue to operate via existing platform tools (`memory-search` for knowledge retrieval). Structured choices are still presented as numbered lists in plain chat — the platform has no inline-UI component primitive on the admin / native-CC surface.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAMA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAMA,OAAO,EAAuC,gBAAgB,EAAuB,MAAM,8BAA8B,CAAC;AA4b1H,OAAO,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -3,7 +3,7 @@ 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 { voiceTagContent, AUTHORSHIP_MODES } from "./tools/voice-tag-content.js";
|
|
6
|
+
import { voiceTagContent, resolveVoiceAuthor, AUTHORSHIP_MODES } from "./tools/voice-tag-content.js";
|
|
7
7
|
import { voiceDistilProfile } from "./tools/voice-distil-profile.js";
|
|
8
8
|
import { voiceRetrieveConditioning } from "./tools/voice-retrieve-conditioning.js";
|
|
9
9
|
import { voiceRecordFeedback } from "./tools/voice-record-feedback.js";
|
|
@@ -40,6 +40,11 @@ function resolveUserId() {
|
|
|
40
40
|
}
|
|
41
41
|
// Format enum schema — shared across tools that accept VoiceFormat.
|
|
42
42
|
const zFormat = z.enum([...FORMAT_VALUES]).describe("Writing format: text | email | social-post | article | marketing-copy | note. One :VoiceProfile per (accountId, userId, format).");
|
|
43
|
+
// Scope enum schema — shared across distil / retrieve / feedback (Task 676).
|
|
44
|
+
const zScope = z
|
|
45
|
+
.enum(["personal", "org"])
|
|
46
|
+
.optional()
|
|
47
|
+
.describe("Voice scope: 'personal' (default) = the operator's own voice, distilled from their author-tagged content and anchored on :AdminUser. 'org' = the account/house voice, distilled from the whole account and anchored on :LocalBusiness under the reserved userId '__org__'.");
|
|
43
48
|
server.tool("voice-tag-content", "Stamp authorshipMode and format on one or many content nodes (:KnowledgeDocument | :Message | :SocialPost) the operator owns. Email threads live as :KnowledgeDocument {source:'email'} since Task 321. Valid modes: human-only, human-led-agent-assisted, agent-led-human-reviewed, agent-only, unknown. Valid formats: text, email, social-post, article, marketing-copy, note. format is editorial — the operator chooses it per node; the tool does not infer it.", {
|
|
44
49
|
nodeIds: z.array(z.string()).min(1).describe("Element IDs of nodes to tag"),
|
|
45
50
|
mode: z
|
|
@@ -52,21 +57,45 @@ server.tool("voice-tag-content", "Stamp authorshipMode and format on one or many
|
|
|
52
57
|
])
|
|
53
58
|
.describe("Authorship mode to apply"),
|
|
54
59
|
format: zFormat.describe("Writing format. Required — the operator's editorial classification of the content."),
|
|
55
|
-
|
|
60
|
+
userId: z
|
|
61
|
+
.string()
|
|
62
|
+
.optional()
|
|
63
|
+
.describe("Operator AdminUser id. Defaults to ADMIN_USER_ID env. Used as the default author when `author` is omitted."),
|
|
64
|
+
author: z
|
|
65
|
+
.string()
|
|
66
|
+
.optional()
|
|
67
|
+
.describe("voiceAuthor userId to stamp on the nodes. Omit to attribute to the tagging operator — single-operator accounts get personal attribution for free."),
|
|
68
|
+
}, async ({ nodeIds, mode, format, userId, author }) => {
|
|
56
69
|
if (!accountId)
|
|
57
70
|
return refuseNoAccount("voice-tag-content");
|
|
71
|
+
let voiceAuthor;
|
|
72
|
+
try {
|
|
73
|
+
voiceAuthor = resolveVoiceAuthor(author, userId ?? resolveUserId());
|
|
74
|
+
}
|
|
75
|
+
catch (err) {
|
|
76
|
+
return {
|
|
77
|
+
content: [
|
|
78
|
+
{
|
|
79
|
+
type: "text",
|
|
80
|
+
text: err instanceof Error ? err.message : String(err),
|
|
81
|
+
},
|
|
82
|
+
],
|
|
83
|
+
isError: true,
|
|
84
|
+
};
|
|
85
|
+
}
|
|
58
86
|
try {
|
|
59
87
|
const result = await voiceTagContent({
|
|
60
88
|
nodeIds,
|
|
61
89
|
mode: mode,
|
|
62
90
|
accountId,
|
|
63
91
|
format: format,
|
|
92
|
+
voiceAuthor,
|
|
64
93
|
});
|
|
65
94
|
return {
|
|
66
95
|
content: [
|
|
67
96
|
{
|
|
68
97
|
type: "text",
|
|
69
|
-
text: `voice-tag: mode=${mode} format=${format} updated=${result.updated} skipped=${result.skipped}`,
|
|
98
|
+
text: `voice-tag: mode=${mode} format=${format} author=${voiceAuthor} updated=${result.updated} skipped=${result.skipped}`,
|
|
70
99
|
},
|
|
71
100
|
],
|
|
72
101
|
};
|
|
@@ -83,7 +112,7 @@ server.tool("voice-tag-content", "Stamp authorshipMode and format on one or many
|
|
|
83
112
|
};
|
|
84
113
|
}
|
|
85
114
|
});
|
|
86
|
-
server.tool("voice-distil-profile", "Three-mode tool. mode='sample' (default) walks the operator's full per-format human-only corpus and returns exemplars + recent edit intents for the agent to compose a fresh style card; cadence-guarded (≥20% corpus growth OR ≥30 days). mode='amend' (Task 472) reads only the named documents plus the existing :VoiceProfile.styleCard so the agent can decide whether one or more specific documents move the profile — operator-initiated, no cadence guard. mode='write' persists the YAML style card the agent composed; supply amendedFromNodeIds to attribute the write to specific documents (Task 472, bypasses cadence + corpus walk; existing LEARNED_FROM edges remain via MERGE). Trashed nodes are excluded from every walk. When format is omitted on 'sample', enumerates all formats in the corpus and distils each.", {
|
|
115
|
+
server.tool("voice-distil-profile", "Three-mode tool. mode='sample' (default) walks the operator's full per-format human-only corpus and returns exemplars + recent edit intents for the agent to compose a fresh style card; cadence-guarded (≥20% corpus growth OR ≥30 days). mode='amend' (Task 472) reads only the named documents plus the existing :VoiceProfile.styleCard so the agent can decide whether one or more specific documents move the profile — operator-initiated, no cadence guard. mode='write' persists the YAML style card the agent composed; supply amendedFromNodeIds to attribute the write to specific documents (Task 472, bypasses cadence + corpus walk; existing LEARNED_FROM edges remain via MERGE). Trashed nodes are excluded from every walk. When format is omitted on 'sample', enumerates all formats in the corpus and distils each. scope (Task 676): 'personal' (default) distils the operator's author-tagged content; 'org' distils the whole account into the house voice anchored on the business.", {
|
|
87
116
|
userId: z
|
|
88
117
|
.string()
|
|
89
118
|
.optional()
|
|
@@ -109,7 +138,8 @@ server.tool("voice-distil-profile", "Three-mode tool. mode='sample' (default) wa
|
|
|
109
138
|
.array(z.string())
|
|
110
139
|
.optional()
|
|
111
140
|
.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)."),
|
|
112
|
-
|
|
141
|
+
scope: zScope,
|
|
142
|
+
}, async ({ userId, format, force, mode, styleCardYaml, nodeIds, amendedFromNodeIds, scope }) => {
|
|
113
143
|
if (!accountId)
|
|
114
144
|
return refuseNoAccount("voice-distil-profile");
|
|
115
145
|
const resolvedUserId = userId ?? resolveUserId();
|
|
@@ -134,6 +164,7 @@ server.tool("voice-distil-profile", "Three-mode tool. mode='sample' (default) wa
|
|
|
134
164
|
styleCardYaml,
|
|
135
165
|
nodeIds,
|
|
136
166
|
amendedFromNodeIds,
|
|
167
|
+
scope: scope,
|
|
137
168
|
});
|
|
138
169
|
// Summarise single-format or multi-format result.
|
|
139
170
|
const summariseOne = (r, fmt) => {
|
|
@@ -171,7 +202,7 @@ server.tool("voice-distil-profile", "Three-mode tool. mode='sample' (default) wa
|
|
|
171
202
|
};
|
|
172
203
|
}
|
|
173
204
|
});
|
|
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' (
|
|
205
|
+
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). scope (Task 676): 'personal' (default) returns the caller's own voice; 'org' returns the account/house voice. A personal request with no personal profile/corpus falls back to the org profile (status 'fallback-org'). Returns {styleCard, exemplars, status} where status is one of: 'ok', 'fallback-org' (personal asked, org returned), 'no-data' (no profile and empty corpus for the scope), 'error' (lookup failed — carries a message). Drafting falls back to default register on 'no-data' and 'error' and injects the org card on 'fallback-org'; only 'no-data' means 'you have no voice profile yet' — never report no-profile on 'error'.", {
|
|
175
206
|
userId: z
|
|
176
207
|
.string()
|
|
177
208
|
.optional()
|
|
@@ -186,8 +217,9 @@ server.tool("voice-retrieve-conditioning", "Return the operator's per-format sty
|
|
|
186
217
|
.optional()
|
|
187
218
|
.describe("K-selector: short = K=5 (16k tokens, email/post); long = K=15 (96k tokens, brochure/prospectus). Defaults to short."),
|
|
188
219
|
register: z.string().optional().describe("Optional register hint"),
|
|
220
|
+
scope: zScope,
|
|
189
221
|
tokenBudget: z.number().int().positive().optional(),
|
|
190
|
-
}, async ({ userId, format, topic, length, register, tokenBudget }) => {
|
|
222
|
+
}, async ({ userId, format, topic, length, register, scope, tokenBudget }) => {
|
|
191
223
|
if (!accountId)
|
|
192
224
|
return refuseNoAccount("voice-retrieve-conditioning");
|
|
193
225
|
const resolvedUserId = userId ?? resolveUserId();
|
|
@@ -217,6 +249,7 @@ server.tool("voice-retrieve-conditioning", "Return the operator's per-format sty
|
|
|
217
249
|
topic,
|
|
218
250
|
length: length,
|
|
219
251
|
register,
|
|
252
|
+
scope: scope,
|
|
220
253
|
},
|
|
221
254
|
tokenBudget,
|
|
222
255
|
});
|
|
@@ -247,7 +280,7 @@ server.tool("voice-retrieve-conditioning", "Return the operator's per-format sty
|
|
|
247
280
|
};
|
|
248
281
|
}
|
|
249
282
|
});
|
|
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).", {
|
|
283
|
+
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). scope (Task 676): 'org' routes the edit to the account/house profile; 'personal' (default) to the operator's own. The editor is always preserved via the AUTHORED edge.", {
|
|
251
284
|
userId: z.string().optional(),
|
|
252
285
|
format: zFormat.describe("Writing format of the draft being edited."),
|
|
253
286
|
originalText: z.string().min(1),
|
|
@@ -258,7 +291,8 @@ server.tool("voice-record-feedback", "Capture an operator's edit on an agent dra
|
|
|
258
291
|
.describe("One sentence summarising what changed and what voice preference it reveals — produced by the calling agent in-turn from originalText vs editedText (Task 424)."),
|
|
259
292
|
skill: z.string().optional().describe("Calling skill name, for provenance"),
|
|
260
293
|
brief: z.string().optional().describe("Drafting brief that produced the original"),
|
|
261
|
-
|
|
294
|
+
scope: zScope,
|
|
295
|
+
}, async ({ userId, format, originalText, editedText, intent, skill, brief, scope }) => {
|
|
262
296
|
if (!accountId)
|
|
263
297
|
return refuseNoAccount("voice-record-feedback");
|
|
264
298
|
const resolvedUserId = userId ?? resolveUserId();
|
|
@@ -281,6 +315,7 @@ server.tool("voice-record-feedback", "Capture an operator's edit on an agent dra
|
|
|
281
315
|
originalText,
|
|
282
316
|
editedText,
|
|
283
317
|
intent,
|
|
318
|
+
scope: scope,
|
|
284
319
|
context: { skill, brief },
|
|
285
320
|
});
|
|
286
321
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,uDAAuD,CAAC;AACtF,aAAa,CAAC,cAAc,CAAC,CAAC;AAE9B,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAuB,MAAM,8BAA8B,CAAC;AACtG,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,EAAE,yBAAyB,EAAE,MAAM,wCAAwC,CAAC;AACnF,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AACvE,OAAO,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAC9E,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,MAAM,MAAM,GAAG,IAAI,SAAS,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SAAS,EAAE;iBACxJ;aACF;SACF,CAAC;IACJ,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,OAAO;YACL,OAAO,EAAE;gBACP;oBACE,IAAI,EAAE,MAAe;oBACrB,IAAI,EAAE,qCAAqC,GAAG,YAAY,KAAK,CAAC,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"}
|
|
@@ -83,4 +83,35 @@ export type VoiceFormat = (typeof FORMAT_VALUES)[number];
|
|
|
83
83
|
* walks use this function.
|
|
84
84
|
*/
|
|
85
85
|
export declare function voiceCorpusWhereWithFormat(format: VoiceFormat): string;
|
|
86
|
+
/**
|
|
87
|
+
* Reserved sentinel userId for the per-account org voice profile (Task 676).
|
|
88
|
+
*
|
|
89
|
+
* Keeps the `(accountId, userId, format)` UNIQUE constraint valid with no
|
|
90
|
+
* migration: exactly one org profile per `(account, format)`. A real
|
|
91
|
+
* `:AdminUser` must never hold this userId — `voice-distil-profile` surfaces
|
|
92
|
+
* a Neo4j constraint error (does not swallow it) if one does.
|
|
93
|
+
*/
|
|
94
|
+
export declare const ORG_USER_ID = "__org__";
|
|
95
|
+
/**
|
|
96
|
+
* Voice profile scope. `personal` = one operator's own voice, keyed
|
|
97
|
+
* `(accountId, userId, format)` and anchored on `:AdminUser`. `org` = the
|
|
98
|
+
* account/house voice, keyed `(accountId, '__org__', format)` and anchored on
|
|
99
|
+
* `:LocalBusiness`.
|
|
100
|
+
*/
|
|
101
|
+
export type VoiceScope = "personal" | "org";
|
|
102
|
+
/**
|
|
103
|
+
* The profile-key userId for a scope: the operator's own id for personal, the
|
|
104
|
+
* reserved sentinel for org. The single place that maps scope → key userId, so
|
|
105
|
+
* distillation, retrieval, and feedback agree on where an org profile lives.
|
|
106
|
+
*/
|
|
107
|
+
export declare function profileUserIdForScope(scope: VoiceScope, userId: string): string;
|
|
108
|
+
/**
|
|
109
|
+
* `VOICE_CORPUS_WHERE` + format predicate + author predicate. Requires both
|
|
110
|
+
* `$format` and `$voiceAuthor` bound in the calling Cypher parameters.
|
|
111
|
+
*
|
|
112
|
+
* Personal distillation and personal retrieval use this to narrow the
|
|
113
|
+
* account-wide corpus to one author's content; org walks use the unchanged
|
|
114
|
+
* account-wide `voiceCorpusWhereWithFormat`.
|
|
115
|
+
*/
|
|
116
|
+
export declare function voiceCorpusWhereWithFormatAndAuthor(format: VoiceFormat): string;
|
|
86
117
|
//# sourceMappingURL=voice-corpus.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"voice-corpus.d.ts","sourceRoot":"","sources":["../../src/lib/voice-corpus.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAEhD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,eAAO,MAAM,kBAAkB,QAU3B,CAAC;AAEL;;;;;;;;GAQG;AACH,eAAO,MAAM,uBAAuB,yDAI1B,CAAC;AAEX;;;;;;;;GAQG;AACH,eAAO,MAAM,aAAa,gFAOhB,CAAC;AAEX,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC;AAEzD;;;;;;;;GAQG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,WAAW,GAAG,MAAM,CAEtE"}
|
|
1
|
+
{"version":3,"file":"voice-corpus.d.ts","sourceRoot":"","sources":["../../src/lib/voice-corpus.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAEhD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,eAAO,MAAM,kBAAkB,QAU3B,CAAC;AAEL;;;;;;;;GAQG;AACH,eAAO,MAAM,uBAAuB,yDAI1B,CAAC;AAEX;;;;;;;;GAQG;AACH,eAAO,MAAM,aAAa,gFAOhB,CAAC;AAEX,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC;AAEzD;;;;;;;;GAQG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,WAAW,GAAG,MAAM,CAEtE;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,WAAW,YAAY,CAAC;AAErC;;;;;GAKG;AACH,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,KAAK,CAAC;AAE5C;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAE/E;AAED;;;;;;;GAOG;AACH,wBAAgB,mCAAmC,CAAC,MAAM,EAAE,WAAW,GAAG,MAAM,CAE/E"}
|
|
@@ -107,4 +107,32 @@ export const FORMAT_VALUES = [
|
|
|
107
107
|
export function voiceCorpusWhereWithFormat(format) {
|
|
108
108
|
return `${VOICE_CORPUS_WHERE}\n AND n.format = $format`;
|
|
109
109
|
}
|
|
110
|
+
/**
|
|
111
|
+
* Reserved sentinel userId for the per-account org voice profile (Task 676).
|
|
112
|
+
*
|
|
113
|
+
* Keeps the `(accountId, userId, format)` UNIQUE constraint valid with no
|
|
114
|
+
* migration: exactly one org profile per `(account, format)`. A real
|
|
115
|
+
* `:AdminUser` must never hold this userId — `voice-distil-profile` surfaces
|
|
116
|
+
* a Neo4j constraint error (does not swallow it) if one does.
|
|
117
|
+
*/
|
|
118
|
+
export const ORG_USER_ID = "__org__";
|
|
119
|
+
/**
|
|
120
|
+
* The profile-key userId for a scope: the operator's own id for personal, the
|
|
121
|
+
* reserved sentinel for org. The single place that maps scope → key userId, so
|
|
122
|
+
* distillation, retrieval, and feedback agree on where an org profile lives.
|
|
123
|
+
*/
|
|
124
|
+
export function profileUserIdForScope(scope, userId) {
|
|
125
|
+
return scope === "org" ? ORG_USER_ID : userId;
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* `VOICE_CORPUS_WHERE` + format predicate + author predicate. Requires both
|
|
129
|
+
* `$format` and `$voiceAuthor` bound in the calling Cypher parameters.
|
|
130
|
+
*
|
|
131
|
+
* Personal distillation and personal retrieval use this to narrow the
|
|
132
|
+
* account-wide corpus to one author's content; org walks use the unchanged
|
|
133
|
+
* account-wide `voiceCorpusWhereWithFormat`.
|
|
134
|
+
*/
|
|
135
|
+
export function voiceCorpusWhereWithFormatAndAuthor(format) {
|
|
136
|
+
return `${VOICE_CORPUS_WHERE}\n AND n.format = $format\n AND n.voiceAuthor = $voiceAuthor`;
|
|
137
|
+
}
|
|
110
138
|
//# sourceMappingURL=voice-corpus.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"voice-corpus.js","sourceRoot":"","sources":["../../src/lib/voice-corpus.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,UAAU,CAAC,KAAa;IACtC,OAAO,UAAU,KAAK,oBAAoB,KAAK,uBAAuB,CAAC;AACzE,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;;QAE1B,UAAU,CAAC,GAAG,CAAC;;;;;;cAMT,UAAU,CAAC,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U,qBAAqB,CAAC,KAAiB,EAAE,MAAc;IACrE,OAAO,KAAK,KAAK,KAAK,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC;AAChD,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,mCAAmC,CAAC,MAAmB;IACrE,OAAO,GAAG,kBAAkB,gEAAgE,CAAC;AAC/F,CAAC"}
|
|
@@ -1,7 +1,13 @@
|
|
|
1
|
-
import { type VoiceFormat } from "../lib/voice-corpus.js";
|
|
1
|
+
import { type VoiceFormat, type VoiceScope } from "../lib/voice-corpus.js";
|
|
2
2
|
export interface VoiceDistilProfileParams {
|
|
3
3
|
accountId: string;
|
|
4
4
|
userId: string;
|
|
5
|
+
/**
|
|
6
|
+
* Profile scope (Task 676). `'personal'` (default) distils the operator's
|
|
7
|
+
* own author-filtered corpus onto `:AdminUser`; `'org'` distils the whole
|
|
8
|
+
* account onto `:LocalBusiness` under the reserved sentinel userId.
|
|
9
|
+
*/
|
|
10
|
+
scope?: VoiceScope;
|
|
5
11
|
force?: boolean;
|
|
6
12
|
/**
|
|
7
13
|
* Writing format to distil. When omitted on `sample`, enumerates distinct
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"voice-distil-profile.d.ts","sourceRoot":"","sources":["../../src/tools/voice-distil-profile.ts"],"names":[],"mappings":"AA4BA,OAAO,
|
|
1
|
+
{"version":3,"file":"voice-distil-profile.d.ts","sourceRoot":"","sources":["../../src/tools/voice-distil-profile.ts"],"names":[],"mappings":"AA4BA,OAAO,EAML,KAAK,WAAW,EAChB,KAAK,UAAU,EAChB,MAAM,wBAAwB,CAAC;AA0BhC,MAAM,WAAW,wBAAwB;IACvC,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf;;;;OAIG;IACH,KAAK,CAAC,EAAE,UAAU,CAAC;IACnB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB;;;;OAIG;IACH,MAAM,CAAC,EAA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