@in-the-loop-labs/pair-review 3.0.6 → 3.1.1
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/package.json +2 -1
- package/plugin/.claude-plugin/plugin.json +1 -1
- package/plugin-code-critic/.claude-plugin/plugin.json +1 -1
- package/plugin-code-critic/skills/analyze/references/level1-balanced.md +8 -0
- package/plugin-code-critic/skills/analyze/references/level1-fast.md +7 -0
- package/plugin-code-critic/skills/analyze/references/level1-thorough.md +8 -0
- package/plugin-code-critic/skills/analyze/references/level2-balanced.md +9 -0
- package/plugin-code-critic/skills/analyze/references/level2-fast.md +8 -0
- package/plugin-code-critic/skills/analyze/references/level2-thorough.md +9 -0
- package/plugin-code-critic/skills/analyze/references/level3-balanced.md +9 -0
- package/plugin-code-critic/skills/analyze/references/level3-fast.md +8 -0
- package/plugin-code-critic/skills/analyze/references/level3-thorough.md +9 -0
- package/plugin-code-critic/skills/analyze/references/orchestration-balanced.md +9 -0
- package/plugin-code-critic/skills/analyze/references/orchestration-fast.md +5 -0
- package/plugin-code-critic/skills/analyze/references/orchestration-thorough.md +9 -0
- package/public/css/analysis-config.css +103 -0
- package/public/css/pr.css +191 -4
- package/public/index.html +20 -0
- package/public/js/components/AIPanel.js +1 -1
- package/public/js/components/AdvancedConfigTab.js +87 -9
- package/public/js/components/AnalysisConfigModal.js +206 -5
- package/public/js/components/ChatPanel.js +22 -5
- package/public/js/components/CouncilProgressModal.js +241 -23
- package/public/js/components/TimeoutSelect.js +2 -0
- package/public/js/components/VoiceCentricConfigTab.js +183 -13
- package/public/js/index.js +119 -1
- package/public/js/local.js +166 -51
- package/public/js/modules/suggestion-manager.js +2 -1
- package/public/js/pr.js +71 -12
- package/public/js/repo-settings.js +2 -2
- package/public/local.html +32 -11
- package/public/pr.html +2 -0
- package/src/ai/analyzer.js +371 -111
- package/src/ai/claude-provider.js +2 -0
- package/src/ai/codex-provider.js +1 -1
- package/src/ai/copilot-provider.js +2 -0
- package/src/ai/executable-provider.js +538 -0
- package/src/ai/gemini-provider.js +2 -0
- package/src/ai/index.js +9 -1
- package/src/ai/pi-provider.js +10 -8
- package/src/ai/prompts/baseline/consolidation/balanced.js +54 -2
- package/src/ai/prompts/baseline/consolidation/fast.js +31 -1
- package/src/ai/prompts/baseline/consolidation/thorough.js +46 -3
- package/src/ai/prompts/baseline/level1/balanced.js +12 -0
- package/src/ai/prompts/baseline/level1/fast.js +11 -0
- package/src/ai/prompts/baseline/level1/thorough.js +12 -0
- package/src/ai/prompts/baseline/level2/balanced.js +13 -0
- package/src/ai/prompts/baseline/level2/fast.js +12 -0
- package/src/ai/prompts/baseline/level2/thorough.js +13 -0
- package/src/ai/prompts/baseline/level3/balanced.js +13 -0
- package/src/ai/prompts/baseline/level3/fast.js +12 -0
- package/src/ai/prompts/baseline/level3/thorough.js +13 -0
- package/src/ai/prompts/baseline/orchestration/balanced.js +15 -0
- package/src/ai/prompts/baseline/orchestration/fast.js +11 -0
- package/src/ai/prompts/baseline/orchestration/thorough.js +15 -0
- package/src/ai/prompts/render-for-skill.js +3 -0
- package/src/ai/prompts/shared/output-schema.js +8 -0
- package/src/ai/provider.js +91 -4
- package/src/chat/prompt-builder.js +39 -4
- package/src/chat/session-manager.js +32 -28
- package/src/config.js +15 -2
- package/src/database.js +59 -15
- package/src/git/base-branch.js +113 -29
- package/src/github/parser.js +1 -1
- package/src/local-review.js +15 -9
- package/src/local-scope.js +83 -0
- package/src/main.js +3 -2
- package/src/routes/analyses.js +34 -8
- package/src/routes/chat.js +15 -8
- package/src/routes/config.js +3 -120
- package/src/routes/councils.js +15 -6
- package/src/routes/executable-analysis.js +494 -0
- package/src/routes/local.js +152 -15
- package/src/routes/mcp.js +9 -4
- package/src/routes/pr.js +166 -29
- package/src/routes/reviews.js +31 -5
- package/src/routes/shared.js +72 -5
- package/src/routes/worktrees.js +4 -2
- package/src/utils/comment-formatter.js +28 -11
- package/src/utils/instructions.js +22 -8
- package/src/utils/logger.js +20 -10
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@in-the-loop-labs/pair-review",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.1.1",
|
|
4
4
|
"description": "Your AI-powered code review partner - Close the feedback loop with AI coding agents",
|
|
5
5
|
"main": "src/server.js",
|
|
6
6
|
"bin": {
|
|
@@ -65,6 +65,7 @@
|
|
|
65
65
|
"@octokit/rest": "^19.0.11",
|
|
66
66
|
"better-sqlite3": "^11.8.1",
|
|
67
67
|
"express": "^4.18.2",
|
|
68
|
+
"glob": "^13.0.6",
|
|
68
69
|
"markdown-it": "^13.0.2",
|
|
69
70
|
"open": "^9.1.0",
|
|
70
71
|
"simple-git": "^3.19.1",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pair-review",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.1.1",
|
|
4
4
|
"description": "pair-review app integration — Open PRs and local changes in the pair-review web UI, run server-side AI analysis, and address review feedback. Requires the pair-review MCP server.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "in-the-loop-labs",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "code-critic",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.1.1",
|
|
4
4
|
"description": "AI-powered code review analysis — Run three-level AI analysis and implement-review-fix loops directly in your coding agent. Works standalone, no server required.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "in-the-loop-labs",
|
|
@@ -72,6 +72,13 @@ Identify the following in changed code:
|
|
|
72
72
|
|
|
73
73
|
Do NOT modify files or run write commands. Analyze and report only.
|
|
74
74
|
|
|
75
|
+
### Severity Classification
|
|
76
|
+
Assign a severity to each suggestion (except praise):
|
|
77
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
78
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
79
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
80
|
+
Omit severity for praise items.
|
|
81
|
+
|
|
75
82
|
## Output Format
|
|
76
83
|
|
|
77
84
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -83,6 +90,7 @@ Do NOT modify files or run write commands. Analyze and report only.
|
|
|
83
90
|
"line": 42,
|
|
84
91
|
"old_or_new": "NEW",
|
|
85
92
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
93
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
86
94
|
"title": "Brief title",
|
|
87
95
|
"description": "Detailed explanation",
|
|
88
96
|
"suggestion": "How to fix/improve (omit for praise items)",
|
|
@@ -59,6 +59,12 @@ ONLY suggest for files in this list:
|
|
|
59
59
|
## Commands (READ-ONLY)
|
|
60
60
|
Annotated diff tool, `cat -n`, ls, find, grep. Do NOT modify files.
|
|
61
61
|
|
|
62
|
+
### Severity
|
|
63
|
+
Assign severity to each suggestion (omit for praise):
|
|
64
|
+
- **critical**: Production incidents, crashes, security vulnerabilities, data corruption/loss, race conditions, breaking changes, test failures
|
|
65
|
+
- **medium**: Degraded functionality, missing error handling, missing validation, missing/poor test coverage
|
|
66
|
+
- **minor**: Code quality, docs gaps, minor optimizations
|
|
67
|
+
|
|
62
68
|
## Output Format
|
|
63
69
|
|
|
64
70
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -70,6 +76,7 @@ Annotated diff tool, `cat -n`, ls, find, grep. Do NOT modify files.
|
|
|
70
76
|
"line": 42,
|
|
71
77
|
"old_or_new": "NEW",
|
|
72
78
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
79
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
73
80
|
"title": "Brief title",
|
|
74
81
|
"description": "Explanation",
|
|
75
82
|
"suggestion": "How to fix (omit for praise)",
|
|
@@ -117,6 +117,13 @@ Your role is strictly to analyze and report findings.
|
|
|
117
117
|
|
|
118
118
|
Note: You may optionally use parallel read-only Tasks to analyze different parts of the changes if that would be helpful for a thorough analysis.
|
|
119
119
|
|
|
120
|
+
### Severity Classification
|
|
121
|
+
Assign a severity to each suggestion (except praise):
|
|
122
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
123
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
124
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
125
|
+
Omit severity for praise items.
|
|
126
|
+
|
|
120
127
|
## Output Format
|
|
121
128
|
|
|
122
129
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -129,6 +136,7 @@ Output JSON with this structure:
|
|
|
129
136
|
"line": 42,
|
|
130
137
|
"old_or_new": "NEW",
|
|
131
138
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
139
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
132
140
|
"title": "Brief title",
|
|
133
141
|
"description": "Detailed explanation",
|
|
134
142
|
"suggestion": "How to fix/improve (omit this field for praise items - no action needed)",
|
|
@@ -74,6 +74,13 @@ Do NOT modify files. Your role is strictly to analyze and report findings.
|
|
|
74
74
|
|
|
75
75
|
Note: You may use parallel read-only Tasks to examine multiple files simultaneously.
|
|
76
76
|
|
|
77
|
+
### Severity Classification
|
|
78
|
+
Assign a severity to each suggestion (except praise):
|
|
79
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
80
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
81
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
82
|
+
Omit severity for praise items.
|
|
83
|
+
|
|
77
84
|
## Output Format
|
|
78
85
|
|
|
79
86
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -85,6 +92,7 @@ Note: You may use parallel read-only Tasks to examine multiple files simultaneou
|
|
|
85
92
|
"line": 42,
|
|
86
93
|
"old_or_new": "NEW",
|
|
87
94
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
95
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
88
96
|
"title": "Brief title",
|
|
89
97
|
"description": "Explanation mentioning why full file context was needed",
|
|
90
98
|
"suggestion": "How to fix/improve (omit for praise items)",
|
|
@@ -94,6 +102,7 @@ Note: You may use parallel read-only Tasks to examine multiple files simultaneou
|
|
|
94
102
|
"fileLevelSuggestions": [{
|
|
95
103
|
"file": "path/to/file",
|
|
96
104
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
105
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
97
106
|
"title": "File-level concern",
|
|
98
107
|
"description": "File-level observation (architecture, organization, naming, etc.)",
|
|
99
108
|
"suggestion": "How to address (omit for praise items)",
|
|
@@ -60,6 +60,12 @@ ONLY suggest for files in this list:
|
|
|
60
60
|
## Commands (READ-ONLY)
|
|
61
61
|
Annotated diff tool (preferred), `cat -n <file>`, ls, find, grep. Do NOT modify files.
|
|
62
62
|
|
|
63
|
+
### Severity
|
|
64
|
+
Assign severity to each suggestion (omit for praise):
|
|
65
|
+
- **critical**: Production incidents, crashes, security vulnerabilities, data corruption/loss, race conditions, breaking changes, test failures
|
|
66
|
+
- **medium**: Degraded functionality, missing error handling, missing validation, missing/poor test coverage
|
|
67
|
+
- **minor**: Code quality, docs gaps, minor optimizations
|
|
68
|
+
|
|
63
69
|
## Output Format
|
|
64
70
|
|
|
65
71
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -71,6 +77,7 @@ Annotated diff tool (preferred), `cat -n <file>`, ls, find, grep. Do NOT modify
|
|
|
71
77
|
"line": 42,
|
|
72
78
|
"old_or_new": "NEW",
|
|
73
79
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
80
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
74
81
|
"title": "Brief title",
|
|
75
82
|
"description": "Why file context was needed",
|
|
76
83
|
"suggestion": "How to fix (omit for praise)",
|
|
@@ -79,6 +86,7 @@ Annotated diff tool (preferred), `cat -n <file>`, ls, find, grep. Do NOT modify
|
|
|
79
86
|
"fileLevelSuggestions": [{
|
|
80
87
|
"file": "path/to/file",
|
|
81
88
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
89
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
82
90
|
"title": "File-level concern",
|
|
83
91
|
"description": "File-level observation",
|
|
84
92
|
"suggestion": "How to address (omit for praise)",
|
|
@@ -147,6 +147,13 @@ Your role is strictly to analyze and report findings.
|
|
|
147
147
|
|
|
148
148
|
Note: You may optionally use parallel read-only Tasks to examine multiple files simultaneously if that would be helpful for a thorough analysis.
|
|
149
149
|
|
|
150
|
+
### Severity Classification
|
|
151
|
+
Assign a severity to each suggestion (except praise):
|
|
152
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
153
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
154
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
155
|
+
Omit severity for praise items.
|
|
156
|
+
|
|
150
157
|
## Output Format
|
|
151
158
|
|
|
152
159
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -159,6 +166,7 @@ Output JSON with this structure:
|
|
|
159
166
|
"line": 42,
|
|
160
167
|
"old_or_new": "NEW",
|
|
161
168
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
169
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
162
170
|
"title": "Brief title",
|
|
163
171
|
"description": "Detailed explanation mentioning why full file context was needed",
|
|
164
172
|
"suggestion": "How to fix/improve based on file context (omit for praise items)",
|
|
@@ -168,6 +176,7 @@ Output JSON with this structure:
|
|
|
168
176
|
"fileLevelSuggestions": [{
|
|
169
177
|
"file": "path/to/file",
|
|
170
178
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
179
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
171
180
|
"title": "Brief title describing file-level concern",
|
|
172
181
|
"description": "Explanation of the file-level observation (architecture, organization, naming, etc.)",
|
|
173
182
|
"suggestion": "How to address the file-level concern (omit for praise items)",
|
|
@@ -110,6 +110,13 @@ git sparse-checkout add <directory>
|
|
|
110
110
|
|
|
111
111
|
This is non-destructive and only adds to what's visible in the worktree.
|
|
112
112
|
|
|
113
|
+
### Severity Classification
|
|
114
|
+
Assign a severity to each suggestion (except praise):
|
|
115
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
116
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
117
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
118
|
+
Omit severity for praise items.
|
|
119
|
+
|
|
113
120
|
## Output Format
|
|
114
121
|
|
|
115
122
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -122,6 +129,7 @@ Output JSON with this structure:
|
|
|
122
129
|
"line": 42,
|
|
123
130
|
"old_or_new": "NEW",
|
|
124
131
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
132
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
125
133
|
"title": "Brief title",
|
|
126
134
|
"description": "Detailed explanation mentioning why codebase context was needed",
|
|
127
135
|
"suggestion": "How to fix/improve based on codebase context (omit for praise items)",
|
|
@@ -131,6 +139,7 @@ Output JSON with this structure:
|
|
|
131
139
|
"fileLevelSuggestions": [{
|
|
132
140
|
"file": "path/to/file",
|
|
133
141
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
142
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
134
143
|
"title": "Brief title describing file-level concern",
|
|
135
144
|
"description": "Explanation of the file-level observation from codebase perspective",
|
|
136
145
|
"suggestion": "How to address the file-level concern (omit for praise items)",
|
|
@@ -82,6 +82,12 @@ git sparse-checkout add <directory>
|
|
|
82
82
|
|
|
83
83
|
This is non-destructive and only adds to what's visible in the worktree.
|
|
84
84
|
|
|
85
|
+
### Severity
|
|
86
|
+
Assign severity to each suggestion (omit for praise):
|
|
87
|
+
- **critical**: Production incidents, crashes, security vulnerabilities, data corruption/loss, race conditions, breaking changes, test failures
|
|
88
|
+
- **medium**: Degraded functionality, missing error handling, missing validation, missing/poor test coverage
|
|
89
|
+
- **minor**: Code quality, docs gaps, minor optimizations
|
|
90
|
+
|
|
85
91
|
## Output Format
|
|
86
92
|
|
|
87
93
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -94,6 +100,7 @@ Output JSON with this structure:
|
|
|
94
100
|
"line": 42,
|
|
95
101
|
"old_or_new": "NEW",
|
|
96
102
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
103
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
97
104
|
"title": "Brief title",
|
|
98
105
|
"description": "Detailed explanation mentioning why codebase context was needed",
|
|
99
106
|
"suggestion": "How to fix/improve based on codebase context (omit for praise items)",
|
|
@@ -102,6 +109,7 @@ Output JSON with this structure:
|
|
|
102
109
|
"fileLevelSuggestions": [{
|
|
103
110
|
"file": "path/to/file",
|
|
104
111
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
112
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
105
113
|
"title": "Brief title describing file-level concern",
|
|
106
114
|
"description": "Explanation of the file-level observation from codebase perspective",
|
|
107
115
|
"suggestion": "How to address the file-level concern (omit for praise items)",
|
|
@@ -221,6 +221,13 @@ git sparse-checkout add <directory>
|
|
|
221
221
|
|
|
222
222
|
This is non-destructive and only adds to what's visible in the worktree.
|
|
223
223
|
|
|
224
|
+
### Severity Classification
|
|
225
|
+
Assign a severity to each suggestion (except praise):
|
|
226
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
227
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
228
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
229
|
+
Omit severity for praise items.
|
|
230
|
+
|
|
224
231
|
## Output Format
|
|
225
232
|
|
|
226
233
|
**>>> CRITICAL: Output ONLY valid JSON. No markdown, no ```json blocks. Start with { end with }. <<<**
|
|
@@ -233,6 +240,7 @@ Output JSON with this structure:
|
|
|
233
240
|
"line": 42,
|
|
234
241
|
"old_or_new": "NEW",
|
|
235
242
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
243
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
236
244
|
"title": "Brief title",
|
|
237
245
|
"description": "Detailed explanation mentioning why codebase context was needed",
|
|
238
246
|
"suggestion": "How to fix/improve based on codebase context (omit for praise items)",
|
|
@@ -242,6 +250,7 @@ Output JSON with this structure:
|
|
|
242
250
|
"fileLevelSuggestions": [{
|
|
243
251
|
"file": "path/to/file",
|
|
244
252
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
253
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
245
254
|
"title": "Brief title describing file-level concern",
|
|
246
255
|
"description": "Explanation of the file-level observation from codebase perspective",
|
|
247
256
|
"suggestion": "How to address the file-level concern (omit for praise items)",
|
|
@@ -48,6 +48,7 @@ Each level provides suggestions as a JSON array with the following schema per it
|
|
|
48
48
|
- title: brief title
|
|
49
49
|
- description: full explanation
|
|
50
50
|
- suggestion: remediation advice
|
|
51
|
+
- severity: "critical", "medium", or "minor" (omit for praise items)
|
|
51
52
|
- confidence: 0.0-1.0 score
|
|
52
53
|
- reasoning: (optional) array of strings with step-by-step reasoning
|
|
53
54
|
- is_file_level: true if this is a file-level suggestion (no line numbers)
|
|
@@ -69,6 +70,12 @@ Each level provides suggestions as a JSON array with the following schema per it
|
|
|
69
70
|
- **Preserve unique insights** that only one level discovered
|
|
70
71
|
- **Prefer preserving line-level suggestions** over file-level suggestions when curating
|
|
71
72
|
- **Do NOT mention which level found the issue** - focus on the insight itself
|
|
73
|
+
- **Assess severity** based on the evidence and reasoning across input levels. When levels assign different severities, evaluate the supporting evidence rather than defaulting to the highest. When truly uncertain, preserve the highest severity. Omit severity for praise items.
|
|
74
|
+
|
|
75
|
+
**Severity Definitions:**
|
|
76
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
77
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
78
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
72
79
|
|
|
73
80
|
### 2. Priority-Based Curation
|
|
74
81
|
Prioritize suggestions in this order:
|
|
@@ -102,6 +109,7 @@ Output JSON with this structure:
|
|
|
102
109
|
"line": 42,
|
|
103
110
|
"old_or_new": "NEW",
|
|
104
111
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
112
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
105
113
|
"title": "Brief title describing the curated insight",
|
|
106
114
|
"description": "Clear explanation of the issue and why this guidance matters to the human reviewer",
|
|
107
115
|
"suggestion": "Specific, actionable guidance for the reviewer. For praise items this can be omitted. For other types always include specific, actionable suggestions.",
|
|
@@ -111,6 +119,7 @@ Output JSON with this structure:
|
|
|
111
119
|
"fileLevelSuggestions": [{
|
|
112
120
|
"file": "path/to/file",
|
|
113
121
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
122
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
114
123
|
"title": "Brief title describing file-level concern",
|
|
115
124
|
"description": "Explanation of the file-level observation",
|
|
116
125
|
"suggestion": "How to address the file-level concern (omit for praise items)",
|
|
@@ -48,6 +48,7 @@ Each level provides suggestions as a JSON array with the following schema per it
|
|
|
48
48
|
- title: brief title
|
|
49
49
|
- description: full explanation
|
|
50
50
|
- suggestion: remediation advice
|
|
51
|
+
- severity: "critical", "medium", or "minor" (omit for praise items)
|
|
51
52
|
- confidence: 0.0-1.0 score
|
|
52
53
|
- reasoning: (optional) array of strings with step-by-step reasoning
|
|
53
54
|
- is_file_level: true if this is a file-level suggestion (no line numbers)
|
|
@@ -63,6 +64,8 @@ Each level provides suggestions as a JSON array with the following schema per it
|
|
|
63
64
|
|
|
64
65
|
## Rules
|
|
65
66
|
Combine related suggestions. Merge overlaps. Preserve unique insights. Never mention levels.
|
|
67
|
+
Assess severity using evidence across levels; preserve highest when uncertain. Omit for praise.
|
|
68
|
+
Severity: critical (crashes, security, data loss, race conditions, breaking changes, test failures), medium (degraded functionality, missing error handling/validation/test coverage), minor (code quality, docs, optimizations).
|
|
66
69
|
|
|
67
70
|
### Priority
|
|
68
71
|
Security > Bugs > Architecture > Performance > Style
|
|
@@ -81,6 +84,7 @@ Use "Consider...", "Worth noting..." - guidance not mandates.
|
|
|
81
84
|
"line": 42,
|
|
82
85
|
"old_or_new": "NEW",
|
|
83
86
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
87
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
84
88
|
"title": "Brief title",
|
|
85
89
|
"description": "Why it matters",
|
|
86
90
|
"suggestion": "What to do (omit for praise)",
|
|
@@ -89,6 +93,7 @@ Use "Consider...", "Worth noting..." - guidance not mandates.
|
|
|
89
93
|
"fileLevelSuggestions": [{
|
|
90
94
|
"file": "path/to/file",
|
|
91
95
|
"type": "...",
|
|
96
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
92
97
|
"title": "Brief title",
|
|
93
98
|
"description": "File-level observation",
|
|
94
99
|
"suggestion": "How to fix (omit for praise)",
|
|
@@ -66,6 +66,7 @@ Each level provides suggestions as a JSON array with the following schema per it
|
|
|
66
66
|
- title: brief title
|
|
67
67
|
- description: full explanation
|
|
68
68
|
- suggestion: remediation advice
|
|
69
|
+
- severity: "critical", "medium", or "minor" (omit for praise items)
|
|
69
70
|
- confidence: 0.0-1.0 score
|
|
70
71
|
- reasoning: (optional) array of strings with step-by-step reasoning
|
|
71
72
|
- is_file_level: true if this is a file-level suggestion (no line numbers)
|
|
@@ -112,6 +113,12 @@ When levels disagree (e.g., Level 1 flags an issue that Level 3 says follows cod
|
|
|
112
113
|
- Use the clearest framing, regardless of which level provided it
|
|
113
114
|
- Do NOT mention which level found the issue - focus on the insight itself
|
|
114
115
|
- When merging would lose important nuance, keep suggestions distinct
|
|
116
|
+
- **Assess severity** based on the evidence and reasoning across input levels. When levels assign different severities, evaluate the supporting evidence rather than defaulting to the highest. When truly uncertain, preserve the highest severity. Omit severity for praise items.
|
|
117
|
+
|
|
118
|
+
**Severity Definitions:**
|
|
119
|
+
- **critical**: Production incidents, system failures, or security vulnerabilities — runtime crashes, data corruption or loss, race conditions, deadlocks, breaking changes, changes that will cause existing tests to fail
|
|
120
|
+
- **medium**: Degraded functionality or reliability — missing error handling, N+1 queries, missing validation, missing or poor test coverage for new functionality
|
|
121
|
+
- **minor**: Code quality concerns — documentation gaps, minor optimizations, style inconsistencies
|
|
115
122
|
|
|
116
123
|
### 2. Priority-Based Curation
|
|
117
124
|
Prioritize suggestions carefully based on impact and urgency:
|
|
@@ -232,6 +239,7 @@ Output JSON with this structure:
|
|
|
232
239
|
"line": 42,
|
|
233
240
|
"old_or_new": "NEW",
|
|
234
241
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
242
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
235
243
|
"title": "Brief title describing the curated insight",
|
|
236
244
|
"description": "Clear explanation of the issue and why this guidance matters to the human reviewer",
|
|
237
245
|
"suggestion": "Specific, actionable guidance for the reviewer (omit for praise items)",
|
|
@@ -241,6 +249,7 @@ Output JSON with this structure:
|
|
|
241
249
|
"fileLevelSuggestions": [{
|
|
242
250
|
"file": "path/to/file",
|
|
243
251
|
"type": "bug|improvement|praise|suggestion|design|performance|security|code-style",
|
|
252
|
+
"severity": "critical|medium|minor (omit for praise)",
|
|
244
253
|
"title": "Brief title describing file-level concern",
|
|
245
254
|
"description": "Explanation of the file-level observation",
|
|
246
255
|
"suggestion": "How to address the file-level concern (omit for praise items)",
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
/* Copyright 2026 Tim Perkins (tjwp) | SPDX-License-Identifier: Apache-2.0 */
|
|
2
|
+
|
|
3
|
+
/* Exclude Previous Findings — collapsible <details> section */
|
|
4
|
+
|
|
5
|
+
.exclude-previous-section {
|
|
6
|
+
margin-top: 24px;
|
|
7
|
+
margin-bottom: 20px;
|
|
8
|
+
border: 1px solid var(--color-border-primary);
|
|
9
|
+
border-radius: 8px;
|
|
10
|
+
overflow: hidden;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.exclude-previous-section > summary {
|
|
14
|
+
cursor: pointer;
|
|
15
|
+
list-style: none;
|
|
16
|
+
padding: 10px 14px;
|
|
17
|
+
background: var(--color-bg-secondary);
|
|
18
|
+
transition: background 0.15s ease;
|
|
19
|
+
margin-bottom: 0;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.exclude-previous-section[open] > summary {
|
|
23
|
+
margin-bottom: 0;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.exclude-previous-section > summary::-webkit-details-marker {
|
|
27
|
+
display: none;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.exclude-previous-section > summary::marker {
|
|
31
|
+
content: '';
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.exclude-previous-section > summary:hover {
|
|
35
|
+
background: var(--color-bg-tertiary);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/* Disclosure triangle via pseudo-element on the summary title */
|
|
39
|
+
.exclude-previous-section > summary.section-title::before {
|
|
40
|
+
content: '';
|
|
41
|
+
display: inline-block;
|
|
42
|
+
width: 0;
|
|
43
|
+
height: 0;
|
|
44
|
+
border-style: solid;
|
|
45
|
+
border-width: 5px 0 5px 7px;
|
|
46
|
+
border-color: transparent transparent transparent var(--color-text-tertiary);
|
|
47
|
+
transition: transform 0.15s ease;
|
|
48
|
+
flex-shrink: 0;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.exclude-previous-section[open] > summary.section-title::before {
|
|
52
|
+
transform: rotate(90deg);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.exclude-previous-options {
|
|
56
|
+
padding: 4px 14px 14px;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.exclude-previous-options .remember-toggle:first-child {
|
|
60
|
+
margin-top: 4px;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/* Disabled toggle style */
|
|
64
|
+
.exclude-previous-options .remember-toggle:has(input:disabled) {
|
|
65
|
+
opacity: 0.5;
|
|
66
|
+
cursor: not-allowed;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.exclude-previous-options .remember-toggle input:disabled + .toggle-switch {
|
|
70
|
+
cursor: not-allowed;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/* Hint text under each checkbox */
|
|
74
|
+
.option-hint {
|
|
75
|
+
margin: 2px 0 10px 46px;
|
|
76
|
+
font-size: 11px;
|
|
77
|
+
line-height: 1.4;
|
|
78
|
+
color: var(--color-text-tertiary);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.option-hint:last-child {
|
|
82
|
+
margin-bottom: 0;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/* Section disabled by provider capability —
|
|
86
|
+
pointer-events on the section blocks interaction; opacity is applied
|
|
87
|
+
only to the options area so the note remains clearly readable and
|
|
88
|
+
the already-disabled GitHub toggle doesn't double-dim. */
|
|
89
|
+
.exclude-previous-section.exclude-previous-disabled {
|
|
90
|
+
pointer-events: none;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.exclude-previous-section.exclude-previous-disabled > summary {
|
|
94
|
+
opacity: 0.5;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.exclude-previous-section.exclude-previous-disabled .exclude-previous-options {
|
|
98
|
+
opacity: 0.5;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.exclude-previous-section .executable-provider-note {
|
|
102
|
+
margin: 8px 14px;
|
|
103
|
+
}
|