@pathmode/mcp-server 1.15.0 → 1.16.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/api-client.d.ts +8 -0
- package/dist/api-client.d.ts.map +1 -1
- package/dist/index.js +368 -39
- package/dist/intent-compiler.d.ts +53 -0
- package/dist/intent-compiler.d.ts.map +1 -1
- package/dist/local-reader.d.ts +0 -5
- package/dist/local-reader.d.ts.map +1 -1
- package/dist/readiness.d.ts +12 -4
- package/dist/readiness.d.ts.map +1 -1
- package/manifest.json +1 -1
- package/package.json +1 -1
package/dist/api-client.d.ts
CHANGED
|
@@ -47,6 +47,8 @@ export interface ApiIntent {
|
|
|
47
47
|
verification: Record<string, any>;
|
|
48
48
|
externalLinks: any[];
|
|
49
49
|
evidenceAnchors: Record<string, string[]>;
|
|
50
|
+
/** Readiness confirmations and waivers. Present since mcp-server 1.16.0 / the confirmations column. */
|
|
51
|
+
confirmations?: Record<string, unknown>[];
|
|
50
52
|
decisions?: IntentDecision[];
|
|
51
53
|
implementationContext?: {
|
|
52
54
|
relevantAreas: {
|
|
@@ -164,6 +166,12 @@ export interface UpdateIntentInput {
|
|
|
164
166
|
inScope?: string[];
|
|
165
167
|
outOfScope?: string[];
|
|
166
168
|
};
|
|
169
|
+
/**
|
|
170
|
+
* Readiness confirmations, sent WHOLE: the column is replace-all, so the caller must carry
|
|
171
|
+
* forward what it read. Never send one in the same call that edits the field it confirms; the
|
|
172
|
+
* API refuses that (M1), and refuses an anchor that does not match the stored text.
|
|
173
|
+
*/
|
|
174
|
+
confirmations?: Record<string, unknown>[];
|
|
167
175
|
}
|
|
168
176
|
export interface EvidenceQuery {
|
|
169
177
|
productId?: string;
|
package/dist/api-client.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/api-client.ts"],"names":[],"mappings":"AAAA;;;GAGG;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GAAE,aAAkB,GAAG,OAAO,CAAC;QAAE,QAAQ,EAAE,WAAW,EAAE,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;IAU/F,cAAc,CAAC,KAAK,EAAE,mBAAmB,GAAG,OAAO,CAAC,WAAW,CAAC;IAQhE,YAAY,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,WAAW,EAAE,MAAM,EAAE,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC;IAQ/I,oBAAoB,CACtB,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE;QAAE,OAAO,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,GACjE,OAAO,CAAC,qBAAqB,CAAC;CAQpC"}
|
package/dist/index.js
CHANGED
|
@@ -34140,6 +34140,9 @@ exports.formatIntentMd = formatIntentMd;
|
|
|
34140
34140
|
exports.formatCursorRules = formatCursorRules;
|
|
34141
34141
|
exports.formatClaudeMdSection = formatClaudeMdSection;
|
|
34142
34142
|
exports.formatOutcomeRubric = formatOutcomeRubric;
|
|
34143
|
+
exports.spliceConfirmationsSection = spliceConfirmationsSection;
|
|
34144
|
+
exports.renderConfirmationsSection = renderConfirmationsSection;
|
|
34145
|
+
exports.writeConfirmationRecord = writeConfirmationRecord;
|
|
34143
34146
|
// Verification check collection. Mirrors lib/verification in the main app — this package is
|
|
34144
34147
|
// standalone (own ncc build) and can't import it, so the type + adapter live here. `kind` is the
|
|
34145
34148
|
const crypto_1 = __nccwpck_require__(6982);
|
|
@@ -34895,6 +34898,87 @@ function formatOutcomeRubric(spec, opts = {}) {
|
|
|
34895
34898
|
doc.push('');
|
|
34896
34899
|
return doc.join('\n');
|
|
34897
34900
|
}
|
|
34901
|
+
/**
|
|
34902
|
+
* Splice a `## Confirmations` section into an existing intent.md WITHOUT regenerating the file.
|
|
34903
|
+
*
|
|
34904
|
+
* Regenerating through formatIntentMd is lossy by construction: LocalIntent is a projection, so
|
|
34905
|
+
* a round-trip drops unknown frontmatter keys, resets `version` and `status` to their defaults,
|
|
34906
|
+
* restamps `created`, and deletes any section the reader has no field for. Measured on a real
|
|
34907
|
+
* spec: status approved -> draft, version 7 -> 1, and `source`, `specVersion` and a `## Evidence`
|
|
34908
|
+
* section gone. A tool that records a judgment must not destroy the document it judges.
|
|
34909
|
+
*
|
|
34910
|
+
* So this is a text operation. It replaces an existing `## Confirmations` section in place, or
|
|
34911
|
+
* appends one at the end, and touches nothing else in the file.
|
|
34912
|
+
*/
|
|
34913
|
+
function spliceConfirmationsSection(original, section) {
|
|
34914
|
+
const lines = original.split('\n');
|
|
34915
|
+
const start = lines.findIndex(l => /^##\s+Confirmations\s*$/.test(l));
|
|
34916
|
+
if (start === -1) {
|
|
34917
|
+
const trimmed = original.replace(/\s*$/, '');
|
|
34918
|
+
return `${trimmed}\n\n${section.trim()}\n`;
|
|
34919
|
+
}
|
|
34920
|
+
// Run to the next `##`/`#` heading, so a later section survives untouched.
|
|
34921
|
+
let end = lines.length;
|
|
34922
|
+
for (let i = start + 1; i < lines.length; i++) {
|
|
34923
|
+
if (/^#{1,2}\s+/.test(lines[i])) {
|
|
34924
|
+
end = i;
|
|
34925
|
+
break;
|
|
34926
|
+
}
|
|
34927
|
+
}
|
|
34928
|
+
const before = lines.slice(0, start).join('\n').replace(/\s*$/, '');
|
|
34929
|
+
const after = lines.slice(end).join('\n').replace(/^\s*/, '');
|
|
34930
|
+
return `${before}\n\n${section.trim()}\n${after ? `\n${after}` : ''}`;
|
|
34931
|
+
}
|
|
34932
|
+
/** Render confirmation records as the `## Confirmations` section body. */
|
|
34933
|
+
function renderConfirmationsSection(records) {
|
|
34934
|
+
const emittable = records.filter((c) => {
|
|
34935
|
+
const dim = String(c.dimension ?? '').toLowerCase();
|
|
34936
|
+
const kind = String(c.kind ?? '').toLowerCase();
|
|
34937
|
+
const by = String(c.by ?? '').toLowerCase();
|
|
34938
|
+
return ['objective', 'outcomes'].includes(dim)
|
|
34939
|
+
&& ['confirmed', 'waived'].includes(kind)
|
|
34940
|
+
&& ['agent', 'human'].includes(by);
|
|
34941
|
+
});
|
|
34942
|
+
if (!emittable.length)
|
|
34943
|
+
return '';
|
|
34944
|
+
const out = ['## Confirmations'];
|
|
34945
|
+
for (const c of emittable) {
|
|
34946
|
+
out.push('');
|
|
34947
|
+
out.push(`**${String(c.dimension).toLowerCase()}** — ${String(c.kind).toLowerCase()} by ${String(c.by).toLowerCase()}`);
|
|
34948
|
+
for (const key of ['actor', 'problem', 'outcome', 'observable', 'reason', 'anchor', 'at']) {
|
|
34949
|
+
const v = c[key];
|
|
34950
|
+
if (typeof v !== 'string' || !v.trim())
|
|
34951
|
+
continue;
|
|
34952
|
+
out.push(`- ${key}: ${v.replace(/\s+/g, ' ').trim()}`);
|
|
34953
|
+
}
|
|
34954
|
+
}
|
|
34955
|
+
return out.join('\n');
|
|
34956
|
+
}
|
|
34957
|
+
function writeConfirmationRecord(opts) {
|
|
34958
|
+
let raw = opts.read();
|
|
34959
|
+
for (let attempt = 0; attempt < 2; attempt++) {
|
|
34960
|
+
if ((raw.match(/^##[ \t]+Confirmations[ \t]*$/gm) ?? []).length > 1) {
|
|
34961
|
+
return { ok: false, code: 'DUPLICATE_SECTION' };
|
|
34962
|
+
}
|
|
34963
|
+
if (opts.anchorOf(raw) !== opts.anchor) {
|
|
34964
|
+
return { ok: false, code: 'FIELD_CHANGED' };
|
|
34965
|
+
}
|
|
34966
|
+
// One live record per dimension: a re-confirmation replaces rather than accumulates.
|
|
34967
|
+
// Rebuilt from the SAME bytes being spliced. The defect was building this list from a
|
|
34968
|
+
// parse taken earlier and splicing it into freshly-read bytes, so a record written in
|
|
34969
|
+
// between was deleted by whoever wrote second.
|
|
34970
|
+
const kept = opts.confirmationsOf(raw).filter(c => c.dimension !== opts.dimension);
|
|
34971
|
+
const content = spliceConfirmationsSection(raw, renderConfirmationsSection([...kept, opts.record]));
|
|
34972
|
+
const fresh = opts.read();
|
|
34973
|
+
if (fresh !== raw) {
|
|
34974
|
+
raw = fresh;
|
|
34975
|
+
continue;
|
|
34976
|
+
}
|
|
34977
|
+
opts.write(content);
|
|
34978
|
+
return { ok: true, kept };
|
|
34979
|
+
}
|
|
34980
|
+
return { ok: false, code: 'FILE_CHANGED' };
|
|
34981
|
+
}
|
|
34898
34982
|
|
|
34899
34983
|
|
|
34900
34984
|
/***/ }),
|
|
@@ -35028,14 +35112,65 @@ function readIntentFile(filePath) {
|
|
|
35028
35112
|
* Exported so lib/intentMdParseParity.test.ts can hold the web paste-box parser
|
|
35029
35113
|
* (lib/intentMdParse.ts) to this implementation's behavior on gate-relevant fields.
|
|
35030
35114
|
*/
|
|
35115
|
+
/**
|
|
35116
|
+
* Sections win; frontmatter fills an absence. Mirrors lib/intentMdParse.preferSection.
|
|
35117
|
+
*
|
|
35118
|
+
* Local mode originally read only files that formatIntentMd wrote, which always carry body
|
|
35119
|
+
* sections, so the fallback never fired and was omitted. The preflight CLI broke that
|
|
35120
|
+
* assumption: it points this parser at hand-written files, including the frontmatter-only
|
|
35121
|
+
* shape the /intentspec starter and `pathmode validate` both bless. Without the fallback the
|
|
35122
|
+
* same CLI validated a spec's outcomes as schema-correct and then reported "nothing found"
|
|
35123
|
+
* for them, which is the false "you wrote nothing" this codebase has spent a research cycle
|
|
35124
|
+
* stamping out.
|
|
35125
|
+
*/
|
|
35126
|
+
function preferSection(fromSection, fromFrontmatter) {
|
|
35127
|
+
if (fromSection.length > 0)
|
|
35128
|
+
return fromSection;
|
|
35129
|
+
if (!Array.isArray(fromFrontmatter))
|
|
35130
|
+
return [];
|
|
35131
|
+
return fromFrontmatter
|
|
35132
|
+
.map((v) => (typeof v === 'string' ? v : coerceItemText(v)))
|
|
35133
|
+
.map((v) => v.trim())
|
|
35134
|
+
.filter(Boolean);
|
|
35135
|
+
}
|
|
35136
|
+
/** Coerce a structured frontmatter entry ({text}, {description}) to its text, else ''. */
|
|
35137
|
+
function coerceItemText(v) {
|
|
35138
|
+
if (!v || typeof v !== 'object')
|
|
35139
|
+
return '';
|
|
35140
|
+
const o = v;
|
|
35141
|
+
for (const key of ['text', 'description', 'title']) {
|
|
35142
|
+
if (typeof o[key] === 'string')
|
|
35143
|
+
return o[key];
|
|
35144
|
+
}
|
|
35145
|
+
return '';
|
|
35146
|
+
}
|
|
35147
|
+
/** Frontmatter edge cases in the schema's {scenario, expectedBehavior} shape. */
|
|
35148
|
+
function frontmatterEdgeCases(v) {
|
|
35149
|
+
if (!Array.isArray(v))
|
|
35150
|
+
return [];
|
|
35151
|
+
return v
|
|
35152
|
+
.map((e) => {
|
|
35153
|
+
const o = (e ?? {});
|
|
35154
|
+
return {
|
|
35155
|
+
scenario: typeof o.scenario === 'string' ? o.scenario.trim() : '',
|
|
35156
|
+
expectedBehavior: typeof o.expectedBehavior === 'string' ? o.expectedBehavior.trim()
|
|
35157
|
+
: typeof o.expected_behavior === 'string' ? o.expected_behavior.trim() : '',
|
|
35158
|
+
};
|
|
35159
|
+
})
|
|
35160
|
+
.filter((e) => e.scenario || e.expectedBehavior);
|
|
35161
|
+
}
|
|
35031
35162
|
function parseIntentMarkdown(content, fallbackId = 'intent') {
|
|
35032
35163
|
const { data, content: rawBody } = (0, gray_matter_1.default)(content);
|
|
35033
35164
|
const body = stripFencedBlocks(rawBody);
|
|
35034
35165
|
const sections = splitSections(body);
|
|
35035
35166
|
const parsedVerification = extractVerification(sections);
|
|
35036
|
-
|
|
35037
|
-
|
|
35038
|
-
|
|
35167
|
+
// The public schema allows verification as a flat string array; read it as manual checks
|
|
35168
|
+
// rather than silently producing {} (the same adapter normalizeSpecForReadiness applies).
|
|
35169
|
+
const frontmatterVerification = Array.isArray(data.verification)
|
|
35170
|
+
? { manualChecks: data.verification.map(v => typeof v === 'string' ? v : coerceItemText(v)).filter(Boolean) }
|
|
35171
|
+
: data.verification && typeof data.verification === 'object'
|
|
35172
|
+
? data.verification
|
|
35173
|
+
: null;
|
|
35039
35174
|
const verification = hasVerificationContent(parsedVerification)
|
|
35040
35175
|
? parsedVerification
|
|
35041
35176
|
: (frontmatterVerification || {});
|
|
@@ -35050,11 +35185,11 @@ function parseIntentMarkdown(content, fallbackId = 'intent') {
|
|
|
35050
35185
|
title: data.title || data.userGoal || extractTitle(body) || 'Untitled Intent',
|
|
35051
35186
|
stageName: data.stage || undefined,
|
|
35052
35187
|
severity: data.severity || undefined,
|
|
35053
|
-
outcomes: extractListSection(sections, 'Outcomes'),
|
|
35188
|
+
outcomes: preferSection(extractListSection(sections, 'Outcomes'), data.outcomes),
|
|
35054
35189
|
decisions: extractDecisions(sections),
|
|
35055
|
-
constraints: extractListSection(sections, 'Constraints'),
|
|
35056
|
-
edgeCases: extractEdgeCases(sections),
|
|
35057
|
-
healthMetrics: extractListSection(sections, 'Health Metrics'),
|
|
35190
|
+
constraints: preferSection(extractListSection(sections, 'Constraints'), data.constraints),
|
|
35191
|
+
edgeCases: (() => { const fromBody = extractEdgeCases(sections); return fromBody.length ? fromBody : frontmatterEdgeCases(data.edgeCases); })(),
|
|
35192
|
+
healthMetrics: preferSection(extractListSection(sections, 'Health Metrics'), data.healthMetrics),
|
|
35058
35193
|
scope: extractScope(sections) || undefined,
|
|
35059
35194
|
verification,
|
|
35060
35195
|
confirmations: extractConfirmations(sections),
|
|
@@ -35741,20 +35876,38 @@ exports.READINESS_BLOCKER_DESCRIPTIONS = {
|
|
|
35741
35876
|
};
|
|
35742
35877
|
/** Display order for the gate strip (title first, matching the Preflight page). */
|
|
35743
35878
|
// ── Confirmation anchoring ──────────────────────────────────────────────────
|
|
35879
|
+
/**
|
|
35880
|
+
* Remove PAIRED markdown emphasis markers and nothing else.
|
|
35881
|
+
*
|
|
35882
|
+
* The earlier version replaced every asterisk in the text with nothing. That
|
|
35883
|
+
* was wrong in both directions at once: dropping a literal wildcard (`search * patterns` ->
|
|
35884
|
+
* `search patterns`) is a substantive edit that kept its confirmation live, while `_italic_` was
|
|
35885
|
+
* left alone so a formatting-only edit invalidated one. Emphasis needs an opening marker followed
|
|
35886
|
+
* by non-space and a matching closer, so a lone `*` or `_` survives. Looped because markers nest.
|
|
35887
|
+
*/
|
|
35888
|
+
function stripEmphasis(text) {
|
|
35889
|
+
let prev;
|
|
35890
|
+
let out = text;
|
|
35891
|
+
do {
|
|
35892
|
+
prev = out;
|
|
35893
|
+
out = out.replace(/(\*\*|__|\*|_)(?=\S)([\s\S]*?\S)\1/g, '$2');
|
|
35894
|
+
} while (out !== prev);
|
|
35895
|
+
return out;
|
|
35896
|
+
}
|
|
35744
35897
|
/**
|
|
35745
35898
|
* Fold away everything that is a rewrite of the same claim, and nothing that is a change to it.
|
|
35746
35899
|
* NFC because one glyph has two encodings; soft hyphens because editors inject them invisibly;
|
|
35747
|
-
* quote/dash folding and markdown emphasis because adding `**` around a word is
|
|
35748
|
-
* a reword.
|
|
35900
|
+
* quote/dash folding and PAIRED markdown emphasis because adding `**` around a word is
|
|
35901
|
+
* formatting, not a reword. An unpaired `*` or `_` is left alone: it is content (a wildcard),
|
|
35902
|
+
* and deleting it silently kept confirmations alive across a real change to the claim. Lowercased and whitespace-collapsed last.
|
|
35749
35903
|
*/
|
|
35750
35904
|
function normalizeAnchor(value) {
|
|
35751
|
-
return coerceText(value)
|
|
35905
|
+
return stripEmphasis(coerceText(value))
|
|
35752
35906
|
.normalize('NFC')
|
|
35753
35907
|
.replace(//g, '')
|
|
35754
35908
|
.replace(/[‘’ʼ]/g, "'")
|
|
35755
35909
|
.replace(/[“”]/g, '"')
|
|
35756
35910
|
.replace(/[–—]/g, '-')
|
|
35757
|
-
.replace(/\*/g, '')
|
|
35758
35911
|
.replace(/\s+/g, ' ')
|
|
35759
35912
|
.trim()
|
|
35760
35913
|
.toLowerCase();
|
|
@@ -35843,8 +35996,16 @@ function applyConfirmations(detail, digests, raw) {
|
|
|
35843
35996
|
rejected.push({ code: 'stale', dimension: dim });
|
|
35844
35997
|
continue;
|
|
35845
35998
|
}
|
|
35846
|
-
if (d && d.state !== 'pass')
|
|
35999
|
+
if (d && d.state !== 'pass') {
|
|
35847
36000
|
d.state = kind === 'waived' ? 'not_applicable' : 'pass';
|
|
36001
|
+
d.confirmedBy = by === 'human' ? 'human' : 'agent';
|
|
36002
|
+
// Assurance is never taken from the record: a file cannot vouch for itself. Anything
|
|
36003
|
+
// arriving without an authenticated boundary is local-unverified, and renders that way.
|
|
36004
|
+
d.assurance = coerceText(c.assurance).trim() === 'authenticated'
|
|
36005
|
+
? 'authenticated' : 'local-unverified';
|
|
36006
|
+
if (kind === 'waived')
|
|
36007
|
+
d.reason = coerceText(c.reason).trim();
|
|
36008
|
+
}
|
|
35848
36009
|
}
|
|
35849
36010
|
return rejected;
|
|
35850
36011
|
}
|
|
@@ -35954,11 +36115,19 @@ const FRONTMATTER_GATE_LABELS = {
|
|
|
35954
36115
|
*/
|
|
35955
36116
|
function formatReadinessFrontmatter(verdict) {
|
|
35956
36117
|
const total = exports.READINESS_GATE_ORDER.length;
|
|
35957
|
-
|
|
35958
|
-
|
|
35959
|
-
|
|
35960
|
-
const
|
|
35961
|
-
|
|
36118
|
+
// A confirmed dimension counts as passed; a WAIVED one never does (contract amendment D:
|
|
36119
|
+
// "passed 6/6 (1 waived)" launders an exception into the score). Waivers are counted
|
|
36120
|
+
// separately and named, and a spec with both product dimensions waived is not scored at all.
|
|
36121
|
+
const passed = exports.READINESS_GATE_ORDER.filter((k) => verdict.detail?.[k]?.state === 'pass' || verdict.signals[k]).length;
|
|
36122
|
+
const waived = exports.READINESS_GATE_ORDER.filter((k) => verdict.detail?.[k]?.state === 'not_applicable');
|
|
36123
|
+
const blocking = exports.READINESS_GATE_ORDER.filter((k) => !verdict.signals[k] && verdict.detail?.[k]?.state !== 'pass' && verdict.detail?.[k]?.state !== 'not_applicable').map((k) => FRONTMATTER_GATE_LABELS[k]);
|
|
36124
|
+
if (blocking.length)
|
|
36125
|
+
return `failed ${passed}/${total} — blocking: ${blocking.join(', ')}`;
|
|
36126
|
+
if (waived.length === 2)
|
|
36127
|
+
return 'product intent preflight not applicable to this change';
|
|
36128
|
+
if (waived.length)
|
|
36129
|
+
return `ready with exceptions: ${passed} passed, ${waived.length} waived (${waived.map(k => FRONTMATTER_GATE_LABELS[k]).join(', ')})`;
|
|
36130
|
+
return `passed ${passed}/${total}`;
|
|
35962
36131
|
}
|
|
35963
36132
|
/**
|
|
35964
36133
|
* The extra line an `unconfirmed` dimension earns: what was read, and an honest statement of
|
|
@@ -35979,21 +36148,50 @@ function truncateForQuote(text, max = 160) {
|
|
|
35979
36148
|
return flat.length <= max ? flat : `${flat.slice(0, max - 1)}…`;
|
|
35980
36149
|
}
|
|
35981
36150
|
/** Human/agent-readable verdict block, stable enough to parse by line prefix. */
|
|
35982
|
-
function formatReadinessVerdict(verdict, specTitle
|
|
36151
|
+
function formatReadinessVerdict(verdict, specTitle,
|
|
36152
|
+
/** Override the closing repair line. The default names MCP tools, which are wrong in a CLI
|
|
36153
|
+
* reading a repo that has never installed Pathmode. */
|
|
36154
|
+
repairHint) {
|
|
35983
36155
|
const lines = [];
|
|
35984
36156
|
const name = (specTitle || '').trim();
|
|
35985
|
-
|
|
35986
|
-
|
|
36157
|
+
// The RESOLVED state is what a reader acts on: `ready`/`signals` stay the pure lexical
|
|
36158
|
+
// verdict underneath, so what a spec earned stays distinguishable from what was vouched for,
|
|
36159
|
+
// but a confirmed dimension must stop being reported as a blocker or the whole confirmation
|
|
36160
|
+
// loop is invisible.
|
|
36161
|
+
const resolved = (k) => verdict.detail?.[k]?.state ?? (verdict.signals[k] ? 'pass' : 'absent');
|
|
36162
|
+
const stillBlocking = BLOCKER_ORDER.filter(k => !verdict.signals[k] && resolved(k) !== 'pass' && resolved(k) !== 'not_applicable');
|
|
36163
|
+
const waivedKeys = BLOCKER_ORDER.filter(k => resolved(k) === 'not_applicable');
|
|
36164
|
+
const vouched = BLOCKER_ORDER.filter(k => !verdict.signals[k] && resolved(k) === 'pass');
|
|
36165
|
+
if (!stillBlocking.length) {
|
|
36166
|
+
if (waivedKeys.length === 2) {
|
|
36167
|
+
lines.push(`– Product intent preflight not applicable to this change${name ? ` ("${name}")` : ''}.`);
|
|
36168
|
+
}
|
|
36169
|
+
else if (waivedKeys.length) {
|
|
36170
|
+
lines.push(`✓ Ready with exceptions${name ? ` for "${name}"` : ''}. ${6 - waivedKeys.length} passed, ${waivedKeys.length} waived.`);
|
|
36171
|
+
}
|
|
36172
|
+
else {
|
|
36173
|
+
lines.push(`✓ Preflight passed${name ? ` for "${name}"` : ''}. 6/6 checks. Ready to hand to an agent.`);
|
|
36174
|
+
}
|
|
36175
|
+
for (const k of vouched) {
|
|
36176
|
+
const d = verdict.detail?.[k];
|
|
36177
|
+
const who = d?.confirmedBy ?? 'agent';
|
|
36178
|
+
lines.push(` ✓ ${GATE_LABELS[k]} confirmed by ${who}${who === 'human' && d?.assurance !== 'authenticated' ? ' (unverified)' : ''}, not by the check`);
|
|
36179
|
+
}
|
|
36180
|
+
for (const k of waivedKeys) {
|
|
36181
|
+
const d = verdict.detail?.[k];
|
|
36182
|
+
const who = d?.confirmedBy ?? 'human';
|
|
36183
|
+
lines.push(` – ${GATE_LABELS[k]} waived by ${who}${who === 'human' && d?.assurance !== 'authenticated' ? ' (unverified)' : ''}: ${d?.reason || 'no reason recorded'}`);
|
|
36184
|
+
}
|
|
35987
36185
|
}
|
|
35988
36186
|
else {
|
|
35989
|
-
lines.push(`✗ Preflight failed${name ? ` for "${name}"` : ''}. ${
|
|
36187
|
+
lines.push(`✗ Preflight failed${name ? ` for "${name}"` : ''}. ${stillBlocking.length}/6 checks blocking.`);
|
|
35990
36188
|
// Blocker lines stay byte-identical and in order; an unconfirmed dimension gets an
|
|
35991
36189
|
// extra indented line quoting what was actually read. Without it the verdict says
|
|
35992
36190
|
// "name the actor" to an author who named one in words this vocabulary misses, which
|
|
35993
36191
|
// an audit of 80 real specs measured as the majority of these failures
|
|
35994
36192
|
// (docs/research/openspec-corpus-audit.md).
|
|
35995
36193
|
for (const key of BLOCKER_ORDER) {
|
|
35996
|
-
if (verdict.signals[key])
|
|
36194
|
+
if (verdict.signals[key] || resolved(key) === 'pass' || resolved(key) === 'not_applicable')
|
|
35997
36195
|
continue;
|
|
35998
36196
|
lines.push(` ✗ ${exports.READINESS_BLOCKER_DESCRIPTIONS[key]}`);
|
|
35999
36197
|
const d = verdict.detail?.[key];
|
|
@@ -36004,10 +36202,13 @@ function formatReadinessVerdict(verdict, specTitle) {
|
|
|
36004
36202
|
}
|
|
36005
36203
|
}
|
|
36006
36204
|
lines.push('');
|
|
36007
|
-
lines.push(exports.READINESS_GATE_ORDER.map(k =>
|
|
36008
|
-
|
|
36205
|
+
lines.push(exports.READINESS_GATE_ORDER.map(k => {
|
|
36206
|
+
const st = resolved(k);
|
|
36207
|
+
return `${st === 'pass' ? '✓' : st === 'not_applicable' ? '–' : st === 'unconfirmed' ? '?' : '·'} ${GATE_LABELS[k]}`;
|
|
36208
|
+
}).join(' '));
|
|
36209
|
+
if (stillBlocking.length) {
|
|
36009
36210
|
lines.push('');
|
|
36010
|
-
lines.push('Repair the failing fields (ask the user one targeted question per blocker), save with intent_save, and re-run check_intent_readiness. The verdict is deterministic: the same spec always gets the same result.');
|
|
36211
|
+
lines.push(repairHint ?? 'Repair the failing fields (ask the user one targeted question per blocker), save with intent_save, and re-run check_intent_readiness. The verdict is deterministic: the same spec always gets the same result.');
|
|
36011
36212
|
}
|
|
36012
36213
|
return lines.join('\n');
|
|
36013
36214
|
}
|
|
@@ -65941,7 +66142,7 @@ module.exports = /*#__PURE__*/JSON.parse('{"$schema":"http://json-schema.org/dra
|
|
|
65941
66142
|
/***/ ((module) => {
|
|
65942
66143
|
|
|
65943
66144
|
"use strict";
|
|
65944
|
-
module.exports = /*#__PURE__*/JSON.parse('{"name":"@pathmode/mcp-server","version":"1.
|
|
66145
|
+
module.exports = /*#__PURE__*/JSON.parse('{"name":"@pathmode/mcp-server","version":"1.16.0","publishConfig":{"access":"public"},"mcpName":"io.github.pathmodeio/mcp-server","description":"Deterministic intent preflight before your agent builds: six calibrated gates, keyless, no model call. Draft and sharpen specs in conversation, or connect a Pathmode workspace to sync intent and evidence across a team.","main":"dist/index.js","bin":{"pathmode-mcp":"dist/index.js"},"files":["dist/","manifest.json","icon.svg","README.md","skills/"],"scripts":{"build":"rm -rf dist && ncc build src/index.ts -o dist","dev":"ts-node src/index.ts","prepublishOnly":"npm run build"},"keywords":["pathmode","mcp","model-context-protocol","claude-code","claude-code-skills","agent-skills","cursor","windsurf","intent-engineering","intent-compiler","ai-agents","product-development","dependency-graph","strategic-planning"],"author":"Pathmode","license":"MIT","type":"commonjs","engines":{"node":">=18.0.0"},"homepage":"https://pathmode.io","dependencies":{"@modelcontextprotocol/sdk":"^1.12.1","gray-matter":"^4.0.3","zod":"^3.24.0"},"devDependencies":{"@types/node":"^25.1.0","@vercel/ncc":"^0.38.4","ts-node":"^10.9.2","typescript":"^5.9.3"}}');
|
|
65945
66146
|
|
|
65946
66147
|
/***/ })
|
|
65947
66148
|
|
|
@@ -67359,12 +67560,23 @@ function startMcpServer() {
|
|
|
67359
67560
|
let sourceUrl;
|
|
67360
67561
|
let didNotTravel = [];
|
|
67361
67562
|
const writeSpecFile = (opts) => {
|
|
67362
|
-
|
|
67563
|
+
let content = (0, intent_compiler_1.formatIntentMd)({ ...fields, id: opts.canonicalId }, {
|
|
67363
67564
|
version, status, created,
|
|
67364
67565
|
readiness: (0, readiness_1.formatReadinessFrontmatter)(verdict),
|
|
67365
67566
|
specVersion: opts.specVersion,
|
|
67366
67567
|
source: opts.sourceUrl,
|
|
67367
67568
|
});
|
|
67569
|
+
// Carry existing confirmations across the rewrite. intent_save builds its content from
|
|
67570
|
+
// the incoming spec, which by design has no `confirmations` field (that absence is what
|
|
67571
|
+
// enforces M1: a confirmation cannot be minted in the write that authored the field).
|
|
67572
|
+
// Without this the very next save silently deletes every confirmation the file holds,
|
|
67573
|
+
// and the anchors would have caught nothing because the records would be gone.
|
|
67574
|
+
// Confirmations are re-validated on read, so a save that changed the field text simply
|
|
67575
|
+
// leaves them stale rather than wrongly live.
|
|
67576
|
+
const prior = (0, fs_1.existsSync)(filePath) ? (0, local_reader_1.readIntentFile)(filePath)?.confirmations ?? [] : [];
|
|
67577
|
+
if (prior.length) {
|
|
67578
|
+
content = (0, intent_compiler_1.spliceConfirmationsSection)(content, (0, intent_compiler_1.renderConfirmationsSection)(prior));
|
|
67579
|
+
}
|
|
67368
67580
|
(0, fs_1.writeFileSync)(filePath, content, 'utf-8');
|
|
67369
67581
|
};
|
|
67370
67582
|
if (isLocalMode) {
|
|
@@ -67457,9 +67669,9 @@ function startMcpServer() {
|
|
|
67457
67669
|
*/
|
|
67458
67670
|
server.registerTool('confirm_intent_dimension', {
|
|
67459
67671
|
title: 'Confirm or waive a readiness dimension',
|
|
67460
|
-
description: 'Resolve an "unconfirmed" readiness dimension in a local intent.md. Use this when check_intent_readiness reports that it READ your objective or outcomes but could not confirm them: the gate matches a fixed English vocabulary and misses valid phrasing, including other languages. ' +
|
|
67672
|
+
description: 'Resolve an "unconfirmed" readiness dimension, in a local intent.md or in a connected workspace. Use this when check_intent_readiness reports that it READ your objective or outcomes but could not confirm them: the gate matches a fixed English vocabulary and misses valid phrasing, including other languages. ' +
|
|
67461
67673
|
'confirm: state who is affected and what goes wrong for them, in your own words, and the dimension passes. ' +
|
|
67462
|
-
'waive: mark the dimension as not applicable to this change (a pure refactor has no product outcome). A waiver is a HUMAN decision, so set humanApproved only after the user has explicitly agreed. ' +
|
|
67674
|
+
'waive: mark the dimension as not applicable to this change (a pure refactor has no product outcome). A waiver is a HUMAN decision, so set humanApproved only after the user has explicitly agreed. Waivers are local-mode only: a workspace will not accept one over an API key, which authenticates as a machine. ' +
|
|
67463
67675
|
'The confirmation is bound to the exact text it was made against and dies automatically if that text is edited. You cannot confirm a dimension the gate read nothing for; write the field first, save, then confirm.',
|
|
67464
67676
|
inputSchema: {
|
|
67465
67677
|
dimension: zod_1.z.enum(['objective', 'outcomes']).describe('Only these two are confirmable. Title and verification are never waivable.'),
|
|
@@ -67470,13 +67682,61 @@ function startMcpServer() {
|
|
|
67470
67682
|
observable: zod_1.z.string().optional().describe('confirm + outcomes: how you would see it.'),
|
|
67471
67683
|
reason: zod_1.z.string().optional().describe('waive: why this dimension does not apply.'),
|
|
67472
67684
|
humanApproved: zod_1.z.boolean().optional().describe('waive only. Set ONLY after the user has explicitly approved the waiver. Recorded as a human decision that this environment cannot verify.'),
|
|
67473
|
-
path: zod_1.z.string().optional().describe('
|
|
67685
|
+
path: zod_1.z.string().optional().describe('Local mode only: path to the intent file. Defaults to intent.md.'),
|
|
67686
|
+
intentId: zod_1.z.string().optional().describe('Cloud mode: confirm on a specific saved intent. Defaults to the current intent.'),
|
|
67474
67687
|
},
|
|
67475
|
-
}, async ({ dimension, action, actor, problem, outcome, observable, reason, humanApproved, path }) => {
|
|
67688
|
+
}, async ({ dimension, action, actor, problem, outcome, observable, reason, humanApproved, path, intentId }) => {
|
|
67689
|
+
/**
|
|
67690
|
+
* Local and cloud differ ONLY in where the spec is read from and where the record is
|
|
67691
|
+
* written. Everything between — which states are confirmable, what a record must name,
|
|
67692
|
+
* how it is anchored — is computed once, so the two modes cannot drift into disagreeing
|
|
67693
|
+
* about what a confirmation means.
|
|
67694
|
+
*/
|
|
67476
67695
|
const filePath = resolveWithinProject(path || 'intent.md');
|
|
67477
|
-
|
|
67478
|
-
|
|
67479
|
-
|
|
67696
|
+
let existing;
|
|
67697
|
+
let cloudTargetId;
|
|
67698
|
+
if (isLocalMode) {
|
|
67699
|
+
const fromFile = (0, local_reader_1.readIntentFile)(filePath);
|
|
67700
|
+
if (!fromFile) {
|
|
67701
|
+
return { content: [{ type: 'text', text: `✗ No intent file at ${filePath}. Save one with intent_save first, then confirm.` }] };
|
|
67702
|
+
}
|
|
67703
|
+
existing = fromFile;
|
|
67704
|
+
}
|
|
67705
|
+
else {
|
|
67706
|
+
const cloud = requireCloudClient();
|
|
67707
|
+
// Re-read the FULL record. The list projection is a different shape, and grading a
|
|
67708
|
+
// listed row is how the cloud preflight could never pass (mcp-server 1.14.1).
|
|
67709
|
+
const listed = intentId ? undefined : pickCurrentIntent(await cloud.listIntents());
|
|
67710
|
+
cloudTargetId = intentId || listed?.id;
|
|
67711
|
+
const record = cloudTargetId
|
|
67712
|
+
? await cloud.getIntent(cloudTargetId).catch(() => undefined)
|
|
67713
|
+
: undefined;
|
|
67714
|
+
if (!record) {
|
|
67715
|
+
return {
|
|
67716
|
+
content: [{
|
|
67717
|
+
type: 'text',
|
|
67718
|
+
text: intentId
|
|
67719
|
+
? `✗ No intent with id "${intentId}" in this workspace.`
|
|
67720
|
+
: '✗ No intents found in this workspace. Create one first, then confirm.',
|
|
67721
|
+
}],
|
|
67722
|
+
};
|
|
67723
|
+
}
|
|
67724
|
+
existing = { ...record, confirmations: (record.confirmations ?? []) };
|
|
67725
|
+
}
|
|
67726
|
+
/**
|
|
67727
|
+
* A waiver is a human decision (amendment A), and in cloud mode this process holds an API
|
|
67728
|
+
* KEY. The API refuses `by: 'human'` from a key precisely so an agent cannot mint the
|
|
67729
|
+
* strongest-looking record there is, and a cloud record renders as `authenticated`, so a
|
|
67730
|
+
* forged one would carry weight a local file's never does. Refuse here with the reason
|
|
67731
|
+
* rather than letting the agent discover it as a 422 it cannot act on.
|
|
67732
|
+
*/
|
|
67733
|
+
if (!isLocalMode && action === 'waive') {
|
|
67734
|
+
return {
|
|
67735
|
+
content: [{
|
|
67736
|
+
type: 'text',
|
|
67737
|
+
text: `✗ A waiver cannot be recorded through an API key. It is a human decision, and this connection authenticates as a machine, so the workspace will not accept one from it. Confirm ${dimension} instead if the text is there, or waive it from the spec in Pathmode.`,
|
|
67738
|
+
}],
|
|
67739
|
+
};
|
|
67480
67740
|
}
|
|
67481
67741
|
const verdict = (0, readiness_1.computeReadinessVerdict)({ ...existing, confirmations: existing.confirmations });
|
|
67482
67742
|
const state = verdict.detail[dimension]?.state;
|
|
@@ -67509,16 +67769,85 @@ function startMcpServer() {
|
|
|
67509
67769
|
? { actor: actor.trim(), problem: problem.trim() }
|
|
67510
67770
|
: { outcome: outcome.trim(), observable: observable.trim() }),
|
|
67511
67771
|
};
|
|
67512
|
-
|
|
67513
|
-
|
|
67514
|
-
|
|
67515
|
-
|
|
67772
|
+
/**
|
|
67773
|
+
* SPLICE, never regenerate. formatIntentMd round-trips through a lossy projection: it
|
|
67774
|
+
* would reset version and status to defaults, restamp created, and delete unknown
|
|
67775
|
+
* frontmatter keys and any section the reader has no field for. Recording a judgment
|
|
67776
|
+
* must not damage the document being judged.
|
|
67777
|
+
*
|
|
67778
|
+
* READ-MODIFY-WRITE GUARD. The earlier version built the replacement list from the parse
|
|
67779
|
+
* taken at the top of this handler and then spliced it into bytes re-read at write time.
|
|
67780
|
+
* Two agents confirming different dimensions concurrently would each write a list missing
|
|
67781
|
+
* the other's record, so the later writer silently deleted the earlier one. The list is
|
|
67782
|
+
* now rebuilt from the SAME bytes being spliced, and the file is re-read immediately
|
|
67783
|
+
* before writing: if it moved, we start over from the new bytes, once, then refuse.
|
|
67784
|
+
*
|
|
67785
|
+
* This narrows the window rather than closing it. There is no atomic
|
|
67786
|
+
* compare-and-swap on a plain file, and a lockfile is not worth the failure modes it
|
|
67787
|
+
* brings to a local dev tool. The remaining race needs a write landing inside the gap
|
|
67788
|
+
* between the final read and the write itself.
|
|
67789
|
+
*/
|
|
67790
|
+
let kept;
|
|
67791
|
+
let where;
|
|
67792
|
+
if (!isLocalMode) {
|
|
67793
|
+
/**
|
|
67794
|
+
* Replace-all column, so the whole list is sent and the caller carries forward what it
|
|
67795
|
+
* read. Fenced on specVersion: a concurrent edit is a 409 rather than a silent
|
|
67796
|
+
* overwrite, which is the same lost-update shape the local splice guard exists for.
|
|
67797
|
+
*
|
|
67798
|
+
* The API independently re-checks the anchor against the stored text and refuses a
|
|
67799
|
+
* confirmation for a field the same request edits. This call sends no field edits at
|
|
67800
|
+
* all, so those checks should pass; if one fails, the spec moved under us and the
|
|
67801
|
+
* message says so rather than retrying into whatever is there now.
|
|
67802
|
+
*/
|
|
67803
|
+
kept = existing.confirmations.filter(c => c.dimension !== dimension);
|
|
67804
|
+
const cloud = requireCloudClient();
|
|
67805
|
+
try {
|
|
67806
|
+
await cloud.updateIntent(cloudTargetId, {
|
|
67807
|
+
confirmations: [...kept, record],
|
|
67808
|
+
...(typeof existing.specVersion === 'string' ? { expectedVersion: existing.specVersion } : {}),
|
|
67809
|
+
});
|
|
67810
|
+
}
|
|
67811
|
+
catch (e) {
|
|
67812
|
+
const msg = e instanceof Error ? e.message : String(e);
|
|
67813
|
+
return {
|
|
67814
|
+
content: [{
|
|
67815
|
+
type: 'text',
|
|
67816
|
+
text: /409|conflict|changed/i.test(msg)
|
|
67817
|
+
? `✗ The intent changed while this confirmation was being written. Re-read it and confirm against the current text.`
|
|
67818
|
+
: `✗ Could not record the confirmation: ${msg}`,
|
|
67819
|
+
}],
|
|
67820
|
+
};
|
|
67821
|
+
}
|
|
67822
|
+
where = `intent ${cloudTargetId}`;
|
|
67823
|
+
}
|
|
67824
|
+
else {
|
|
67825
|
+
const writeResult = (0, intent_compiler_1.writeConfirmationRecord)({
|
|
67826
|
+
read: () => (0, fs_1.readFileSync)(filePath, 'utf-8'),
|
|
67827
|
+
write: (content) => (0, fs_1.writeFileSync)(filePath, content, 'utf-8'),
|
|
67828
|
+
dimension,
|
|
67829
|
+
record: record,
|
|
67830
|
+
anchor,
|
|
67831
|
+
anchorOf: (bytes) => (0, readiness_1.fieldDigest)((0, readiness_1.computeReadinessVerdict)((0, local_reader_1.parseIntentMarkdown)(bytes, 'intent')).detail[dimension]?.extracted ?? ''),
|
|
67832
|
+
confirmationsOf: (bytes) => ((0, local_reader_1.parseIntentMarkdown)(bytes, 'intent').confirmations ?? []),
|
|
67833
|
+
});
|
|
67834
|
+
if (!writeResult.ok) {
|
|
67835
|
+
const why = {
|
|
67836
|
+
DUPLICATE_SECTION: `${filePath} has more than one "## Confirmations" section. The reader takes the last and this writer replaces the first, so a record written now would be invisible. Merge them into one section, then confirm.`,
|
|
67837
|
+
FIELD_CHANGED: `${dimension} in ${filePath} changed while this confirmation was being written. Re-read the file and confirm against the current text.`,
|
|
67838
|
+
FILE_CHANGED: `${filePath} kept changing while this confirmation was being written. Nothing was saved. Retry, or check whether another agent is writing the same file.`,
|
|
67839
|
+
}[writeResult.code];
|
|
67840
|
+
return { content: [{ type: 'text', text: `✗ ${why}` }] };
|
|
67841
|
+
}
|
|
67842
|
+
kept = writeResult.kept;
|
|
67843
|
+
where = filePath;
|
|
67844
|
+
}
|
|
67516
67845
|
const after = (0, readiness_1.computeReadinessVerdict)({ ...existing, confirmations: [...kept, record] });
|
|
67517
67846
|
return {
|
|
67518
67847
|
content: [{
|
|
67519
67848
|
type: 'text',
|
|
67520
67849
|
text: [
|
|
67521
|
-
`✓ ${dimension} ${action === 'waive' ? 'waived' : 'confirmed'} in ${
|
|
67850
|
+
`✓ ${dimension} ${action === 'waive' ? 'waived' : 'confirmed'} in ${where}`,
|
|
67522
67851
|
` ${after.detail[dimension]?.state === 'not_applicable' ? 'not applicable to this change' : 'confirmed against the current text'} · anchor ${anchor}`,
|
|
67523
67852
|
action === 'waive' ? ' Recorded as a human decision this environment cannot verify.' : '',
|
|
67524
67853
|
'',
|
|
@@ -137,3 +137,56 @@ export interface OutcomeRubricOptions {
|
|
|
137
137
|
* Docs: https://platform.claude.com/docs/en/managed-agents/define-outcomes
|
|
138
138
|
*/
|
|
139
139
|
export declare function formatOutcomeRubric(spec: IntentFields, opts?: OutcomeRubricOptions): string;
|
|
140
|
+
/**
|
|
141
|
+
* Splice a `## Confirmations` section into an existing intent.md WITHOUT regenerating the file.
|
|
142
|
+
*
|
|
143
|
+
* Regenerating through formatIntentMd is lossy by construction: LocalIntent is a projection, so
|
|
144
|
+
* a round-trip drops unknown frontmatter keys, resets `version` and `status` to their defaults,
|
|
145
|
+
* restamps `created`, and deletes any section the reader has no field for. Measured on a real
|
|
146
|
+
* spec: status approved -> draft, version 7 -> 1, and `source`, `specVersion` and a `## Evidence`
|
|
147
|
+
* section gone. A tool that records a judgment must not destroy the document it judges.
|
|
148
|
+
*
|
|
149
|
+
* So this is a text operation. It replaces an existing `## Confirmations` section in place, or
|
|
150
|
+
* appends one at the end, and touches nothing else in the file.
|
|
151
|
+
*/
|
|
152
|
+
export declare function spliceConfirmationsSection(original: string, section: string): string;
|
|
153
|
+
/** Render confirmation records as the `## Confirmations` section body. */
|
|
154
|
+
export declare function renderConfirmationsSection(records: Record<string, unknown>[]): string;
|
|
155
|
+
/**
|
|
156
|
+
* Write one confirmation record into a file's `## Confirmations` section, under a
|
|
157
|
+
* read-modify-write guard.
|
|
158
|
+
*
|
|
159
|
+
* Extracted from the tool handler so the race it exists to narrow is actually testable. The
|
|
160
|
+
* handler version could only be exercised through stdio, which cannot open the window: the bug
|
|
161
|
+
* needed a write landing between the handler's parse and its write, and a test that cannot create
|
|
162
|
+
* that window proves nothing about the guard. Everything here is injected, so a test supplies a
|
|
163
|
+
* `read` that returns different bytes on successive calls.
|
|
164
|
+
*
|
|
165
|
+
* The three refusals, all of which lose a record if waved through:
|
|
166
|
+
* - DUPLICATE_SECTION: the reader takes the LAST `## Confirmations` heading and this writer
|
|
167
|
+
* replaces the FIRST, so on a two-section file a successful write lands where nothing reads.
|
|
168
|
+
* - FIELD_CHANGED: the confirmed text was edited while we were writing, so the record would be
|
|
169
|
+
* stale the moment it landed.
|
|
170
|
+
* - FILE_CHANGED: the file moved under us twice. One retry, then stop.
|
|
171
|
+
*
|
|
172
|
+
* This narrows the window; it does not close it. There is no atomic compare-and-swap on a plain
|
|
173
|
+
* file, and a lockfile brings failure modes a local dev tool should not have. What remains needs a
|
|
174
|
+
* write landing between the final read and the write itself.
|
|
175
|
+
*/
|
|
176
|
+
export type ConfirmationWriteResult = {
|
|
177
|
+
ok: true;
|
|
178
|
+
kept: Record<string, unknown>[];
|
|
179
|
+
} | {
|
|
180
|
+
ok: false;
|
|
181
|
+
code: 'DUPLICATE_SECTION' | 'FIELD_CHANGED' | 'FILE_CHANGED';
|
|
182
|
+
};
|
|
183
|
+
export declare function writeConfirmationRecord(opts: {
|
|
184
|
+
read: () => string;
|
|
185
|
+
write: (content: string) => void;
|
|
186
|
+
dimension: string;
|
|
187
|
+
record: Record<string, unknown>;
|
|
188
|
+
/** The digest the record is anchored to; recomputed from each candidate read. */
|
|
189
|
+
anchor: string;
|
|
190
|
+
anchorOf: (raw: string) => string;
|
|
191
|
+
confirmationsOf: (raw: string) => Record<string, unknown>[];
|
|
192
|
+
}): ConfirmationWriteResult;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/intent-compiler.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAMH,MAAM,WAAW,cAAc;IAC3B,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,UAAU,CAAC,EAAE,MAAM,CAAC;CACvB;AAOD,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG,QAAQ,GAAG,gBAAgB,GAAG,kBAAkB,GAAG,MAAM,CAAC;AAC1G,MAAM,MAAM,uBAAuB,GAAG,SAAS,GAAG,SAAS,GAAG,SAAS,CAAC;AACxE,MAAM,WAAW,iBAAiB;IAC9B,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,qBAAqB,CAAC;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,uBAAuB,CAAC;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAsDD,MAAM,WAAW,YAA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CAAC;IAChC,iFAAiF;IACjF,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;IAClC,eAAe,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,CAAC;CAC/D,GAAG,uBAAuB,CA0B1B"}
|
package/dist/local-reader.d.ts
CHANGED
|
@@ -105,9 +105,4 @@ export declare function readIntentMeta(filePath: string): LocalIntentMeta | null
|
|
|
105
105
|
* Parse a single intent.md file with YAML frontmatter.
|
|
106
106
|
*/
|
|
107
107
|
export declare function readIntentFile(filePath: string): LocalIntent | null;
|
|
108
|
-
/**
|
|
109
|
-
* Parse intent.md content (frontmatter + body) into a LocalIntent. Pure: no fs, no cwd.
|
|
110
|
-
* Exported so lib/intentMdParseParity.test.ts can hold the web paste-box parser
|
|
111
|
-
* (lib/intentMdParse.ts) to this implementation's behavior on gate-relevant fields.
|
|
112
|
-
*/
|
|
113
108
|
export declare function parseIntentMarkdown(content: string, fallbackId?: string): LocalIntent;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/local-reader.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAMH,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG,QAAQ,GAAG,gBAAgB,GAAG,kBAAkB,GAAG,MAAM,CAAC;AAE1G,MAAM,WAAW,sBAAsB;IACnC,IAAI,EAAE,qBAAqB,CAAC;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,SAAS,CAAC;IAC3C,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,wGAAwG;AACxG,MAAM,WAAW,aAAa;IAC1B,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MA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,MAAM,CAAA;KAAE,EAAE,CAAC;IAC5D,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,KAAK,CAAC,EAAE;QAAE,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC;IACtD,YAAY,EAAE,iBAAiB,CAAC;IAChC,0EAA0E;IAC1E,aAAa,EAAE,iBAAiB,EAAE,CAAC;IACnC,MAAM,EAAE,OAAO,CAAC;CACnB;AAED,gFAAgF;AAChF,MAAM,WAAW,eAAe;IAC5B,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;6EACyE;IACzE,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB;AAID;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,WAAW,EAAE,CAmBhD;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,eAAe,GAAG,IAAI,CAevE;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,WAAW,GAAG,IAAI,CAUnE;
|
|
1
|
+
{"version":3,"file":"","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/local-reader.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAMH,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG,QAAQ,GAAG,gBAAgB,GAAG,kBAAkB,GAAG,MAAM,CAAC;AAE1G,MAAM,WAAW,sBAAsB;IACnC,IAAI,EAAE,qBAAqB,CAAC;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,SAAS,CAAC;IAC3C,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,wGAAwG;AACxG,MAAM,WAAW,aA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AAE,CAAC;IACtB,SAAS,EAAE;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,gBAAgB,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAC5D,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,KAAK,CAAC,EAAE;QAAE,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC;IACtD,YAAY,EAAE,iBAAiB,CAAC;IAChC,0EAA0E;IAC1E,aAAa,EAAE,iBAAiB,EAAE,CAAC;IACnC,MAAM,EAAE,OAAO,CAAC;CACnB;AAED,gFAAgF;AAChF,MAAM,WAAW,eAAe;IAC5B,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;6EACyE;IACzE,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB;AAID;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,WAAW,EAAE,CAmBhD;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,eAAe,GAAG,IAAI,CAevE;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,WAAW,GAAG,IAAI,CAUnE;AAoDD,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,SAAW,GAAG,WAAW,CAuCvF"}
|
package/dist/readiness.d.ts
CHANGED
|
@@ -20,12 +20,12 @@ export declare function isVerificationCheckSubstantive(description: string | nul
|
|
|
20
20
|
export declare function isObjectiveSpecific(objective: string | null | undefined): boolean;
|
|
21
21
|
export declare function isOutcomeMeasurable(text: string): boolean;
|
|
22
22
|
export declare const READINESS_BLOCKER_DESCRIPTIONS: Record<string, string>;
|
|
23
|
-
/** Display order for the gate strip (title first, matching the Preflight page). */
|
|
24
23
|
/**
|
|
25
24
|
* Fold away everything that is a rewrite of the same claim, and nothing that is a change to it.
|
|
26
25
|
* NFC because one glyph has two encodings; soft hyphens because editors inject them invisibly;
|
|
27
|
-
* quote/dash folding and markdown emphasis because adding `**` around a word is
|
|
28
|
-
* a reword.
|
|
26
|
+
* quote/dash folding and PAIRED markdown emphasis because adding `**` around a word is
|
|
27
|
+
* formatting, not a reword. An unpaired `*` or `_` is left alone: it is content (a wildcard),
|
|
28
|
+
* and deleting it silently kept confirmations alive across a real change to the claim. Lowercased and whitespace-collapsed last.
|
|
29
29
|
*/
|
|
30
30
|
export declare function normalizeAnchor(value: unknown): string;
|
|
31
31
|
/**
|
|
@@ -86,6 +86,11 @@ export interface DimensionDetail {
|
|
|
86
86
|
state: DimensionState;
|
|
87
87
|
/** What the reader actually read for this dimension, for quoting back. */
|
|
88
88
|
extracted?: string;
|
|
89
|
+
/** Set when a confirmation or waiver moved this dimension: who vouched, and how well we know it. */
|
|
90
|
+
confirmedBy?: 'agent' | 'human';
|
|
91
|
+
assurance?: 'authenticated' | 'local-unverified';
|
|
92
|
+
/** The waiver's stated reason, for rendering the exception rather than hiding it. */
|
|
93
|
+
reason?: string;
|
|
89
94
|
}
|
|
90
95
|
export interface ReadinessVerdict {
|
|
91
96
|
ready: boolean;
|
|
@@ -115,4 +120,7 @@ export declare function computeReadinessVerdict(spec: ReadinessSpecInput): Readi
|
|
|
115
120
|
*/
|
|
116
121
|
export declare function formatReadinessFrontmatter(verdict: ReadinessVerdict): string;
|
|
117
122
|
/** Human/agent-readable verdict block, stable enough to parse by line prefix. */
|
|
118
|
-
export declare function formatReadinessVerdict(verdict: ReadinessVerdict, specTitle?: string
|
|
123
|
+
export declare function formatReadinessVerdict(verdict: ReadinessVerdict, specTitle?: string,
|
|
124
|
+
/** Override the closing repair line. The default names MCP tools, which are wrong in a CLI
|
|
125
|
+
* reading a repo that has never installed Pathmode. */
|
|
126
|
+
repairHint?: string): string;
|
package/dist/readiness.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/readiness.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAIH,wBAAgB,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAQjD;AAED,wBAAgB,OAAO,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,EAAE,GAAG,IAAI,GAAG,SAAS,GAAG,CAAC,EAAE,CAIjE;AAoCD,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,CAQ3E;AAID,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAI5D;AAED,wBAAgB,8BAA8B,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,CAI9F;AAQD,wBAAgB,mBAAmB,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,CAOjF;AAQD,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAKzD;AAID,eAAO,MAAM,8BAA8B,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAOjE,CAAC;
|
|
1
|
+
{"version":3,"file":"","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/readiness.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAIH,wBAAgB,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAQjD;AAED,wBAAgB,OAAO,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,EAAE,GAAG,IAAI,GAAG,SAAS,GAAG,CAAC,EAAE,CAIjE;AAoCD,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,CAQ3E;AAID,wBAAgB,o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AAM,CAyDR"}
|
package/manifest.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"manifest_version": "0.3",
|
|
3
3
|
"name": "pathmode",
|
|
4
4
|
"display_name": "Pathmode",
|
|
5
|
-
"version": "1.
|
|
5
|
+
"version": "1.16.0",
|
|
6
6
|
"description": "Deterministic preflight for the intent you hand to a coding agent: six calibrated gates, the exact blockers named, no model call, no key needed.",
|
|
7
7
|
"long_description": "Pathmode MCP Server runs a deterministic preflight before your coding agent builds: check_intent_readiness scores an intent spec against six calibrated gates (title, objective, outcomes, constraints, edge cases, verification) and names the exact blockers, with no model call and no account. Keyless local mode works out of the box; specs live in intent.md in your repo, plain markdown you own, and skills for drafting, pressure-testing, and handing off intent ride along. Connect a Pathmode workspace with an API key to sync intent and evidence across a team, analyze dependency graphs, and verify pull requests against the outcomes you agreed to.",
|
|
8
8
|
"author": {
|