projscan 4.11.1 → 4.12.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.
@@ -18,6 +18,10 @@ export const assessTool = {
18
18
  type: 'number',
19
19
  description: 'Maximum Proof Cards to return. Default: 5, max: 25.',
20
20
  },
21
+ feedback_path: {
22
+ type: 'string',
23
+ description: 'Optional local feedback artifact path to apply as trust memory.',
24
+ },
21
25
  max_tokens: {
22
26
  type: 'number',
23
27
  description: 'Cap the response to roughly this many tokens.',
@@ -31,6 +35,7 @@ export const assessTool = {
31
35
  maxCards: typeof args.max_cards === 'number' && Number.isFinite(args.max_cards)
32
36
  ? args.max_cards
33
37
  : undefined,
38
+ feedbackPath: typeof args.feedback_path === 'string' ? args.feedback_path : undefined,
34
39
  }),
35
40
  }),
36
41
  };
@@ -1 +1 @@
1
- {"version":3,"file":"assess.js","sourceRoot":"","sources":["../../../src/mcp/tools/assess.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAIrD,MAAM,YAAY,GAAG,IAAI,GAAG,CAAa,CAAC,UAAU,EAAE,WAAW,EAAE,gBAAgB,CAAC,CAAC,CAAC;AAEtF,MAAM,CAAC,MAAM,UAAU,GAAY;IACjC,IAAI,EAAE,iBAAiB;IACvB,WAAW,EACT,uKAAuK;IACzK,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,IAAI,EAAE;gBACJ,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,0EAA0E;aACxF;YACD,IAAI,EAAE;gBACJ,IAAI,EAAE,QAAQ;gBACd,WAAW,EACT,uGAAuG;aAC1G;YACD,SAAS,EAAE;gBACT,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,qDAAqD;aACnE;YACD,UAAU,EAAE;gBACV,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,+CAA+C;aAC7D;SACF;KACF;IACD,OAAO,EAAE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;gBACd,WAAW,EAAE,qDAAqD;aACnE;YACD,aAAa,EAAE;gBACb,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,iEAAiE;aAC/E;YACD,UAAU,EAAE;gBACV,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,+CAA+C;aAC7D;SACF;KACF;IACD,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,CAAC,CAAC;QAClC,MAAM,EAAE,MAAM,aAAa,CAAC,QAAQ,EAAE;YACpC,IAAI,EAAE,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS;YAC3D,IAAI,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC;YAC1B,QAAQ,EACN,OAAO,IAAI,CAAC,SAAS,KAAK,QAAQ,IAAI,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,SAAS,CAAC;gBACnE,CAAC,CAAC,IAAI,CAAC,SAAS;gBAChB,CAAC,CAAC,SAAS;YACf,YAAY,EAAE,OAAO,IAAI,CAAC,aAAa,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,SAAS;SACtF,CAAC;KACH,CAAC;CACH,CAAC;AAEF,SAAS,SAAS,CAAC,KAAc;IAC/B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,YAAY,CAAC,GAAG,CAAC,KAAmB,CAAC;QACvE,CAAC,CAAE,KAAoB;QACvB,CAAC,CAAC,SAAS,CAAC;AAChB,CAAC"}
@@ -1,23 +1,23 @@
1
1
  {
2
2
  "bomFormat": "CycloneDX",
3
3
  "specVersion": "1.5",
4
- "serialNumber": "urn:uuid:ac1a1fd3-2c78-4830-8579-508d0b0ff5e9",
4
+ "serialNumber": "urn:uuid:ca5d65db-a8a8-4950-9238-f24ca99d602b",
5
5
  "version": 1,
6
6
  "metadata": {
7
- "timestamp": "2026-06-22T06:58:43.839Z",
7
+ "timestamp": "2026-06-22T20:54:55.115Z",
8
8
  "tools": [
9
9
  {
10
10
  "vendor": "projscan",
11
11
  "name": "projscan-sbom-generator",
12
- "version": "4.11.1"
12
+ "version": "4.12.0"
13
13
  }
14
14
  ],
15
15
  "component": {
16
16
  "type": "application",
17
- "bom-ref": "pkg:npm/projscan@4.11.1",
17
+ "bom-ref": "pkg:npm/projscan@4.12.0",
18
18
  "name": "projscan",
19
- "version": "4.11.1",
20
- "purl": "pkg:npm/projscan@4.11.1"
19
+ "version": "4.12.0",
20
+ "purl": "pkg:npm/projscan@4.12.0"
21
21
  }
22
22
  },
23
23
  "components": [
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "projscan",
3
- "version": "4.11.1",
3
+ "version": "4.12.0",
4
4
  "mcpProtocolVersion": null,
5
- "generatedAt": "2026-06-22T06:58:50.868Z",
5
+ "generatedAt": "2026-06-22T20:55:02.250Z",
6
6
  "toolCount": 47,
7
7
  "tools": [
8
8
  {
@@ -1019,6 +1019,10 @@
1019
1019
  "type": "number",
1020
1020
  "description": "Maximum Proof Cards to return. Default: 5, max: 25."
1021
1021
  },
1022
+ "feedback_path": {
1023
+ "type": "string",
1024
+ "description": "Optional local feedback artifact path to apply as trust memory."
1025
+ },
1022
1026
  "max_tokens": {
1023
1027
  "type": "number",
1024
1028
  "description": "Cap the response to roughly this many tokens."
@@ -45,6 +45,35 @@ export interface AssessSuppression {
45
45
  export interface AssessFeedback {
46
46
  command: string;
47
47
  }
48
+ export type AssessEvidenceStrengthLevel = 'strong' | 'moderate' | 'thin';
49
+ export type AssessTrustMemoryStatus = 'none' | 'helpful' | 'noisy' | 'suppressed' | 'mixed';
50
+ export interface AssessEvidenceStrength {
51
+ level: AssessEvidenceStrengthLevel;
52
+ score: number;
53
+ sources: string[];
54
+ reasons: string[];
55
+ }
56
+ export interface AssessRanking {
57
+ rank: number;
58
+ score: number;
59
+ reasons: string[];
60
+ }
61
+ export interface AssessTrustMemory {
62
+ status: AssessTrustMemoryStatus;
63
+ summary: string;
64
+ signals: string[];
65
+ feedbackCommand: string;
66
+ }
67
+ export interface AssessAgentHandoff {
68
+ title: string;
69
+ problem: string;
70
+ scope: string[];
71
+ files: string[];
72
+ constraints: string[];
73
+ verificationCommands: string[];
74
+ doneCriteria: string[];
75
+ rollback: string;
76
+ }
48
77
  export interface AssessProofCard {
49
78
  id: string;
50
79
  priority: WorkplanPriority;
@@ -57,6 +86,12 @@ export interface AssessProofCard {
57
86
  recommendedFix: AssessRecommendedFix;
58
87
  verification: AssessVerification;
59
88
  confidence: AssessConfidence;
89
+ confidenceReason: string;
90
+ evidenceStrength: AssessEvidenceStrength;
91
+ evidenceGaps: string[];
92
+ ranking: AssessRanking;
93
+ trustMemory: AssessTrustMemory;
94
+ agentHandoff: AssessAgentHandoff;
60
95
  suppression: AssessSuppression;
61
96
  feedback: AssessFeedback;
62
97
  riskDelta: RiskDeltaSnapshot;
@@ -24,6 +24,18 @@ export interface SimulateRolloutStep {
24
24
  detail: string;
25
25
  commands: string[];
26
26
  }
27
+ export type SimulateAlternativeId = 'bounded-extraction' | 'test-first' | 'leave-unchanged';
28
+ export interface SimulateAlternative {
29
+ id: SimulateAlternativeId;
30
+ title: string;
31
+ summary: string;
32
+ riskDelta: number;
33
+ blastRadius: number;
34
+ confidence: SimulateConfidence;
35
+ proofCommands: string[];
36
+ reason: string;
37
+ tradeoffs: string[];
38
+ }
27
39
  export interface SimulateReport {
28
40
  schemaVersion: 1;
29
41
  plan: string;
@@ -37,5 +49,7 @@ export interface SimulateReport {
37
49
  rolloutPlan: SimulateRolloutStep[];
38
50
  proofCommands: string[];
39
51
  evidence: SimulateEvidence[];
52
+ alternatives: SimulateAlternative[];
53
+ recommendedAlternative: SimulateAlternative;
40
54
  warnings: string[];
41
55
  }
package/docs/GUIDE.md CHANGED
@@ -123,12 +123,10 @@ and a before-edit gate instead of a free-form plan.
123
123
  ### Before handoff or commit
124
124
 
125
125
  ```bash
126
- projscan bug-hunt --format json
126
+ projscan start --intent "is this safe to commit?"
127
+ projscan assess --mode fix-first --format markdown
127
128
  projscan preflight --mode before_commit --format json
128
129
  projscan evidence-pack --pr-comment
129
- projscan assess --goal "make this repo safer to ship this week"
130
- projscan assess --mode fix-first --format markdown
131
- projscan simulate --plan "split bugHunt.ts into ranking, evidence, and output modules"
132
130
  ```
133
131
 
134
132
  Success criteria: concrete fix targets, manual review gates, and proof commands
@@ -137,13 +135,26 @@ are separated before a reviewer sees the work.
137
135
  `projscan assess` turns those same signals into Proof Cards with evidence,
138
136
  impact, a safe change shape, verification commands, feedback or suppression
139
137
  guidance, and a risk delta. Add `--baseline previous-assess.json` to compare
140
- the current risk delta against a prior run. It does not release, tag, publish,
141
- or deploy.
138
+ the current risk delta against a prior run. Add `--feedback
139
+ .projscan-feedback.json` when accepted recommendations, noisy findings, false
140
+ positives, or suppressions should affect future ranking. The Markdown output
141
+ shows evidence strength, confidence reason, ranking reasons, trust memory,
142
+ evidence gaps, and an AgentLoopKit handoff packet. It does not release, tag,
143
+ publish, or deploy.
142
144
 
143
145
  `projscan simulate --plan "<change plan>"` is the next step when the safest
144
146
  fix shape is a refactor, extraction, or module split. It predicts likely files,
145
147
  affected tests, contract surfaces, rollout steps, proof commands, and projected
146
- risk delta from local evidence. It is read-only and does not execute the plan.
148
+ risk delta from local evidence. It compares bounded extraction, test-first, and
149
+ leave-unchanged alternatives, then names the recommended option. It is read-only
150
+ and does not execute the plan.
151
+
152
+ Weekly or before a larger refactor, run the broader assessment and simulator:
153
+
154
+ ```bash
155
+ projscan assess --goal "make this repo safer to ship this week"
156
+ projscan simulate --plan "split bugHunt.ts into ranking, evidence, and output modules"
157
+ ```
147
158
 
148
159
  ### Before release-candidate review
149
160
 
@@ -248,8 +259,8 @@ When the agent first opens a repo, or before starting a refactor, the question i
248
259
  - **`projscan_bug_hunt` / `projscan bug-hunt`** — bug-hunt action queue. Combines doctor issues, preflight, hotspots, and session coordination into ranked actions with verification commands; release-scale-only findings print as manual review/sign-off work while preserving JSON verdict compatibility, and pure hotspot churn stays as watchlist/top-suspect evidence when health and gates are clean.
249
260
  - **`projscan_agent_brief` / `projscan agent-brief`** — compact next-agent context packet with focus items, repo context, coordination hints, guardrails, and suggested next actions.
250
261
  - **`projscan_quality_scorecard` / `projscan quality-scorecard`** — dimensioned quality view across health, security, tests, maintainability, coordination, top risks, and verification commands.
251
- - **`projscan_assess` / `projscan assess`** — proof-first assessment. Composes quality-scorecard, bug-hunt, and preflight into Proof Cards with local evidence, impact, a safe fix shape, verification commands, feedback or suppression guidance, and risk delta. Use `projscan assess --goal "make this repo safer to ship this week"` for a broad weekly pass, `projscan assess --mode fix-first --format markdown` when you want one or two next actions instead of a long list, or `--baseline previous-assess.json` to compare against a prior assessment. The command is read-only and does not release, tag, publish, or deploy.
252
- - **`projscan_simulate` / `projscan simulate`** — risk delta simulator. Evaluates a proposed change plan before editing and returns likely touched files, affected tests, contract surfaces, rollout steps, proof commands, confidence, and projected before/after risk. Use `projscan simulate --plan "split bugHunt.ts into ranking, evidence, and output modules"` before doing a refactor. The command is read-only and does not execute the plan.
262
+ - **`projscan_assess` / `projscan assess`** — proof-first assessment. Composes quality-scorecard, bug-hunt, and preflight into Proof Cards with local evidence, impact, a safe fix shape, verification commands, feedback or suppression guidance, and risk delta. Proof Cards include evidence strength, confidence reason, ranking reasons, trust memory, evidence gaps, and an AgentLoopKit handoff packet. Use `projscan assess --goal "make this repo safer to ship this week"` for a broad weekly pass, `projscan assess --mode fix-first --format markdown` when you want one or two next actions instead of a long list, `--feedback .projscan-feedback.json` when local reviewer memory should affect ranking, or `--baseline previous-assess.json` to compare against a prior assessment. The command is read-only and does not release, tag, publish, or deploy.
263
+ - **`projscan_simulate` / `projscan simulate`** — risk delta simulator. Evaluates a proposed change plan before editing and returns likely touched files, affected tests, contract surfaces, rollout steps, proof commands, confidence, projected before/after risk, alternatives, and a recommended option. Use `projscan simulate --plan "split bugHunt.ts into ranking, evidence, and output modules"` before doing a refactor. The command is read-only and does not execute the plan.
253
264
  - **`projscan_understand` / `projscan understand`** — cited repo-comprehension surface. Returns repo maps, runtime flow maps, contract maps, change-readiness guidance, verification tiers, unknowns, read-first files, and exact next commands.
254
265
  - **`projscan_adoption` / `projscan init team` / `projscan init mcp` / `projscan mcp doctor` / `projscan init policy` / `projscan init github-action` / `projscan recipes` / `projscan first-run` / `projscan telemetry` / `projscan dogfood`** — adoption layer. Returns MCP client config snippets, setup verification, policy starters, PR workflow scaffolding with validated PR comments and block-only enforcement, baseline memory, ownership routing, first-PR onboarding steps, repeatable team-bootstrap and PR-automation recipes, multi-repo dogfood evidence, measured reviewer feedback, default-off telemetry controls, adoption trial reports, and setup diagnostics.
255
266
  - **`projscan_release_train` / `projscan release-train`** — product-line readiness planner. Plans upcoming product lines with version, scope, readiness, and next-action evidence.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "projscan",
3
3
  "mcpName": "io.github.abhiyoheswaran1/projscan",
4
- "version": "4.11.1",
4
+ "version": "4.12.0",
5
5
  "description": "Local code intelligence for agent-assisted engineering. Focused daily workflows for repo orientation before edits, proof before handoff or commit, and release-candidate review, with AST-backed evidence through an MCP server and CLI. Runs locally by default.",
6
6
  "type": "module",
7
7
  "main": "./dist/index.js",