@subseam/mcp 0.4.0 → 0.4.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.
Files changed (2) hide show
  1. package/dist/main.js +13 -9
  2. package/package.json +1 -1
package/dist/main.js CHANGED
@@ -30591,13 +30591,12 @@ function renderDraft(d) {
30591
30591
  const partial2 = h !== null && h.complete === false ? ` so far (still running: ${h.of} of ${h.planned ?? "?"} trunk versions counted, through ${h.reached === void 0 ? "?" : at(h.reached)})` : "";
30592
30592
  const history = h === null ? "not computed yet" : h.last === null ? `never fired on ${h.of} trunk versions${since}${partial2}` : `would have fired at ${h.fired} of ${h.of} trunk versions${since}, last at ${at(h.last)}${partial2}`;
30593
30593
  const floor = h === null || h.uncomputedVersions === 0 ? [] : [` ${h.uncomputedVersions} of those versions could not be evaluated: the count is a floor there`];
30594
- const line = h === null ? [] : [" counted over the versions walked as trunk; git's first-parent count can differ"];
30595
30594
  const shown = d.atTip.failures.slice(0, FAILURES_SHOWN).map((f) => `${f.path}:${f.line} ${f.cause}`);
30596
30595
  const more = d.atTip.failures.length - shown.length;
30597
30596
  const tip = d.atTip.failures.length === 0 ? ` at tip ${d.atTip.sha.slice(0, 9)}: holds` : ` at tip ${d.atTip.sha.slice(0, 9)}: ${d.atTip.failures.length} failing: ` + shown.join("; ") + (more > 0 ? `; \u2026 and ${more} more` : "");
30598
30597
  const open7 = notComputedLines(d.atTip.uncomputed);
30599
30598
  if (typeof d.gated === "string") return [` ${d.statement}`, ` gated: ${d.gated} This definition is not evaluated.`, ` conflicts: ${d.conflicts}`].join("\n");
30600
- return [` ${d.statement}`, ...exampleLines(d.examples), ` history: ${history}`, ...floor, ...line, tip, ...open7, ` conflicts: ${d.conflicts}`].join("\n");
30599
+ return [` ${d.statement}`, ...exampleLines(d.examples), ` history: ${history}`, ...floor, tip, ...open7, ` conflicts: ${d.conflicts}`].join("\n");
30601
30600
  }
30602
30601
 
30603
30602
  // ../define/src/tool/define.ts
