@pathmode/mcp-server 1.20.1 → 1.21.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.
@@ -1 +1 @@
1
- {"version":3,"file":"measurement-schema.d.ts","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/measurement-schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,cAAc,6CAA2C,CAAC;AACvE,eAAO,MAAM,cAAc,+CAA6C,CAAC;AAEzE,eAAO,MAAM,aAAa;;;;;;;;;EAGxB,CAAC;AAEH;;;;GAIG;AACH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAclB,CAAC;AAEP,eAAO,MAAM,gBAAgB;;;;;;;;;;;;EAI3B,CAAC;AAEH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAS1B,CAAC;AAEH,4EAA4E;AAC5E,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAW/C,CAAC;AAEF;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE;IAAE,SAAS,CAAC,EAAE,MAAM,CAAC;IAAC,YAAY,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,MAAM,GAAG,IAAI,CAKxG"}
1
+ {"version":3,"file":"measurement-schema.d.ts","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/measurement-schema.ts"],"names":[],"mappings":"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MAAM,GAAG,IAAI,CAKxG"}
@@ -39,6 +39,11 @@ export interface PushClient {
39
39
  createIntent(input: any): Promise<SettledIdentity>;
40
40
  /** Used to recover when a create commits but its response is lost. */
41
41
  getIntent?(id: string): Promise<SettledIdentity>;
42
+ getIntentChangeRequest?(intentId: string, requestId: string): Promise<{
43
+ changeRequest?: {
44
+ status?: string;
45
+ };
46
+ }>;
42
47
  updateIntent(id: string, input: any): Promise<SettledIdentity>;
43
48
  recordDecision(intentId: string, input: any): Promise<unknown>;
44
49
  saveImplementationContext(intentId: string, input: any): Promise<unknown>;
@@ -56,6 +61,12 @@ export interface PushSpecInput {
56
61
  ruledOut?: string;
57
62
  }[];
58
63
  implementationContext?: string;
64
+ /** The exact structured PM request this save is applying. It rides on every write leg because
65
+ * the material change may live in the body, decisions, or implementation context. */
66
+ changeRequest?: {
67
+ id: string;
68
+ baseRepoBodyRevision: string;
69
+ };
59
70
  /** Called once identity is settled, before any enrichment. This is the file write. */
60
71
  onIdentitySettled: (result: {
61
72
  canonicalId: string;
@@ -1 +1 @@
1
- {"version":3,"file":"push-spec.d.ts","sourceRoot":"","sources":["file:///Users/jannelammi/code/Pathmode/packages/mcp-server/src/push-spec.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH;;6FAE6F;AAC7F,MAAM,WAAW,eAAe;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B;;oFAEgF;IAChF,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACrC;AAED,MAAM,WAAW,UAAU;IACvB,YAAY,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;IACnD,sEAAsE;IACtE,SAAS,CAAC,CAAC,EAAE,EAAE,MAAM,GA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AE,CAAA;CAAE,GAClG;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,SAAS,CAAC,EAAE,OAAO,CAAA;KAAE,EAAE,CAAA;CAAE,CAAC;AAElH,wBAAsB,QAAQ,CAAC,KAAK,EAAE,aAAa,GAAG,OAAO,CAAC,cAAc,CAAC,CAqI5E"}
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.20.1",
5
+ "version": "1.21.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": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pathmode/mcp-server",
3
- "version": "1.20.1",
3
+ "version": "1.21.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -50,6 +50,14 @@
50
50
  "gray-matter": "^4.0.3",
51
51
  "zod": "^3.24.0"
52
52
  },
53
+ "overrides": {
54
+ "@hono/node-server": "^1.19.17",
55
+ "body-parser": "^2.3.0",
56
+ "fast-uri": "^3.1.6",
57
+ "hono": "^4.13.5",
58
+ "ip-address": "^10.7.0",
59
+ "js-yaml": "^3.15.2"
60
+ },
53
61
  "devDependencies": {
54
62
  "@types/node": "^25.1.0",
55
63
  "@vercel/ncc": "^0.38.4",
@@ -5,7 +5,9 @@ description: Run the deterministic readiness check on an intent spec before an a
5
5
 
6
6
  <what-to-do>
7
7
 
8
- Call the `check_intent_readiness` MCP tool (Pathmode). With no arguments it prefers `intent.md` in the project root in both local and connected modes; only when that repo-bound file is absent does connected mode fall back to the workspace current intent. Pass `spec` inline to preflight a draft before saving it, or `intentId` when the user deliberately selects a different saved intent.
8
+ Call the `check_intent_readiness` MCP tool (Pathmode). With no arguments it resolves `intent.md` from the MCP client's declared workspace roots or the server launch directory. Connected mode falls back to the workspace current intent only when declared roots are known to contain no repo-bound file; if the repository cannot be identified, it refuses to guess and asks for `intentId` or an inline `spec`. Pass `spec` inline to preflight a draft before saving it, or `intentId` when the user deliberately selects a different saved intent.
9
+
10
+ In connected mode, when the repo-bound file carries a cloud id, check for PM judgment before implementation: call `list_intent_change_requests` with that id. For every open request, call `get_intent_change_request`, apply the requested field/item change deliberately to `intent.md`, and call `intent_save` with the request's exact `changeRequestId` and `baseRepoBodyRevision`. If the request is unworkable, call `reject_intent_change_request` with a concrete reason instead of pretending it was applied. After an applied request, re-run the readiness check, report that the new repository revision is pending human authorization, and STOP. Do not begin implementation until a later `get_agent_prompt` confirms that the exact current revision is authorized by a signed-in product owner.
9
11
 
10
12
  Show the user the verdict block exactly as returned — the blocker strings are the calibrated gate output, do not paraphrase them.
11
13
 
@@ -5,7 +5,9 @@ description: Review code changes against the active intent's outcomes and constr
5
5
 
6
6
  <what-to-do>
7
7
 
8
- Load the active intent. Read `intent.md` from the project root first — the file is bound to this repository, which makes it the authority on what governs this diff. If `PATHMODE_API_KEY` is set and the file's frontmatter carries a cloud id, also fetch that intent's execution bundle (`get_agent_prompt` with the id) to pick up what the file cannot hold: open findings, handoff notes, authorization state. Do not let `get_current_intent` choose the intent for you when a local file exists — "current" is a workspace heuristic, not a repo binding. Only with no local file at all, fall back to `get_current_intent`.
8
+ Load the active intent. Read `intent.md` from the project root first — the file is bound to this repository, which makes it the authority on what governs this diff. If `PATHMODE_API_KEY` is set and the file's frontmatter carries a cloud id, also fetch that intent's execution bundle (`get_agent_prompt` with the id) to pick up what the file cannot hold: open PM change requests, findings, handoff notes, and authorization state. Do not let `get_current_intent` choose the intent for you when a local file exists — "current" is a workspace heuristic, not a repo binding. Only with no local file at all, fall back to `get_current_intent`.
9
+
10
+ If the execution bundle reports an open PM change request, or says the current repository revision is pending, rejected, or stale, stop before reviewing the diff as delivered work. Name the exact request/revision blocker and direct the agent through `preflight`: a requested spec change must be applied with request-bound `intent_save`, then a signed-in product owner must authorize that exact resulting revision. Never approve code against the superseded or unauthorized spec.
9
11
 
10
12
  Identify the changed files using git diff against the base branch (or staged changes if no base specified).
11
13