projscan 1.8.1 → 1.10.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.
Files changed (55) hide show
  1. package/README.md +2 -2
  2. package/dist/analyzers/securityCheck.js +5 -1
  3. package/dist/analyzers/securityCheck.js.map +1 -1
  4. package/dist/cli/commands/plugin.d.ts +6 -0
  5. package/dist/cli/commands/plugin.js +118 -0
  6. package/dist/cli/commands/plugin.js.map +1 -0
  7. package/dist/cli/index.js +2 -0
  8. package/dist/cli/index.js.map +1 -1
  9. package/dist/core/applyFix.d.ts +9 -0
  10. package/dist/core/applyFix.js +77 -1
  11. package/dist/core/applyFix.js.map +1 -1
  12. package/dist/core/codeGraph.js +14 -2
  13. package/dist/core/codeGraph.js.map +1 -1
  14. package/dist/core/intent.d.ts +94 -0
  15. package/dist/core/intent.js +472 -0
  16. package/dist/core/intent.js.map +1 -0
  17. package/dist/core/issueEngine.js +12 -0
  18. package/dist/core/issueEngine.js.map +1 -1
  19. package/dist/core/memory.d.ts +28 -0
  20. package/dist/core/memory.js +22 -0
  21. package/dist/core/memory.js.map +1 -1
  22. package/dist/core/plugins.d.ts +83 -0
  23. package/dist/core/plugins.js +209 -0
  24. package/dist/core/plugins.js.map +1 -0
  25. package/dist/core/prDiff.js +18 -4
  26. package/dist/core/prDiff.js.map +1 -1
  27. package/dist/core/repositoryScanner.js +6 -1
  28. package/dist/core/repositoryScanner.js.map +1 -1
  29. package/dist/core/review.d.ts +8 -0
  30. package/dist/core/review.js +56 -4
  31. package/dist/core/review.js.map +1 -1
  32. package/dist/core/taint.js +27 -4
  33. package/dist/core/taint.js.map +1 -1
  34. package/dist/core/watcher.d.ts +8 -0
  35. package/dist/core/watcher.js +56 -18
  36. package/dist/core/watcher.js.map +1 -1
  37. package/dist/mcp/tools/costSummary.js +259 -49
  38. package/dist/mcp/tools/costSummary.js.map +1 -1
  39. package/dist/mcp/tools/memory.js +8 -3
  40. package/dist/mcp/tools/memory.js.map +1 -1
  41. package/dist/mcp/tools/plugin.d.ts +13 -0
  42. package/dist/mcp/tools/plugin.js +87 -0
  43. package/dist/mcp/tools/plugin.js.map +1 -0
  44. package/dist/mcp/tools/review.js +7 -2
  45. package/dist/mcp/tools/review.js.map +1 -1
  46. package/dist/mcp/tools/reviewWatch.d.ts +121 -0
  47. package/dist/mcp/tools/reviewWatch.js +153 -17
  48. package/dist/mcp/tools/reviewWatch.js.map +1 -1
  49. package/dist/mcp/tools.js +2 -0
  50. package/dist/mcp/tools.js.map +1 -1
  51. package/dist/tool-manifest.json +51 -8
  52. package/dist/types.d.ts +35 -0
  53. package/dist/utils/changedFiles.js +25 -0
  54. package/dist/utils/changedFiles.js.map +1 -1
  55. package/package.json +2 -2
@@ -1,7 +1,128 @@
1
+ import type { ReviewReport } from '../../types.js';
1
2
  import type { McpTool } from './_shared.js';
