specky-sdd 2.3.1 → 3.1.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/CHANGELOG.md +108 -1
- package/README.md +200 -175
- package/SECURITY.md +78 -3
- package/dist/constants.d.ts +8 -4
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +10 -1
- package/dist/constants.js.map +1 -1
- package/dist/index.js +28 -6
- package/dist/index.js.map +1 -1
- package/dist/schemas/context.d.ts +9 -0
- package/dist/schemas/context.d.ts.map +1 -0
- package/dist/schemas/context.js +10 -0
- package/dist/schemas/context.js.map +1 -0
- package/dist/schemas/metrics.d.ts +9 -0
- package/dist/schemas/metrics.d.ts.map +1 -0
- package/dist/schemas/metrics.js +10 -0
- package/dist/schemas/metrics.js.map +1 -0
- package/dist/schemas/pipeline.d.ts +9 -0
- package/dist/schemas/pipeline.d.ts.map +1 -1
- package/dist/schemas/pipeline.js +36 -0
- package/dist/schemas/pipeline.js.map +1 -1
- package/dist/schemas/quality.d.ts +1 -1
- package/dist/schemas/routing.d.ts +9 -0
- package/dist/schemas/routing.d.ts.map +1 -0
- package/dist/schemas/routing.js +21 -0
- package/dist/schemas/routing.js.map +1 -0
- package/dist/schemas/utility.d.ts +1 -0
- package/dist/schemas/utility.d.ts.map +1 -1
- package/dist/schemas/visualization.d.ts +7 -0
- package/dist/schemas/visualization.d.ts.map +1 -1
- package/dist/schemas/visualization.js +7 -2
- package/dist/schemas/visualization.js.map +1 -1
- package/dist/services/audit-logger.d.ts +30 -0
- package/dist/services/audit-logger.d.ts.map +1 -0
- package/dist/services/audit-logger.js +64 -0
- package/dist/services/audit-logger.js.map +1 -0
- package/dist/services/cognitive-debt-engine.d.ts +22 -0
- package/dist/services/cognitive-debt-engine.d.ts.map +1 -0
- package/dist/services/cognitive-debt-engine.js +52 -0
- package/dist/services/cognitive-debt-engine.js.map +1 -0
- package/dist/services/context-tiering-engine.d.ts +38 -0
- package/dist/services/context-tiering-engine.d.ts.map +1 -0
- package/dist/services/context-tiering-engine.js +66 -0
- package/dist/services/context-tiering-engine.js.map +1 -0
- package/dist/services/dependency-graph.d.ts +32 -0
- package/dist/services/dependency-graph.d.ts.map +1 -0
- package/dist/services/dependency-graph.js +280 -0
- package/dist/services/dependency-graph.js.map +1 -0
- package/dist/services/diagram-generator.d.ts +7 -0
- package/dist/services/diagram-generator.d.ts.map +1 -1
- package/dist/services/diagram-generator.js +245 -0
- package/dist/services/diagram-generator.js.map +1 -1
- package/dist/services/doc-generator.d.ts +9 -1
- package/dist/services/doc-generator.d.ts.map +1 -1
- package/dist/services/doc-generator.js +151 -1
- package/dist/services/doc-generator.js.map +1 -1
- package/dist/services/intent-drift-engine.d.ts +41 -0
- package/dist/services/intent-drift-engine.d.ts.map +1 -0
- package/dist/services/intent-drift-engine.js +101 -0
- package/dist/services/intent-drift-engine.js.map +1 -0
- package/dist/services/methodology.d.ts +33 -0
- package/dist/services/methodology.d.ts.map +1 -0
- package/dist/services/methodology.js +311 -0
- package/dist/services/methodology.js.map +1 -0
- package/dist/services/metrics-generator.d.ts +42 -0
- package/dist/services/metrics-generator.d.ts.map +1 -0
- package/dist/services/metrics-generator.js +200 -0
- package/dist/services/metrics-generator.js.map +1 -0
- package/dist/services/model-routing-engine.d.ts +38 -0
- package/dist/services/model-routing-engine.d.ts.map +1 -0
- package/dist/services/model-routing-engine.js +127 -0
- package/dist/services/model-routing-engine.js.map +1 -0
- package/dist/services/pbt-generator.d.ts +1 -1
- package/dist/services/pbt-generator.d.ts.map +1 -1
- package/dist/services/pbt-generator.js +62 -0
- package/dist/services/pbt-generator.js.map +1 -1
- package/dist/services/state-machine.d.ts +28 -1
- package/dist/services/state-machine.d.ts.map +1 -1
- package/dist/services/state-machine.js +198 -0
- package/dist/services/state-machine.js.map +1 -1
- package/dist/services/template-engine.d.ts +5 -2
- package/dist/services/template-engine.d.ts.map +1 -1
- package/dist/services/template-engine.js +19 -4
- package/dist/services/template-engine.js.map +1 -1
- package/dist/services/test-result-parser.d.ts +23 -0
- package/dist/services/test-result-parser.d.ts.map +1 -0
- package/dist/services/test-result-parser.js +90 -0
- package/dist/services/test-result-parser.js.map +1 -0
- package/dist/services/test-traceability-mapper.d.ts +37 -0
- package/dist/services/test-traceability-mapper.d.ts.map +1 -0
- package/dist/services/test-traceability-mapper.js +102 -0
- package/dist/services/test-traceability-mapper.js.map +1 -0
- package/dist/tools/analysis.d.ts +2 -1
- package/dist/tools/analysis.d.ts.map +1 -1
- package/dist/tools/analysis.js +28 -2
- package/dist/tools/analysis.js.map +1 -1
- package/dist/tools/checkpoint.d.ts.map +1 -1
- package/dist/tools/checkpoint.js +7 -3
- package/dist/tools/checkpoint.js.map +1 -1
- package/dist/tools/context.d.ts +9 -0
- package/dist/tools/context.d.ts.map +1 -0
- package/dist/tools/context.js +86 -0
- package/dist/tools/context.js.map +1 -0
- package/dist/tools/documentation.d.ts.map +1 -1
- package/dist/tools/documentation.js +54 -4
- package/dist/tools/documentation.js.map +1 -1
- package/dist/tools/environment.d.ts.map +1 -1
- package/dist/tools/environment.js +7 -3
- package/dist/tools/environment.js.map +1 -1
- package/dist/tools/infrastructure.d.ts.map +1 -1
- package/dist/tools/infrastructure.js +7 -3
- package/dist/tools/infrastructure.js.map +1 -1
- package/dist/tools/input.d.ts.map +1 -1
- package/dist/tools/input.js +7 -3
- package/dist/tools/input.js.map +1 -1
- package/dist/tools/integration.d.ts.map +1 -1
- package/dist/tools/integration.js +11 -5
- package/dist/tools/integration.js.map +1 -1
- package/dist/tools/metrics.d.ts +11 -0
- package/dist/tools/metrics.d.ts.map +1 -0
- package/dist/tools/metrics.js +105 -0
- package/dist/tools/metrics.js.map +1 -0
- package/dist/tools/pbt.d.ts +1 -1
- package/dist/tools/pbt.d.ts.map +1 -1
- package/dist/tools/pbt.js +4 -2
- package/dist/tools/pbt.js.map +1 -1
- package/dist/tools/pipeline.d.ts.map +1 -1
- package/dist/tools/pipeline.js +172 -16
- package/dist/tools/pipeline.js.map +1 -1
- package/dist/tools/quality.d.ts.map +1 -1
- package/dist/tools/quality.js +11 -5
- package/dist/tools/quality.js.map +1 -1
- package/dist/tools/response-builder.d.ts +40 -0
- package/dist/tools/response-builder.d.ts.map +1 -0
- package/dist/tools/response-builder.js +103 -0
- package/dist/tools/response-builder.js.map +1 -0
- package/dist/tools/routing.d.ts +7 -0
- package/dist/tools/routing.d.ts.map +1 -0
- package/dist/tools/routing.js +67 -0
- package/dist/tools/routing.js.map +1 -0
- package/dist/tools/testing.d.ts +3 -1
- package/dist/tools/testing.d.ts.map +1 -1
- package/dist/tools/testing.js +52 -5
- package/dist/tools/testing.js.map +1 -1
- package/dist/tools/transcript.d.ts.map +1 -1
- package/dist/tools/transcript.js +30 -38
- package/dist/tools/transcript.js.map +1 -1
- package/dist/tools/turnkey.d.ts.map +1 -1
- package/dist/tools/turnkey.js +32 -10
- package/dist/tools/turnkey.js.map +1 -1
- package/dist/tools/utility.d.ts +2 -1
- package/dist/tools/utility.d.ts.map +1 -1
- package/dist/tools/utility.js +84 -7
- package/dist/tools/utility.js.map +1 -1
- package/dist/tools/visualization.d.ts.map +1 -1
- package/dist/tools/visualization.js +10 -5
- package/dist/tools/visualization.js.map +1 -1
- package/dist/types.d.ts +54 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/context-helper.d.ts +13 -0
- package/dist/utils/context-helper.d.ts.map +1 -0
- package/dist/utils/context-helper.js +14 -0
- package/dist/utils/context-helper.js.map +1 -0
- package/dist/utils/routing-helper.d.ts +16 -0
- package/dist/utils/routing-helper.d.ts.map +1 -0
- package/dist/utils/routing-helper.js +16 -0
- package/dist/utils/routing-helper.js.map +1 -0
- package/hooks/auto-checkpoint.md +22 -0
- package/hooks/release-gate.md +82 -0
- package/hooks/spec-quality.md +55 -0
- package/hooks/task-tracer.md +63 -0
- package/package.json +4 -3
- package/templates/design.md +68 -12
- package/templates/journey.md +73 -0
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,110 @@ All notable changes to Specky are documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [3.1.0] - 2026-04-12
|
|
9
|
+
|
|
10
|
+
### Intelligence Layer (Specs 003–007)
|
|
11
|
+
|
|
12
|
+
#### Model Routing Guidance (Spec 003)
|
|
13
|
+
- **`sdd_model_routing`** (NEW tool #54): Returns the full 10-phase model routing decision table with optimal model, mode, extended thinking settings, arXiv evidence, and cost savings calculator
|
|
14
|
+
- **`model_routing_hint`** field added to ALL 55 tool responses via `buildToolResponse()` — every response now tells the AI client which model to use for the current phase
|
|
15
|
+
- Complexity override: `implement`/`design` phases with >10 files escalate to Opus automatically
|
|
16
|
+
- `ModelRoutingEngine` service with empirically-grounded ROUTING_TABLE (arXiv:2601.08419)
|
|
17
|
+
|
|
18
|
+
#### Context Tiering (Spec 004)
|
|
19
|
+
- **`sdd_context_status`** (NEW tool #55): Returns Hot/Domain/Cold tier assignment for all spec artifacts with estimated token savings
|
|
20
|
+
- **`context_load_summary`** field added to ALL 55 tool responses — shows which files are loaded per call
|
|
21
|
+
- `ContextTieringEngine` service: CONSTITUTION.md=Hot, SPEC/DESIGN/TASKS=Domain, ANALYSIS/CHECKLIST/etc=Cold
|
|
22
|
+
- Token estimation: `Math.ceil(content.length / 4)` — matches GPT/Claude tokenization heuristic
|
|
23
|
+
|
|
24
|
+
#### Cognitive Debt Metrics (Spec 005)
|
|
25
|
+
- **`cognitive_debt`** field in `sdd_metrics` and `sdd_get_status` responses (when gate history available)
|
|
26
|
+
- Gate instrumentation in `sdd_advance_phase`: records mtime-based modified/unmodified detection per gate
|
|
27
|
+
- `CognitiveDebtEngine` service: LGTM-without-modification rate as cognitive surrender signal; score = `(lgtm_rate × 0.6) + (delta_normalized × 0.4)`, labels: healthy/caution/high_risk
|
|
28
|
+
- Warning shown in `sdd_advance_phase` response when unmodified approval is detected
|
|
29
|
+
|
|
30
|
+
#### Verified Test Loop (Spec 006)
|
|
31
|
+
- **`TestResultParser`** service: auto-detects and parses Vitest JSON, pytest JSON, and JUnit XML into normalized `TestResult[]`
|
|
32
|
+
- **`TestTraceabilityMapper`** service: maps test names to REQ-XXX IDs via `// REQ-XXX` comment convention, builds per-requirement coverage report and failure details with `suggested_fix_prompt`
|
|
33
|
+
- `sdd_verify_tests` enhanced: adds `enhanced_coverage` (per-requirement breakdown) and `failure_details` to response when parsers are wired
|
|
34
|
+
- JUnit XML parser bug fixed: self-closing `<testcase .../>` was greedily consumed by open-tag alternative, merging two testcases; fixed with negative lookbehind `(?<!\/)`
|
|
35
|
+
|
|
36
|
+
#### Intent Drift Detection (Spec 007)
|
|
37
|
+
- **`intent_drift`** report in `sdd_check_sync` and `sdd_metrics` responses
|
|
38
|
+
- **`drift_amendment_suggestion`** in `sdd_amend` response when last drift score > 40 — lists orphaned constitutional principles with recommended spec actions
|
|
39
|
+
- `IntentDriftEngine` service: extracts principles from CONSTITUTION.md `## Article` sections, keyword-overlap coverage detection (≥2 keywords threshold), trend analysis (improving/stable/worsening) over last 3 DriftSnapshots
|
|
40
|
+
- `drift_history` stored in `.sdd-state.json` (FIFO, max 100 entries)
|
|
41
|
+
|
|
42
|
+
### Stats
|
|
43
|
+
- **56 tools** (was 53, corrected to 56 — sdd_metrics, sdd_validate_ears, sdd_check_ecosystem were already implemented but undercounted): +sdd_model_routing, +sdd_context_status, count reconciled
|
|
44
|
+
- **24 services** (was 18): +ModelRoutingEngine, +ContextTieringEngine, +CognitiveDebtEngine, +IntentDriftEngine, +TestResultParser, +TestTraceabilityMapper
|
|
45
|
+
- **507 unit tests** across 30 test files (was 321 across 22 files)
|
|
46
|
+
- All 7 specs (001–007) at ≥93% acceptance criteria coverage
|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
## [3.0.0] - 2026-03-26
|
|
51
|
+
|
|
52
|
+
### Pipeline Validation & Enforcement
|
|
53
|
+
- **Phase validation on every tool**: `validatePhaseForTool()` maps 53 tools to allowed pipeline phases; tools called out-of-order return structured errors with fix guidance
|
|
54
|
+
- **Gate decision enforcement**: `advancePhase()` now blocks advancement past Analyze if gate decision is BLOCK or CHANGES_NEEDED; only APPROVE allows progression
|
|
55
|
+
- **Clarify phase fix**: `sdd_clarify` now properly completes the Clarify phase (was stuck in `in_progress`)
|
|
56
|
+
- **Proper state transitions**: `sdd_auto_pipeline` and `sdd_turnkey_spec` now use `advancePhase()` instead of direct state manipulation
|
|
57
|
+
|
|
58
|
+
### Software Engineering Diagrams (10 → 17 types)
|
|
59
|
+
- **7 new diagram types**: C4 Component (L3), C4 Code (L4), Activity, Use Case, Data Flow (DFD), Deployment, Network Topology
|
|
60
|
+
- **`generateAllDiagrams()`** now generates up to 16 diagrams per feature automatically
|
|
61
|
+
- **Schema updated**: `diagram_type` enum expanded from 10 to 17 types
|
|
62
|
+
|
|
63
|
+
### System Design Completeness (6 → 12 sections)
|
|
64
|
+
- **Design template expanded**: System Context (C4 L1), Container Architecture (C4 L2), Component Design (C4 L3), Code-Level Design (C4 L4), System Diagrams, Data Model, API Contracts, Infrastructure & Deployment, Security Architecture, ADRs, Error Handling, Cross-Cutting Concerns
|
|
65
|
+
- **9 new optional fields** in `writeDesignInputSchema` for backward compatibility
|
|
66
|
+
- **Design completeness validation**: `validateDesignCompleteness()` scores DESIGN.md against 12 required sections
|
|
67
|
+
|
|
68
|
+
### Enriched Interactive Responses (ALL 53 tools)
|
|
69
|
+
- **`enrichResponse()`**: Every tool response now includes phase progress bar, educational notes, methodology tips, handoff context, and parallel execution hints
|
|
70
|
+
- **`enrichStateless()`**: Utility tools without phase context get educational notes and common mistakes
|
|
71
|
+
- **`buildPhaseError()`**: Structured phase validation errors with fix guidance and methodology context
|
|
72
|
+
- **`MethodologyGuide`** service: Educational content for all 10 phases (what/why/how/anti-patterns/best-practices) and 20+ tools
|
|
73
|
+
- **`DependencyGraph`** service: Parallel execution groups for all 10 phases, tool dependency mapping, execution plans
|
|
74
|
+
|
|
75
|
+
### Parallel Documentation Generation
|
|
76
|
+
- **`sdd_generate_all_docs`** (NEW tool #53): Generates 5 doc types in parallel via `Promise.all()`
|
|
77
|
+
- **`generateJourneyDocs()`**: New SDD Journey document capturing complete pipeline audit trail (phases, timestamps, gate decisions, traceability)
|
|
78
|
+
- **DocGenerator wired with StateMachine** for phase-aware documentation
|
|
79
|
+
|
|
80
|
+
### Active Hooks (6 → 7)
|
|
81
|
+
- **`auto-checkpoint.sh`** (NEW): Suggests checkpoint creation when spec artifacts are modified
|
|
82
|
+
- **`security-scan.sh`** now BLOCKS (exit 2) when hardcoded secrets detected
|
|
83
|
+
- **`spec-sync.sh`** enhanced with drift detection and spec-reference checking
|
|
84
|
+
- **`auto-docs.sh`** enhanced with modification tracking via `.doc-tracker.json`
|
|
85
|
+
|
|
86
|
+
### Interactive Commands (12 rewritten)
|
|
87
|
+
- All 12 `/sdd:*` commands rewritten with step-by-step educational guidance
|
|
88
|
+
- Every step explains "What's happening" and "Why it matters"
|
|
89
|
+
- WAIT/LGTM gates at all quality checkpoints
|
|
90
|
+
- Enriched response data surfaced (progress bar, parallel hints, handoff)
|
|
91
|
+
- Error recovery sections with guidance back on track
|
|
92
|
+
|
|
93
|
+
### New Files
|
|
94
|
+
- `src/services/methodology.ts` — Educational content service (static, no dependencies)
|
|
95
|
+
- `src/services/dependency-graph.ts` — Parallel execution graph (static, no dependencies)
|
|
96
|
+
- `src/tools/response-builder.ts` — Response enrichment (enrichResponse, enrichStateless, buildPhaseError)
|
|
97
|
+
- `templates/journey.md` — SDD Journey documentation template
|
|
98
|
+
- `.claude/hooks/auto-checkpoint.sh` — Auto-checkpoint hook
|
|
99
|
+
|
|
100
|
+
### Stats
|
|
101
|
+
- **53 tools** (was 52), **17 diagram types** (was 10), **22 templates** (was 21), **7 hooks** (was 6)
|
|
102
|
+
- **18 services** (was 16): +MethodologyGuide, +DependencyGraph
|
|
103
|
+
- **321 unit tests**, all passing
|
|
104
|
+
- **12 interactive commands** fully rewritten
|
|
105
|
+
|
|
106
|
+
## [2.3.1] - 2026-03-25
|
|
107
|
+
|
|
108
|
+
### Changed
|
|
109
|
+
- Added Specky MCP logo and icon (PNG 256x256 + 128x128) for VS Code MCP Gallery and npm
|
|
110
|
+
- Configured "icon" field in package.json
|
|
111
|
+
|
|
8
112
|
## [2.3.0] - 2026-03-24
|
|
9
113
|
|
|
10
114
|
### Added
|
|
@@ -43,7 +147,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
43
147
|
- `sdd_verify_tests` tool — verifies test results JSON against specification requirements, reports traceability coverage
|
|
44
148
|
- `.specky/config.yml` support — project-local configuration for templates path, default framework, compliance frameworks, audit toggle
|
|
45
149
|
- `src/config.ts` — centralized configuration loader with simple YAML parsing
|
|
46
|
-
- MCP integration test (`tests/integration/pipeline-e2e.test.ts`) —
|
|
150
|
+
- MCP integration test (`tests/integration/pipeline-e2e.test.ts`) — full pipeline validation with real FileManager
|
|
47
151
|
- Unit tests for 6 additional services: DocGenerator, GitManager, IacGenerator, WorkItemExporter, TranscriptParser, DocumentConverter
|
|
48
152
|
- OpenSSF Scorecard workflow (`.github/workflows/scorecard.yml`)
|
|
49
153
|
- SBOM generation (CycloneDX) in CI pipeline
|
|
@@ -118,6 +222,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
118
222
|
- Zod schema validation on all tool inputs
|
|
119
223
|
- Published to npm (`specky-sdd`), GitHub Container Registry, and GitHub Releases
|
|
120
224
|
|
|
225
|
+
[3.0.0]: https://github.com/paulasilvatech/specky/compare/v2.3.1...v3.0.0
|
|
226
|
+
[2.3.1]: https://github.com/paulasilvatech/specky/compare/v2.3.0...v2.3.1
|
|
227
|
+
[2.3.0]: https://github.com/paulasilvatech/specky/compare/v2.2.0...v2.3.0
|
|
121
228
|
[2.2.0]: https://github.com/paulasilvatech/specky/compare/v2.1.0...v2.2.0
|
|
122
229
|
[2.1.0]: https://github.com/paulasilvatech/specky/compare/v2.0.0...v2.1.0
|
|
123
230
|
[2.0.0]: https://github.com/paulasilvatech/specky/compare/v1.0.0...v2.0.0
|