empirical-sdd 0.31.0 → 0.33.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 CHANGED
@@ -8,6 +8,99 @@ under the alpha rules in [docs/versioning.md](docs/versioning.md).
8
8
 
9
9
  ## [Unreleased]
10
10
 
11
+ ## [0.33.0] - 2026-09-09
12
+
13
+ ### Added
14
+
15
+ - Added a saved **Create mockups before coding?** Yes/No preference to init and
16
+ configuration, exposed as `mockupsBeforeCoding` through MCP. Existing
17
+ repositories retain enabled behavior until explicitly changed. Disabling it
18
+ skips mandatory UI mockups while retaining fidelity checks for approved designs.
19
+ - Added a terminal-only fresh-repository demo with recorded CLI, MCP, worktree,
20
+ verification, review, and integration scenarios.
21
+
22
+ ### Changed
23
+
24
+ - Setup shows proposed defaults for new repositories and actual saved values
25
+ for existing repositories, with one applicable menu and explicit Save.
26
+ - Init prefers permitted host-native selection controls and uses one text
27
+ prompt when they are unavailable, without duplicating the same question.
28
+ - Linear MCP discovery resolves actual host tools by provider and capability,
29
+ including lazy-loaded tools, and distinguishes configuration, tool exposure,
30
+ authentication, permissions, and transient failures before offering recovery.
31
+
32
+ ### Fixed
33
+
34
+ - Fixed initialization rejecting valid Linear MCP policies after discovery and
35
+ preview by routing them through the existing credential-free MCP setup path.
36
+ - Prevented missing tool-name prefixes or unavailable future write operations
37
+ from triggering an automatic Linear API-key fallback.
38
+ - Preserved an explicit mockup preference through repeated initialization and
39
+ unrelated configuration updates, while rejecting invalid values before writes.
40
+ - Limited product test discovery to `tests/` so generated demo repositories do
41
+ not accidentally enter the product suite.
42
+
43
+ ### Migration
44
+
45
+ No migration required.
46
+
47
+ ## [0.32.0] - 2026-09-08
48
+
49
+ ### Added
50
+
51
+ - Added a six-step initialization wizard covering Setup, Preferences, Review
52
+ bot, Tracking, Confirm, and Apply, with Back/Edit navigation, retained
53
+ choices, and explicit Save before setup changes.
54
+ - Added clickable app and feature mockup previews through `empirical mockups`,
55
+ human approval before UI contracts freeze, and fidelity checks against the
56
+ approved design during verification.
57
+ - Added explicit reuse of exact-revision QA receipts after validating source,
58
+ specification, policy, command, runtime, executable, and artifact identities.
59
+ - Added bounded verification progress and a repeatable benchmark for measuring
60
+ final verification without treating diagnostics as promotion evidence.
61
+ - Added explicit selection of existing specs and recoverable approved worktree
62
+ handoffs, including retries after interrupted Git creation or feature setup.
63
+
64
+ ### Changed
65
+
66
+ - Capability claims are now non-exclusive: specs in separate worktrees can
67
+ progress on the same capability while integration retains semantic conflict
68
+ detection against each spec's recorded base.
69
+ - Git worktrees now use their own selected feature instead of automatically
70
+ inheriting unfinished spec histories. Multiple unclaimed specs may remain
71
+ inactive without blocking unrelated new work.
72
+ - Reviewer-bot setup is optional, includes an explicit disable choice, and
73
+ preserves saved fresh-context review without repeated credential prompts.
74
+ - Linear tracking prefers authenticated sibling MCP tools, including upgrade
75
+ recovery from legacy API-key configuration, and derives ticket content from
76
+ the specification while storing recovery identities in attachment metadata.
77
+
78
+ ### Fixed
79
+
80
+ - Prevented unrelated malformed or blocked feature histories and sibling
81
+ checkout metadata from blocking normal work in another Git checkout.
82
+ - Preserved strict tracker recovery obligations and checkout ownership across
83
+ terminal transitions, interrupted handoffs, and explicit feature selection.
84
+ - Bound reused verification evidence to the selected executable and runtime
85
+ permission metadata so changed execution conditions cannot reuse stale proof.
86
+ - Rejected blank mockup approvals and ambiguous fidelity fields, and preserved
87
+ path containment and explicit human design decisions.
88
+ - Preserved user-authored tracker content while validating bounded MCP recovery
89
+ results and avoiding repeated provider mutations after ambiguous responses.
90
+
91
+ ### Migration
92
+
93
+ After upgrading, run `empirical update` to refresh installed bootstrap guidance
94
+ and invoke `empirical-init` in existing repositories to refresh managed local
95
+ workflow instructions while retaining saved settings. Schema 5 remains in use;
96
+ no manual data conversion is required.
97
+
98
+ A Git checkout without a selected feature now remains idle. To resume an existing
99
+ spec, explicitly select its feature through `empirical_select`; unclaimed specs
100
+ are retained. UI changes must record the mockup approval and fidelity artifacts
101
+ requested by the workflow. Verification receipts without matching current runtime
102
+ and executable identities must be rerun rather than reused.
103
+
11
104
  ## [0.31.0] - 2026-09-04
12
105
 
13
106
  ### Added
@@ -381,7 +474,9 @@ Published through GitHub Actions trusted publishing with npm provenance.
381
474
 
382
475
  - Prepared and released package version `0.20.2`.
383
476
 
