empirical-sdd 0.20.4 → 0.23.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 +78 -0
- package/README.md +124 -48
- package/dist/agent-catalog.d.ts +3 -3
- package/dist/cli.js +39354 -31535
- package/dist/coordination.d.ts +94 -0
- package/dist/core.d.ts +27 -4
- package/dist/delivery.d.ts +139 -0
- package/dist/doctor.d.ts +16 -0
- package/dist/evidence.d.ts +47 -0
- package/dist/index.d.ts +3 -13
- package/dist/index.js +24689 -3327
- package/dist/integrations.d.ts +14 -22
- package/dist/integrations.js +18776 -0
- package/dist/journal.d.ts +66 -0
- package/dist/knowledge-templates.d.ts +2 -0
- package/dist/knowledge.d.ts +17 -2
- package/dist/lifecycle.d.ts +5 -0
- package/dist/mcp.js +41643 -0
- package/dist/migration-scratch.d.ts +7 -0
- package/dist/migration.d.ts +16 -0
- package/dist/operations.d.ts +38 -0
- package/dist/policy.d.ts +10 -0
- package/dist/protocol.d.ts +381 -0
- package/dist/protocol.js +15086 -0
- package/dist/routing.d.ts +24 -0
- package/dist/runtime.d.ts +52 -0
- package/dist/specifications.d.ts +15 -0
- package/dist/storage.d.ts +3 -1
- package/dist/tracking.d.ts +108 -0
- package/dist/types.d.ts +287 -7
- package/docs/versioning.md +64 -0
- package/package.json +28 -10
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to Empirical SDD are documented in this file.
|
|
4
|
+
|
|
5
|
+
The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project follows [Semantic Versioning](https://semver.org/spec/v2.0.0.html)
|
|
7
|
+
under the alpha rules in [docs/versioning.md](docs/versioning.md).
|
|
8
|
+
|
|
9
|
+
## [Unreleased]
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
|
|
13
|
+
- Nothing yet.
|
|
14
|
+
|
|
15
|
+
## [0.23.0] - 2026-08-11
|
|
16
|
+
|
|
17
|
+
This version is prepared in the repository but is not published by the version
|
|
18
|
+
change alone.
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
|
|
22
|
+
- Replaced the globally automatic `empirical` skill with the explicit,
|
|
23
|
+
setup-only `empirical-init` bootstrap.
|
|
24
|
+
- Made initialized repositories route ordinary change prompts automatically
|
|
25
|
+
through marker-owned local instructions and skills; read-only prompts remain
|
|
26
|
+
outside the workflow.
|
|
27
|
+
- Added explicit-only invocation metadata where supported and retained all
|
|
28
|
+
existing workflow, evidence, tracker, integration, and publication gates.
|
|
29
|
+
|
|
30
|
+
### Added
|
|
31
|
+
|
|
32
|
+
- Added this changelog and a documented alpha Semantic Versioning and release
|
|
33
|
+
policy.
|
|
34
|
+
|
|
35
|
+
### Migration
|
|
36
|
+
|
|
37
|
+
- After upgrading from `0.22.x`, invoke `empirical-init` once in each existing
|
|
38
|
+
repository to install local automatic activation. Repair preserves Schema 5
|
|
39
|
+
configuration, context, feature history, and evidence unless setup values are
|
|
40
|
+
explicitly changed.
|
|
41
|
+
|
|
42
|
+
## [0.22.0] - 2026-08-03
|
|
43
|
+
|
|
44
|
+
### Added
|
|
45
|
+
|
|
46
|
+
- Introduced the Schema 5 protocol, strict Policy v2 evidence, resumable
|
|
47
|
+
journals, capability claims, independent integration, protected delivery,
|
|
48
|
+
explicit publication, and a single consolidated global workflow skill.
|
|
49
|
+
|
|
50
|
+
## [0.20.4] - 2026-07-31
|
|
51
|
+
|
|
52
|
+
### Fixed
|
|
53
|
+
|
|
54
|
+
- Completed the `0.20.4` release and its recorded release evidence.
|
|
55
|
+
|
|
56
|
+
## [0.20.3] - 2026-07-31
|
|
57
|
+
|
|
58
|
+
### Fixed
|
|
59
|
+
|
|
60
|
+
- Made CI and release fixtures portable across supported operating systems,
|
|
61
|
+
including Windows executable-extension casing.
|
|
62
|
+
|
|
63
|
+
### Changed
|
|
64
|
+
|
|
65
|
+
- Simplified installation guidance and clarified README commands.
|
|
66
|
+
|
|
67
|
+
## [0.20.2] - 2026-07-30
|
|
68
|
+
|
|
69
|
+
### Changed
|
|
70
|
+
|
|
71
|
+
- Prepared and released package version `0.20.2`.
|
|
72
|
+
|
|
73
|
+
[Unreleased]: https://github.com/goempirical/empirical-sdd/compare/v0.23.0...HEAD
|
|
74
|
+
[0.23.0]: https://github.com/goempirical/empirical-sdd/compare/v0.22.0...v0.23.0
|
|
75
|
+
[0.22.0]: https://github.com/goempirical/empirical-sdd/compare/v0.20.4...v0.22.0
|
|
76
|
+
[0.20.4]: https://github.com/goempirical/empirical-sdd/compare/v0.20.3...v0.20.4
|
|
77
|
+
[0.20.3]: https://github.com/goempirical/empirical-sdd/compare/v0.20.2...v0.20.3
|
|
78
|
+
[0.20.2]: https://github.com/goempirical/empirical-sdd/releases/tag/v0.20.2
|
package/README.md
CHANGED
|
@@ -1,75 +1,151 @@
|
|
|
1
1
|
# Empirical SDD
|
|
2
2
|
|
|
3
|
-
Agent-neutral, resumable spec-driven development
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
Agent-neutral, resumable spec-driven development with deterministic routing,
|
|
4
|
+
immutable evidence, safe cross-worktree integration, optional external ticket
|
|
5
|
+
mirrors, and an explicit bootstrap that makes normal repository work automatic.
|
|
6
|
+
Empirical installs across 73 global agent targets and provides verified guidance
|
|
7
|
+
for Codex, Claude Code, Cursor, Gemini CLI, Windsurf, and MCP clients.
|
|
6
8
|
|
|
7
|
-
> Empirical is alpha software.
|
|
8
|
-
>
|
|
9
|
+
> Empirical 0.23 is alpha software. Schema 5 remains unchanged. One checkout
|
|
10
|
+
> selects at most one active feature; linked Git worktrees isolate parallel work.
|
|
9
11
|
|
|
10
12
|
## Install
|
|
11
13
|
|
|
12
14
|
| Command | Purpose |
|
|
13
15
|
| --- | --- |
|
|
14
|
-
| `npm install -g empirical-sdd` | Install the
|
|
15
|
-
| `empirical install` | Choose coding agents and install
|
|
16
|
-
| `empirical update` | Upgrade Empirical and
|
|
16
|
+
| `npm install -g empirical-sdd` | Install the CLI. Node.js 22 or newer is required. |
|
|
17
|
+
| `empirical install` | Choose coding agents and install the single explicit `empirical-init` skill. |
|
|
18
|
+
| `empirical update` | Upgrade Empirical and reconcile installed skills. |
|
|
19
|
+
| `empirical uninstall` | Remove managed global skills, owned selection metadata, then the global package. |
|
|
17
20
|
|
|
18
|
-
|
|
21
|
+
The installer uses a pinned local catalog. It remembers exact target IDs,
|
|
22
|
+
deduplicates shared skill roots, and performs no runtime network fetch or `npx`
|
|
23
|
+
execution. Automation can use repeatable `--agent`/`-a`, `--all`, `--yes`, and
|
|
24
|
+
`--json` options.
|
|
19
25
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
or
|
|
25
|
-
`--json`; the legacy ids `claude` and `gemini` remain aliases.
|
|
26
|
+
Uninstall is fail-closed: interactive use shows the exact scope and defaults to
|
|
27
|
+
cancel, while automation must use `empirical uninstall --yes` (optionally with
|
|
28
|
+
`--json`). It removes only marker-owned global artifacts. Project `.empirical`
|
|
29
|
+
history, evidence, and repository MCP/agent configuration are always preserved;
|
|
30
|
+
unmanaged or unsafe global paths are also preserved and reported.
|
|
26
31
|
|
|
27
|
-
|
|
32
|
+
### Upgrade from 0.22
|
|
28
33
|
|
|
29
|
-
|
|
34
|
+
| Previous 0.22 behavior | Updated 0.23 behavior |
|
|
35
|
+
| --- | --- |
|
|
36
|
+
| A global `empirical` skill watched every prompt. | The global skill is explicit `empirical-init` and is limited to setup or repair. |
|
|
37
|
+
| Normal work required naming `empirical`. | Initialized repositories route ordinary change prompts automatically. |
|
|
38
|
+
| Project workflow guidance was removed. | Short marker-owned project dispatchers and detailed local skills are restored. |
|
|
39
|
+
| Existing repositories needed no integration repair. | Invoke `empirical-init` once per existing checkout; configuration and history are preserved. |
|
|
40
|
+
|
|
41
|
+
## Skills
|
|
30
42
|
|
|
31
|
-
|
|
32
|
-
| --- | --- | --- | --- | --- | --- |
|
|
33
|
-
| Codex | `$empirical` | `$empirical-init` | `$empirical-spec` | `$empirical-socratic` | `$empirical-loop` |
|
|
34
|
-
| Claude Code | `/empirical` | `/empirical-init` | `/empirical-spec` | `/empirical-socratic` | `/empirical-loop` |
|
|
35
|
-
| Cursor | `empirical` | `empirical-init` | `empirical-spec` | `empirical-socratic` | `empirical-loop` |
|
|
36
|
-
| Gemini CLI | `empirical` | `empirical-init` | `empirical-spec` | `empirical-socratic` | `empirical-loop` |
|
|
37
|
-
| Windsurf | `@empirical` | `@empirical-init` | `@empirical-spec` | `@empirical-socratic` | `@empirical-loop` |
|
|
43
|
+
These are coding-agent skills, not public shell workflow commands.
|
|
38
44
|
|
|
39
|
-
|
|
|
45
|
+
| Entry | Purpose |
|
|
40
46
|
| --- | --- |
|
|
41
|
-
| `empirical
|
|
42
|
-
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
47
|
+
| `empirical-init` | Explicitly initialize a new repository or repair an existing repository's context and integrations. |
|
|
48
|
+
| Ordinary change prompt | Automatically route, optionally interview or mirror, resume, and complete work in a valid initialized repository. |
|
|
49
|
+
|
|
50
|
+
Native bootstrap examples include `$empirical-init` in Codex,
|
|
51
|
+
`/empirical-init` in Claude Code, and `@empirical-init` in Windsurf. Reload an
|
|
52
|
+
agent after installation. Once initialized, ask normally—for example, “fix the
|
|
53
|
+
pagination bug.” Read-only questions remain outside Empirical, and a repository
|
|
54
|
+
without valid completed `.empirical/config.json` is never enrolled implicitly.
|
|
55
|
+
|
|
56
|
+
## Trust model
|
|
57
|
+
|
|
58
|
+
Requests are classified into deterministic risk floors: contract-neutral,
|
|
59
|
+
behavioral, sensitive, migration, integration, delivery, or publication. Fast
|
|
60
|
+
is available only to contract-neutral work. Every higher floor uses Complex;
|
|
61
|
+
wording a risky request as “quick” cannot demote it.
|
|
62
|
+
|
|
63
|
+
Normal mode asks only when a material product choice or permission is missing.
|
|
64
|
+
YOLO persists bounded standing authorization and asks only for genuine blockers
|
|
65
|
+
before its authorized ceiling. It never bypasses host permissions or branch
|
|
66
|
+
protection, force-writes Git, extracts credentials, deletes real worktrees or
|
|
67
|
+
branches, replaces immutable releases, or infers publication.
|
|
68
|
+
|
|
69
|
+
Fast is contract-neutral and ends at verified. Complex records an impact
|
|
70
|
+
manifest and proceeds through Specify, Design, Plan, Implement, conditional
|
|
71
|
+
Context refinement, Verify, Review, and independent Integrate. An authorized delivery may continue through two
|
|
72
|
+
protected GitHub PRs. Publication is always a separate explicit operation bound
|
|
73
|
+
to an exact version, commit, tag, and dist-tag.
|
|
74
|
+
|
|
75
|
+
Evidence is not a caller-supplied boolean. Empirical either executes a Policy v2
|
|
76
|
+
command or collects a content-addressed artifact, then writes an immutable
|
|
77
|
+
receipt tied to criteria, source state, and provenance. Completion reports only
|
|
78
|
+
the highest proven level: implemented, verified, integrated, delivered, or
|
|
79
|
+
published.
|
|
80
|
+
|
|
81
|
+
## External ticket tracking
|
|
82
|
+
|
|
83
|
+
External tracking is optional and local-only by default. When enabled through
|
|
84
|
+
the repository-local workflow, one selected feature can create or attach one ticket in
|
|
85
|
+
Linear, GitHub Issues + Projects v2, or Jira Cloud. Empirical's hash-chained
|
|
86
|
+
local journal remains authoritative; the ticket is a one-way projection of the
|
|
87
|
+
committed phase, normalized status, revision, completion level, and blocker
|
|
88
|
+
summary.
|
|
89
|
+
|
|
90
|
+
The provider-neutral Tracker Policy v1 lives at `.empirical/tracker.json`.
|
|
91
|
+
It selects exactly one provider, names its board/project and normalized status
|
|
92
|
+
IDs, and stores only credential environment-variable names. Credential values
|
|
93
|
+
are injected into the Empirical runtime by the host, must carry access to the
|
|
94
|
+
configured provider target, and are never written to `.empirical/`. Bindings
|
|
95
|
+
pin the exact provider target; changing that target fails closed until explicit
|
|
96
|
+
replacement, while a same-target status-map change forces the committed
|
|
97
|
+
revision to be projected again. Bindings and durable retry operations live
|
|
98
|
+
under each feature's `tracker/` directory.
|
|
99
|
+
|
|
100
|
+
After every local journal commit, the skill asks the granular MCP tracker layer
|
|
101
|
+
to converge the remote ticket. A provider outage never rolls back or blocks
|
|
102
|
+
local SDD progress. Status and action packets expose `local-only`, `synced`,
|
|
103
|
+
`pending`, or `failed` tracker health. Ordinary retries resume the exact durable
|
|
104
|
+
pending operation. If ticket creation has an ambiguous outcome, Empirical does
|
|
105
|
+
not issue another create automatically: it first performs bounded reconciliation
|
|
106
|
+
using the persisted marker. If no unique match is found, attachment is required
|
|
107
|
+
unless the caller explicitly confirms a new attempt that may create a duplicate.
|
|
108
|
+
See [MCP usage](docs/mcp.md#external-ticket-mirror) for the strict provider
|
|
109
|
+
schemas, runtime permissions, state mapping, and recovery details.
|
|
110
|
+
|
|
111
|
+
## Repository model
|
|
112
|
+
|
|
113
|
+
Schema 5 stores strict Policy v2 configuration, Manifest v2 knowledge
|
|
114
|
+
fingerprints, impact manifests, receipts, Git-common-dir capability claims, and
|
|
115
|
+
hash-chained per-feature journals. Terminal journals compact transactionally to
|
|
116
|
+
a verified snapshot boundary. `empirical_doctor` diagnoses schema, journal,
|
|
117
|
+
lock, claim, toolchain, policy, tracker configuration, credential presence,
|
|
118
|
+
knowledge, evidence, worktree, and delivery state without mutating the
|
|
119
|
+
repository. It still validates dormant feature binding and pending files when
|
|
120
|
+
tracking is local-only or disabled.
|
|
121
|
+
|
|
122
|
+
Schema 4 repositories migrate atomically on the first mutating Schema-5 operation.
|
|
123
|
+
The migration validates a complete candidate tree before promotion and retains
|
|
124
|
+
a recovery receipt. Earlier schemas must first be upgraded to Schema 4 with the
|
|
125
|
+
version that created them.
|
|
58
126
|
|
|
59
127
|
## Development
|
|
60
128
|
|
|
61
|
-
|
|
129
|
+
Development requires Node.js 22+ and Bun. CI covers Node 22, 24, and 26.
|
|
62
130
|
|
|
63
131
|
| Command | Purpose |
|
|
64
132
|
| --- | --- |
|
|
65
|
-
| `bun install` | Install
|
|
66
|
-
| `bun run
|
|
133
|
+
| `bun install` | Install dependencies. |
|
|
134
|
+
| `bun run check` | Type-check the source. |
|
|
135
|
+
| `bun run test` | Run the test suite. |
|
|
136
|
+
| `bun run test:coverage` | Enforce aggregate and per-module coverage gates. |
|
|
137
|
+
| `bun run test:dist` | Build and smoke-test the packaged CLI and MCP server. |
|
|
138
|
+
| `bun run test:package` | Install and import the generated npm package. |
|
|
139
|
+
| `bun run ci` | Run every required gate. |
|
|
140
|
+
|
|
141
|
+
The package exposes only `.`, `./protocol`, `./mcp`, and `./integrations`.
|
|
67
142
|
|
|
68
143
|
## Documentation
|
|
69
144
|
|
|
70
|
-
[
|
|
71
|
-
[MCP](docs/mcp.md) · [Security](docs/security.md) ·
|
|
72
|
-
[Migration](docs/migration-v1.md)
|
|
145
|
+
[Protocol](docs/protocol.md) · [Architecture](docs/architecture.md) ·
|
|
146
|
+
[MCP](docs/mcp.md) · [Demo](docs/demo.md) · [Security](docs/security.md) ·
|
|
147
|
+
[Migration](docs/migration-v1.md) · [Versioning](docs/versioning.md) ·
|
|
148
|
+
[Changelog](CHANGELOG.md)
|
|
73
149
|
|
|
74
150
|
## License
|
|
75
151
|
|
package/dist/agent-catalog.d.ts
CHANGED
|
@@ -64,7 +64,7 @@ export declare const AGENT_SKILL_TARGETS: readonly [{
|
|
|
64
64
|
readonly aliases: readonly ["claude"];
|
|
65
65
|
readonly executables: readonly ["claude"];
|
|
66
66
|
readonly invocation: "/empirical";
|
|
67
|
-
readonly reload: "Restart Claude Code so it reloads the global Empirical
|
|
67
|
+
readonly reload: "Restart Claude Code so it reloads the global Empirical Init skill, then invoke /empirical-init for repository setup or repair.";
|
|
68
68
|
readonly projectMcp: true;
|
|
69
69
|
readonly handoff: true;
|
|
70
70
|
}, {
|
|
@@ -104,7 +104,7 @@ export declare const AGENT_SKILL_TARGETS: readonly [{
|
|
|
104
104
|
readonly detectPaths: readonly [".codex"];
|
|
105
105
|
readonly executables: readonly ["codex"];
|
|
106
106
|
readonly invocation: "$empirical";
|
|
107
|
-
readonly reload: "Restart or reopen Codex so it rescans user skills, then invoke
|
|
107
|
+
readonly reload: "Restart or reopen Codex so it rescans user skills, then invoke $empirical-init for repository setup or repair.";
|
|
108
108
|
readonly projectMcp: true;
|
|
109
109
|
readonly handoff: true;
|
|
110
110
|
}, {
|
|
@@ -371,7 +371,7 @@ export declare const AGENT_SKILL_TARGETS: readonly [{
|
|
|
371
371
|
readonly detectPaths: readonly [".codeium/windsurf"];
|
|
372
372
|
readonly executables: readonly ["windsurf"];
|
|
373
373
|
readonly invocation: "@empirical";
|
|
374
|
-
readonly reload: "Reload Windsurf or start a new Cascade session, then invoke
|
|
374
|
+
readonly reload: "Reload Windsurf or start a new Cascade session, then invoke @empirical-init for repository setup or repair.";
|
|
375
375
|
readonly projectMcp: true;
|
|
376
376
|
readonly handoff: true;
|
|
377
377
|
}, {
|