@hustle-together/api-dev-tools 1.3.0 → 1.6.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.
package/README.md CHANGED
@@ -26,11 +26,13 @@ Five powerful slash commands for Claude Code:
26
26
  - **`/api-status [endpoint]`** - Track implementation progress and phase completion
27
27
 
28
28
  ### Enforcement Hooks
29
- Three Python hooks that provide **real programmatic guarantees**:
29
+ Five Python hooks that provide **real programmatic guarantees**:
30
30
 
31
31
  - **`enforce-research.py`** - Blocks API code writing until research is complete
32
- - **`track-tool-use.py`** - Logs all research activity (Context7, WebSearch, WebFetch)
33
- - **`api-workflow-check.py`** - Prevents stopping until required phases are complete
32
+ - **`enforce-interview.py`** - Verifies user questions were actually asked (prevents self-answering)
33
+ - **`verify-implementation.py`** - Checks implementation matches interview requirements
34
+ - **`track-tool-use.py`** - Logs all research activity (Context7, WebSearch, WebFetch, AskUserQuestion)
35
+ - **`api-workflow-check.py`** - Prevents stopping until required phases are complete + git diff verification
34
36
 
35
37
  ### State Tracking
36
38
  - **`.claude/api-dev-state.json`** - Persistent state file tracking all workflow progress
@@ -402,6 +404,47 @@ The `.claude/api-dev-state.json` file tracks:
402
404
  - All research activity is **logged** - auditable trail
403
405
  - Workflow completion is **verified** - can't stop early
404
406
 
407
+ ## 🔍 Gap Detection & Verification (v1.6.0+)
408
+
409
+ The workflow now includes automatic detection of common implementation gaps:
410
+
411
+ ### Gap 1: Exact Term Matching
412
+ **Problem:** AI paraphrases user terminology instead of using exact terms for research.
413
+
414
+ **Example:**
415
+ - User says: "Use Vercel AI Gateway"
416
+ - AI searches for: "Vercel AI SDK" (wrong!)
417
+
418
+ **Fix:** `verify-implementation.py` extracts key terms from interview answers and warns if those exact terms weren't used in research queries.
419
+
420
+ ### Gap 2: File Change Tracking
421
+ **Problem:** AI claims "all files updated" but doesn't verify which files actually changed.
422
+
423
+ **Fix:** `api-workflow-check.py` runs `git diff --name-only` and compares against tracked `files_created`/`files_modified` in state. Warns about untracked changes.
424
+
425
+ ### Gap 3: Skipped Test Investigation
426
+ **Problem:** AI accepts "9 tests skipped" without investigating why.
427
+
428
+ **Fix:** `verification_warnings` in state file tracks issues that need review. Stop hook shows unaddressed warnings.
429
+
430
+ ### Gap 4: Implementation Verification
431
+ **Problem:** AI marks task complete without verifying implementation matches interview.
432
+
433
+ **Fix:** Stop hook checks that:
434
+ - Route files exist if endpoints mentioned
435
+ - Test files are tracked
436
+ - Key terms from interview appear in implementation
437
+
438
+ ### Gap 5: Test/Production Alignment
439
+ **Problem:** Test files check different environment variables than production code.
440
+
441
+ **Example:**
442
+ - Interview: "single gateway key"
443
+ - Production: uses `AI_GATEWAY_API_KEY`
444
+ - Test: still checks `OPENAI_API_KEY` (wrong!)
445
+
446
+ **Fix:** `verify-implementation.py` warns when test files check env vars that don't match interview requirements.
447
+
405
448
  ## 🔧 Requirements
406
449
 
407
450
  - **Node.js** 14.0.0 or higher