3
+ /**
4
+ * 1.8+ — `projscan_review_watch`. Long-running PR-watch mode that
5
+ * complements `projscan_review` (one-shot snapshot). Subscribe-once-
6
+ * watch-forever closes the long-session loop on PRs the way file
7
+ * `--watch` (1.3) did for source files: agents can pin a PR, react to
8
+ * pushes as they happen, and avoid re-running review on every turn.
9
+ *
10
+ * Subactions:
11
+ * - "start" : begin polling. Returns the initial review payload AND
12
+ * a `watchId` the caller persists.
13
+ * - "stop" : cancel a watch by id.
14
+ * - "list" : enumerate active watches in this server's session.
15
+ *
16
+ * Polling: every `interval_seconds` (default 30, min 5, max 600) the
17
+ * server re-runs computeReview against the same base+head pair. If the
18
+ * result's `signature` (verdict + base/head SHA + flow count + risky-
19
+ * function-name set) differs from the previous tick, it emits a
20
+ * `notifications/projscan/pr_changed` notification with the new full
21
+ * report inline. Successive ticks with the same signature are silent.
22
+ *
23
+ * Notification flow (sent over the JSON-RPC notify channel):
24
+ *
25
+ * { method: "notifications/projscan/pr_changed",
26
+ * params: { watchId, base, head, baseSha, headSha, report } }
27
+ *
28
+ * Lifecycle: the server holds the cancel handle in `toolWatches`. On
29
+ * close() (process exit, EOF on stdin) all watches are cancelled. Tool
30
+ * results, including the watch itself, are best-effort: if computeReview
31
+ * fails on a tick, the failure is logged via the same notification
32
+ * channel with a `pr_review_error` method instead of `pr_changed`.
33
+ */
34
+ interface WatchSnapshot {
35
+ /** 1.8+ */
36
+ verdict: string;
37
+ baseSha: string | null;
38
+ headSha: string | null;
39
+ changedFilesCount: number;
40
+ taintFlowKeys: string[];
41
+ riskyFunctionKeys: string[];
42
+ /**
43
+ * 1.9+ — deepened signature. Each cycle is fingerprinted by its
44
+ * sorted file list so we can tell newly-introduced cycles apart from
45
+ * stable ones across ticks.
46
+ */
47
+ cycleKeys: string[];
48
+ /**
49
+ * 1.9+ — dependency-change fingerprint per (manifest, name, kind).
50
+ * 'add'/'remove' carry the version; 'bump' carries from->to.
51
+ * Allows the delta to count adds/removes/bumps separately.
52
+ */
53
+ depAdds: string[];
54
+ depRemoves: string[];
55
+ depBumps: string[];
56
+ }
57
+ interface WatchDelta {
58
+ /**
59
+ * 1.9+ — which buckets actually changed since last tick. Lets the
60
+ * agent decide whether to refetch full data or just react to one
61
+ * dimension (e.g. only `deps` triggered, so re-run audit not review).
62
+ */
63
+ changeKinds: Array<'verdict' | 'baseSha' | 'headSha' | 'changedFiles' | 'cycles' | 'risky' | 'taint' | 'deps'>;
64
+ cycles: {
65
+ added: number;
66
+ removed: number;
67
+ };
68
+ risky: {
69
+ added: number;
70
+ removed: number;
71
+ };
72
+ taint: {
73
+ added: number;
74
+ removed: number;
75
+ };
76
+ deps: {
77
+ added: number;
78
+ removed: number;
79
+ bumped: number;
80
+ };
81
+ }
2
82
  export declare const reviewWatchTool: McpTool;
83
+ /**
84
+ * 1.9+ — Capture the change-detection-relevant slice of a review.
85
+ * Replaces 1.8's `signatureOf(report) → string` so we can both compare
86
+ * ticks for equality AND compute a structured delta when they differ.
87
+ *
88
+ * Cycles use a sorted-files fingerprint, dependency changes are split
89
+ * into adds / removes / bumps. Risky-function keys carry both file and
90
+ * name so renames in unchanged files surface, and so two functions
91
+ * with the same anonymous name in different files don't collapse.
92
+ */
93
+ declare function snapshotOf(report: ReviewReport): WatchSnapshot;
94
+ /**
95
+ * Serialize a snapshot into a stable comparison key. Used only for
96
+ * the fast "did anything change?" check — the structured delta is
97
+ * computed separately via diffSnapshots.
98
+ */
99
+ declare function signatureOf(snapshot: WatchSnapshot): string;
100
+ /**
101
+ * 1.9+ — Structured diff between two watch snapshots. Counts items
102
+ * that moved into or out of each bucket, and records which buckets
103
+ * had any change at all. Caller embeds this in the `delta` field of
104
+ * the `notifications/projscan/pr_changed` payload so agents can react
105
+ * to a specific dimension without re-reading the full report.
106
+ *
107
+ * `prev` may be null for the very first emitted notification — in
108
+ * that case every non-empty bucket is reported as an "added" delta
109
+ * against an empty baseline.
110
+ */
111
+ declare function diffSnapshots(prev: WatchSnapshot | null, next: WatchSnapshot): WatchDelta;
3
112
  /**
4
113
  * Test-only: drop all watches in the module. Lets unit tests verify
5
114
  * start/stop semantics without leaking timers across cases.
6
115
  */
7
116
  export declare function __resetReviewWatchesForTests(): void;
117
+ /**
118
+ * Test-only exports: snapshot + diff helpers for the 1.9 signature
119
+ * deepening. Keeping these accessible avoids over-loading the public
120
+ * tool surface with internals while still letting tests assert on the
121
+ * specific shape and per-bucket counts the agent will see.
122
+ */
123
+ export declare const __internal: {
124
+ snapshotOf: typeof snapshotOf;
125
+ signatureOf: typeof signatureOf;
126
+ diffSnapshots: typeof diffSnapshots;
127
+ };
128
+ export type { WatchSnapshot, WatchDelta };
@@ -5,7 +5,7 @@ const MIN_INTERVAL_S = 5;
5
5
  const MAX_INTERVAL_S = 600;
