@bendyline/docblocks-cli 2.2.1 → 2.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -0
- package/THIRD_PARTY_NOTICES.txt +16509 -0
- package/dist/bin.js +87 -50
- package/package.json +10 -9
package/dist/bin.js
CHANGED
|
@@ -4253,7 +4253,7 @@ function registerAgenticTools(server, context) {
|
|
|
4253
4253
|
server.registerTool(
|
|
4254
4254
|
"list_roots",
|
|
4255
4255
|
{
|
|
4256
|
-
description: "
|
|
4256
|
+
description: "Call first when durable local output is requested. Lists opaque startup-granted roots; if none is write-enabled, save_artifact cannot publish a file and the MCP server must be restarted with --allow-write.",
|
|
4257
4257
|
inputSchema: z.object({}).strict(),
|
|
4258
4258
|
outputSchema: DOCBLOCKS_MCP_TOOL_OUTPUT_SCHEMAS.list_roots,
|
|
4259
4259
|
annotations: READ_ONLY
|
|
@@ -4261,7 +4261,7 @@ function registerAgenticTools(server, context) {
|
|
|
4261
4261
|
async () => {
|
|
4262
4262
|
try {
|
|
4263
4263
|
const roots = (await context.authority).listRoots();
|
|
4264
|
-
return textAndStructured({ roots });
|
|
4264
|
+
return textAndStructured({ roots }, rootDiscoveryText(roots));
|
|
4265
4265
|
} catch (caught) {
|
|
4266
4266
|
return errorResult(caught, "resolve");
|
|
4267
4267
|
}
|
|
@@ -4338,7 +4338,7 @@ function registerAgenticTools(server, context) {
|
|
|
4338
4338
|
server.registerTool(
|
|
4339
4339
|
"create_document_bundle",
|
|
4340
4340
|
{
|
|
4341
|
-
description: "
|
|
4341
|
+
description: "Stage Markdown plus authority-scoped assets as a reusable immutable DBK artifact when the same complete draft will be passed to two or more validate, inspect, preview, or convert calls. Pass its artifact URI instead of repeating the Markdown.",
|
|
4342
4342
|
inputSchema: z.object({ source: bundleDocumentSourceSchema }).strict(),
|
|
4343
4343
|
outputSchema: DOCBLOCKS_MCP_TOOL_OUTPUT_SCHEMAS.create_document_bundle,
|
|
4344
4344
|
annotations: ARTIFACT_CREATING
|
|
@@ -4412,7 +4412,7 @@ function registerAgenticTools(server, context) {
|
|
|
4412
4412
|
server.registerTool(
|
|
4413
4413
|
"inspect_document",
|
|
4414
4414
|
{
|
|
4415
|
-
description: "Inspect
|
|
4415
|
+
description: "Inspect bounded semantic structure, block provenance, assets, metadata, theme, and diagnostics. Use for those details; do not pair it with validate_document for a routine export preflight.",
|
|
4416
4416
|
inputSchema: z.object({
|
|
4417
4417
|
source: documentSourceSchema,
|
|
4418
4418
|
maxBlocks: z.number().int().min(1).max(2e3).optional(),
|
|
@@ -4444,7 +4444,7 @@ function registerAgenticTools(server, context) {
|
|
|
4444
4444
|
server.registerTool(
|
|
4445
4445
|
"validate_document",
|
|
4446
4446
|
{
|
|
4447
|
-
description: "
|
|
4447
|
+
description: "Primary pre-export review for structure, template content retention, annotations, assets, accessibility, and target fidelity. Diagnostics include repairs; normally do not also call inspect_document.",
|
|
4448
4448
|
inputSchema: z.object({
|
|
4449
4449
|
source: documentSourceSchema,
|
|
4450
4450
|
targetFormat: formatInputSchema.nullable().optional()
|
|
@@ -4617,7 +4617,7 @@ function registerAuthoringGuideResource(server) {
|
|
|
4617
4617
|
"authoring-guide",
|
|
4618
4618
|
"docblocks://authoring-guide",
|
|
4619
4619
|
{
|
|
4620
|
-
description: "
|
|
4620
|
+
description: "Complete linked-Squisq authoring catalog with exact template inputs, fidelity modes, themes, and transform styles. Read only when the focused authoring context is insufficient.",
|
|
4621
4621
|
mimeType: "application/json",
|
|
4622
4622
|
annotations: { audience: ["assistant"], priority: 1 }
|
|
4623
4623
|
},
|
|
@@ -4628,15 +4628,15 @@ function registerAuthoringGuideResource(server) {
|
|
|
4628
4628
|
import("@bendyline/squisq/transform")
|
|
4629
4629
|
]);
|
|
4630
4630
|
const guide = {
|
|
4631
|
-
version:
|
|
4631
|
+
version: 7,
|
|
4632
4632
|
workflow: [
|
|
4633
4633
|
"treat supplied facts as a closed evidence set; label calculations, assumptions, hypotheses, recommendations, and examples; do not present causal links, rhetorical performance labels, superlatives, sole causes, targets, capabilities, owners, dates, channels, or operational details as established facts unless supplied",
|
|
4634
4634
|
"when the requested genre needs unsupplied roles, gates, timelines, channels, or procedures, add one explicit proposed operating model scope note that applies to those details, then complete the requested element",
|
|
4635
4635
|
"author complete Squisq-compatible Markdown with annotations bound to headings; ordinary headings default to the loss-averse content template",
|
|
4636
4636
|
"for PPTX, use exactly one level-one Markdown heading per slide and no level-two through level-six headings because every heading becomes a slide by default",
|
|
4637
4637
|
"by default, pass the complete Markdown\u2014or a bundle source when assets are needed\u2014directly to convert_document; revise by editing the complete Markdown and converting again",
|
|
4638
|
-
"use create_document_bundle
|
|
4639
|
-
"use
|
|
4638
|
+
"use create_document_bundle when the same complete draft will be passed to two or more validate, inspect, preview, or convert calls, then pass its artifact URI instead of repeating Markdown",
|
|
4639
|
+
"use validate_document as the routine export preflight; use inspect_document only for semantic structure, provenance, assets, metadata, or theme details; use preview_document only when visual evidence is useful",
|
|
4640
4640
|
"for visual polish, replace selected content blocks with compatible visual templates while preserving required content",
|
|
4641
4641
|
"convert_document creates one or more immutable artifacts from the authoritative complete source",
|
|
4642
4642
|
"save_artifact only when a durable file is required"
|
|
@@ -4680,7 +4680,7 @@ function registerTemplateTools(server, context) {
|
|
|
4680
4680
|
server.registerTool(
|
|
4681
4681
|
"get_authoring_context",
|
|
4682
4682
|
{
|
|
4683
|
-
description: "Get a
|
|
4683
|
+
description: "Get a focused authoring contract, target capability, safe default template, themes, transforms, and optional source-based recommendations. Exact full template inputs remain on demand through describe_template or docblocks://authoring-guide.",
|
|
4684
4684
|
inputSchema: z.object({
|
|
4685
4685
|
targetFormat: formatInputSchema.optional(),
|
|
4686
4686
|
goal: z.enum(["content-first", "visual-polish"]).optional(),
|
|
@@ -4709,7 +4709,7 @@ function registerTemplateTools(server, context) {
|
|
|
4709
4709
|
import("@bendyline/squisq/transform")
|
|
4710
4710
|
]);
|
|
4711
4711
|
const annotationHandling = normalizedTarget ? await targetTemplateAnnotationHandling(normalizedTarget) : null;
|
|
4712
|
-
const
|
|
4712
|
+
const candidateTemplates = annotationHandling === "ignored" ? fullTemplates.filter((template) => template.safeForContentFirst) : fullTemplates;
|
|
4713
4713
|
let recommendations = [];
|
|
4714
4714
|
let totalBlocks = null;
|
|
4715
4715
|
let truncated = false;
|
|
@@ -4729,7 +4729,7 @@ function registerTemplateTools(server, context) {
|
|
|
4729
4729
|
const profile = recommendModule.profileBlockContents(block.contents ?? []);
|
|
4730
4730
|
const visual = recommendModule.recommendTemplatesForBlock(
|
|
4731
4731
|
profile,
|
|
4732
|
-
|
|
4732
|
+
candidateTemplates.map((template) => template.id)
|
|
4733
4733
|
).recommended;
|
|
4734
4734
|
const recommendedTemplateIds = goal === "content-first" ? ["content", ...visual.filter((id) => id !== "content")] : visual;
|
|
4735
4735
|
return {
|
|
@@ -4753,29 +4753,23 @@ function registerTemplateTools(server, context) {
|
|
|
4753
4753
|
defaultTemplateId: "content",
|
|
4754
4754
|
defaultFidelity: authoringDefaultFidelity(normalizedTarget, goal),
|
|
4755
4755
|
workflow: [
|
|
4756
|
-
"
|
|
4757
|
-
"
|
|
4758
|
-
"Complete every requested element without presenting invented policy as established fact. When a requested policy, playbook, or training guide needs unsupplied roles, gates, timelines, channels, or procedures, add one explicit proposed operating model scope note placed before the first such detail so it governs all of them. Prefix each unsupplied operational rule with Proposed: on its slide or section.",
|
|
4759
|
-
"Generic option traits\u2014control, flexibility, vendor support, freed capacity, switching costs\u2014are capability claims: state one only when supplied or labeled Assumption or Judgment, even in table cells and tradeoffs.",
|
|
4760
|
-
"Author complete Squisq-compatible content with heading-bound annotations; ordinary headings default to the loss-averse content template.",
|
|
4756
|
+
"For durable local output, call list_roots before drafting. If no returned root is write-enabled, stop and explain that the MCP server must restart with --allow-write; do not fall back to a shell or CLI converter. A transient artifact is acceptable only when the user did not require a file.",
|
|
4757
|
+
"Treat supplied facts as a closed evidence set. Preserve them exactly; label calculations, assumptions, hypotheses, recommendations, causal claims, capabilities, owners, dates, and unsupplied operating details. When a requested policy or playbook needs invented procedures, introduce one proposed operating model scope note before those details.",
|
|
4761
4758
|
normalizedTarget === "pptx" ? "Match every explicitly requested slide count exactly. Use exactly one level-one Markdown heading (#) per slide and no level-two through level-six headings because every heading becomes a slide by default. Target at most 80 words per slide, and use lists, tables, or bold labels for within-slide structure." : "Honor the requested word range and document genre. Prefer connected memo prose for executive decisions and native headings, tables, and checklists for operational documents.",
|
|
4762
|
-
|
|
4763
|
-
"
|
|
4764
|
-
"
|
|
4765
|
-
"
|
|
4766
|
-
"
|
|
4767
|
-
"
|
|
4768
|
-
"Use preview_document when visual evidence is needed, inspect previewBasis, and repair overflow or layout problems in the authoritative Markdown.",
|
|
4769
|
-
normalizedTarget === "pptx" ? "For visual polish, replace selected content blocks with compatible recommended templates; use patterns such as definitionCard for a definition, dataTable for a true table, comparisonBar for supported numeric comparisons, and list for concise steps when the returned catalog supports them. Preserve all required content and preview again." : annotationHandling === "ignored" ? "This target flattens template annotations to semantic content, so visual templates have no effect on the exported file: rely on native headings, tables, and checklists for structure and scanning." : "For visual polish, use native headings, tables, and checklists where they improve scanning; keep complete-body content when a visual template would discard detail, then preview again.",
|
|
4770
|
-
"Convert to immutable artifacts, inspect conversion reports, and save only final durable outputs."
|
|
4759
|
+
"Author the complete Squisq-compatible Markdown with annotations bound to headings. Ordinary headings default to the loss-averse content template; keep that default until the complete content is sound.",
|
|
4760
|
+
"Before conversion, count slide sections or document words, verify every requested element, and rewrite or label unsupported claims. For decisions, ground tradeoffs in supplied alternatives and label unsupplied accountability, capacity, outcomes, and review cadences as proposed or assumed.",
|
|
4761
|
+
"Use validate_document as the routine export preflight and follow its repair diagnostics. Call inspect_document only when semantic structure, provenance, assets, metadata, or theme details are needed.",
|
|
4762
|
+
"When the same complete draft will feed two or more validate, inspect, preview, or convert calls, stage it once with create_document_bundle and reuse its artifact URI; after edits, stage the revised draft again.",
|
|
4763
|
+
normalizedTarget === "pptx" ? "For visual polish, call recommend_templates on the complete draft, then describe_template only for selected candidates before replacing content blocks. Preserve required content and use preview_document only when visual evidence is needed." : annotationHandling === "ignored" ? "This target flattens template annotations to semantic content, so visual templates have no effect on the exported file: rely on native headings, tables, and checklists for structure and scanning." : "For visual polish, use native headings, tables, and checklists where they improve scanning; describe a selected visual template before use and keep complete-body content when it would discard detail.",
|
|
4764
|
+
"Pass the authoritative Markdown or bundle source directly to convert_document. It returns immutable artifacts; call save_artifact only for final durable outputs and never switch to a shell or CLI converter."
|
|
4771
4765
|
],
|
|
4772
4766
|
syntax: {
|
|
4773
4767
|
headingAnnotation: "# Heading {[content]}",
|
|
4774
4768
|
standaloneAnnotation: "{[content]}",
|
|
4775
4769
|
standaloneWarning: "A standalone annotation creates an additional heading-less block. Bind it to a heading unless that extra block is deliberate."
|
|
4776
4770
|
},
|
|
4777
|
-
formats,
|
|
4778
|
-
templates,
|
|
4771
|
+
formats: normalizedTarget ? formats.filter((format) => format.id === normalizedTarget) : formats,
|
|
4772
|
+
templates: focusedAuthoringTemplates(candidateTemplates, recommendations),
|
|
4779
4773
|
themes: schemaModule.getThemeSummaries().slice(0, MCP_WIRE_LIMITS7.arrayEntries).map((theme) => ({
|
|
4780
4774
|
id: requireWireIdentifier(theme.id, "theme id"),
|
|
4781
4775
|
name: boundWireText(theme.name, MCP_WIRE_LIMITS7.labelCharacters, theme.id),
|
|
@@ -4790,7 +4784,19 @@ function registerTemplateTools(server, context) {
|
|
|
4790
4784
|
totalBlocks,
|
|
4791
4785
|
truncated
|
|
4792
4786
|
};
|
|
4793
|
-
return
|
|
4787
|
+
return {
|
|
4788
|
+
content: [
|
|
4789
|
+
{ type: "text", text: compactAuthoringContextText(payload) },
|
|
4790
|
+
{
|
|
4791
|
+
type: "resource_link",
|
|
4792
|
+
uri: "docblocks://authoring-guide",
|
|
4793
|
+
name: "authoring-guide",
|
|
4794
|
+
description: "Complete linked-Squisq authoring catalog; read only if needed.",
|
|
4795
|
+
mimeType: "application/json"
|
|
4796
|
+
}
|
|
4797
|
+
],
|
|
4798
|
+
structuredContent: asStructuredContent(successResult(payload))
|
|
4799
|
+
};
|
|
4794
4800
|
});
|
|
4795
4801
|
} catch (caught) {
|
|
4796
4802
|
return errorResult(caught, "inspect", null, extra.signal);
|
|
@@ -5206,6 +5212,25 @@ function textAndStructured(payload, text = JSON.stringify(payload, null, 2)) {
|
|
|
5206
5212
|
structuredContent: asStructuredContent(successResult(payload))
|
|
5207
5213
|
};
|
|
5208
5214
|
}
|
|
5215
|
+
function rootDiscoveryText(roots) {
|
|
5216
|
+
if (roots.length === 0) {
|
|
5217
|
+
return "No DocBlocks MCP roots are configured. Durable file output is unavailable: restart the server with --allow-write <directory>. Do not fall back to a shell or CLI converter; keep a transient artifact only when the user did not require a file.";
|
|
5218
|
+
}
|
|
5219
|
+
const catalog = JSON.stringify({ roots }, null, 2);
|
|
5220
|
+
if (roots.some((root) => root.write)) return catalog;
|
|
5221
|
+
return `${catalog}
|
|
5222
|
+
|
|
5223
|
+
No returned root is write-enabled. Durable file output is unavailable: restart the server with --allow-write <directory>. Do not fall back to a shell or CLI converter.`;
|
|
5224
|
+
}
|
|
5225
|
+
function focusedAuthoringTemplates(candidates, recommendations) {
|
|
5226
|
+
const selectedIds = /* @__PURE__ */ new Set(["content"]);
|
|
5227
|
+
for (const recommendation of recommendations) {
|
|
5228
|
+
for (const templateId of recommendation.recommendedTemplateIds) {
|
|
5229
|
+
selectedIds.add(templateId);
|
|
5230
|
+
}
|
|
5231
|
+
}
|
|
5232
|
+
return candidates.filter((template) => selectedIds.has(template.id));
|
|
5233
|
+
}
|
|
5209
5234
|
function compactAuthoringContextText(context) {
|
|
5210
5235
|
const target = context.targetFormat ?? "unspecified target";
|
|
5211
5236
|
const lines = [
|
|
@@ -5230,7 +5255,7 @@ function compactAuthoringContextText(context) {
|
|
|
5230
5255
|
}
|
|
5231
5256
|
lines.push(
|
|
5232
5257
|
"",
|
|
5233
|
-
"
|
|
5258
|
+
"This response is intentionally focused. Use recommend_templates on a complete draft, describe_template for exact selected inputs, or read docblocks://authoring-guide only when the full catalog is required."
|
|
5234
5259
|
);
|
|
5235
5260
|
return lines.join("\n");
|
|
5236
5261
|
}
|
|
@@ -5708,34 +5733,37 @@ function registerAuthoringPrompts(server) {
|
|
|
5708
5733
|
function presentationPrompt(topic, style, theme, template) {
|
|
5709
5734
|
return `Create a presentation about: ${topic}
|
|
5710
5735
|
|
|
5711
|
-
1.
|
|
5712
|
-
2.
|
|
5713
|
-
3.
|
|
5714
|
-
4.
|
|
5715
|
-
5.
|
|
5716
|
-
6.
|
|
5717
|
-
7.
|
|
5718
|
-
8.
|
|
5736
|
+
1. For durable output, call list_roots before drafting. If no returned root is write-enabled, stop and explain that the MCP server must restart with --allow-write; do not use a shell or CLI converter.
|
|
5737
|
+
2. Call get_authoring_context with targetFormat "pptx" and goal "content-first" for the focused linked-Squisq workflow and safe default. Read the full authoring-guide resource only if focused follow-up tools are insufficient.
|
|
5738
|
+
3. Treat the topic facts as a closed evidence set. Preserve them exactly, use temporal or correlational wording unless causality is supplied, and label calculations, assumptions, hypotheses, recommendations, and examples. Causal links, rhetorical performance labels, superlatives, sole causes, capabilities, owners, dates, channels, and operational details must be supplied or explicitly framed. Do not connect separate metrics, audiences, segments, or workflows unless the relationship is supplied. Prefer observed, coincided with, intended to, or proposed over drove, addresses, protects, or proves. Add decision value through supplied baselines, goals, targets, rankings, and transparent calculations. Do not call choices a sequence or capacity allocation unless order, timing, or resources were supplied. When the requested content needs unsupplied operating details, add one proposed operating model scope note that applies to them.
|
|
5739
|
+
4. Match every explicitly requested slide count exactly. Use exactly one level-one Markdown heading (\`#\`) per slide and no level-two through level-six headings because every heading becomes a slide by default; use lists, tables, or bold labels within a slide. Target at most 80 words per slide. Make slide one a supported point-of-view thesis, not a generic title or unsupported flourish. For requested choices, state concrete opportunity costs grounded in supplied alternatives and one clearly labeled proposed accountable role per choice. Label any unsupplied capacity or outcome assumption as \`Assumption:\` or \`Potential tradeoff:\`. Author complete Markdown sections with accessible alt text. Put annotations on headings, for example \`# Heading {[content]}\`; a standalone \`{[template]}\` creates an extra block. Prefer style "${style ?? "choose from the returned transform styles"}", theme "${theme ?? "choose from the returned themes"}", and template "${template ?? "content until visual optimization"}".
|
|
5740
|
+
5. Keep the complete Markdown as the authoritative draft. If it will feed two or more validate, inspect, preview, or convert calls, stage it once with create_document_bundle and reuse the artifact URI. Otherwise pass it\u2014or a bundle source when assets are needed\u2014directly to convert_document. Do not write a temporary local Markdown file or invent a root id.
|
|
5741
|
+
6. Before conversion, count slide sections, verify every requested element, and rewrite or label every unsupported claim. Use validate_document as the routine export preflight; use inspect_document only for semantic or metadata detail and preview_document only for visual evidence such as overflow. Repair findings in the complete Markdown.
|
|
5742
|
+
7. Only after content coverage is acceptable, call recommend_templates, describe only selected candidates, and replace compatible \`content\` blocks when their semantic inputs fit. Preserve required content.
|
|
5743
|
+
8. Call convert_document with the complete source and a pptx target. Choose editable-native for editable Office structures, rendered-fidelity for exact Squisq visuals, or hybrid for rendered visuals plus semantic retention. Revise by editing the complete Markdown and converting again.
|
|
5744
|
+
9. Use get_conversion_report for provenance and save_artifact only when a durable file is required.`;
|
|
5719
5745
|
}
|
|
5720
5746
|
function videoPrompt(topic, orientation, theme, template) {
|
|
5721
5747
|
return `Create a video about: ${topic}
|
|
5722
5748
|
|
|
5723
|
-
1.
|
|
5724
|
-
2.
|
|
5725
|
-
3.
|
|
5726
|
-
4.
|
|
5727
|
-
5.
|
|
5749
|
+
1. For durable output, call list_roots before drafting and stop if no root is write-enabled; do not use a shell or CLI converter.
|
|
5750
|
+
2. Call get_authoring_context with targetFormat "mp4" for the focused linked-Squisq workflow.
|
|
5751
|
+
3. Author concise Markdown for a ${orientation ?? "landscape"} animated sequence using theme "${theme ?? "choose from the returned themes"}" and template "${template ?? "content until visual optimization"}". Bind annotations to headings.
|
|
5752
|
+
4. Keep the complete Markdown as the authoritative draft and pass it\u2014or a bundle source when assets are needed\u2014directly to convert_document. Use validate_document for uncertain target constraints and preview_document when representative-frame evidence is useful; repair findings in the complete Markdown.
|
|
5753
|
+
5. Call convert_document with the complete source, an mp4 target, and orientation "${orientation ?? "landscape"}"; monitor progress and honor cancellation. Revise by editing the complete Markdown and converting again.
|
|
5754
|
+
6. Use get_conversion_report for provenance and save_artifact only when a durable file is required.`;
|
|
5728
5755
|
}
|
|
5729
5756
|
function documentPrompt(topic, format, theme, template) {
|
|
5730
5757
|
const target = format ?? "pdf";
|
|
5731
5758
|
return `Create a professional document about: ${topic}
|
|
5732
5759
|
|
|
5733
|
-
1.
|
|
5734
|
-
2.
|
|
5735
|
-
3.
|
|
5736
|
-
4.
|
|
5737
|
-
5.
|
|
5738
|
-
6.
|
|
5760
|
+
1. For durable output, call list_roots before drafting and stop if no root is write-enabled; do not use a shell or CLI converter.
|
|
5761
|
+
2. Call get_authoring_context with targetFormat "${target}" for the focused linked-Squisq workflow.
|
|
5762
|
+
3. Treat the topic facts as a closed evidence set. Preserve them exactly, use temporal or correlational wording unless causality is supplied, and label calculations, assumptions, hypotheses, recommendations, and examples. Causal links, superlatives, sole causes, capabilities, owners, dates, channels, and operational details must be supplied or explicitly framed. When the requested genre needs unsupplied roles, gates, timelines, channels, or procedures, add one proposed operating model scope note that applies to those details.
|
|
5763
|
+
4. Honor the requested word range and document genre. Author structured Markdown using theme "${theme ?? "choose from the returned themes"}" and template "${template ?? "content until visual optimization"}". Bind annotations to headings. Use connected memo prose for executive decisions and native headings, tables, and checklists for operational documents; retain complete-body content when a visual template would discard detail.
|
|
5764
|
+
5. Before conversion, count document words, verify every requested element, and rewrite or label every unsupported claim. If the complete draft will feed two or more review or conversion calls, stage it with create_document_bundle and reuse the artifact URI. Use validate_document as the routine export preflight and preview_document only when page-layout evidence is useful; repair findings in the complete Markdown.
|
|
5765
|
+
6. Call convert_document with the complete source and a ${target} target to create an immutable artifact. Revise by editing the complete Markdown and converting again.
|
|
5766
|
+
7. Use get_conversion_report for provenance and save_artifact only when a durable file is required.`;
|
|
5739
5767
|
}
|
|
5740
5768
|
function complete(values, prefix) {
|
|
5741
5769
|
const value = prefix ?? "";
|
|
@@ -5777,7 +5805,16 @@ function createMcpServer(options = {}) {
|
|
|
5777
5805
|
const server = new McpServer(
|
|
5778
5806
|
{ name: "docblocks", version: getPackageVersion() },
|
|
5779
5807
|
{
|
|
5780
|
-
instructions:
|
|
5808
|
+
instructions: [
|
|
5809
|
+
"For durable local output, call list_roots before drafting and use a returned write-enabled root id exactly as given. If none is writable, stop and explain that the server must restart with --allow-write; do not fall back to a shell or CLI converter.",
|
|
5810
|
+
"Call get_authoring_context once for the focused linked-Squisq contract. Read the full authoring-guide resource or call describe_template only when exact additional catalog detail is needed; do not also enumerate catalogs by default.",
|
|
5811
|
+
"Treat supplied facts as a closed evidence set: preserve them exactly, use temporal or correlational wording unless causality is supplied, and label calculations, assumptions, hypotheses, recommendations, capabilities, owners, dates, and unsupplied operating details. For a policy or playbook, introduce one proposed operating model scope note before invented procedures.",
|
|
5812
|
+
"Honor explicit slide/page counts and word ranges. For PPTX use one level-one heading per slide, no lower-level headings, and at most 80 words per slide. Ground decision tradeoffs in supplied alternatives and label unsupplied accountability, capacity, outcomes, or review cadences as proposed or assumed.",
|
|
5813
|
+
"Author complete Squisq-compatible Markdown with annotations on headings, for example `# Heading {[content]}`. Ordinary headings default to the loss-averse content template; standalone annotations create an extra heading-less block.",
|
|
5814
|
+
"Use validate_document as the routine export preflight and repair its diagnostics. Use inspect_document only for semantic structure, provenance, assets, metadata, or theme details, and preview_document only when visual evidence is useful.",
|
|
5815
|
+
"When the same complete draft will feed two or more validate, inspect, preview, or convert calls, stage it once with create_document_bundle and reuse its artifact URI instead of resending Markdown.",
|
|
5816
|
+
"Pass the complete Markdown or bundle source directly into convert_document. Save only the final durable artifact with save_artifact; never invent root ids or switch conversion to a shell or CLI."
|
|
5817
|
+
].join(" ")
|
|
5781
5818
|
}
|
|
5782
5819
|
);
|
|
5783
5820
|
registerAgenticTools(server, {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bendyline/docblocks-cli",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.2",
|
|
4
4
|
"description": "Build, preview, convert, render, inspect, and automate documents",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Bendyline",
|
|
@@ -39,24 +39,25 @@
|
|
|
39
39
|
"node": ">=22.14.0"
|
|
40
40
|
},
|
|
41
41
|
"files": [
|
|
42
|
-
"dist"
|
|
42
|
+
"dist",
|
|
43
|
+
"THIRD_PARTY_NOTICES.txt"
|
|
43
44
|
],
|
|
44
45
|
"scripts": {
|
|
45
46
|
"build": "tsup",
|
|
46
47
|
"typecheck": "tsc --noEmit"
|
|
47
48
|
},
|
|
48
49
|
"dependencies": {
|
|
49
|
-
"@bendyline/docblocks": "2.2.
|
|
50
|
-
"@bendyline/squisq": "2.
|
|
51
|
-
"@bendyline/squisq-cli": "2.
|
|
52
|
-
"@bendyline/squisq-formats": "2.3.
|
|
53
|
-
"@bendyline/squisq-react": "2.
|
|
54
|
-
"@bendyline/squisq-video": "2.2.
|
|
50
|
+
"@bendyline/docblocks": "2.2.2",
|
|
51
|
+
"@bendyline/squisq": "2.4.1",
|
|
52
|
+
"@bendyline/squisq-cli": "2.4.1",
|
|
53
|
+
"@bendyline/squisq-formats": "2.3.5",
|
|
54
|
+
"@bendyline/squisq-react": "2.4.1",
|
|
55
|
+
"@bendyline/squisq-video": "2.2.5",
|
|
55
56
|
"@modelcontextprotocol/sdk": "1.29.0",
|
|
56
57
|
"commander": "13.1.0",
|
|
57
58
|
"jszip": "3.10.1",
|
|
58
59
|
"pdf-lib": "1.17.1",
|
|
59
|
-
"playwright-core": "1.
|
|
60
|
+
"playwright-core": "1.61.1",
|
|
60
61
|
"zod": "3.25.76"
|
|
61
62
|
}
|
|
62
63
|
}
|