384
- [Unreleased]: https://github.com/goempirical/empirical-sdd/compare/v0.31.0...HEAD
477
+ [Unreleased]: https://github.com/goempirical/empirical-sdd/compare/v0.33.0...HEAD
478
+ [0.33.0]: https://github.com/goempirical/empirical-sdd/compare/v0.32.0...v0.33.0
479
+ [0.32.0]: https://github.com/goempirical/empirical-sdd/compare/v0.31.0...v0.32.0
385
480
  [0.31.0]: https://github.com/goempirical/empirical-sdd/compare/v0.30.0...v0.31.0
386
481
  [0.30.0]: https://github.com/goempirical/empirical-sdd/compare/v0.29.0...v0.30.0
387
482
  [0.29.0]: https://github.com/goempirical/empirical-sdd/compare/v0.28.0...v0.29.0
package/README.md CHANGED
@@ -26,6 +26,17 @@ workflow. Its zero-build source is [docs/index.html](docs/index.html).
26
26
  - Codex: `$empirical-init`
27
27
  - Claude Code: `/empirical-init`
28
28
 
29
+ Init guides you through six steps in your agent chat: **Setup → Preferences →
30
+ Review bot → Tracking → Confirm → Apply**. It shows your current step and asks
31
+ one question at a time. Use **Back** or **Edit** to revisit a section while
32
+ keeping your other answers. Nothing is applied until you confirm **Save**.
33
+
34
+ Bot review is optional. Init offers it once; say “no,” “skip,” or “ignore”
35
+ to save fresh-context review without a bot token. Future init runs preserve
36
+ that choice. To enable it later, tell your agent “enable bot review.”
37
+ Fresh-context review still uses an isolated reviewer, but does not count as
38
+ an independent GitHub approval.
39
+
29
40
  3. Ask for the change normally.
30
41
 
31
42
  ```text
@@ -60,6 +71,12 @@ Empirical routes by risk, not prompt length:
60
71
  Specify → Design → Plan → Implement → Context? → Verify → Review → Integrate
61
72
  ```
62
73
 
74
+ A feature that shows an interface gets its mockup at Specify, while the
75
+ contract is still open, because seeing a screen reveals states and flows that
76
+ prose misses and those belong in the criteria. `empirical mockups` serves the
77
+ directions on a local address so a person can click through and choose one;
78
+ Verify then checks what was built against what was approved.
79
+
63
80
  Context runs when repository knowledge needs refinement. Failed verification or
64
81
  requested review changes return to implementation. Evidence, review, and
65
82
  integration are different claims, and Empirical reports only the highest level
@@ -82,8 +99,10 @@ repository/
82
99
  ├── policy.json verification and delivery policy
83
100
  ├── tracker.json secret-free tracker choice
84
101
  ├── context/ repository knowledge
102
+ ├── mockups/decision.md app mockups adopted or declined
85
103
  ├── specs/<feature>/
86
104
  │ ├── spec.md + decisions.md contract and decisions
105
+ │ ├── mockups/ approved directions and fidelity
87
106
  │ ├── design.md + plan.md Complex approach and plan
88
107
  │ ├── impact.json affected behavior and surfaces
89
108
  │ ├── state.json + events/ phase and resumable journal
@@ -138,3 +157,17 @@ reserved for validated release pull requests.
138
157
  ## License
139
158
 
140
159
  [MIT](LICENSE)
160
+
161
+ ### Shared specs across worktrees
162
+
163
+ Specs and capability contracts are repository artifacts. Each Git worktree
164
+ selects and claims its own active feature in local Git metadata; different
165
+ worktrees can execute different features concurrently. Unclaimed or temporarily
166
+ inactive specs stay in `.empirical/specs/`. They are not abandoned work.
167
+
168
+ Use the agent's `empirical_select` operation to resume an existing unclaimed
169
+ feature. Explicit new feature starts and repository setup/context repair are not
170
+ blocked by unrelated unclaimed specs. If a feature-required operation needs a
171
+ choice, it lists candidates rather than choosing or moving a spec. An approved
172
+ worktree handoff can be retried with its original input after interruption.
173
+ See [selection and recovery semantics](docs/protocol.md#shared-specs-and-checkout-selection).
@@ -1,3 +1,5 @@
1
+ /** Serialize checkout ownership across every worktree sharing Git metadata. */
2
+ export declare function withCheckoutLock<T>(root: string, operation: () => Promise<T>): Promise<T>;
1
3
  export interface CheckoutSelection {
2
4
  feature: string | null;
3
5
  linked: boolean;
@@ -5,4 +7,17 @@ export interface CheckoutSelection {
5
7
  claimedElsewhere: Set<string>;
6
8
  }
7
9
  export declare function readCheckoutSelection(rootInput: string): Promise<CheckoutSelection>;
8
- export declare function writeCheckoutSelection(rootInput: string, feature: string | null): Promise<void>;
10
+ export declare function writeCheckoutSelection(rootInput: string, feature: string | null, expectedFeature?: string): Promise<void>;
11
+ /** Read only this checkout's recovery anchor, never sibling selections. */
12
+ export declare function readCheckoutLastFeature(rootInput: string): Promise<{
13
+ git: boolean;
14
+ feature: string | null;
15
+ }>;
16
+ export declare function readCheckoutRecoveryFeatures(rootInput: string): Promise<{
17
+ git: boolean;
18
+ features: string[];
19
+ }>;
20
+ /** Write-ahead ownership: call after validation but before a terminal journal
21
+ * commit, so a process exit before selector cleanup cannot orphan the effect. */
22
+ export declare function recordCheckoutRecoveryFeature(rootInput: string, feature: string): Promise<void>;
23
+ export declare function forgetCheckoutRecoveryFeatures(rootInput: string, resolvedFeatures: string[]): Promise<void>;