6
6
  export const reviewWatchTool = {
7
7
  name: 'projscan_review_watch',
8
- description: 'Long-running PR review. Polls a base+head ref pair on an interval and emits a notifications/projscan/pr_changed notification whenever the review verdict, SHAs, flow count, or risky-function set changes. Pairs with projscan_review (one-shot) — use this when an agent wants to react to pushes on a PR without re-asking. Actions: start (returns initial review + watchId) / stop / list.',
8
+ description: 'Long-running PR review. Polls a base+head ref pair on an interval and emits a notifications/projscan/pr_changed notification whenever the review verdict, SHAs, cycle set, dep changes, taint flows, or risky-function set changes. 1.9+: the notification carries a structured `delta` describing exactly which buckets moved (verdict/baseSha/headSha/changedFiles/cycles/risky/taint/deps) and counts of newly-appearing items per bucket, so agents can skip work they do not need. Pairs with projscan_review (one-shot) — use this when an agent wants to react to pushes on a PR without re-asking. Actions: start (returns initial review + watchId) / stop / list.',
9
9
  inputSchema: {
10
10
  type: 'object',
11
11
  properties: {
@@ -54,7 +54,8 @@ async function startWatch(args, rootPath, context) {
54
54
  // Initial review — synchronous, returned with the response so the agent
55
55
  // gets a useful payload right away and can react before the first tick.
56
56
  const initial = await computeReview(rootPath, { base, head });
57
- const initialSignature = signatureOf(initial);
57
+ const initialSnapshot = snapshotOf(initial);
58
+ const initialSignature = signatureOf(initialSnapshot);
58
59
  if (!context?.registerWatch || !context.notify) {
59
60
  // Caller is in a transport without a notify channel (CLI smoke,
60
61
  // tests). Return the initial review with a clear note that no
@@ -95,6 +96,7 @@ async function startWatch(args, rootPath, context) {
95
96
  startedAt: new Date().toISOString(),
96
97
  ticks: 0,
97
98
  lastSignature: initialSignature,
99
+ lastSnapshot: initialSnapshot,
98
100
  lastReportAt: new Date().toISOString(),
99
101
  inFlight: false,
100
102
  });
@@ -141,10 +143,17 @@ async function runTick(rootPath, watchId, base, head, context) {
141
143
  context.notify?.('notifications/projscan/pr_review_error', { watchId, error: message });
142
144
  return;
143
145
  }
144
- const sig = signatureOf(report);
146
+ const snapshot = snapshotOf(report);
147
+ const sig = signatureOf(snapshot);
145
148
  if (sig === state.lastSignature)
146
149
  return; // unchanged — silent
150
+ // 1.9+ — diff against the previous snapshot so the notification
151
+ // tells the agent *what kind* of change triggered it. Lets the
152
+ // agent skip work it doesn't need: e.g. dep-only changes don't
153
+ // need a full review re-read; verdict changes do.
154
+ const delta = diffSnapshots(state.lastSnapshot, snapshot);
147
155
  state.lastSignature = sig;
156
+ state.lastSnapshot = snapshot;
148
157
  state.lastReportAt = new Date().toISOString();
149
158
  context.notify?.('notifications/projscan/pr_changed', {
150
159
  watchId,
@@ -152,6 +161,7 @@ async function runTick(rootPath, watchId, base, head, context) {
152
161
  head: report.head?.ref ?? head ?? null,
153
162
  baseSha: report.base?.resolvedSha ?? null,
154
163
  headSha: report.head?.resolvedSha ?? null,
164
+ delta,
155
165
  report,
156
166
  });
157
167
  }
@@ -197,21 +207,136 @@ function listWatches() {
197
207
  };
198
208
  }
199
209
  /**
200
- * A change-detection signature: tracks the bits of the review the
201
- * agent cares about (verdict, SHAs, flow / risky-fn counts and names).
202
- * Two ticks with identical signatures are silent; a delta on any of
203
- * these triggers a `pr_changed` notification with the full report.
210
+ * 1.9+ — Capture the change-detection-relevant slice of a review.
211
+ * Replaces 1.8's `signatureOf(report) string` so we can both compare
212
+ * ticks for equality AND compute a structured delta when they differ.
213
+ *
214
+ * Cycles use a sorted-files fingerprint, dependency changes are split
215
+ * into adds / removes / bumps. Risky-function keys carry both file and
216
+ * name so renames in unchanged files surface, and so two functions
217
+ * with the same anonymous name in different files don't collapse.
204
218
  */
205
- function signatureOf(report) {
206
- const parts = [];
207
- parts.push(report.verdict ?? '');
208
- parts.push(report.base?.resolvedSha ?? '');
209
- parts.push(report.head?.resolvedSha ?? '');
210
- parts.push(String(report.changedFiles?.length ?? 0));
211
- parts.push(String(report.newTaintFlows?.length ?? 0));
212
- const risky = (report.riskyFunctions ?? []).map((f) => f.name).sort().join(',');
213
- parts.push(risky);
214
- return parts.join('|');
219
+ function snapshotOf(report) {
220
+ const cycleKeys = (report.newCycles ?? [])
221
+ .map((c) => [...c.files].sort().join('|'))
222
+ .sort();
223
+ const taintFlowKeys = (report.newTaintFlows ?? [])
224
+ .map((f) => `${f.sourceFn}::${f.sinkFn}`)
225
+ .sort();
226
+ const riskyFunctionKeys = (report.riskyFunctions ?? [])
227
+ .map((f) => `${f.file}::${f.name}`)
228
+ .sort();
229
+ const depAdds = [];
230
+ const depRemoves = [];
231
+ const depBumps = [];
232
+ for (const change of report.dependencyChanges ?? []) {
233
+ for (const a of change.added) {
234
+ depAdds.push(`${change.manifestFile}::${a.name}::${a.kind}::${a.version}`);
235
+ }
236
+ for (const r of change.removed) {
237
+ depRemoves.push(`${change.manifestFile}::${r.name}::${r.kind}::${r.version}`);
238
+ }
239
+ for (const b of change.bumped) {
240
+ depBumps.push(`${change.manifestFile}::${b.name}::${b.kind}::${b.from}->${b.to}`);
241
+ }
242
+ }
243
+ depAdds.sort();
244
+ depRemoves.sort();
245
+ depBumps.sort();
246
+ return {
247
+ verdict: report.verdict ?? '',
248
+ baseSha: report.base?.resolvedSha ?? null,
249
+ headSha: report.head?.resolvedSha ?? null,
250
+ changedFilesCount: report.changedFiles?.length ?? 0,
251
+ taintFlowKeys,
252
+ riskyFunctionKeys,
253
+ cycleKeys,
254
+ depAdds,
255
+ depRemoves,
256
+ depBumps,
257
+ };
258
+ }
259
+ /**
260
+ * Serialize a snapshot into a stable comparison key. Used only for
261
+ * the fast "did anything change?" check — the structured delta is
262
+ * computed separately via diffSnapshots.
263
+ */
264
+ function signatureOf(snapshot) {
265
+ return JSON.stringify(snapshot);
266
+ }
267
+ /**
268
+ * 1.9+ — Structured diff between two watch snapshots. Counts items
269
+ * that moved into or out of each bucket, and records which buckets
270
+ * had any change at all. Caller embeds this in the `delta` field of
271
+ * the `notifications/projscan/pr_changed` payload so agents can react
272
+ * to a specific dimension without re-reading the full report.
273
+ *
274
+ * `prev` may be null for the very first emitted notification — in
275
+ * that case every non-empty bucket is reported as an "added" delta
276
+ * against an empty baseline.
277
+ */
278
+ function diffSnapshots(prev, next) {
279
+ const prevCycles = new Set(prev?.cycleKeys ?? []);
280
+ const nextCycles = new Set(next.cycleKeys);
281
+ const prevTaint = new Set(prev?.taintFlowKeys ?? []);
282
+ const nextTaint = new Set(next.taintFlowKeys);
283
+ const prevRisky = new Set(prev?.riskyFunctionKeys ?? []);
284
+ const nextRisky = new Set(next.riskyFunctionKeys);
285
+ const prevDepAdds = new Set(prev?.depAdds ?? []);
286
+ const nextDepAdds = new Set(next.depAdds);
287
+ const prevDepRemoves = new Set(prev?.depRemoves ?? []);
288
+ const nextDepRemoves = new Set(next.depRemoves);
289
+ const prevDepBumps = new Set(prev?.depBumps ?? []);
290
+ const nextDepBumps = new Set(next.depBumps);
291
+ const cycles = setDiffCounts(prevCycles, nextCycles);
292
+ const taint = setDiffCounts(prevTaint, nextTaint);
293
+ const risky = setDiffCounts(prevRisky, nextRisky);
294
+ const depAddsDiff = setDiffCounts(prevDepAdds, nextDepAdds);
295
+ const depRemovesDiff = setDiffCounts(prevDepRemoves, nextDepRemoves);
296
+ const depBumpsDiff = setDiffCounts(prevDepBumps, nextDepBumps);
297
+ // Each dep-bucket counter reports records that NEWLY appeared. We
298
+ // intentionally don't roll up reverts (records that vanished from a
299
+ // bucket since last tick); they fire `changeKinds.push('deps')` so
300
+ // the agent knows a dep-bucket moved, but counting them would
301
+ // conflate "PR newly adds foo" with "PR no longer removes foo",
302
+ // which mean different things to the reviewer.
303
+ const deps = {
304
+ added: depAddsDiff.added,
305
+ removed: depRemovesDiff.added,
306
+ bumped: depBumpsDiff.added,
307
+ };
308
+ const depsChanged = depAddsDiff.added + depAddsDiff.removed +
309
+ depRemovesDiff.added + depRemovesDiff.removed +
310
+ depBumpsDiff.added + depBumpsDiff.removed > 0;
311
+ const changeKinds = [];
312
+ if (!prev || prev.verdict !== next.verdict)
313
+ changeKinds.push('verdict');
314
+ if (!prev || prev.baseSha !== next.baseSha)
315
+ changeKinds.push('baseSha');
316
+ if (!prev || prev.headSha !== next.headSha)
317
+ changeKinds.push('headSha');
318
+ if (!prev || prev.changedFilesCount !== next.changedFilesCount)
319
+ changeKinds.push('changedFiles');
320
+ if (cycles.added + cycles.removed > 0)
321
+ changeKinds.push('cycles');
322
+ if (risky.added + risky.removed > 0)
323
+ changeKinds.push('risky');
324
+ if (taint.added + taint.removed > 0)
325
+ changeKinds.push('taint');
326
+ if (depsChanged)
327
+ changeKinds.push('deps');
328
+ return { changeKinds, cycles, risky, taint, deps };
329
+ }
330
+ function setDiffCounts(prev, next) {
331
+ let added = 0;
332
+ let removed = 0;
333
+ for (const k of next)
334
+ if (!prev.has(k))
335
+ added++;
336
+ for (const k of prev)
337
+ if (!next.has(k))
338
+ removed++;
339
+ return { added, removed };
215
340
  }
216
341
  function clamp(n, lo, hi) {
217
342
  if (!Number.isFinite(n))
@@ -225,4 +350,15 @@ function clamp(n, lo, hi) {
225
350
  export function __resetReviewWatchesForTests() {
226
351
  watches.clear();
227
352
  }
353
+ /**
354
+ * Test-only exports: snapshot + diff helpers for the 1.9 signature
355
+ * deepening. Keeping these accessible avoids over-loading the public
356
+ * tool surface with internals while still letting tests assert on the
357
+ * specific shape and per-bucket counts the agent will see.
358
+ */
359
+ export const __internal = {
360
+ snapshotOf,
361
+ signatureOf,
362
+ diffSnapshots,
363
+ };
228
364
  //# sourceMappingURL=reviewWatch.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"reviewWatch.js","sourceRoot":"","sources":["../../../src/mcp/tools/reviewWatch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAuDrD,MAAM,OAAO,GAAG,IAAI,GAAG,EAAsB,CAAC;AAC9C,MAAM,kBAAkB,GAAG,EAAE,CAAC;AAC9B,MAAM,cAAc,GAAG,CAAC,CAAC;AACzB,MAAM,cAAc,GAAG,GAAG,CAAC;AAE3B,MAAM,CAAC,MAAM,eAAe,GAAY;IACtC,IAAI,EAAE,uBAAuB;IAC7B,WAAW,EACT,gYAAgY;IAClY,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,MAAM,EAAE;gBACN,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,CAAC;gBAC/B,WAAW,EACT,4HAA4H;aAC/H;YACD,IAAI,EAAE;gBACJ,IAAI,EAAE,QAAQ;gB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,WAAW,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;AACrD,CAAC;AAED,SAAS,aAAa,CAAC,IAAiB,EAAE,IAAiB;IACzD,IAAI,KAAK,GAAG,CAAC,CAAC;IACd,IAAI,OAAO,GAAG,CAAC,CAAC;IAChB,KAAK,MAAM,CAAC,IAAI,IAAI;QAAE,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;YAAE,KAAK,EAAE,CAAC;IAChD,KAAK,MAAM,CAAC,IAAI,IAAI;QAAE,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;YAAE,OAAO,EAAE,CAAC;IAClD,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC;AAC5B,CAAC;AAED,SAAS,KAAK,CAAC,CAAS,EAAE,EAAU,EAAE,EAAU;IAC9C,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC;QAAE,OAAO,EAAE,CAAC;IACnC,OAAO,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC;AACvC,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,4BAA4B;IAC1C,OAAO,CAAC,KAAK,EAAE,CAAC;AAClB,CAAC;AAED;;;;;GAKG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,UAAU;IACV,WAAW;IACX,aAAa;CACd,CAAC"}
package/dist/mcp/tools.js CHANGED
@@ -35,6 +35,7 @@ import { applyFixTool } from './tools/applyFix.js';
35
35
  import { taintTool } from './tools/taint.js';
36
36
  import { costSummaryTool } from './tools/costSummary.js';
37
37
  import { reviewWatchTool } from './tools/reviewWatch.js';
38
+ import { pluginTool } from './tools/plugin.js';
38
39
  const tools = [
39
40
  analyzeTool,
40
41
  doctorTool,
@@ -63,6 +64,7 @@ const tools = [
63
64
  taintTool,
64
65
  costSummaryTool,
65
66
  reviewWatchTool,
67
+ pluginTool,
66
68
  ];
67
69
  export function getToolDefinitions() {
68
70
  return tools.map(({ name, description, inputSchema }) => ({ name, description, inputSchema }));
@@ -1 +1 @@
1
- {"version":3,"file":"tools.js","sourceRoot":"","sources":["../../src/mcp/tools.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC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C,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAM/C,MAAM,KAAK,GAAc;IACvB,WAAW;IACX,UAAU;IACV,YAAY;IACZ,WAAW;IACX,QAAQ;IACR,aAAa;IACb,gBAAgB;IAChB,YAAY;IACZ,SAAS;IACT,WAAW;IACX,YAAY;IACZ,SAAS;IACT,YAAY;IACZ,cAAc;IACd,UAAU;IACV,UAAU;IACV,cAAc;IACd,gBAAgB;IAChB,UAAU;IACV,UAAU;IACV,WAAW;IACX,UAAU;IACV,kBAAkB;IAClB,YAAY;IACZ,SAAS;IACT,eAAe;IACf,eAAe;IACf,UAAU;CACX,CAAC;AAEF,MAAM,UAAU,kBAAkB;IAChC,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,WAAW,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,WAAW,EAAE,WAAW,EAAE,CAAC,CAAC,CAAC;AACjG,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,IAAY;IACzC,OAAO,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,IAAI,CAAC,EAAE,OAAO,CAAC;AACrD,CAAC"}
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "projscan",
3
- "version": "1.8.1",
3
+ "version": "1.10.0",
4
4
  "mcpProtocolVersion": "2025-03-26",
5
- "generatedAt": "2026-05-08T20:06:22.086Z",
6
- "toolCount": 27,
5
+ "generatedAt": "2026-05-12T21:51:14.985Z",
6
+ "toolCount": 28,
7
7
  "tools": [
8
8
  {
9
9
  "name": "projscan_analyze",
@@ -334,7 +334,7 @@
334
334
  },
335
335
  {
336
336
  "name": "projscan_review",
337
- "description": "One-call PR review. Combines projscan_pr_diff + per-changed-file risk score + new/expanded import cycles + risky function additions + dependency changes, plus a verdict (\"ok\" | \"review\" | \"block\") with a one-line summary. Use when an agent is asked \"is this PR safe to merge?\" Defaults: base=origin/main (falls back to main/master/HEAD~1), head=HEAD. Pass `max_cost_tokens` (1.5+) to get a budget-shaped response: <3000 returns verdict-only, <7000 returns a summary, otherwise the full review.",
337
+ "description": "One-call PR review. Combines projscan_pr_diff + per-changed-file risk score + new/expanded import cycles + risky function additions + dependency changes, plus a verdict (\"ok\" | \"review\" | \"block\") with a one-line summary. Use when an agent is asked \"is this PR safe to merge?\" Defaults: base=origin/main (falls back to main/master/HEAD~1), head=HEAD. Pass `max_cost_tokens` (1.5+) to get a budget-shaped response: <3000 returns verdict-only, <7000 returns a summary, otherwise the full review. 1.9+: pass `intent` (a free-text PR description like \"refactor auth middleware\" or \"docs: fix codex setup\") to get an intent-grounded review — each finding is labelled expected / unexpected / out-of-scope against the stated intent. Verdict is unchanged; this is an extra narration layer.",
338
338
  "inputSchema": {
339
339
  "type": "object",
340
340
  "properties": {
@@ -357,6 +357,10 @@
357
357
  "package": {
358
358
  "type": "string",
359
359
  "description": "Optional. Workspace package name to scope all sections of the review to a single package."
360
+ },
361
+ "intent": {
362
+ "type": "string",
363
+ "description": "1.9+ — free-text description of what the PR is trying to do. projscan parses this into an action (feature / fix / refactor / perf / test / docs / chore / remove) plus scope tokens, then labels every finding as expected / unexpected / out-of-scope against that intent. Returns an `intent` echo and an `intentAnalysis` summary; per-finding labels appear as `intentAlignment` on each changedFile / riskyFunction / newCycle / newTaintFlow / dependencyChange. Does NOT change the verdict (verdict stays structural)."
360
364
  }
361
365
  }
362
366
  }
@@ -548,7 +552,7 @@
548
552
  "forget",
549
553
  "forget-hotspot"
550
554
  ],
551
- "description": "Subaction. \"current\" returns aggregate counts. \"stable\" returns long-running rules with a config-snippet suggestion. \"runs\" returns every tracked rule. \"accepted\" (1.5+) returns files Project Memory marks as accepted load-bearing debt (top-K hotspot for ≥ 5 runs over ≥ 7 days without improving). \"confidence\" (1.7+) returns each tracked rule labelled high/medium/low based on observed fix-rate — high = user has fixed instances; low = persistently ignored. \"forget\" drops one rule. \"forget-hotspot\" drops one file from hotspot memory."
555
+ "description": "Subaction. \"current\" returns aggregate counts. \"stable\" returns long-running rules with a config-snippet suggestion. \"runs\" returns every tracked rule. \"accepted\" (1.5+) returns files Project Memory marks as accepted load-bearing debt (top-K hotspot for ≥ 5 runs over ≥ 7 days without improving). \"confidence\" (1.7+) returns each tracked rule labelled high/medium/low based on observed fix-rate — high = user has fixed instances; low = persistently ignored. 1.9+: each rule also carries a `drift` label (stable / noisy / cry-wolf) so the agent can deprioritize rules the user has effectively classified as false positives. \"forget\" drops one rule. \"forget-hotspot\" drops one file from hotspot memory."
552
556
  },
553
557
  "rule": {
554
558
  "type": "string",
@@ -645,20 +649,38 @@
645
649
  },
646
650
  {
647
651
  "name": "projscan_cost_summary",
648
- "description": "Aggregate token-cost analytics from the current session's tool-call history. Returns total tokens spent, top spenders, per-tool typical/p95 estimates, and a static expected-cost catalog so the agent can budget pre-call. Pairs with the `_cost` sidecar attached to every tool result. Read-only. Note: the session event log is bounded at 500 entries, so the view reflects recent activity rather than the full lifetime of the session — for long-running sessions, older calls are dropped.",
652
+ "description": "Aggregate token-cost analytics from the current session's tool-call history. action:\"snapshot\" (default) returns total tokens spent, top spenders, per-tool typical/p95 estimates, and a static expected-cost catalog so the agent can budget pre-call. 1.10+: action:\"start_stream\" / \"stop_stream\" / \"list_streams\" turns this into a live cost dashboard — the server polls the session log on an interval and emits notifications/projscan/cost_delta whenever new tool calls have accrued, with the per-tool deltas and the new cumulative totals inline. Pairs with the `_cost` sidecar attached to every tool result. Read-only. Note: the session event log is bounded at 500 entries — for long-running sessions, older calls are dropped from the snapshot.",
649
653
  "inputSchema": {
650
654
  "type": "object",
651
655
  "properties": {
656
+ "action": {
657
+ "type": "string",
658
+ "enum": [
659
+ "snapshot",
660
+ "start_stream",
661
+ "stop_stream",
662
+ "list_streams"
663
+ ],
664
+ "description": "\"snapshot\" (default) returns the current aggregate. \"start_stream\" begins a live cost-delta watch. \"stop_stream\" cancels by stream_id. \"list_streams\" enumerates active streams."
665
+ },
652
666
  "top": {
653
667
  "type": "number",
654
- "description": "Optional. Number of top spenders to return. Default: 10."
668
+ "description": "Optional. Number of top spenders to return. Default: 10. (snapshot + start_stream)"
669
+ },
670
+ "interval_seconds": {
671
+ "type": "number",
672
+ "description": "Stream poll interval in seconds. Default: 10. Min: 2, max: 600. (start_stream only)"
673
+ },
674
+ "stream_id": {
675
+ "type": "string",
676
+ "description": "Stream identifier returned by a previous start_stream. (stop_stream only)"
655
677
  }
656
678
  }
657
679
  }
658
680
  },
659
681
  {
660
682
  "name": "projscan_review_watch",
661
- "description": "Long-running PR review. Polls a base+head ref pair on an interval and emits a notifications/projscan/pr_changed notification whenever the review verdict, SHAs, flow count, or risky-function set changes. Pairs with projscan_review (one-shot) — use this when an agent wants to react to pushes on a PR without re-asking. Actions: start (returns initial review + watchId) / stop / list.",
683
+ "description": "Long-running PR review. Polls a base+head ref pair on an interval and emits a notifications/projscan/pr_changed notification whenever the review verdict, SHAs, cycle set, dep changes, taint flows, or risky-function set changes. 1.9+: the notification carries a structured `delta` describing exactly which buckets moved (verdict/baseSha/headSha/changedFiles/cycles/risky/taint/deps) and counts of newly-appearing items per bucket, so agents can skip work they do not need. Pairs with projscan_review (one-shot) — use this when an agent wants to react to pushes on a PR without re-asking. Actions: start (returns initial review + watchId) / stop / list.",
662
684
  "inputSchema": {
663
685
  "type": "object",
664
686
  "properties": {
@@ -689,6 +711,27 @@
689
711
  }
690
712
  }
691
713
  }
714
+ },
715
+ {
716
+ "name": "projscan_plugin",
717
+ "description": "1.10+ preview. Discover and validate third-party analyzer plugins under .projscan-plugins/. Gated by the PROJSCAN_PLUGINS_PREVIEW=1 env flag; the schema is preview-only and may shift before 2.0. Use action:\"list\" to see what is discoverable today, action:\"validate\" to check a manifest before committing it.",
718
+ "inputSchema": {
719
+ "type": "object",
720
+ "properties": {
721
+ "action": {
722
+ "type": "string",
723
+ "enum": [
724
+ "list",
725
+ "validate"
726
+ ],
727
+ "description": "\"list\" enumerates manifests under <root>/.projscan-plugins/ with discovery status. \"validate\" lints a manifest at the given path against the 1.10 schema."
728
+ },
729
+ "manifest_path": {
730
+ "type": "string",
731
+ "description": "\"validate\" only — repo-relative or absolute path to a *.projscan-plugin.json file."
732
+ }
733
+ }
734
+ }
692
735
  }
693
736
  ]
694
737
  }
package/dist/types.d.ts CHANGED
@@ -551,6 +551,8 @@ export interface ReviewFile {
551
551
  importsAdded: number;
552
552
  /** Number of imports removed. */
553
553
  importsRemoved: number;
554
+ /** 1.9+ — set when `projscan_review` was called with an `intent` arg. Absent otherwise. */
555
+ intentAlignment?: 'expected' | 'unexpected' | 'out-of-scope' | 'unknown';
554
556
  }
555
557
  /**
556
558
  * A circular import that exists at head and either didn't exist at base or
@@ -565,6 +567,8 @@ export interface ReviewCycle {
565
567
  * file added to an existing cycle.
566
568
  */
567
569
  classification: 'new' | 'expanded';
570
+ /** 1.9+ — set when `projscan_review` was called with an `intent` arg. Absent otherwise. */
571
+ intentAlignment?: 'expected' | 'unexpected' | 'out-of-scope' | 'unknown';
568
572
  }
569
573
  /**
570
574
  * A function whose CC newly crossed a worry threshold (>= 10) at head, or
@@ -580,6 +584,8 @@ export interface ReviewFunction {
580
584
  baseCc: number | null;
581
585
  /** Why this function shows up. */
582
586
  reason: 'added' | 'jumped' | 'crossed-threshold';
587
+ /** 1.9+ — set when `projscan_review` was called with an `intent` arg. Absent otherwise. */
588
+ intentAlignment?: 'expected' | 'unexpected' | 'out-of-scope' | 'unknown';
583
589
  }
584
590
  /**
585
591
  * 1.6+ — A taint flow that is NEW at head (not present at base). Mirrors
@@ -596,6 +602,8 @@ export interface ReviewTaintFlow {
596
602
  pathLength: number;
597
603
  /** First and last files in the path; same value when length = 1. */
598
604
  files: string[];
605
+ /** 1.9+ — set when `projscan_review` was called with an `intent` arg. Absent otherwise. */
606
+ intentAlignment?: 'expected' | 'unexpected' | 'out-of-scope' | 'unknown';
599
607
  }
600
608
  /** Workspace-package-scoped dependency change. Aggregates root + workspaces. */
601
609
  export interface ReviewDependencyChange {
@@ -618,6 +626,8 @@ export interface ReviewDependencyChange {
618
626
  to: string;
619
627
  kind: 'dep' | 'dev';
620
628
  }>;
629
+ /** 1.9+ — set when `projscan_review` was called with an `intent` arg. Absent otherwise. */
630
+ intentAlignment?: 'expected' | 'unexpected' | 'out-of-scope' | 'unknown';
621
631
  }
622
632
  /**
623
633
  * 1.5+ — `projscan_review` can shape its response at three tiers based
@@ -664,6 +674,31 @@ export interface ReviewReport {
664
674
  * report is returned without budget shaping.
665
675
  */
666
676
  tier?: ReviewTier;
677
+ /**
678
+ * 1.9+ — the parsed intent the agent passed (if any). Echo of the
679
+ * raw string + the parser's classified action + extracted scope
680
+ * tokens. Absent when `intent` arg wasn't provided.
681
+ */
682
+ intent?: {
683
+ raw: string;
684
+ action: 'feature' | 'fix' | 'refactor' | 'perf' | 'test' | 'docs' | 'chore' | 'remove' | 'unknown';
685
+ scopeTokens: string[];
686
+ };
687
+ /**
688
+ * 1.9+ — per-alignment totals across all findings + a small sample
689
+ * of "notable" (unexpected / out-of-scope) findings. Absent when
690
+ * no intent was provided. Verdict is NOT affected by intent —
691
+ * verdict stays structural.
692
+ */
693
+ intentAnalysis?: {
694
+ totals: Record<'expected' | 'unexpected' | 'out-of-scope' | 'unknown', number>;
695
+ notable: Array<{
696
+ kind: 'file' | 'function' | 'cycle' | 'taint' | 'dependency';
697
+ label: string;
698
+ alignment: 'expected' | 'unexpected' | 'out-of-scope' | 'unknown';
699
+ reason: string;
700
+ }>;
701
+ };
667
702
  }
668
703
  /**
669
704
  * One reachable file in an impact analysis. `distance` is BFS-hops from the
@@ -33,6 +33,21 @@ export async function getChangedFiles(rootPath, explicitBaseRef) {
33
33
  return { available: true, baseRef: ref, files };
34
34
  }
35
35
  catch (err) {
36
+ // 1.10+ — surface stdio-too-large explicitly instead of letting it
37
+ // fall through to the generic "no usable base ref" path. The ref
38
+ // exists; the diff against it is just too big to fit in our 10MB
39
+ // buffer (typical when HEAD has diverged from the base by 100K+
40
+ // files). The user needs a closer base ref or a streaming reader,
41
+ // not a missing-ref diagnosis.
42
+ if (isMaxBufferError(err)) {
43
+ return {
44
+ available: false,
45
+ reason: `git diff against "${ref}" exceeded the 10MB output buffer ` +
46
+ '(typically > 100K files changed). Use --base-ref to pin a closer ref.',
47
+ baseRef: null,
48
+ files: [],
49
+ };
50
+ }
36
51
  lastError = err instanceof Error ? err.message : String(err);
37
52
  }
38
53
  }
@@ -110,4 +125,14 @@ async function statusNames(rootPath) {
110
125
  function normalizePath(p) {
111
126
  return p.split(path.sep).join('/');
112
127
  }
128
+ function isMaxBufferError(err) {
129
+ if (!err || typeof err !== 'object')
130
+ return false;
131
+ const e = err;
132
+ if (e.code === 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER')
133
+ return true;
134
+ if (typeof e.message === 'string' && /maxBuffer length exceeded/i.test(e.message))
135
+ return true;
136
+ return false;
137
+ }
113
138
  //# sourceMappingURL=changedFiles.js.map