Clone this repository
For self-hosted knots, clone URLs may differ based on your setup.
Download tar.gz
New command: phoenix inspect [--port=N]
Serves a single-page web app showing the full provenance pipeline:
Spec Files → Clauses → Canonical Nodes → IUs → Generated Files
Features:
- 5-column pipeline view with all nodes at each stage
- Click any node to highlight its full causal chain across all columns
- Detail panel shows provenance trace (upstream ↑ and downstream ↓)
- Per-column search/filter
- Stats bar: spec count, clauses, canon nodes, IUs, files, edges, drift
- /data.json endpoint exposes raw pipeline data for external tools
- Dark theme, monospace, keyboard nav (Escape to close)
Also exposes collectInspectData() and renderInspectHTML() as public API
for programmatic access to the pipeline graph.
When re-canonicalization changes an IU's canon_ids, the iu_id changes
too. The manifest previously accumulated both old and new entries for
the same file path, causing false drift detection.
Now recordIU() and recordAll() evict stale manifest entries that own
the same output file paths as an incoming entry with a different IU ID.
Added spec/web-dashboard.md describing a task management dashboard:
- Dashboard page with header, create form, task list
- Styled task cards with priority/status badges
- Analytics stats panel
- Responsive CSS with custom properties
Phoenix bootstrap: 3 spec files → 48 canonical nodes → 11 IUs → 3 services:
- Analytics API (:3000)
- Tasks API (:3001)
- Web Dashboard (:3002/4000) — serves complete HTML with inline CSS+JS
Run: cd examples/taskflow && PORT=4000 node dist/generated/web-dashboard/server.js
Open: http://localhost:4000
- New example: examples/taskflow/ — task management + analytics
2 spec files → 29 canonical nodes → 7 IUs → working TypeScript
Generated via Claude Sonnet with typecheck-and-retry
Clean tsc --noEmit, drift detection, provenance tracing
- Fixed scaffold generator: renamed internal vars metrics→_svcMetrics,
modules→_svcModules to avoid collisions with generated module names
Phase 2: Real LLM Integration
- Added canonicalizer-llm.ts: LLM-enhanced canonical node extraction
with structured JSON prompts, batch processing, and graceful fallback
to rule-based extraction when LLM is unavailable or fails
- Added classifier-llm.ts: LLM-enhanced D-class resolution that
escalates uncertain changes to Claude/GPT for semantic classification,
reducing D-rate in the trust loop
- Wired LLM-enhanced canonicalization into CLI bootstrap and canonicalize
commands (auto-detects provider from ANTHROPIC_API_KEY/OPENAI_API_KEY)
- Added llm_resolved field to ChangeClassification model
Phase 1: E2E Integration Tests (PRD §19 Success Criteria)
- §19.1: Delete generated code → full regen succeeds
- §19.2: Clause change invalidates only dependent IU subtree
- §19.3: Boundary linter catches undeclared coupling
- §19.4: Drift detection blocks unlabeled edits
- §19.5: D-rate within acceptable bounds
- §19.6: Shadow pipeline upgrade produces classified diff
- §19.7: Compaction preserves ancestry
- §19.8: Freeq bots perform ingest/canon/plan/regen/status safely
- Multi-spec project lifecycle tests
- Evidence & cascade pipeline E2E
- Full provenance traceability: spec line → clause → canon → IU → file
Added test fixtures: spec-gateway.md, spec-notifications.md
233 tests passing across 28 test files (was 201 across 25)