@@ -30700,10 +30699,11 @@ var input2 = external_exports.object({
30700
30699
  source: external_exports.record(external_exports.unknown()).optional(),
30701
30700
  nlIntent: external_exports.string().min(1).optional(),
30702
30701
  createdBy: external_exports.string().min(1).optional(),
30703
- // OPTIONAL IN THE SCHEMA, MANDATORY IN EFFECT (the shape `invoke-define-admit-route.ts` takes):
30704
- // the `source` arm's admission is `authored`, and Core refuses a blank basis with a typed
30702
+ // OPTIONAL IN THE SCHEMA, MANDATORY IN EFFECT ON `source` (the shape `invoke-define-admit-route.ts`
30703
+ // takes): the `source` arm's admission is `authored`, and Core refuses a blank basis with a typed
30705
30704
  // MISSING_BASIS carrying its repair hint. Declaring it required here would trade that named
30706
- // refusal for a Zod 400 with nothing to act on, and the `dry_run`/`mine` arms need none.
30705
+ // refusal for a Zod 400 with nothing to act on, and the `dry_run`/`mine` arms need none. The
30706
+ // `nlIntent` arm forwards it when given and otherwise cites its own sentence.
30707
30707
  basis: external_exports.string().min(1).optional(),
30708
30708
  dry_run: external_exports.boolean().optional(),
30709
30709
  mine: external_exports.object({
@@ -30715,7 +30715,7 @@ var input2 = external_exports.object({
30715
30715
  });
30716
30716
  var defineTool = {
30717
30717
  name: "define",
30718
- description: "Write a definition into this tenant's governing corpus. Pass exactly one of `source` (the SDL definition object \u2014 deterministic, no LLM) or `nlIntent` (a natural-language intent, authored through the CEGIS loop), plus `repo` (org-qualified) and optional `commit` (defaults to resolved tip). With `source`, pass `basis` too: free text citing what the definition stood on \u2014 the source doc plus its section (there is no fixed vocabulary). It is required in effect on this arm; an admission that cites nothing is refused. `nlIntent` supplies its own. `dry_run: true` with `source` validates against the live graph and admits NOTHING, returning per-gate errors with repair hints. `dry_run: true` with `source` and no `repo` answers only whether the language can say it (bind, capability and strength are deferred until a repo is named). `mine: {repo}` submits a whole-repo candidate mining pass instead (async \u2014 poll with `mine: {jobId}`). New versions land defaulted until approved. `gap: { construct, witness, issue }` records a construct the language cannot say yet (witness is the file:line that needed it) and admits nothing.",
30718
+ description: "Write a definition into this tenant's governing corpus. Pass exactly one of `source` (the SDL definition object \u2014 deterministic, no LLM) or `nlIntent` (a natural-language intent, authored through the CEGIS loop), plus `repo` (org-qualified) and optional `commit` (defaults to resolved tip). Pass `basis` on either arm: free text citing what the definition stood on \u2014 the source doc plus its section (there is no fixed vocabulary), or `capture-note:<id>` for a captured note, which also marks that note formalized. It is required in effect with `source`; an admission that cites nothing is refused. With `nlIntent` it defaults to the intent sentence. `dry_run: true` with `source` validates against the live graph and admits NOTHING, returning per-gate errors with repair hints. `dry_run: true` with `source` and no `repo` answers only whether the language can say it (bind, capability and strength are deferred until a repo is named). `mine: {repo}` submits a whole-repo candidate mining pass instead (async \u2014 poll with `mine: {jobId}`). New versions land defaulted until approved. `gap: { construct, witness, issue }` records a construct the language cannot say yet (witness is the file:line that needed it) and admits nothing.",
30719
30719
  capability: "define",
30720
30720
  inputSchema: input2.shape,
30721
30721
  async handler(raw, ctx) {
@@ -30764,7 +30764,8 @@ var defineTool = {
30764
30764
  repo: args2.repo,
30765
30765
  nlIntent: args2.nlIntent,
30766
30766
  ...args2.commit !== void 0 ? { commit: args2.commit } : {},
30767
- ...args2.createdBy !== void 0 ? { createdBy: args2.createdBy } : {}
30767
+ ...args2.createdBy !== void 0 ? { createdBy: args2.createdBy } : {},
30768
+ ...args2.basis !== void 0 ? { basis: args2.basis } : {}
30768
30769
  };
30769
30770
  const wire = await ctx.gateway.invoke("define-author", payload2);
30770
30771
  const body2 = readBody(authorBody, wire, "define", "define-author");
@@ -31592,6 +31593,7 @@ var defineInboxTool = {
31592
31593
  };
31593
31594
  var LABELS = {
31594
31595
  drift: "drift",
31596
+ draft: "draft",
31595
31597
  "refinement-pending": "refinement",
31596
31598
  "snooze-expired": "snooze expired",
31597
31599
  "snooze-expiring": "snooze due",
@@ -31607,6 +31609,8 @@ var HOW = {
31607
31609
  // parsing a number back out of a sentence to put it in a tool call is precisely the guessed
31608
31610
  // content the ruling forbids. So the call is named with the id it does hold and the remaining
31609
31611
  // arguments are stated as arguments the caller supplies.
31612
+ // A first draft is version 1, so the call is complete.
31613
+ draft: (item) => `define_ratify {kind:'ratify-version', definitionId:'${item.id}', version:1, status:'ratified'|'corrected'}`,
31610
31614
  "refinement-pending": (item) => `define_ratify {kind:'ratify-version', definitionId:'${item.id}', version:\u2026, status:'ratified'|'corrected'} \u2014 supply the version shown in this line`,
31611
31615
  // The read shows the alteration, verdict and definition; the adjudication follows it.
31612
31616
  proposal: (item) => `define_proposal_read {taskId:'${item.id}'}, then define_adjudicate {taskId:'${item.id}', decision:'accept'|'reject', reason:\u2026}`
@@ -31982,7 +31986,7 @@ function renderCapture(n) {
31982
31986
  const anchor = onPackage ? `attached to the package holding ${n.path}` : n.anchorKind === "concept" ? `concept ${n.conceptId}` : n.anchorKind === "path" ? `path ${n.path}` : n.anchorKind === "repo" ? `repo ${n.repoId}` : "unanchored";
31983
31987
  const chan = n.channel !== null ? ` [${n.channel}]` : "";
31984
31988
  return `capture: note ${n.id} stored (${anchor})${chan}.
31985
- To draft it as a definition, call \`define\` with this repo as \`repo\`, \`basis: "capture-note:${n.id}"\` and the definition as an SDL \`source\`.`;
31989
+ To draft it as a definition, call \`define\` with this repo as \`repo\`, \`basis: "capture-note:${n.id}"\`, and either \`nlIntent\` (the note in your words) or an SDL \`source\`.`;
31986
31990
  }
31987
31991
 
31988
31992
  // ../capture/src/tool/capture-list.ts
@@ -48307,7 +48311,7 @@ var workReadTools = createWorkReadToolProviders({ capability: "work" });
48307
48311
  var bundledProviders = [src_default2, src_default, tension_default, ...defineTools, ...decisionTools, ...captureTools, ...buildTools, secureTool, ...workTools, ...workReadTools];
48308
48312
 
48309
48313
  // package.json
48310
- var version2 = "0.4.0";
48314
+ var version2 = "0.4.2";
48311
48315
 
48312
48316
  // src/server.ts
48313
48317
  var SERVER_VERSION = version2;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@subseam/mcp",
3
- "version": "0.4.0",
3
+ "version": "0.4.2",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "bin": {