specweave 0.33.3 → 0.33.5
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/CLAUDE.md +85 -19
- package/dist/src/cli/cleanup-zombies.js +8 -5
- package/dist/src/cli/cleanup-zombies.js.map +1 -1
- package/dist/src/cli/commands/jobs.js +19 -2
- package/dist/src/cli/commands/jobs.js.map +1 -1
- package/dist/src/cli/commands/living-docs.js +1 -1
- package/dist/src/cli/commands/living-docs.js.map +1 -1
- package/dist/src/cli/helpers/init/external-import-grouping.d.ts.map +1 -1
- package/dist/src/cli/helpers/init/external-import-grouping.js +11 -7
- package/dist/src/cli/helpers/init/external-import-grouping.js.map +1 -1
- package/dist/src/cli/workers/clone-worker.js +22 -5
- package/dist/src/cli/workers/clone-worker.js.map +1 -1
- package/dist/src/config/types.d.ts +203 -1208
- package/dist/src/config/types.d.ts.map +1 -1
- package/dist/src/core/background/job-dependency.d.ts.map +1 -1
- package/dist/src/core/background/job-dependency.js +1 -0
- package/dist/src/core/background/job-dependency.js.map +1 -1
- package/dist/src/core/background/job-launcher.js +2 -2
- package/dist/src/core/background/job-launcher.js.map +1 -1
- package/dist/src/core/background/job-manager.d.ts +8 -0
- package/dist/src/core/background/job-manager.d.ts.map +1 -1
- package/dist/src/core/background/job-manager.js +19 -1
- package/dist/src/core/background/job-manager.js.map +1 -1
- package/dist/src/core/background/types.d.ts +9 -1
- package/dist/src/core/background/types.d.ts.map +1 -1
- package/dist/src/core/background/types.js +8 -1
- package/dist/src/core/background/types.js.map +1 -1
- package/dist/src/importers/external-importer.d.ts +26 -5
- package/dist/src/importers/external-importer.d.ts.map +1 -1
- package/dist/src/importers/item-converter.d.ts.map +1 -1
- package/dist/src/importers/item-converter.js +18 -1
- package/dist/src/importers/item-converter.js.map +1 -1
- package/dist/src/importers/jira-importer.d.ts +10 -0
- package/dist/src/importers/jira-importer.d.ts.map +1 -1
- package/dist/src/importers/jira-importer.js +70 -6
- package/dist/src/importers/jira-importer.js.map +1 -1
- package/dist/src/init/architecture/types.d.ts +33 -140
- package/dist/src/init/architecture/types.d.ts.map +1 -1
- package/dist/src/init/compliance/types.d.ts +30 -27
- package/dist/src/init/compliance/types.d.ts.map +1 -1
- package/dist/src/init/repo/types.d.ts +11 -34
- package/dist/src/init/repo/types.d.ts.map +1 -1
- package/dist/src/init/research/src/config/types.d.ts +15 -82
- package/dist/src/init/research/src/config/types.d.ts.map +1 -1
- package/dist/src/init/research/types.d.ts +38 -93
- package/dist/src/init/research/types.d.ts.map +1 -1
- package/dist/src/init/team/types.d.ts +4 -42
- package/dist/src/init/team/types.d.ts.map +1 -1
- package/dist/src/living-docs/smart-doc-organizer.js +1 -1
- package/dist/src/living-docs/smart-doc-organizer.js.map +1 -1
- package/dist/src/sync/closure-metrics.d.ts +102 -0
- package/dist/src/sync/closure-metrics.d.ts.map +1 -0
- package/dist/src/sync/closure-metrics.js +267 -0
- package/dist/src/sync/closure-metrics.js.map +1 -0
- package/dist/src/sync/sync-coordinator.d.ts +29 -0
- package/dist/src/sync/sync-coordinator.d.ts.map +1 -1
- package/dist/src/sync/sync-coordinator.js +153 -16
- package/dist/src/sync/sync-coordinator.js.map +1 -1
- package/dist/src/utils/docs-preview/config-generator.d.ts.map +1 -1
- package/dist/src/utils/docs-preview/config-generator.js +4 -0
- package/dist/src/utils/docs-preview/config-generator.js.map +1 -1
- package/dist/src/utils/notification-constants.d.ts +87 -0
- package/dist/src/utils/notification-constants.d.ts.map +1 -0
- package/dist/src/utils/notification-constants.js +131 -0
- package/dist/src/utils/notification-constants.js.map +1 -0
- package/dist/src/utils/notification-manager.d.ts +24 -0
- package/dist/src/utils/notification-manager.d.ts.map +1 -1
- package/dist/src/utils/notification-manager.js +29 -0
- package/dist/src/utils/notification-manager.js.map +1 -1
- package/dist/src/utils/platform-utils.d.ts +13 -3
- package/dist/src/utils/platform-utils.d.ts.map +1 -1
- package/dist/src/utils/platform-utils.js +17 -6
- package/dist/src/utils/platform-utils.js.map +1 -1
- package/package.json +1 -1
- package/plugins/specweave/commands/specweave-increment.md +46 -0
- package/plugins/specweave/commands/specweave-jobs.md +153 -8
- package/plugins/specweave/commands/specweave-judge-llm.md +296 -0
- package/plugins/specweave/commands/specweave-organize-docs.md +2 -2
- package/plugins/specweave/hooks/hooks.json +10 -0
- package/plugins/specweave/hooks/spec-project-validator.sh +24 -2
- package/plugins/specweave/hooks/universal/hook-wrapper.cmd +26 -26
- package/plugins/specweave/hooks/universal/session-start.cmd +16 -16
- package/plugins/specweave/hooks/universal/session-start.ps1 +16 -16
- package/plugins/specweave/hooks/v2/guards/metadata-json-guard.sh +87 -0
- package/plugins/specweave/hooks/v2/guards/metadata-json-guard.test.sh +302 -0
- package/plugins/specweave/hooks/v2/guards/per-us-project-validator.sh +72 -18
- package/plugins/specweave/hooks/v2/guards/per-us-project-validator.test.sh +406 -0
- package/plugins/specweave/scripts/session-watchdog.sh +288 -134
- package/plugins/specweave/skills/increment-planner/SKILL.md +48 -18
- package/plugins/specweave/skills/increment-planner/templates/spec-multi-project.md +27 -14
- package/plugins/specweave/skills/increment-planner/templates/spec-single-project.md +16 -5
- package/plugins/specweave/skills/spec-generator/SKILL.md +74 -15
- package/plugins/specweave-docs/commands/build.md +4 -4
- package/plugins/specweave-docs/commands/generate.md +1 -1
- package/plugins/specweave-docs/commands/health.md +1 -1
- package/plugins/specweave-docs/commands/init.md +1 -1
- package/plugins/specweave-docs/commands/organize.md +2 -2
- package/plugins/specweave-docs/commands/validate.md +1 -1
- package/plugins/specweave-docs/commands/view.md +391 -0
- package/plugins/specweave-docs/skills/preview/SKILL.md +56 -17
- package/src/templates/AGENTS.md.template +24 -28
- package/src/templates/CLAUDE.md.template +12 -8
- package/plugins/specweave/commands/specweave-judge.md +0 -276
- package/plugins/specweave-docs/commands/preview.md +0 -274
- package/plugins/specweave-github/hooks/.specweave/logs/hooks-debug.log +0 -738
- package/plugins/specweave-release/hooks/.specweave/logs/dora-tracking.log +0 -1107
|
@@ -297,13 +297,19 @@ export class PlatformUtils {
|
|
|
297
297
|
*
|
|
298
298
|
* Fails gracefully if notification system is unavailable
|
|
299
299
|
*
|
|
300
|
-
*
|
|
301
|
-
*
|
|
300
|
+
* IMPORTANT: Notifications MUST be explicit! Always:
|
|
301
|
+
* 1. Start title with "SpecWeave:" to identify source
|
|
302
|
+
* 2. Use explicit message describing what happened
|
|
303
|
+
* 3. Include "No action needed" for informational notifications
|
|
304
|
+
*
|
|
305
|
+
* @param title Notification title (should start with "SpecWeave:")
|
|
306
|
+
* @param body Notification body text (should be explicit about what happened)
|
|
307
|
+
* @param sound Optional sound name for macOS (default: "Pop" for neutral notifications)
|
|
302
308
|
*/
|
|
303
|
-
async sendNotification(title, body) {
|
|
309
|
+
async sendNotification(title, body, sound) {
|
|
304
310
|
try {
|
|
305
311
|
if (this.platform === 'darwin') {
|
|
306
|
-
await this.sendNotificationMacOS(title, body);
|
|
312
|
+
await this.sendNotificationMacOS(title, body, sound);
|
|
307
313
|
}
|
|
308
314
|
else if (this.platform === 'linux') {
|
|
309
315
|
await this.sendNotificationLinux(title, body);
|
|
@@ -319,11 +325,16 @@ export class PlatformUtils {
|
|
|
319
325
|
}
|
|
320
326
|
/**
|
|
321
327
|
* macOS notification using osascript
|
|
328
|
+
*
|
|
329
|
+
* @param title Notification title (should start with "SpecWeave:")
|
|
330
|
+
* @param body Notification body (should be explicit about what happened)
|
|
331
|
+
* @param sound Optional sound name (default: "Pop" for neutral notifications)
|
|
322
332
|
*/
|
|
323
|
-
async sendNotificationMacOS(title, body) {
|
|
333
|
+
async sendNotificationMacOS(title, body, sound = 'Pop') {
|
|
324
334
|
const escapedTitle = title.replace(/"/g, '\\"');
|
|
325
335
|
const escapedBody = body.replace(/"/g, '\\"');
|
|
326
|
-
const
|
|
336
|
+
const soundParam = sound ? ` sound name "${sound}"` : '';
|
|
337
|
+
const cmd = `osascript -e 'display notification "${escapedBody}" with title "${escapedTitle}"${soundParam}'`;
|
|
327
338
|
execSync(cm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AQ,CAAC,gBAAgB,YAAY,MAAM,WAAW,GAAG,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC,CAAC;QAClF,CAAC;QAAC,OAAO,GAAG,EAAE,CAAC;YACb,MAAM,IAAI,KAAK,CAAC,0CAA0C,CAAC,CAAC;QAC9D,CAAC;IACH,CAAC;IAED;;OAEG;IACK,KAAK,CAAC,uBAAuB,CAAC,KAAa,EAAE,IAAY;QAC/D,MAAM,YAAY,GAAG,KAAK,CAAC,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;QAC/C,MAAM,WAAW,GAAG,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;QAC7C,MAAM,QAAQ,GAAG;;;;8EAIyD,YAAY;8EACZ,WAAW;;;KAGpF,CAAC;QACF,QAAQ,CAAC,wBAAwB,QAAQ,GAAG,EAAE;YAC5C,KAAK,EAAE,QAAQ;YACf,WAAW,EAAE,IAAI;SAClB,CAAC,CAAC;IACL,CAAC;CACF;AAED,4CAA4C;AAC5C,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,aAAa,EAAE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "specweave",
|
|
3
|
-
"version": "0.33.
|
|
3
|
+
"version": "0.33.5",
|
|
4
4
|
"description": "Spec-driven development framework for Claude Code. AI-native workflow with living documentation, intelligent agents, and multilingual support (9 languages). Enterprise-grade traceability with permanent specs and temporary increments.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -364,6 +364,52 @@ Proceeding with hotfix 0006...
|
|
|
364
364
|
- Hotfixes and bugs bypass context switching warnings (emergency work)
|
|
365
365
|
- Use sparingly - discipline exists for a reason!
|
|
366
366
|
|
|
367
|
+
### Step 0D: Get Project Context (MANDATORY - RUN FIRST!)
|
|
368
|
+
|
|
369
|
+
**⛔ THIS STEP MUST BE COMPLETED BEFORE ANY SPEC GENERATION!**
|
|
370
|
+
|
|
371
|
+
**🚨 YOU MUST USE THE BASH TOOL TO RUN THIS COMMAND:**
|
|
372
|
+
|
|
373
|
+
```bash
|
|
374
|
+
specweave context projects
|
|
375
|
+
```
|
|
376
|
+
|
|
377
|
+
**CAPTURE THE OUTPUT AND STORE IT:**
|
|
378
|
+
|
|
379
|
+
```json
|
|
380
|
+
// Example 1-level output:
|
|
381
|
+
{
|
|
382
|
+
"level": 1,
|
|
383
|
+
"projects": [{"id": "frontend-app"}, {"id": "backend-api"}, {"id": "shared"}]
|
|
384
|
+
}
|
|
385
|
+
|
|
386
|
+
// Example 2-level output:
|
|
387
|
+
{
|
|
388
|
+
"level": 2,
|
|
389
|
+
"projects": [{"id": "acme-corp"}],
|
|
390
|
+
"boardsByProject": {
|
|
391
|
+
"acme-corp": [{"id": "digital-ops"}, {"id": "mobile-team"}]
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
```
|
|
395
|
+
|
|
396
|
+
**STORE THESE VALUES FOR USE IN STEP 5:**
|
|
397
|
+
```
|
|
398
|
+
STRUCTURE_LEVEL = 1 or 2
|
|
399
|
+
AVAILABLE_PROJECTS = ["frontend-app", "backend-api", "shared"]
|
|
400
|
+
AVAILABLE_BOARDS = {...} // for 2-level only
|
|
401
|
+
```
|
|
402
|
+
|
|
403
|
+
**WHY THIS IS MANDATORY:**
|
|
404
|
+
- Without this data, spec.md will have `{{PROJECT_ID}}` placeholders
|
|
405
|
+
- Placeholders WILL BE BLOCKED by `spec-project-validator.sh` hook
|
|
406
|
+
- Living docs sync and external tool sync WILL FAIL
|
|
407
|
+
- User will get frustrated with blocked edits
|
|
408
|
+
|
|
409
|
+
**YOU MUST ACTUALLY RUN THE COMMAND** - reading documentation about it is NOT enough!
|
|
410
|
+
|
|
411
|
+
---
|
|
412
|
+
|
|
367
413
|
### Step 1: Find next increment number
|
|
368
414
|
|
|
369
415
|
- Scan `.specweave/increments/` directory (active increments)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: specweave:jobs
|
|
3
3
|
description: Show current work status (active increments, progress) and background jobs (imports, cloning). Even with no jobs, shows increment summary and helpful context.
|
|
4
|
-
usage: /specweave:jobs [--all] [--id <job-id>] [--resume <job-id>] [--kill <job-id>] [--follow <job-id>] [--logs <job-id>]
|
|
4
|
+
usage: /specweave:jobs [--all] [--id <job-id>] [--resume <job-id>] [--kill <job-id>] [--follow <job-id>] [--logs <job-id>] [--diagnostics]
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# Background Jobs Monitor
|
|
@@ -17,6 +17,7 @@ Monitor and manage long-running background operations:
|
|
|
17
17
|
- **Issue import** (10K+ items from GitHub/JIRA/ADO)
|
|
18
18
|
- **External sync** operations
|
|
19
19
|
- **Brownfield analysis** (codebase documentation gap detection)
|
|
20
|
+
- **Session health monitoring** (watchdog diagnostics)
|
|
20
21
|
|
|
21
22
|
**ASYNC ARCHITECTURE (2025-12-01)**:
|
|
22
23
|
- Jobs run as **detached processes** that survive terminal close
|
|
@@ -29,13 +30,14 @@ Monitor and manage long-running background operations:
|
|
|
29
30
|
|
|
30
31
|
| Option | Description |
|
|
31
32
|
|--------|-------------|
|
|
32
|
-
| (none) | Show active jobs |
|
|
33
|
+
| (none) | Show active jobs + session health |
|
|
33
34
|
| `--all` | Show all jobs (including completed) |
|
|
34
35
|
| `--id <jobId>` | Show details for specific job |
|
|
35
36
|
| `--follow <jobId>` | Follow job progress in real-time |
|
|
36
37
|
| `--logs <jobId>` | Show worker log output |
|
|
37
38
|
| `--resume <jobId>` | Resume paused job |
|
|
38
39
|
| `--kill <jobId>` | Kill running background job |
|
|
40
|
+
| `--diagnostics` | Show detailed watchdog diagnostics |
|
|
39
41
|
|
|
40
42
|
---
|
|
41
43
|
|
|
@@ -57,7 +59,9 @@ STATE_FILE=".specweave/state/background-jobs.json"
|
|
|
57
59
|
### Display Format
|
|
58
60
|
|
|
59
61
|
```
|
|
60
|
-
📋 Background Jobs
|
|
62
|
+
📋 Background Jobs & Session Health
|
|
63
|
+
|
|
64
|
+
🩺 Session Health: ✅ healthy (last check: 30s ago)
|
|
61
65
|
|
|
62
66
|
🔄 Running (2):
|
|
63
67
|
[abc12345] import-issues (ADO)
|
|
@@ -87,6 +91,7 @@ STATE_FILE=".specweave/state/background-jobs.json"
|
|
|
87
91
|
/specweave:jobs --logs abc12345 → View worker logs
|
|
88
92
|
/specweave:jobs --resume def67890 → Resume paused job
|
|
89
93
|
/specweave:jobs --kill abc12345 → Kill running job
|
|
94
|
+
/specweave:jobs --diagnostics → Show watchdog diagnostics
|
|
90
95
|
/specweave:jobs --all → Show all jobs (including old)
|
|
91
96
|
```
|
|
92
97
|
|
|
@@ -221,14 +226,57 @@ const result = await launchImportJob({
|
|
|
221
226
|
## Implementation
|
|
222
227
|
|
|
223
228
|
1. Read `.specweave/state/background-jobs.json`
|
|
224
|
-
2.
|
|
225
|
-
3.
|
|
226
|
-
4.
|
|
229
|
+
2. Read `.specweave/state/.watchdog-diagnostics.json` for session health
|
|
230
|
+
3. Parse job entries
|
|
231
|
+
4. Display formatted status with health indicator
|
|
232
|
+
5. For --resume, update job status and continue operation
|
|
233
|
+
6. For --diagnostics, show detailed watchdog checks
|
|
227
234
|
|
|
228
|
-
### State File
|
|
235
|
+
### State File Locations
|
|
229
236
|
|
|
230
237
|
```
|
|
231
|
-
.specweave/state/background-jobs.json
|
|
238
|
+
.specweave/state/background-jobs.json - Job status and progress
|
|
239
|
+
.specweave/state/.watchdog-diagnostics.json - Session health checks
|
|
240
|
+
.specweave/state/jobs/<jobId>/config.json - Job configuration
|
|
241
|
+
.specweave/state/jobs/<jobId>/worker.pid - Worker process ID
|
|
242
|
+
.specweave/state/jobs/<jobId>/worker.log - Worker output log
|
|
243
|
+
.specweave/logs/watchdog.log - Watchdog history
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
### Reading Session Health
|
|
247
|
+
|
|
248
|
+
```typescript
|
|
249
|
+
import * as fs from 'fs';
|
|
250
|
+
import * as path from 'path';
|
|
251
|
+
|
|
252
|
+
function getSessionHealth(projectPath: string): SessionHealth | null {
|
|
253
|
+
const diagnosticsPath = path.join(projectPath, '.specweave/state/.watchdog-diagnostics.json');
|
|
254
|
+
if (!fs.existsSync(diagnosticsPath)) {
|
|
255
|
+
return null; // Watchdog not running
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
try {
|
|
259
|
+
const content = fs.readFileSync(diagnosticsPath, 'utf-8');
|
|
260
|
+
return JSON.parse(content);
|
|
261
|
+
} catch {
|
|
262
|
+
return null;
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
interface SessionHealth {
|
|
267
|
+
timestamp: string;
|
|
268
|
+
severity: 0 | 1 | 2; // INFO | WARNING | CRITICAL
|
|
269
|
+
status: 'healthy' | 'warning' | 'critical';
|
|
270
|
+
checks: {
|
|
271
|
+
lock: { severity: number; message: string };
|
|
272
|
+
zombies: { count: number; message: string };
|
|
273
|
+
mcp: { drops: number; message: string };
|
|
274
|
+
orphanedJobs: { count: number; message: string };
|
|
275
|
+
};
|
|
276
|
+
consecutiveWarnings: number;
|
|
277
|
+
thresholdSeconds: number;
|
|
278
|
+
checkIntervalSeconds: number;
|
|
279
|
+
}
|
|
232
280
|
```
|
|
233
281
|
|
|
234
282
|
### Job Types
|
|
@@ -299,9 +347,106 @@ If job failed:
|
|
|
299
347
|
|
|
300
348
|
---
|
|
301
349
|
|
|
350
|
+
## Session Health & Watchdog Diagnostics (v2.0)
|
|
351
|
+
|
|
352
|
+
The `/specweave:jobs` command now includes session health monitoring. The watchdog runs in the background and writes diagnostics that help explain any alerts you may have received.
|
|
353
|
+
|
|
354
|
+
### Display Format (with health status)
|
|
355
|
+
|
|
356
|
+
```
|
|
357
|
+
📋 Background Jobs & Session Health
|
|
358
|
+
|
|
359
|
+
🩺 Session Health: ✅ healthy
|
|
360
|
+
Last check: 30 seconds ago
|
|
361
|
+
Consecutive warnings: 0/3
|
|
362
|
+
|
|
363
|
+
🔄 Running (1):
|
|
364
|
+
[abc12345] import-issues (ADO)
|
|
365
|
+
Progress: 2,500/10,000 (25%)
|
|
366
|
+
...
|
|
367
|
+
```
|
|
368
|
+
|
|
369
|
+
### Diagnostics File
|
|
370
|
+
|
|
371
|
+
The watchdog writes diagnostics to `.specweave/state/.watchdog-diagnostics.json`:
|
|
372
|
+
|
|
373
|
+
```json
|
|
374
|
+
{
|
|
375
|
+
"timestamp": "2025-12-10T10:30:00Z",
|
|
376
|
+
"severity": 0,
|
|
377
|
+
"status": "healthy",
|
|
378
|
+
"checks": {
|
|
379
|
+
"lock": { "severity": 0, "message": "ok" },
|
|
380
|
+
"zombies": { "count": 0, "message": "none" },
|
|
381
|
+
"mcp": { "drops": 2, "message": "minor instability" },
|
|
382
|
+
"orphanedJobs": { "count": 0, "message": "none" }
|
|
383
|
+
},
|
|
384
|
+
"consecutiveWarnings": 0,
|
|
385
|
+
"thresholdSeconds": 300,
|
|
386
|
+
"checkIntervalSeconds": 60
|
|
387
|
+
}
|
|
388
|
+
```
|
|
389
|
+
|
|
390
|
+
### View Detailed Diagnostics
|
|
391
|
+
|
|
392
|
+
```
|
|
393
|
+
/specweave:jobs --diagnostics
|
|
394
|
+
|
|
395
|
+
🩺 Watchdog Diagnostics
|
|
396
|
+
|
|
397
|
+
Overall Status: ✅ healthy
|
|
398
|
+
Last Check: 2025-12-10 10:30:00
|
|
399
|
+
Severity Level: INFO (0)
|
|
400
|
+
|
|
401
|
+
Checks:
|
|
402
|
+
📁 Lock File: ✅ ok
|
|
403
|
+
💀 Zombie Procs: ✅ none (0)
|
|
404
|
+
🔌 MCP Connection: ⚠️ 2 drops detected (minor instability)
|
|
405
|
+
📦 Orphaned Jobs: ✅ none (0)
|
|
406
|
+
|
|
407
|
+
Alert Threshold: 3 consecutive warnings
|
|
408
|
+
Current Warnings: 0/3
|
|
409
|
+
|
|
410
|
+
Severity Levels:
|
|
411
|
+
INFO (0) - Everything healthy, no action needed
|
|
412
|
+
WARNING (1) - Minor issue detected, monitoring (NO notification)
|
|
413
|
+
CRITICAL (2) - Real stuck condition detected → NOTIFICATION SENT
|
|
414
|
+
|
|
415
|
+
💡 The watchdog only sends notifications for CRITICAL issues
|
|
416
|
+
that persist across 3+ consecutive checks (prevents false positives).
|
|
417
|
+
```
|
|
418
|
+
|
|
419
|
+
### Why You Got a Notification
|
|
420
|
+
|
|
421
|
+
If you received a notification but your job completed successfully, here's what happened:
|
|
422
|
+
|
|
423
|
+
1. **Old behavior (v1)**: Watchdog triggered on stale lock files even if no process was stuck
|
|
424
|
+
2. **New behavior (v2)**: Watchdog verifies actual process state before alerting
|
|
425
|
+
|
|
426
|
+
Common false positive causes (now fixed):
|
|
427
|
+
- Stale `.processor.lock` file from completed job
|
|
428
|
+
- Missing heartbeat file (never written in normal operation)
|
|
429
|
+
- MCP connection drops (warning only, not critical)
|
|
430
|
+
|
|
431
|
+
**The v2 watchdog now requires**:
|
|
432
|
+
1. **Actual stuck process** (zombie heredoc, hung worker)
|
|
433
|
+
2. **3 consecutive checks** showing the same issue
|
|
434
|
+
3. **CRITICAL severity** (not just warnings)
|
|
435
|
+
|
|
436
|
+
### Watchdog Log
|
|
437
|
+
|
|
438
|
+
View historical watchdog checks:
|
|
439
|
+
|
|
440
|
+
```bash
|
|
441
|
+
cat .specweave/logs/watchdog.log
|
|
442
|
+
```
|
|
443
|
+
|
|
444
|
+
---
|
|
445
|
+
|
|
302
446
|
## Notes
|
|
303
447
|
|
|
304
448
|
- Jobs persist across Claude sessions
|
|
305
449
|
- Paused jobs can be resumed later
|
|
306
450
|
- Completed jobs cleaned up after 10 entries
|
|
307
451
|
- Rate limiting auto-pauses and notifies
|
|
452
|
+
- Watchdog diagnostics available via `--diagnostics` flag
|
|
@@ -0,0 +1,296 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: specweave:judge-llm
|
|
3
|
+
description: Ultrathink LLM-as-Judge validation of completed work. Uses extended thinking by DEFAULT for thorough evaluation.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /specweave:judge-llm - Ultrathink LLM-as-Judge Validation
|
|
7
|
+
|
|
8
|
+
**ULTRATHINK BY DEFAULT** - Validate completed work using extended thinking and the LLM-as-Judge pattern.
|
|
9
|
+
|
|
10
|
+
## CRITICAL: Extended Thinking is DEFAULT
|
|
11
|
+
|
|
12
|
+
This command ALWAYS uses **ultrathink (extended thinking)** for thorough LLM-as-Judge evaluation:
|
|
13
|
+
|
|
14
|
+
```
|
|
15
|
+
DEFAULT BEHAVIOR = ULTRATHINK MODE
|
|
16
|
+
- Extended thinking enabled
|
|
17
|
+
- Deep chain-of-thought reasoning
|
|
18
|
+
- Thorough multi-dimensional analysis
|
|
19
|
+
- ~60-90 seconds for comprehensive evaluation
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Use `--quick` only if you explicitly need faster (but less thorough) validation.
|
|
23
|
+
|
|
24
|
+
## Purpose
|
|
25
|
+
|
|
26
|
+
Use when you've completed work and want **maximum-quality AI validation**:
|
|
27
|
+
- Works on **any files** (not just SpecWeave increments)
|
|
28
|
+
- Uses **ultrathink extended thinking** for deepest analysis
|
|
29
|
+
- Returns **clear verdict** with detailed reasoning
|
|
30
|
+
|
|
31
|
+
## Usage
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
# DEFAULT: Ultrathink validation (recommended)
|
|
35
|
+
/specweave:judge-llm src/file.ts
|
|
36
|
+
/specweave:judge-llm "src/**/*.ts"
|
|
37
|
+
|
|
38
|
+
# Validate git changes (ultrathink by default)
|
|
39
|
+
/specweave:judge-llm --staged # Staged changes
|
|
40
|
+
/specweave:judge-llm --last-commit # Last commit
|
|
41
|
+
/specweave:judge-llm --diff main # Diff vs branch
|
|
42
|
+
|
|
43
|
+
# Quick mode (ONLY if you need speed over thoroughness)
|
|
44
|
+
/specweave:judge-llm src/file.ts --quick
|
|
45
|
+
|
|
46
|
+
# Additional options
|
|
47
|
+
/specweave:judge-llm src/file.ts --strict # Fail on any concern
|
|
48
|
+
/specweave:judge-llm src/file.ts --fix # Include fix suggestions
|
|
49
|
+
/specweave:judge-llm src/file.ts --export # Export report to markdown
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
## How It Works
|
|
53
|
+
|
|
54
|
+
When you invoke `/specweave:judge-llm`, Claude will:
|
|
55
|
+
|
|
56
|
+
### Step 1: Gather Input
|
|
57
|
+
|
|
58
|
+
Determine what to validate:
|
|
59
|
+
- If file paths provided → read those files
|
|
60
|
+
- If `--staged` → get staged git changes
|
|
61
|
+
- If `--last-commit` → get files from last commit
|
|
62
|
+
- If `--diff <branch>` → get diff against branch
|
|
63
|
+
- If no args → validate recent work in conversation context
|
|
64
|
+
|
|
65
|
+
### Step 2: ULTRATHINK Analysis (Default)
|
|
66
|
+
|
|
67
|
+
**MANDATORY**: Use extended thinking for deep LLM-as-Judge evaluation:
|
|
68
|
+
|
|
69
|
+
```
|
|
70
|
+
Claude MUST use ultrathink/extended thinking to:
|
|
71
|
+
|
|
72
|
+
1. **DEEP READ**: Thoroughly understand all code, context, and intent
|
|
73
|
+
2. **MULTI-DIMENSIONAL ANALYSIS**: Evaluate across ALL dimensions:
|
|
74
|
+
- Correctness: Does it work exactly as intended?
|
|
75
|
+
- Completeness: ALL edge cases handled? ALL requirements met?
|
|
76
|
+
- Security: ANY vulnerabilities? OWASP Top 10 checked?
|
|
77
|
+
- Performance: Algorithmic complexity? Memory usage? Bottlenecks?
|
|
78
|
+
- Maintainability: Clean? Clear? Follows conventions?
|
|
79
|
+
- Testability: Can it be tested? Are tests adequate?
|
|
80
|
+
- Error handling: All failure modes covered?
|
|
81
|
+
3. **CRITICAL EVALUATION**: Weigh ALL findings by severity
|
|
82
|
+
4. **REASONED VERDICT**: Form verdict based on thorough analysis
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
### Step 3: Return Verdict
|
|
86
|
+
|
|
87
|
+
```
|
|
88
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
89
|
+
JUDGE-LLM VERDICT: APPROVED | CONCERNS | REJECTED
|
|
90
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
91
|
+
|
|
92
|
+
Mode: ULTRATHINK (extended thinking)
|
|
93
|
+
Confidence: 0.XX
|
|
94
|
+
Files Analyzed: N
|
|
95
|
+
|
|
96
|
+
REASONING:
|
|
97
|
+
[Detailed chain-of-thought from extended thinking]
|
|
98
|
+
|
|
99
|
+
ISSUES (if any):
|
|
100
|
+
🔴 CRITICAL: [title]
|
|
101
|
+
[description]
|
|
102
|
+
📍 [file:line]
|
|
103
|
+
💡 [suggestion]
|
|
104
|
+
|
|
105
|
+
🟡 HIGH: [title]
|
|
106
|
+
...
|
|
107
|
+
|
|
108
|
+
🟢 LOW: [title]
|
|
109
|
+
...
|
|
110
|
+
|
|
111
|
+
VERDICT: [summary sentence]
|
|
112
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
## Verdict Meanings
|
|
116
|
+
|
|
117
|
+
| Verdict | Meaning | Action |
|
|
118
|
+
|---------|---------|--------|
|
|
119
|
+
| **APPROVED** | Work is solid, no significant issues | Safe to proceed |
|
|
120
|
+
| **CONCERNS** | Issues found worth addressing | Review and fix recommended |
|
|
121
|
+
| **REJECTED** | Critical issues found | MUST fix before proceeding |
|
|
122
|
+
|
|
123
|
+
## Validation Modes
|
|
124
|
+
|
|
125
|
+
### Default Mode (ULTRATHINK) - RECOMMENDED
|
|
126
|
+
- **Extended thinking ENABLED by default**
|
|
127
|
+
- Most thorough validation (~60-90 seconds)
|
|
128
|
+
- Deep multi-dimensional analysis
|
|
129
|
+
- Best for any completed work
|
|
130
|
+
- Cost: ~$0.10-0.25
|
|
131
|
+
|
|
132
|
+
### Quick Mode (`--quick`)
|
|
133
|
+
- Fast validation (~10-15 seconds)
|
|
134
|
+
- Standard reasoning (no extended thinking)
|
|
135
|
+
- Good for quick sanity checks during development
|
|
136
|
+
- Cost: ~$0.02-0.05
|
|
137
|
+
|
|
138
|
+
### Strict Mode (`--strict`)
|
|
139
|
+
- Any concern results in REJECTED
|
|
140
|
+
- Use for critical paths, security code, or CI gates
|
|
141
|
+
- Combines with ultrathink by default
|
|
142
|
+
|
|
143
|
+
## Examples
|
|
144
|
+
|
|
145
|
+
### Example 1: Default ultrathink validation
|
|
146
|
+
|
|
147
|
+
```
|
|
148
|
+
User: /specweave:judge-llm src/core/auth/login.ts
|
|
149
|
+
|
|
150
|
+
Claude: [Uses extended thinking for deep analysis]
|
|
151
|
+
|
|
152
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
153
|
+
JUDGE-LLM VERDICT: APPROVED
|
|
154
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
155
|
+
|
|
156
|
+
Mode: ULTRATHINK (extended thinking)
|
|
157
|
+
Confidence: 0.91
|
|
158
|
+
Files Analyzed: 1
|
|
159
|
+
|
|
160
|
+
REASONING:
|
|
161
|
+
After thorough analysis with extended thinking:
|
|
162
|
+
|
|
163
|
+
The login implementation demonstrates excellent security practices:
|
|
164
|
+
- Password hashing uses bcrypt with cost factor 12 (appropriate)
|
|
165
|
+
- Rate limiting implemented correctly (5 attempts, 15 min exponential backoff)
|
|
166
|
+
- Input validation prevents SQL injection and XSS
|
|
167
|
+
- Error messages are generic (don't leak user existence)
|
|
168
|
+
- Session tokens use cryptographically secure random generation
|
|
169
|
+
- CSRF protection properly implemented
|
|
170
|
+
|
|
171
|
+
Edge cases handled:
|
|
172
|
+
- Empty input validation ✓
|
|
173
|
+
- Unicode normalization for usernames ✓
|
|
174
|
+
- Timing attack mitigation via constant-time comparison ✓
|
|
175
|
+
|
|
176
|
+
No security, performance, or maintainability issues found.
|
|
177
|
+
|
|
178
|
+
VERDICT: Production-ready implementation with excellent security posture.
|
|
179
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
### Example 2: Validate staged changes
|
|
183
|
+
|
|
184
|
+
```
|
|
185
|
+
User: /specweave:judge-llm --staged
|
|
186
|
+
|
|
187
|
+
Claude: [Uses extended thinking]
|
|
188
|
+
|
|
189
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
190
|
+
JUDGE-LLM VERDICT: CONCERNS
|
|
191
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
192
|
+
|
|
193
|
+
Mode: ULTRATHINK (extended thinking)
|
|
194
|
+
Confidence: 0.84
|
|
195
|
+
Files Analyzed: 3
|
|
196
|
+
|
|
197
|
+
REASONING:
|
|
198
|
+
Extended thinking analysis of staged changes reveals:
|
|
199
|
+
|
|
200
|
+
Positive aspects:
|
|
201
|
+
- New API endpoint follows existing patterns
|
|
202
|
+
- TypeScript types are correct
|
|
203
|
+
- Error handling present
|
|
204
|
+
|
|
205
|
+
However, thorough analysis found issues:
|
|
206
|
+
|
|
207
|
+
🟡 HIGH: Missing Input Validation
|
|
208
|
+
User input passed to database without sanitization
|
|
209
|
+
📍 src/api/users.ts:45
|
|
210
|
+
💡 Add Zod schema validation:
|
|
211
|
+
```typescript
|
|
212
|
+
const schema = z.object({ userId: z.string().uuid() });
|
|
213
|
+
const { userId } = schema.parse(req.body);
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
🟡 HIGH: Information Disclosure Risk
|
|
217
|
+
Stack traces exposed in error responses
|
|
218
|
+
📍 src/api/users.ts:62
|
|
219
|
+
💡 Use production error handler that sanitizes output
|
|
220
|
+
|
|
221
|
+
🟢 LOW: Missing rate limiting
|
|
222
|
+
New endpoint has no rate limiting
|
|
223
|
+
📍 src/api/users.ts:30
|
|
224
|
+
💡 Add rate limiter middleware
|
|
225
|
+
|
|
226
|
+
VERDICT: Address HIGH issues before merging. LOW can be follow-up.
|
|
227
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
### Example 3: Quick validation (when needed)
|
|
231
|
+
|
|
232
|
+
```
|
|
233
|
+
User: /specweave:judge-llm src/utils/format.ts --quick
|
|
234
|
+
|
|
235
|
+
Claude: [Standard reasoning, no extended thinking]
|
|
236
|
+
|
|
237
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
238
|
+
JUDGE-LLM VERDICT: APPROVED
|
|
239
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
240
|
+
|
|
241
|
+
Mode: QUICK (standard reasoning)
|
|
242
|
+
Confidence: 0.75
|
|
243
|
+
Files Analyzed: 1
|
|
244
|
+
|
|
245
|
+
REASONING:
|
|
246
|
+
Utility formatting functions look correct. No obvious issues.
|
|
247
|
+
|
|
248
|
+
VERDICT: Looks good for a utility file.
|
|
249
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
## Simplest Usage
|
|
253
|
+
|
|
254
|
+
Just say in your prompt:
|
|
255
|
+
```
|
|
256
|
+
"judge-llm my work"
|
|
257
|
+
"use judge-llm"
|
|
258
|
+
"judge-llm this"
|
|
259
|
+
```
|
|
260
|
+
|
|
261
|
+
Claude will:
|
|
262
|
+
1. Automatically gather context from the conversation
|
|
263
|
+
2. Use ULTRATHINK extended thinking by default
|
|
264
|
+
3. Apply thorough LLM-as-Judge evaluation
|
|
265
|
+
|
|
266
|
+
## Difference from /specweave:qa
|
|
267
|
+
|
|
268
|
+
| Aspect | `/specweave:qa` | `/specweave:judge-llm` |
|
|
269
|
+
|--------|-----------------|------------------------|
|
|
270
|
+
| **Scope** | Increments only | Any files |
|
|
271
|
+
| **Input** | Increment ID | Files, git diff, context |
|
|
272
|
+
| **Default Mode** | Standard | **ULTRATHINK** |
|
|
273
|
+
| **Pattern** | 7-dimension scoring | Judge LLM reasoning |
|
|
274
|
+
| **Focus** | Spec quality, risks | Code correctness |
|
|
275
|
+
| **When** | Before increment close | After any work |
|
|
276
|
+
|
|
277
|
+
## Best Practices
|
|
278
|
+
|
|
279
|
+
1. **Use by default**: Ultrathink is worth the extra time for quality
|
|
280
|
+
2. **Use `--staged`**: Validate before committing
|
|
281
|
+
3. **Use `--strict` for critical code**: Payment, auth, security
|
|
282
|
+
4. **Fix CRITICAL issues immediately**: Never ignore these
|
|
283
|
+
5. **Trust the ultrathink analysis**: Extended thinking catches subtle issues
|
|
284
|
+
|
|
285
|
+
## Limitations
|
|
286
|
+
|
|
287
|
+
- ❌ Doesn't execute tests (use test runners)
|
|
288
|
+
- ❌ Doesn't auto-apply fixes (only suggests)
|
|
289
|
+
- ❌ May miss domain-specific issues
|
|
290
|
+
- ❌ Not a replacement for human review
|
|
291
|
+
|
|
292
|
+
## Related
|
|
293
|
+
|
|
294
|
+
- `/specweave:qa` - Increment-bound quality assessment
|
|
295
|
+
- `/specweave:validate` - Rule-based increment validation
|
|
296
|
+
- `ado-sync-judge` agent - Uses judge pattern for sync validation
|
|
@@ -162,7 +162,7 @@ Uncategorized: 14 files
|
|
|
162
162
|
After running this command, use:
|
|
163
163
|
|
|
164
164
|
```bash
|
|
165
|
-
/specweave-docs:
|
|
165
|
+
/specweave-docs:view
|
|
166
166
|
```
|
|
167
167
|
|
|
168
168
|
The generated indexes will appear in the sidebar:
|
|
@@ -180,6 +180,6 @@ The generated indexes will appear in the sidebar:
|
|
|
180
180
|
|
|
181
181
|
## Related Commands
|
|
182
182
|
|
|
183
|
-
- `/specweave-docs:
|
|
183
|
+
- `/specweave-docs:view` - View documentation with Docusaurus
|
|
184
184
|
- `/specweave-docs:build` - Build static documentation site
|
|
185
185
|
- Enterprise health report - Includes organization recommendations
|