mcp-scraper 0.4.14 → 0.6.0
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/bin/api-server.cjs +393 -29
- package/dist/bin/api-server.cjs.map +1 -1
- package/dist/bin/api-server.js +2 -2
- package/dist/bin/mcp-scraper-cli.cjs +1 -1
- package/dist/bin/mcp-scraper-cli.cjs.map +1 -1
- package/dist/bin/mcp-scraper-cli.js +1 -1
- package/dist/bin/mcp-scraper-install.cjs +1 -1
- package/dist/bin/mcp-scraper-install.cjs.map +1 -1
- package/dist/bin/mcp-scraper-install.js +1 -1
- package/dist/bin/mcp-stdio-server.cjs +588 -11
- package/dist/bin/mcp-stdio-server.cjs.map +1 -1
- package/dist/bin/mcp-stdio-server.js +3 -2
- package/dist/bin/mcp-stdio-server.js.map +1 -1
- package/dist/{chunk-XZ2GPRCM.js → chunk-3K5GT6VG.js} +326 -12
- package/dist/chunk-3K5GT6VG.js.map +1 -0
- package/dist/{chunk-SIPXEFTR.js → chunk-APJO2XV5.js} +6 -6
- package/dist/chunk-APJO2XV5.js.map +1 -0
- package/dist/{chunk-VQV7MB2S.js → chunk-BL7BBSYF.js} +2 -2
- package/dist/chunk-F2BXETDX.js +7 -0
- package/dist/chunk-F2BXETDX.js.map +1 -0
- package/dist/{server-TGORO4AJ.js → server-WHM446IZ.js} +70 -18
- package/dist/server-WHM446IZ.js.map +1 -0
- package/dist/{site-extract-repository-6X2C7RLF.js → site-extract-repository-U476J44K.js} +3 -3
- package/dist/{worker-WCSKUAOT.js → worker-KJZ3ZN2N.js} +2 -2
- package/package.json +2 -2
- package/dist/chunk-OL65BO4S.js +0 -7
- package/dist/chunk-OL65BO4S.js.map +0 -1
- package/dist/chunk-SIPXEFTR.js.map +0 -1
- package/dist/chunk-XZ2GPRCM.js.map +0 -1
- package/dist/server-TGORO4AJ.js.map +0 -1
- /package/dist/{chunk-VQV7MB2S.js.map → chunk-BL7BBSYF.js.map} +0 -0
- /package/dist/{site-extract-repository-6X2C7RLF.js.map → site-extract-repository-U476J44K.js.map} +0 -0
- /package/dist/{worker-WCSKUAOT.js.map → worker-KJZ3ZN2N.js.map} +0 -0
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
registerMemoryMcpTools,
|
|
8
8
|
registerPaaExtractorMcpTools,
|
|
9
9
|
registerSerpIntelligenceCaptureTools
|
|
10
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-3K5GT6VG.js";
|
|
11
11
|
import "../chunk-GWRIO6JT.js";
|
|
12
12
|
import "../chunk-HPV4VOQX.js";
|
|
13
13
|
import {
|
|
@@ -16,7 +16,8 @@ import {
|
|
|
16
16
|
import "../chunk-XGIPATLV.js";
|
|
17
17
|
import {
|
|
18
18
|
PACKAGE_VERSION
|
|
19
|
-
} from "../chunk-
|
|
19
|
+
} from "../chunk-F2BXETDX.js";
|
|
20
|
+
import "../chunk-APJO2XV5.js";
|
|
20
21
|
import "../chunk-M2S27J6Z.js";
|
|
21
22
|
|
|
22
23
|
// bin/mcp-stdio-server.ts
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../bin/mcp-stdio-server.ts"],"sourcesContent":["#!/usr/bin/env node\nimport { readFileSync } from 'node:fs'\nimport { homedir } from 'node:os'\nimport { join } from 'node:path'\nimport { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js'\nimport { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js'\nimport { HttpMcpToolExecutor } from '../src/mcp/http-mcp-tool-executor.js'\nimport { registerBrowserAgentMcpTools } from '../src/mcp/browser-agent-mcp-server.js'\nimport { registerPaaExtractorMcpTools, registerSerpIntelligenceCaptureTools } from '../src/mcp/paa-mcp-server.js'\nimport { registerMemoryMcpTools } from '../src/mcp/memory-mcp-server.js'\nimport { MemoryMcpToolExecutor } from '../src/mcp/memory-mcp-tool-executor.js'\nimport { SERVER_INSTRUCTIONS } from '../src/mcp/server-instructions.js'\nimport { renderInstallTerminal } from '../src/install-terminal.js'\nimport { PACKAGE_VERSION } from '../src/version.js'\n\nconst forceStdio =\n process.argv.includes('--stdio') ||\n process.env.MCP_SCRAPER_FORCE_STDIO === '1'\nconst interactiveTerminal = Boolean(process.stdin.isTTY && process.stdout.isTTY)\nconst wantsHelp = process.argv.includes('--help') || process.argv.includes('-h')\n\nif (!forceStdio && (interactiveTerminal || wantsHelp)) {\n const noColor =\n process.argv.includes('--no-color') ||\n process.env.NO_COLOR !== undefined ||\n process.env.FORCE_COLOR === '0' ||\n !process.stdout.isTTY\n\n process.stdout.write(renderInstallTerminal({\n version: PACKAGE_VERSION,\n color: !noColor,\n apiKeyConfigured: Boolean(process.env.MCP_SCRAPER_API_KEY?.trim()),\n }))\n process.exit(0)\n}\n\nfunction readApiKeyFile(): string | undefined {\n const explicitPath = process.env.MCP_SCRAPER_KEY_PATH?.trim()\n const paths = [explicitPath, join(homedir(), '.mcp-scraper-key')].filter(Boolean) as string[]\n for (const path of paths) {\n try {\n const value = readFileSync(path, 'utf8').trim()\n if (value) return value\n } catch {\n void 0\n }\n }\n return undefined\n}\n\nconst apiKey = (\n process.env.MCP_SCRAPER_API_KEY ??\n process.env.MCP_SCRAPER_KEY ??\n process.env.MCP_API_KEY ??\n readApiKeyFile()\n)?.trim()\nif (!apiKey) {\n process.stderr.write('MCP_SCRAPER_API_KEY env var or ~/.mcp-scraper-key is required\\n')\n process.exit(1)\n}\n\nconst baseUrl = process.env.MCP_SCRAPER_BASE_URL?.trim() || process.env.MCP_BASE_URL?.trim() || 'https://mcpscraper.dev'\nconst consoleBaseUrl = process.env.BROWSER_AGENT_CONSOLE_URL?.trim() || baseUrl\nconst server = new McpServer({ name: 'mcp-scraper', version: PACKAGE_VERSION }, { instructions: SERVER_INSTRUCTIONS })\n\nconst httpExecutor = new HttpMcpToolExecutor(baseUrl, apiKey)\nregisterPaaExtractorMcpTools(server, httpExecutor)\nregisterSerpIntelligenceCaptureTools(server, httpExecutor)\nregisterBrowserAgentMcpTools(server, { baseUrl, apiKey, consoleBaseUrl })\nregisterMemoryMcpTools(server, new MemoryMcpToolExecutor(baseUrl, apiKey))\n\nconst transport = new StdioServerTransport()\n\nasync function main() {\n await server.connect(transport)\n}\n\nmain().catch(err => {\n process.stderr.write(`${err instanceof Error ? err.message : String(err)}\\n`)\n process.exit(1)\n})\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../bin/mcp-stdio-server.ts"],"sourcesContent":["#!/usr/bin/env node\nimport { readFileSync } from 'node:fs'\nimport { homedir } from 'node:os'\nimport { join } from 'node:path'\nimport { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js'\nimport { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js'\nimport { HttpMcpToolExecutor } from '../src/mcp/http-mcp-tool-executor.js'\nimport { registerBrowserAgentMcpTools } from '../src/mcp/browser-agent-mcp-server.js'\nimport { registerPaaExtractorMcpTools, registerSerpIntelligenceCaptureTools } from '../src/mcp/paa-mcp-server.js'\nimport { registerMemoryMcpTools } from '../src/mcp/memory-mcp-server.js'\nimport { MemoryMcpToolExecutor } from '../src/mcp/memory-mcp-tool-executor.js'\nimport { SERVER_INSTRUCTIONS } from '../src/mcp/server-instructions.js'\nimport { renderInstallTerminal } from '../src/install-terminal.js'\nimport { PACKAGE_VERSION } from '../src/version.js'\n\nconst forceStdio =\n process.argv.includes('--stdio') ||\n process.env.MCP_SCRAPER_FORCE_STDIO === '1'\nconst interactiveTerminal = Boolean(process.stdin.isTTY && process.stdout.isTTY)\nconst wantsHelp = process.argv.includes('--help') || process.argv.includes('-h')\n\nif (!forceStdio && (interactiveTerminal || wantsHelp)) {\n const noColor =\n process.argv.includes('--no-color') ||\n process.env.NO_COLOR !== undefined ||\n process.env.FORCE_COLOR === '0' ||\n !process.stdout.isTTY\n\n process.stdout.write(renderInstallTerminal({\n version: PACKAGE_VERSION,\n color: !noColor,\n apiKeyConfigured: Boolean(process.env.MCP_SCRAPER_API_KEY?.trim()),\n }))\n process.exit(0)\n}\n\nfunction readApiKeyFile(): string | undefined {\n const explicitPath = process.env.MCP_SCRAPER_KEY_PATH?.trim()\n const paths = [explicitPath, join(homedir(), '.mcp-scraper-key')].filter(Boolean) as string[]\n for (const path of paths) {\n try {\n const value = readFileSync(path, 'utf8').trim()\n if (value) return value\n } catch {\n void 0\n }\n }\n return undefined\n}\n\nconst apiKey = (\n process.env.MCP_SCRAPER_API_KEY ??\n process.env.MCP_SCRAPER_KEY ??\n process.env.MCP_API_KEY ??\n readApiKeyFile()\n)?.trim()\nif (!apiKey) {\n process.stderr.write('MCP_SCRAPER_API_KEY env var or ~/.mcp-scraper-key is required\\n')\n process.exit(1)\n}\n\nconst baseUrl = process.env.MCP_SCRAPER_BASE_URL?.trim() || process.env.MCP_BASE_URL?.trim() || 'https://mcpscraper.dev'\nconst consoleBaseUrl = process.env.BROWSER_AGENT_CONSOLE_URL?.trim() || baseUrl\nconst server = new McpServer({ name: 'mcp-scraper', version: PACKAGE_VERSION }, { instructions: SERVER_INSTRUCTIONS })\n\nconst httpExecutor = new HttpMcpToolExecutor(baseUrl, apiKey)\nregisterPaaExtractorMcpTools(server, httpExecutor)\nregisterSerpIntelligenceCaptureTools(server, httpExecutor)\nregisterBrowserAgentMcpTools(server, { baseUrl, apiKey, consoleBaseUrl })\nregisterMemoryMcpTools(server, new MemoryMcpToolExecutor(baseUrl, apiKey))\n\nconst transport = new StdioServerTransport()\n\nasync function main() {\n await server.connect(transport)\n}\n\nmain().catch(err => {\n process.stderr.write(`${err instanceof Error ? err.message : String(err)}\\n`)\n process.exit(1)\n})\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AACA,SAAS,oBAAoB;AAC7B,SAAS,eAAe;AACxB,SAAS,YAAY;AACrB,SAAS,iBAAiB;AAC1B,SAAS,4BAA4B;AAUrC,IAAM,aACJ,QAAQ,KAAK,SAAS,SAAS,KAC/B,QAAQ,IAAI,4BAA4B;AAC1C,IAAM,sBAAsB,QAAQ,QAAQ,MAAM,SAAS,QAAQ,OAAO,KAAK;AAC/E,IAAM,YAAY,QAAQ,KAAK,SAAS,QAAQ,KAAK,QAAQ,KAAK,SAAS,IAAI;AAE/E,IAAI,CAAC,eAAe,uBAAuB,YAAY;AACrD,QAAM,UACJ,QAAQ,KAAK,SAAS,YAAY,KAClC,QAAQ,IAAI,aAAa,UACzB,QAAQ,IAAI,gBAAgB,OAC5B,CAAC,QAAQ,OAAO;AAElB,UAAQ,OAAO,MAAM,sBAAsB;AAAA,IACzC,SAAS;AAAA,IACT,OAAO,CAAC;AAAA,IACR,kBAAkB,QAAQ,QAAQ,IAAI,qBAAqB,KAAK,CAAC;AAAA,EACnE,CAAC,CAAC;AACF,UAAQ,KAAK,CAAC;AAChB;AAEA,SAAS,iBAAqC;AAC5C,QAAM,eAAe,QAAQ,IAAI,sBAAsB,KAAK;AAC5D,QAAM,QAAQ,CAAC,cAAc,KAAK,QAAQ,GAAG,kBAAkB,CAAC,EAAE,OAAO,OAAO;AAChF,aAAW,QAAQ,OAAO;AACxB,QAAI;AACF,YAAM,QAAQ,aAAa,MAAM,MAAM,EAAE,KAAK;AAC9C,UAAI,MAAO,QAAO;AAAA,IACpB,QAAQ;AAAA,IAER;AAAA,EACF;AACA,SAAO;AACT;AAEA,IAAM,UACJ,QAAQ,IAAI,uBACZ,QAAQ,IAAI,mBACZ,QAAQ,IAAI,eACZ,eAAe,IACd,KAAK;AACR,IAAI,CAAC,QAAQ;AACX,UAAQ,OAAO,MAAM,iEAAiE;AACtF,UAAQ,KAAK,CAAC;AAChB;AAEA,IAAM,UAAU,QAAQ,IAAI,sBAAsB,KAAK,KAAK,QAAQ,IAAI,cAAc,KAAK,KAAK;AAChG,IAAM,iBAAiB,QAAQ,IAAI,2BAA2B,KAAK,KAAK;AACxE,IAAM,SAAS,IAAI,UAAU,EAAE,MAAM,eAAe,SAAS,gBAAgB,GAAG,EAAE,cAAc,oBAAoB,CAAC;AAErH,IAAM,eAAe,IAAI,oBAAoB,SAAS,MAAM;AAC5D,6BAA6B,QAAQ,YAAY;AACjD,qCAAqC,QAAQ,YAAY;AACzD,6BAA6B,QAAQ,EAAE,SAAS,QAAQ,eAAe,CAAC;AACxE,uBAAuB,QAAQ,IAAI,sBAAsB,SAAS,MAAM,CAAC;AAEzE,IAAM,YAAY,IAAI,qBAAqB;AAE3C,eAAe,OAAO;AACpB,QAAM,OAAO,QAAQ,SAAS;AAChC;AAEA,KAAK,EAAE,MAAM,SAAO;AAClB,UAAQ,OAAO,MAAM,GAAG,eAAe,QAAQ,IAAI,UAAU,OAAO,GAAG,CAAC;AAAA,CAAI;AAC5E,UAAQ,KAAK,CAAC;AAChB,CAAC;","names":[]}
|
|
@@ -17,7 +17,10 @@ import {
|
|
|
17
17
|
} from "./chunk-XGIPATLV.js";
|
|
18
18
|
import {
|
|
19
19
|
PACKAGE_VERSION
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-F2BXETDX.js";
|
|
21
|
+
import {
|
|
22
|
+
MC_PER_CREDIT
|
|
23
|
+
} from "./chunk-APJO2XV5.js";
|
|
21
24
|
import {
|
|
22
25
|
sanitizeVendorName
|
|
23
26
|
} from "./chunk-M2S27J6Z.js";
|
|
@@ -196,7 +199,7 @@ Multi-step orchestrations \u2014 prefer these over hand-chaining primitives when
|
|
|
196
199
|
read it back for full detail rather than expecting the whole payload inline.
|
|
197
200
|
|
|
198
201
|
## Memory
|
|
199
|
-
mcp-scraper also exposes
|
|
202
|
+
mcp-scraper also exposes persistent per-user memory tools (notes, facts, vaults,
|
|
200
203
|
scheduled actions, tables, channels) backed by memory.mcpscraper.dev. Every account starts with 13
|
|
201
204
|
vaults \u2014 call **list-vaults** to see what exists before creating anything new. Pick the vault whose job
|
|
202
205
|
matches the content: **Ideas** (unvalidated concepts), **Knowledge** (distilled lessons/how-tos),
|
|
@@ -206,11 +209,45 @@ matches the content: **Ideas** (unvalidated concepts), **Knowledge** (distilled
|
|
|
206
209
|
**Improvement Log** (receipts of changes made and whether they worked), **Experiments** (hypothesis +
|
|
207
210
|
measured result), **Sprint** (current cycle's scope), **Inspiration** (other people's work worth
|
|
208
211
|
studying).
|
|
209
|
-
|
|
210
|
-
|
|
212
|
+
For a normal new narrative note, call **prepare-memory-write** first. It queries the live vault contract,
|
|
213
|
+
tag vocabulary, and natural neighbor vaults, and returns interlink candidates that must be read before
|
|
214
|
+
acceptance. Compose every returned template section, then call **memory-capture**, which validates the
|
|
215
|
+
note, registers canonical tags, writes it, and verifies readback. Reserve low-level **memory-put** for
|
|
216
|
+
deliberate edits and migrations. Use
|
|
211
217
|
**table-create**/**table-insert-rows**/**table-query** instead when the caller wants row-shaped data
|
|
212
218
|
they'll filter/sort by exact value. **memory-search** is meaning-based over full content (embeds, slower);
|
|
213
219
|
**memory-list** filters one vault by kind/tags (fast, exact).
|
|
220
|
+
|
|
221
|
+
Treat every memory create or update as a graph operation. **prepare-memory-write** supplies the initial
|
|
222
|
+
shortlist; use **memory-search** when it is weak or the topic is broad, and **memory-get** to read the best
|
|
223
|
+
candidates in full. Add only links supported by the notes: same-
|
|
224
|
+
vault targets go in props.related and natural [[path]] body links; cross-vault targets go in
|
|
225
|
+
props.related_vault_notes as Vault Name::relative/path.md. Prefer existing People/Projects/system
|
|
226
|
+
hubs and fewer strong links. Do not trust a background linker to repair a weak write.
|
|
227
|
+
|
|
228
|
+
Use the target vault's template, not generic prose. Always set summary, specific reusable tags,
|
|
229
|
+
source_type, source_ref, related, related_vault_notes, embed, embed_priority, and a valid
|
|
230
|
+
status; include vault-specific props when relevant. Body patterns: Knowledge = Thesis / Explanation /
|
|
231
|
+
Examples / Implications; Library = Source Identity / Preserved Material / Extraction Notes; People =
|
|
232
|
+
Identity / Relationship / Known Context / Interaction History / Open Loops; Projects = Purpose / Current
|
|
233
|
+
State / Architecture / Open Work / Decisions; Issues = Observation / Impact / Confirmation / Evidence /
|
|
234
|
+
Resolution; Improvement Log = Improvement / Issue Link / Change Made / Verification / Result. Keep Tasks,
|
|
235
|
+
Calendar, Communications, Ideas, Inspiration, Experiments, and Sprint aligned to their named purpose.
|
|
236
|
+
Tags are live vocabulary, not improvised labels: **list-memory-tags** shows what exists and
|
|
237
|
+
**resolve-memory-tags** returns reuse/create/omit. A new tag is justified only when the concept is central,
|
|
238
|
+
reusable, and has no exact, alias, or near-equivalent. Use **memory-backlinks**,
|
|
239
|
+
**memory-graph-universe**, and **memory-graph-path** to trace the linked universe across vaults.
|
|
240
|
+
|
|
241
|
+
Scrape deposits are raw evidence and therefore go to **Library** through **library-ingest**, with the full
|
|
242
|
+
Library template and source metadata. If the source contains durable applicable guidance, create a separate
|
|
243
|
+
Knowledge companion through prepare-memory-write + memory-capture and link it to the Library source with
|
|
244
|
+
derived_from; do not replace the raw source with the guide.
|
|
245
|
+
|
|
246
|
+
For an update, call **memory-get** first and pass its revision as baseRevision. Preserve the existing
|
|
247
|
+
title, source, capture time, content context, and props unless the request deliberately changes them.
|
|
248
|
+
If a legacy backend does not return props, do not overwrite an existing linked note through that surface;
|
|
249
|
+
report that link preservation cannot be proved. After the write, read it back and search a distinctive
|
|
250
|
+
phrase to verify persistence and indexing.
|
|
214
251
|
`.trim();
|
|
215
252
|
}
|
|
216
253
|
var SERVER_INSTRUCTIONS = serverInstructions(true);
|
|
@@ -1958,7 +1995,7 @@ function formatCreditsInfo(raw, input) {
|
|
|
1958
1995
|
return `| ${c.label} | ${c.credits} | ${c.unit}${notes} |`;
|
|
1959
1996
|
}).join("\n");
|
|
1960
1997
|
const ledgerRows = ledger.map((row) => {
|
|
1961
|
-
const credits = row.amount_mc /
|
|
1998
|
+
const credits = row.amount_mc / MC_PER_CREDIT;
|
|
1962
1999
|
return `| ${row.created_at} | ${row.operation} | ${credits} | ${row.description ?? ""} |`;
|
|
1963
2000
|
}).join("\n");
|
|
1964
2001
|
const matchedSection = matched ? `
|
|
@@ -2008,7 +2045,7 @@ ${ledgerRows}` : ""
|
|
|
2008
2045
|
ledger: ledger.map((row) => ({
|
|
2009
2046
|
createdAt: String(row.created_at ?? ""),
|
|
2010
2047
|
operation: String(row.operation ?? ""),
|
|
2011
|
-
credits: row.amount_mc /
|
|
2048
|
+
credits: row.amount_mc / MC_PER_CREDIT,
|
|
2012
2049
|
description: row.description ?? null
|
|
2013
2050
|
})),
|
|
2014
2051
|
concurrency: concurrencyRaw && upgradeRaw ? {
|
|
@@ -6874,6 +6911,52 @@ var UnlinkShareSchema = {
|
|
|
6874
6911
|
openWorldHint: false
|
|
6875
6912
|
}
|
|
6876
6913
|
};
|
|
6914
|
+
var memoryCaptureTool_notePropsSchema = z3.object({
|
|
6915
|
+
status: z3.string().describe("Status enum value from the target vault contract."),
|
|
6916
|
+
summary: z3.string().describe("Short retrieval-ready description."),
|
|
6917
|
+
tags: z3.array(z3.string()).describe("AI-generated keyword tags, not vault names."),
|
|
6918
|
+
pinned: z3.boolean().describe("Recall boost for important notes."),
|
|
6919
|
+
source_type: z3.string().describe("Attribution kind: user, person, url, file, channel, thread, or note."),
|
|
6920
|
+
source_ref: z3.string().describe("Attribution reference (URL, path, channel, thread, or source note)."),
|
|
6921
|
+
related: z3.array(z3.string()).describe("Same-vault links (wiki [[ ]] targets)."),
|
|
6922
|
+
related_vault_notes: z3.array(z3.string()).describe('Cross-vault references in "Vault Name::relative/path.md" form.'),
|
|
6923
|
+
embed: z3.boolean().describe("Whether Smart RAG should index the note."),
|
|
6924
|
+
embed_priority: z3.enum(["low", "normal", "high"]).describe("Embedding priority."),
|
|
6925
|
+
embedding_summary: z3.string().describe("Optional retrieval-specific summary."),
|
|
6926
|
+
type: z3.string().describe("Note type from the target vault contract (also used to route the note)."),
|
|
6927
|
+
domain: z3.string().describe("Domain folder for Library/Knowledge (AI, SEO, Copywriting & Ads, Business, Spirituality)."),
|
|
6928
|
+
folder: z3.string().describe("Explicit sub-folder within the vault; overrides routing-derived folder."),
|
|
6929
|
+
parentMessageId: z3.string().describe("Channel messages only: the path of the top-level message this is a reply to. Absent on top-level messages.")
|
|
6930
|
+
}).partial().passthrough();
|
|
6931
|
+
var MemoryCaptureSchema = {
|
|
6932
|
+
id: "memory-capture",
|
|
6933
|
+
upstreamName: "memoryCaptureTool",
|
|
6934
|
+
description: "Strict normal-create path for durable memory. Refuses incomplete notes, writes through memory-put, registers canonical tags, and reads the note back to verify persisted content and props. Call prepare-memory-write first. Reserve memory-put for low-level migrations or deliberate edits.",
|
|
6935
|
+
input: {
|
|
6936
|
+
vault: z3.string(),
|
|
6937
|
+
folder: z3.string().optional(),
|
|
6938
|
+
path: z3.string().min(1),
|
|
6939
|
+
title: z3.string().min(1),
|
|
6940
|
+
content: z3.string().min(1),
|
|
6941
|
+
props: memoryCaptureTool_notePropsSchema,
|
|
6942
|
+
baseRevision: z3.number().optional(),
|
|
6943
|
+
tagDecisions: z3.array(z3.object({ tag: z3.string().min(1), central: z3.boolean(), reusable: z3.boolean(), description: z3.string().optional() })).max(8).optional().describe("Required justification for any tag that does not already exist. Existing exact/alias/near tags are canonicalized automatically; a new tag is accepted only when its matching decision has central=true and reusable=true.")
|
|
6944
|
+
},
|
|
6945
|
+
output: {
|
|
6946
|
+
ok: z3.boolean(),
|
|
6947
|
+
valid: z3.boolean().optional(),
|
|
6948
|
+
errors: z3.array(z3.string()).optional(),
|
|
6949
|
+
warnings: z3.array(z3.string()).optional(),
|
|
6950
|
+
tagResolutions: z3.array(z3.object({ candidate: z3.string(), action: z3.enum(["reuse", "create", "omit"]), tag: z3.string().optional(), reason: z3.string() })).optional(),
|
|
6951
|
+
note: z3.object({ path: z3.string(), title: z3.string(), updatedAt: z3.string(), revision: z3.number() }).optional(),
|
|
6952
|
+
indexed: z3.number().optional(),
|
|
6953
|
+
verified: z3.object({ contentBytes: z3.number(), propsPersisted: z3.boolean(), revision: z3.number() }).optional(),
|
|
6954
|
+
conflict: z3.boolean().optional(),
|
|
6955
|
+
code: z3.string().optional(),
|
|
6956
|
+
error: z3.string().optional()
|
|
6957
|
+
},
|
|
6958
|
+
annotations: { title: "Capture Governed Memory", readOnlyHint: false, destructiveHint: false, idempotentHint: true, openWorldHint: true }
|
|
6959
|
+
};
|
|
6877
6960
|
var MemoryQuestionsSchema = {
|
|
6878
6961
|
id: "memory-questions",
|
|
6879
6962
|
upstreamName: "memoryQuestionsTool",
|
|
@@ -6903,6 +6986,67 @@ var MemoryQuestionsSchema = {
|
|
|
6903
6986
|
openWorldHint: true
|
|
6904
6987
|
}
|
|
6905
6988
|
};
|
|
6989
|
+
var PrepareMemoryWriteSchema = {
|
|
6990
|
+
id: "prepare-memory-write",
|
|
6991
|
+
upstreamName: "prepareMemoryWriteTool",
|
|
6992
|
+
description: "Mandatory planning pass for a normal new memory. Routes the note, returns the live template and natural vault relationships, resolves proposed tags against the registry, and shortlists interlink opportunities that must be read/reviewed before capture.",
|
|
6993
|
+
input: {
|
|
6994
|
+
title: z3.string().min(1),
|
|
6995
|
+
content: z3.string().min(1),
|
|
6996
|
+
source: z3.string().optional(),
|
|
6997
|
+
type: z3.string().optional(),
|
|
6998
|
+
vault: z3.string().optional(),
|
|
6999
|
+
tagCandidates: z3.array(z3.object({ tag: z3.string().min(1), central: z3.boolean().optional(), reusable: z3.boolean().optional(), description: z3.string().optional() })).max(20).optional(),
|
|
7000
|
+
maxLinks: z3.number().int().min(1).max(20).optional()
|
|
7001
|
+
},
|
|
7002
|
+
output: {
|
|
7003
|
+
ok: z3.boolean(),
|
|
7004
|
+
route: z3.record(z3.unknown()).optional(),
|
|
7005
|
+
contract: z3.record(z3.unknown()).optional(),
|
|
7006
|
+
tagResolutions: z3.array(z3.record(z3.unknown())).optional(),
|
|
7007
|
+
linkOpportunities: z3.array(z3.record(z3.unknown())).optional(),
|
|
7008
|
+
instructions: z3.array(z3.string()).optional(),
|
|
7009
|
+
error: z3.string().optional()
|
|
7010
|
+
},
|
|
7011
|
+
annotations: { title: "Prepare Memory Write", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
7012
|
+
};
|
|
7013
|
+
var validateMemoryWriteTool_notePropsSchema = z3.object({
|
|
7014
|
+
status: z3.string().describe("Status enum value from the target vault contract."),
|
|
7015
|
+
summary: z3.string().describe("Short retrieval-ready description."),
|
|
7016
|
+
tags: z3.array(z3.string()).describe("AI-generated keyword tags, not vault names."),
|
|
7017
|
+
pinned: z3.boolean().describe("Recall boost for important notes."),
|
|
7018
|
+
source_type: z3.string().describe("Attribution kind: user, person, url, file, channel, thread, or note."),
|
|
7019
|
+
source_ref: z3.string().describe("Attribution reference (URL, path, channel, thread, or source note)."),
|
|
7020
|
+
related: z3.array(z3.string()).describe("Same-vault links (wiki [[ ]] targets)."),
|
|
7021
|
+
related_vault_notes: z3.array(z3.string()).describe('Cross-vault references in "Vault Name::relative/path.md" form.'),
|
|
7022
|
+
embed: z3.boolean().describe("Whether Smart RAG should index the note."),
|
|
7023
|
+
embed_priority: z3.enum(["low", "normal", "high"]).describe("Embedding priority."),
|
|
7024
|
+
embedding_summary: z3.string().describe("Optional retrieval-specific summary."),
|
|
7025
|
+
type: z3.string().describe("Note type from the target vault contract (also used to route the note)."),
|
|
7026
|
+
domain: z3.string().describe("Domain folder for Library/Knowledge (AI, SEO, Copywriting & Ads, Business, Spirituality)."),
|
|
7027
|
+
folder: z3.string().describe("Explicit sub-folder within the vault; overrides routing-derived folder."),
|
|
7028
|
+
parentMessageId: z3.string().describe("Channel messages only: the path of the top-level message this is a reply to. Absent on top-level messages.")
|
|
7029
|
+
}).partial().passthrough();
|
|
7030
|
+
var ValidateMemoryWriteSchema = {
|
|
7031
|
+
id: "validate-memory-write",
|
|
7032
|
+
upstreamName: "validateMemoryWriteTool",
|
|
7033
|
+
description: "Validate a proposed governed note without writing it. Checks template completeness, vault status/type, canonical tag count, attribution, Obsidian link primitives, and retrieval metadata.",
|
|
7034
|
+
input: {
|
|
7035
|
+
vault: z3.string(),
|
|
7036
|
+
title: z3.string(),
|
|
7037
|
+
content: z3.string(),
|
|
7038
|
+
props: validateMemoryWriteTool_notePropsSchema
|
|
7039
|
+
},
|
|
7040
|
+
output: {
|
|
7041
|
+
ok: z3.boolean(),
|
|
7042
|
+
valid: z3.boolean().optional(),
|
|
7043
|
+
errors: z3.array(z3.string()).optional(),
|
|
7044
|
+
warnings: z3.array(z3.string()).optional(),
|
|
7045
|
+
normalizedTags: z3.array(z3.string()).optional(),
|
|
7046
|
+
error: z3.string().optional()
|
|
7047
|
+
},
|
|
7048
|
+
annotations: { title: "Validate Memory Write", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
7049
|
+
};
|
|
6906
7050
|
var CreateChannelSchema = {
|
|
6907
7051
|
id: "create-channel",
|
|
6908
7052
|
upstreamName: "createChannelTool",
|
|
@@ -7243,18 +7387,78 @@ var RecordFactSchema = {
|
|
|
7243
7387
|
openWorldHint: false
|
|
7244
7388
|
}
|
|
7245
7389
|
};
|
|
7390
|
+
var NoteBacklinksSchema = {
|
|
7391
|
+
id: "memory-backlinks",
|
|
7392
|
+
upstreamName: "noteBacklinksTool",
|
|
7393
|
+
description: "Return every resolved incoming link to a note across all accessible vaults, including typed metadata links and Obsidian wiki links.",
|
|
7394
|
+
input: {
|
|
7395
|
+
note: z3.string().min(1),
|
|
7396
|
+
vault: z3.string().optional()
|
|
7397
|
+
},
|
|
7398
|
+
output: {
|
|
7399
|
+
ok: z3.boolean(),
|
|
7400
|
+
nodes: z3.array(z3.object({ id: z3.string(), vault: z3.string(), path: z3.string(), title: z3.string(), resolved: z3.boolean() })).optional(),
|
|
7401
|
+
edges: z3.array(z3.object({ source: z3.string(), target: z3.string(), type: z3.string(), evidence: z3.string(), sourceField: z3.string(), resolved: z3.boolean() })).optional(),
|
|
7402
|
+
error: z3.string().optional()
|
|
7403
|
+
},
|
|
7404
|
+
annotations: { title: "Memory Backlinks", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
7405
|
+
};
|
|
7406
|
+
var GraphPathSchema = {
|
|
7407
|
+
id: "memory-graph-path",
|
|
7408
|
+
upstreamName: "graphPathTool",
|
|
7409
|
+
description: "Find the shortest navigable connection between two memory notes across vault boundaries. Returns an empty graph when no path exists within maxDepth.",
|
|
7410
|
+
input: {
|
|
7411
|
+
from: z3.string().min(1),
|
|
7412
|
+
to: z3.string().min(1),
|
|
7413
|
+
fromVault: z3.string().optional(),
|
|
7414
|
+
toVault: z3.string().optional(),
|
|
7415
|
+
maxDepth: z3.number().int().min(1).max(12).optional()
|
|
7416
|
+
},
|
|
7417
|
+
output: {
|
|
7418
|
+
ok: z3.boolean(),
|
|
7419
|
+
nodes: z3.array(z3.object({ id: z3.string(), vault: z3.string(), path: z3.string(), title: z3.string(), resolved: z3.boolean() })).optional(),
|
|
7420
|
+
edges: z3.array(z3.object({ source: z3.string(), target: z3.string(), type: z3.string(), evidence: z3.string(), sourceField: z3.string(), resolved: z3.boolean() })).optional(),
|
|
7421
|
+
error: z3.string().optional()
|
|
7422
|
+
},
|
|
7423
|
+
annotations: { title: "Memory Graph Path", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
7424
|
+
};
|
|
7425
|
+
var GraphUniverseSchema = {
|
|
7426
|
+
id: "memory-graph-universe",
|
|
7427
|
+
upstreamName: "graphUniverseTool",
|
|
7428
|
+
description: "Traverse the interlinked memory universe around one note in every direction, like an Obsidian local graph. Returns nodes and typed edges to a bounded depth.",
|
|
7429
|
+
input: {
|
|
7430
|
+
note: z3.string().min(1),
|
|
7431
|
+
vault: z3.string().optional(),
|
|
7432
|
+
depth: z3.number().int().min(0).max(6).optional(),
|
|
7433
|
+
maxNodes: z3.number().int().min(1).max(500).optional()
|
|
7434
|
+
},
|
|
7435
|
+
output: {
|
|
7436
|
+
ok: z3.boolean(),
|
|
7437
|
+
root: z3.string().optional(),
|
|
7438
|
+
depth: z3.number().optional(),
|
|
7439
|
+
truncated: z3.boolean().optional(),
|
|
7440
|
+
nodes: z3.array(z3.object({ id: z3.string(), vault: z3.string(), path: z3.string(), title: z3.string(), resolved: z3.boolean() })).optional(),
|
|
7441
|
+
edges: z3.array(z3.object({ source: z3.string(), target: z3.string(), type: z3.string(), evidence: z3.string(), sourceField: z3.string(), resolved: z3.boolean() })).optional(),
|
|
7442
|
+
error: z3.string().optional()
|
|
7443
|
+
},
|
|
7444
|
+
annotations: { title: "Memory Graph Universe", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
7445
|
+
};
|
|
7246
7446
|
var LibraryIngestSchema = {
|
|
7247
7447
|
id: "library-ingest",
|
|
7248
7448
|
upstreamName: "libraryIngestTool",
|
|
7249
7449
|
description: "Deposit a scrape, transcript, or generated output into the tenant Library vault for later semantic recall. Content is embedded for per-tenant search and best-effort mirrored to a local vault when configured. Requires write scope on the target vault.",
|
|
7250
7450
|
input: {
|
|
7251
7451
|
vault: z3.string().optional().describe(
|
|
7252
|
-
|
|
7452
|
+
"Vault to deposit into. Optional and normally omitted: raw scrapes always default to Library. Override only for a deliberate nonstandard migration."
|
|
7253
7453
|
),
|
|
7254
7454
|
title: z3.string().min(1).describe("Short human-readable title for the item; used to build the stored path. Must be non-empty."),
|
|
7255
7455
|
content: z3.string().min(1).describe("The full captured text (scrape/transcript/output) to store and index. Must be non-empty."),
|
|
7256
7456
|
source: z3.string().min(1).describe("Provenance of the content, e.g. a URL or tool name. Must be non-empty."),
|
|
7257
7457
|
capturedAt: z3.string().optional().describe("ISO-8601 capture timestamp. Optional; defaults to now. Also seeds the deterministic storage path."),
|
|
7458
|
+
summary: z3.string().optional().describe("Retrieval-ready source summary. Optional; a provenance summary is generated when omitted."),
|
|
7459
|
+
tags: z3.array(z3.string()).max(8).optional().describe("Reviewed canonical tags. Existing tags should be resolved first; when omitted, deterministic source/topic tags are generated."),
|
|
7460
|
+
related: z3.array(z3.string()).optional().describe("Reviewed same-vault Library note paths."),
|
|
7461
|
+
relatedVaultNotes: z3.array(z3.string()).optional().describe("Reviewed cross-vault references in Vault::path.md form."),
|
|
7258
7462
|
localVaultPath: z3.string().optional().describe("Filesystem root to also mirror the item to. Optional; falls back to MEMORY_LOCAL_VAULT_ROOT env when set.")
|
|
7259
7463
|
},
|
|
7260
7464
|
output: {
|
|
@@ -7264,6 +7468,7 @@ var LibraryIngestSchema = {
|
|
|
7264
7468
|
path: z3.string().optional().describe("Vault-relative path the item was stored at (under library/...)."),
|
|
7265
7469
|
indexed: z3.number().optional().describe("Number of search chunks indexed (0 if embedding failed but the note still saved)."),
|
|
7266
7470
|
dualWritten: z3.boolean().optional().describe("True if the item was also mirrored to the local filesystem vault."),
|
|
7471
|
+
nextStep: z3.string().optional().describe("Recommended extraction action after the raw Library source is safe."),
|
|
7267
7472
|
code: z3.string().optional().describe("Machine-readable denial code when ok is false: quota_exceeded or free_cost_cap."),
|
|
7268
7473
|
error: z3.string().optional().describe("Human-readable failure reason when ok is false.")
|
|
7269
7474
|
},
|
|
@@ -7341,10 +7546,27 @@ var ExportSchema = {
|
|
|
7341
7546
|
openWorldHint: false
|
|
7342
7547
|
}
|
|
7343
7548
|
};
|
|
7549
|
+
var getTool_notePropsSchema = z3.object({
|
|
7550
|
+
status: z3.string().describe("Status enum value from the target vault contract."),
|
|
7551
|
+
summary: z3.string().describe("Short retrieval-ready description."),
|
|
7552
|
+
tags: z3.array(z3.string()).describe("AI-generated keyword tags, not vault names."),
|
|
7553
|
+
pinned: z3.boolean().describe("Recall boost for important notes."),
|
|
7554
|
+
source_type: z3.string().describe("Attribution kind: user, person, url, file, channel, thread, or note."),
|
|
7555
|
+
source_ref: z3.string().describe("Attribution reference (URL, path, channel, thread, or source note)."),
|
|
7556
|
+
related: z3.array(z3.string()).describe("Same-vault links (wiki [[ ]] targets)."),
|
|
7557
|
+
related_vault_notes: z3.array(z3.string()).describe('Cross-vault references in "Vault Name::relative/path.md" form.'),
|
|
7558
|
+
embed: z3.boolean().describe("Whether Smart RAG should index the note."),
|
|
7559
|
+
embed_priority: z3.enum(["low", "normal", "high"]).describe("Embedding priority."),
|
|
7560
|
+
embedding_summary: z3.string().describe("Optional retrieval-specific summary."),
|
|
7561
|
+
type: z3.string().describe("Note type from the target vault contract (also used to route the note)."),
|
|
7562
|
+
domain: z3.string().describe("Domain folder for Library/Knowledge (AI, SEO, Copywriting & Ads, Business, Spirituality)."),
|
|
7563
|
+
folder: z3.string().describe("Explicit sub-folder within the vault; overrides routing-derived folder."),
|
|
7564
|
+
parentMessageId: z3.string().describe("Channel messages only: the path of the top-level message this is a reply to. Absent on top-level messages.")
|
|
7565
|
+
}).partial().passthrough();
|
|
7344
7566
|
var GetSchema = {
|
|
7345
7567
|
id: "memory-get",
|
|
7346
7568
|
upstreamName: "getTool",
|
|
7347
|
-
description: "Read a single note from a vault by its exact path, or by shareId for a note shared with you and accepted. Returns a revision number \u2014 pass it as baseRevision on a later memory-put/delete-note to detect a concurrent edit instead of silently overwriting it. Requires read scope.",
|
|
7569
|
+
description: "Read a single note from a vault by its exact path, or by shareId for a note shared with you and accepted. Owned notes include their stored Obsidian props so edits can preserve links and template metadata. Returns a revision number \u2014 pass it as baseRevision on a later memory-put/delete-note to detect a concurrent edit instead of silently overwriting it. Requires read scope.",
|
|
7348
7570
|
input: {
|
|
7349
7571
|
vault: z3.string().optional().describe(
|
|
7350
7572
|
"Vault to read from. Optional; defaults to the session active vault, then the first vault the caller is entitled to. Ignored when shareId is given."
|
|
@@ -7364,6 +7586,7 @@ var GetSchema = {
|
|
|
7364
7586
|
capturedAt: z3.string().describe("ISO-8601 timestamp of when the note was first captured."),
|
|
7365
7587
|
revision: z3.number().describe("Current revision number. Pass this as baseRevision when editing, so a concurrent edit by someone else is detected instead of silently overwritten."),
|
|
7366
7588
|
updatedBy: z3.string().nullable().describe("Identity that made the last write, if known."),
|
|
7589
|
+
props: getTool_notePropsSchema.optional().describe("Stored Obsidian metadata for an owned note, including links and vault-specific template fields. Omitted for secure or individually shared notes."),
|
|
7367
7590
|
sharedBy: z3.string().optional().describe("Present only when read via shareId: the identity who owns and shared this note."),
|
|
7368
7591
|
othersEditing: z3.array(z3.string()).optional().describe("Advisory only, not a lock: identities who read this same note within the last ~2 minutes and may be about to edit it. Worth a heads-up to the human before you write; the real safety net is still baseRevision on the write itself.")
|
|
7369
7592
|
}).optional().describe("The full note. Present when ok is true."),
|
|
@@ -7411,7 +7634,7 @@ var ListSchema = {
|
|
|
7411
7634
|
openWorldHint: false
|
|
7412
7635
|
}
|
|
7413
7636
|
};
|
|
7414
|
-
var
|
|
7637
|
+
var putTool_notePropsSchema = z3.object({
|
|
7415
7638
|
status: z3.string().describe("Status enum value from the target vault contract."),
|
|
7416
7639
|
summary: z3.string().describe("Short retrieval-ready description."),
|
|
7417
7640
|
tags: z3.array(z3.string()).describe("AI-generated keyword tags, not vault names."),
|
|
@@ -7427,7 +7650,7 @@ var notePropsSchema = z3.object({
|
|
|
7427
7650
|
domain: z3.string().describe("Domain folder for Library/Knowledge (AI, SEO, Copywriting & Ads, Business, Spirituality)."),
|
|
7428
7651
|
folder: z3.string().describe("Explicit sub-folder within the vault; overrides routing-derived folder."),
|
|
7429
7652
|
parentMessageId: z3.string().describe("Channel messages only: the path of the top-level message this is a reply to. Absent on top-level messages.")
|
|
7430
|
-
}).partial();
|
|
7653
|
+
}).partial().passthrough();
|
|
7431
7654
|
var PutSchema = {
|
|
7432
7655
|
id: "memory-put",
|
|
7433
7656
|
upstreamName: "putTool",
|
|
@@ -7440,7 +7663,7 @@ var PutSchema = {
|
|
|
7440
7663
|
shareId: z3.string().optional().describe("Edit a note someone individually shared with you and you accepted (accept-share), by its shareId, instead of vault+path. Requires the share to grant edit permission, and baseRevision is mandatory (get the current revision first) since you are editing alongside the owner and possibly others."),
|
|
7441
7664
|
title: z3.string().optional().describe("Optional human-readable title; defaults are derived from the path when omitted."),
|
|
7442
7665
|
content: z3.string().min(1).describe("The full note body to store and index for semantic search. Must be non-empty."),
|
|
7443
|
-
props:
|
|
7666
|
+
props: putTool_notePropsSchema.optional().describe("Obsidian note primitives plus vault-specific template fields. On edits, supplied fields patch the stored props instead of replacing the whole object; pass an empty array to deliberately clear a link list. Type/domain/folder also steer routing when no vault is given."),
|
|
7444
7667
|
baseRevision: z3.number().optional().describe("Revision the edit is based on (from a prior get/put). When provided, the write only applies if the note is still at this revision; otherwise it is rejected as a conflict instead of silently overwriting a concurrent edit. Omit for last-write-wins (fine for solo notes).")
|
|
7445
7668
|
},
|
|
7446
7669
|
output: {
|
|
@@ -8054,6 +8277,51 @@ var QueryTableSchema = {
|
|
|
8054
8277
|
openWorldHint: false
|
|
8055
8278
|
}
|
|
8056
8279
|
};
|
|
8280
|
+
var ListTagsSchema = {
|
|
8281
|
+
id: "list-memory-tags",
|
|
8282
|
+
upstreamName: "listTagsTool",
|
|
8283
|
+
description: "List the live canonical tag vocabulary, aliases, usage counts, and per-vault distribution. Use this before choosing tags so existing concepts are reused instead of fragmented.",
|
|
8284
|
+
input: {
|
|
8285
|
+
includeDeprecated: z3.boolean().optional()
|
|
8286
|
+
},
|
|
8287
|
+
output: {
|
|
8288
|
+
ok: z3.boolean(),
|
|
8289
|
+
tags: z3.array(z3.object({ tag: z3.string(), description: z3.string().nullable(), aliases: z3.array(z3.string()), status: z3.enum(["active", "deprecated"]), usageCount: z3.number(), vaultUsage: z3.record(z3.number()) })).optional(),
|
|
8290
|
+
error: z3.string().optional()
|
|
8291
|
+
},
|
|
8292
|
+
annotations: { title: "List Memory Tags", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
8293
|
+
};
|
|
8294
|
+
var ResolveTagsSchema = {
|
|
8295
|
+
id: "resolve-memory-tags",
|
|
8296
|
+
upstreamName: "resolveTagsTool",
|
|
8297
|
+
description: "Resolve proposed concepts against the live tag vocabulary. Returns reuse, create, or omit. A new tag is allowed only when no equivalent exists and the caller marks the concept central and reusable.",
|
|
8298
|
+
input: {
|
|
8299
|
+
candidates: z3.array(z3.object({ tag: z3.string().min(1), central: z3.boolean().optional(), reusable: z3.boolean().optional(), description: z3.string().optional() })).min(1).max(20)
|
|
8300
|
+
},
|
|
8301
|
+
output: {
|
|
8302
|
+
ok: z3.boolean(),
|
|
8303
|
+
resolutions: z3.array(z3.object({ candidate: z3.string(), normalized: z3.string(), action: z3.enum(["reuse", "create", "omit"]), tag: z3.string().optional(), matchedBy: z3.enum(["exact", "alias", "near"]).optional(), score: z3.number().optional(), reason: z3.string() })).optional(),
|
|
8304
|
+
error: z3.string().optional()
|
|
8305
|
+
},
|
|
8306
|
+
annotations: { title: "Resolve Memory Tags", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
8307
|
+
};
|
|
8308
|
+
var UpsertTagSchema = {
|
|
8309
|
+
id: "upsert-memory-tag",
|
|
8310
|
+
upstreamName: "upsertTagTool",
|
|
8311
|
+
description: "Define or curate one canonical tag, its meaning, aliases, and lifecycle. Use only after resolve-memory-tags returns create, or to merge/deprecate vocabulary intentionally. Requires write scope.",
|
|
8312
|
+
input: {
|
|
8313
|
+
tag: z3.string().min(1),
|
|
8314
|
+
description: z3.string().optional(),
|
|
8315
|
+
aliases: z3.array(z3.string()).optional(),
|
|
8316
|
+
status: z3.enum(["active", "deprecated"]).optional()
|
|
8317
|
+
},
|
|
8318
|
+
output: {
|
|
8319
|
+
ok: z3.boolean(),
|
|
8320
|
+
tag: z3.object({ tag: z3.string(), description: z3.string().nullable(), aliases: z3.array(z3.string()), status: z3.enum(["active", "deprecated"]) }).optional(),
|
|
8321
|
+
error: z3.string().optional()
|
|
8322
|
+
},
|
|
8323
|
+
annotations: { title: "Upsert Memory Tag", readOnlyHint: false, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
8324
|
+
};
|
|
8057
8325
|
var AddVaultSchema = {
|
|
8058
8326
|
id: "add-vault",
|
|
8059
8327
|
upstreamName: "addVaultTool",
|
|
@@ -8121,6 +8389,21 @@ var DeleteVaultSchema = {
|
|
|
8121
8389
|
openWorldHint: false
|
|
8122
8390
|
}
|
|
8123
8391
|
};
|
|
8392
|
+
var GetVaultContractSchema = {
|
|
8393
|
+
id: "get-vault-contract",
|
|
8394
|
+
upstreamName: "getVaultContractTool",
|
|
8395
|
+
description: "Read the machine-enforced purpose, template, statuses, types, natural neighbor vaults, and typed relationship guidance for one of the 13 governed Obsidian-style vaults. Call before composing a note when the correct shape is uncertain.",
|
|
8396
|
+
input: {
|
|
8397
|
+
vault: z3.string().describe("One governed vault: Ideas, Inspiration, Knowledge, Library, People, Communications, Calendar, Tasks, Projects, Issues, Improvement Log, Experiments, or Sprint.")
|
|
8398
|
+
},
|
|
8399
|
+
output: {
|
|
8400
|
+
ok: z3.boolean(),
|
|
8401
|
+
vault: z3.string().optional(),
|
|
8402
|
+
contract: z3.record(z3.unknown()).optional(),
|
|
8403
|
+
error: z3.string().optional()
|
|
8404
|
+
},
|
|
8405
|
+
annotations: { title: "Get Vault Contract", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
8406
|
+
};
|
|
8124
8407
|
var ListSharedWithMeSchema = {
|
|
8125
8408
|
id: "list-shared-with-me",
|
|
8126
8409
|
upstreamName: "listSharedWithMeTool",
|
|
@@ -8205,6 +8488,26 @@ var ProvisionDefaultsSchema = {
|
|
|
8205
8488
|
openWorldHint: false
|
|
8206
8489
|
}
|
|
8207
8490
|
};
|
|
8491
|
+
var RouteMemorySchema = {
|
|
8492
|
+
id: "route-memory",
|
|
8493
|
+
upstreamName: "routeMemoryTool",
|
|
8494
|
+
description: "Choose the correct governed vault and folder from content intent. Raw scraped/source material routes to Library; distilled applicable guidance routes to Knowledge. Returns the live vault contract so the result does not depend on prompt memory.",
|
|
8495
|
+
input: {
|
|
8496
|
+
title: z3.string().min(1),
|
|
8497
|
+
content: z3.string().min(1),
|
|
8498
|
+
type: z3.string().optional(),
|
|
8499
|
+
source: z3.string().optional()
|
|
8500
|
+
},
|
|
8501
|
+
output: {
|
|
8502
|
+
ok: z3.boolean(),
|
|
8503
|
+
vault: z3.string().optional(),
|
|
8504
|
+
folder: z3.string().optional(),
|
|
8505
|
+
reason: z3.string().optional(),
|
|
8506
|
+
contract: z3.record(z3.unknown()).optional(),
|
|
8507
|
+
error: z3.string().optional()
|
|
8508
|
+
},
|
|
8509
|
+
annotations: { title: "Route Memory", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false }
|
|
8510
|
+
};
|
|
8208
8511
|
var VideoAnalyzeStartSchema = {
|
|
8209
8512
|
id: "video-analyze-start",
|
|
8210
8513
|
upstreamName: "videoAnalyzeStartTool",
|
|
@@ -8327,7 +8630,10 @@ var MEMORY_TOOL_SCHEMAS = [
|
|
|
8327
8630
|
SwapVaultSchema,
|
|
8328
8631
|
SwitchAccountSchema,
|
|
8329
8632
|
UnlinkShareSchema,
|
|
8633
|
+
MemoryCaptureSchema,
|
|
8330
8634
|
MemoryQuestionsSchema,
|
|
8635
|
+
PrepareMemoryWriteSchema,
|
|
8636
|
+
ValidateMemoryWriteSchema,
|
|
8331
8637
|
CreateChannelSchema,
|
|
8332
8638
|
GetMessageNoteSchema,
|
|
8333
8639
|
ListChannelMembersSchema,
|
|
@@ -8340,6 +8646,9 @@ var MEMORY_TOOL_SCHEMAS = [
|
|
|
8340
8646
|
ReplyMessageSchema,
|
|
8341
8647
|
FactHistorySchema,
|
|
8342
8648
|
RecordFactSchema,
|
|
8649
|
+
NoteBacklinksSchema,
|
|
8650
|
+
GraphPathSchema,
|
|
8651
|
+
GraphUniverseSchema,
|
|
8343
8652
|
LibraryIngestSchema,
|
|
8344
8653
|
DeleteNoteSchema,
|
|
8345
8654
|
ExportSchema,
|
|
@@ -8369,12 +8678,17 @@ var MEMORY_TOOL_SCHEMAS = [
|
|
|
8369
8678
|
InsertTableRowsSchema,
|
|
8370
8679
|
ListTablesSchema,
|
|
8371
8680
|
QueryTableSchema,
|
|
8681
|
+
ListTagsSchema,
|
|
8682
|
+
ResolveTagsSchema,
|
|
8683
|
+
UpsertTagSchema,
|
|
8372
8684
|
AddVaultSchema,
|
|
8373
8685
|
CreateSecureVaultSchema,
|
|
8374
8686
|
DeleteVaultSchema,
|
|
8687
|
+
GetVaultContractSchema,
|
|
8375
8688
|
ListSharedWithMeSchema,
|
|
8376
8689
|
ListVaultsSchema,
|
|
8377
8690
|
ProvisionDefaultsSchema,
|
|
8691
|
+
RouteMemorySchema,
|
|
8378
8692
|
VideoAnalyzeStartSchema,
|
|
8379
8693
|
VideoAnalyzeStatusSchema,
|
|
8380
8694
|
CreateWebhookSchema,
|
|
@@ -8453,4 +8767,4 @@ export {
|
|
|
8453
8767
|
registerMemoryMcpTools,
|
|
8454
8768
|
MemoryMcpToolExecutor
|
|
8455
8769
|
};
|
|
8456
|
-
//# sourceMappingURL=chunk-
|
|
8770
|
+
//# sourceMappingURL=chunk-3K5GT6VG.js.map
|