ultra-builder-pro-cli 0.24.0 → 0.24.1
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/.ultra-template/tasks/tasks.json +4 -2
- package/CHANGELOG.md +27 -0
- package/README.md +38 -25
- package/docs/AGENT-CONTEXT.md +6 -4
- package/docs/ARCHITECTURE.md +6 -4
- package/docs/ARTIFACT-AUTHORITY.md +10 -7
- package/docs/LEGACY-CLI-CROSSWALK.md +1 -1
- package/docs/WORKFLOW-LIFECYCLE.md +38 -23
- package/hooks/health_check.py +11 -6
- package/mcp-server/lib/baseline-workflow.cjs +74 -46
- package/mcp-server/lib/change-authority.cjs +26 -0
- package/mcp-server/lib/change-workflow.cjs +69 -36
- package/mcp-server/lib/state-ops.cjs +21 -3
- package/mcp-server/lib/ultra-facade.cjs +159 -32
- package/package.json +1 -1
- package/skills/ultra-change/SKILL.md +2 -1
- package/skills/ultra-deliver/SKILL.md +15 -17
- package/skills/ultra-dev/SKILL.md +3 -1
- package/skills/ultra-doctor/SKILL.md +2 -2
- package/skills/ultra-init/references/brownfield-adoption.md +13 -10
- package/skills/ultra-plan/SKILL.md +10 -8
- package/skills/ultra-research/SKILL.md +8 -4
- package/skills/ultra-review/SKILL.md +6 -4
- package/skills/ultra-test/SKILL.md +6 -4
- package/skills/ultra-think/SKILL.md +3 -2
- package/spec/mcp-tools.yaml +6 -2
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"kind": "ultra-team-task-ledger",
|
|
3
|
-
"schema_version": "
|
|
3
|
+
"schema_version": "2.0",
|
|
4
4
|
"generation": 0,
|
|
5
5
|
"parent_digest": null,
|
|
6
6
|
"ancestors": [],
|
|
7
|
-
"state_digest": "
|
|
7
|
+
"state_digest": "88098433d797125bb0f87068a01205cf378494169ca93ee2a9dcf15c1c83dd63",
|
|
8
8
|
"published_at": null,
|
|
9
9
|
"reason": "scaffold",
|
|
10
10
|
"baseline": null,
|
|
11
11
|
"changes": [],
|
|
12
|
+
"decisions": [],
|
|
13
|
+
"checkpoints": [],
|
|
12
14
|
"tasks": []
|
|
13
15
|
}
|
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,33 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.24.1] — 2026-07-31
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
- Kept semantic completeness, route selection, baseline sufficiency, and delivery
|
|
15
|
+
acceptance in Skills and the host model. The MCP kernel now records those conclusions
|
|
16
|
+
as advisory diagnostics while retaining hard failures only for structural authority,
|
|
17
|
+
current bytes, digests, scope ownership, concurrency, permissions, and recovery.
|
|
18
|
+
- Made local delivery follow the evidence required by the actual Change route. Explicit
|
|
19
|
+
omissions and their rationale are preserved without imposing a fixed
|
|
20
|
+
Plan/Dev/Test/Review sequence on every archive.
|
|
21
|
+
- Made completed Tasks explicitly reopenable without erasing their prior completion
|
|
22
|
+
commit or accepted history.
|
|
23
|
+
|
|
24
|
+
### Fixed
|
|
25
|
+
|
|
26
|
+
- Fixed nonexistent or mismatched Task/Change checkpoint scopes creating ghost
|
|
27
|
+
checkpoint authority; invalid scopes now fail before any Context or checkpoint write.
|
|
28
|
+
- Fixed shallow or contradictory evidence declarations being accepted without checking
|
|
29
|
+
current managed artifact authority and stable file bytes.
|
|
30
|
+
- Fixed baseline semantic gaps, missing optional research, and `not_run` verification
|
|
31
|
+
being misrepresented as mechanical authority failures.
|
|
32
|
+
- Fixed installed Change revision paths depending on source-only semantic supervisor
|
|
33
|
+
modules excluded from the npm package.
|
|
34
|
+
- Fixed Hooks, Skills, templates, and packaged documentation disagreeing about advisory
|
|
35
|
+
diagnostics, adaptive delivery, and the persistence/safety-kernel boundary.
|
|
36
|
+
|
|
10
37
|
## [0.24.0] — 2026-07-30
|
|
11
38
|
|
|
12
39
|
### Added
|
package/README.md
CHANGED
|
@@ -48,8 +48,10 @@ Ultra Builder Pro addresses those gaps with four ideas:
|
|
|
48
48
|
recovery state across host sessions. Tracked semantic artifacts plus the
|
|
49
49
|
MCP-published `.ultra/tasks/tasks.json` checkpoint carry reviewed project intent
|
|
50
50
|
across Git checkouts without committing SQLite, leases, or telemetry.
|
|
51
|
-
4. **
|
|
52
|
-
|
|
51
|
+
4. **Adaptive delivery.** The host model evaluates the evidence produced by the
|
|
52
|
+
actual Change route, explicitly records any omitted capability and its rationale,
|
|
53
|
+
and asks the owner to accept the local handoff. MCP validates current managed
|
|
54
|
+
authority and archive integrity rather than requiring a fixed stage sequence.
|
|
53
55
|
|
|
54
56
|
For example, if the user asks an agent to add organization SSO to an existing
|
|
55
57
|
application, Ultra helps the agent inspect the real authentication path, capture
|
|
@@ -103,14 +105,14 @@ The responsibility split is deliberate:
|
|
|
103
105
|
|---|---|
|
|
104
106
|
| **User** | Product intent, semantic route selection, material scope and trade-offs, risk acceptance, destructive actions, publishing and deployment authorization |
|
|
105
107
|
| **Host model** | Fact-finding, synthesis, research-coverage and route recommendations, reversible implementation decisions |
|
|
106
|
-
| **Ultra MCP** | Structure validation,
|
|
108
|
+
| **Ultra MCP** | Structure/current-byte validation, caller-declared checkpoints, evidence references, digests, team sync, leases, archive transactions, and mechanical recovery; never semantic completeness or route selection |
|
|
107
109
|
| **Host adapter** | Native Skill discovery, user questions, tool invocation, installation, and runtime wiring |
|
|
108
110
|
| **Hooks** | Fast lifecycle observation, current breadcrumb injection, and protection of MCP-owned checkpoint and generated projection paths |
|
|
109
111
|
|
|
110
|
-
The MCP does not replace the model's judgment or pre-authorize a
|
|
111
|
-
reports
|
|
112
|
-
|
|
113
|
-
appeared in a conversation.
|
|
112
|
+
The MCP does not replace the model's judgment, judge completion, or pre-authorize a
|
|
113
|
+
semantic route. It reports diagnostics and safely commits the model's explicit
|
|
114
|
+
checkpoint/archive handoff. A hook does not decide product strategy. A prompt does not
|
|
115
|
+
become durable authority merely because it appeared in a conversation.
|
|
114
116
|
|
|
115
117
|
### The seven-tool MCP kernel
|
|
116
118
|
|
|
@@ -120,10 +122,10 @@ The public model-facing surface is intentionally small:
|
|
|
120
122
|
|---|---|
|
|
121
123
|
| `ultra.context` | Read the complete current spine without side effects |
|
|
122
124
|
| `ultra.record` | Batch typed draft facts and events with idempotency |
|
|
123
|
-
| `ultra.checkpoint` |
|
|
125
|
+
| `ultra.checkpoint` | Commit one caller-declared stage checkpoint after structural, byte, digest, and publication validation |
|
|
124
126
|
| `ultra.sync` | Inspect, import, or publish the Git team checkpoint |
|
|
125
127
|
| `ultra.session` | Own the transactional execution lease |
|
|
126
|
-
| `ultra.archive` |
|
|
128
|
+
| `ultra.archive` | Persist one explicit local delivery handoff through the recoverable filesystem/DB boundary |
|
|
127
129
|
| `ultra.doctor` | Inspect or repair mechanical health, backup first |
|
|
128
130
|
|
|
129
131
|
Retired fine-grained operation names are neither discoverable nor callable. Workflow
|
|
@@ -283,7 +285,7 @@ resolves observable facts itself and asks for material product decisions as
|
|
|
283
285
|
needed. Once the evidence and specifications are accurate, the user approves
|
|
284
286
|
the baseline.
|
|
285
287
|
|
|
286
|
-
|
|
288
|
+
One common full-depth path after baseline approval is:
|
|
287
289
|
|
|
288
290
|
```text
|
|
289
291
|
ultra-change
|
|
@@ -295,11 +297,14 @@ ultra-change
|
|
|
295
297
|
-> ultra-deliver
|
|
296
298
|
```
|
|
297
299
|
|
|
298
|
-
Each public workflow is explicitly invoked rather than auto-chained.
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
300
|
+
Each public workflow is explicitly invoked rather than auto-chained. The example is a
|
|
301
|
+
recommended route for a normal implementation Change, not an archive state machine.
|
|
302
|
+
Thinking and research coverage are adaptive, verification depth is risk-selected, and
|
|
303
|
+
the host may omit or repeat a capability when the actual Change makes that appropriate,
|
|
304
|
+
provided the delivery handoff names the omission and its rationale. Any implementation
|
|
305
|
+
task still requires a current plan, DB-backed task contract, and role-scoped context.
|
|
306
|
+
“Direct Build” skips Research only; it does not bypass Plan, Task, or Context authority
|
|
307
|
+
when development is performed.
|
|
303
308
|
|
|
304
309
|
### 2. Adopt an existing project
|
|
305
310
|
|
|
@@ -365,9 +370,12 @@ must be reconciled against the current Change authority.
|
|
|
365
370
|
|
|
366
371
|
### 4. Deliver and continue
|
|
367
372
|
|
|
368
|
-
`ultra-deliver`
|
|
369
|
-
|
|
370
|
-
|
|
373
|
+
`ultra-deliver` asks the host model to assess the current managed evidence for the
|
|
374
|
+
route the Change actually took. The handoff explicitly records any omitted capability
|
|
375
|
+
and its evidence-based rationale; the owner decides whether that semantic packet is
|
|
376
|
+
sufficient. MCP then validates paths, digests, reconciliation structure, idempotency,
|
|
377
|
+
and recoverability before archiving the local Ultra change authority. It does not
|
|
378
|
+
require every Change to pass through a fixed Research/Plan/Dev/Test/Review sequence.
|
|
371
379
|
|
|
372
380
|
Delivery does **not** grant permission to commit, push, publish, tag, deploy, or
|
|
373
381
|
perform another external effect. Those actions remain separate and require the
|
|
@@ -430,11 +438,16 @@ flowchart TD
|
|
|
430
438
|
PLAN --> DEV["ultra-dev<br/>one dependency-ready vertical task"]
|
|
431
439
|
DEV --> TASKS{"More executable tasks?"}
|
|
432
440
|
TASKS -->|"Yes"| DEV
|
|
433
|
-
TASKS -->|"No"|
|
|
441
|
+
TASKS -->|"No"| ASSESS{"What evidence does this Change still need?"}
|
|
442
|
+
ROUTE -->|"Accepted handoff already has sufficient evidence"| DELIVER["ultra-deliver"]
|
|
443
|
+
ASSESS -->|"Risk-selected verification"| TEST["ultra-test<br/>risk-selected formal verification"]
|
|
444
|
+
ASSESS -->|"Independent review"| REVIEW["ultra-review<br/>specification fidelity and engineering quality"]
|
|
445
|
+
ASSESS -->|"Caller accepts current evidence and explicit omissions"| DELIVER
|
|
434
446
|
TEST -->|"Failed or incomplete"| DEV
|
|
435
|
-
TEST -->|"
|
|
447
|
+
TEST -->|"Review is warranted"| REVIEW
|
|
448
|
+
TEST -->|"Caller accepts current evidence and explicit omissions"| DELIVER
|
|
436
449
|
REVIEW -->|"Changes required"| DEV
|
|
437
|
-
REVIEW -->|"Approved"| DELIVER
|
|
450
|
+
REVIEW -->|"Approved"| DELIVER
|
|
438
451
|
DELIVER --> ARCHIVE["Reconcile specifications<br/>apply the Change overlay and archive evidence"]
|
|
439
452
|
ARCHIVE --> NEXT{"Continue"}
|
|
440
453
|
NEXT -->|"Next outcome"| CHANGE
|
|
@@ -586,10 +599,10 @@ host's existing model session.
|
|
|
586
599
|
any real conflict. Never edit `.ultra/tasks/tasks.json` by hand.
|
|
587
600
|
- **A generated view disagrees with MCP:** trust `.ultra/.runtime/state.db`; never edit
|
|
588
601
|
`.ultra/.runtime/projections/` by hand.
|
|
589
|
-
- **A draft checkpoint
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
state must be cancelled first.
|
|
602
|
+
- **A draft checkpoint reports warnings:** the model keeps them visible and decides
|
|
603
|
+
whether to investigate, revise, defer with rationale, or accept. If a checkpoint is
|
|
604
|
+
rejected for a structural, digest, path, publication, or concurrency conflict, fix
|
|
605
|
+
the same mutable draft and retry; no hidden workflow state must be cancelled first.
|
|
593
606
|
- **Kimi reports a native-module ABI error:** ensure an external Node.js 22+
|
|
594
607
|
executable is available on `PATH`; the generated Kimi MCP launcher uses
|
|
595
608
|
`env node`.
|
package/docs/AGENT-CONTEXT.md
CHANGED
|
@@ -95,15 +95,17 @@ If the host mode forbids interaction, leave the decision unresolved.
|
|
|
95
95
|
|
|
96
96
|
## Stage Checkpoints
|
|
97
97
|
|
|
98
|
-
Skills describe adaptive evidence expectations
|
|
99
|
-
|
|
98
|
+
Skills describe adaptive evidence expectations and decide semantic sufficiency;
|
|
99
|
+
SQLite does not authorize a fixed step sequence or reinterpret the supplied verdict.
|
|
100
|
+
A stage has a mutable draft and immutable accepted revisions:
|
|
100
101
|
|
|
101
102
|
```text
|
|
102
103
|
draft N -> accepted N -> superseded by accepted N+1
|
|
103
104
|
```
|
|
104
105
|
|
|
105
|
-
Warnings and semantic gaps do not
|
|
106
|
-
|
|
106
|
+
Warnings and semantic gaps do not reject explicit acceptance. Structural, digest,
|
|
107
|
+
path, publication, and concurrency conflicts leave the draft mutable. An accepted
|
|
108
|
+
revision can be replaced by a later accepted revision without rewriting history.
|
|
107
109
|
|
|
108
110
|
## Worker handoff
|
|
109
111
|
|
package/docs/ARCHITECTURE.md
CHANGED
|
@@ -59,10 +59,10 @@ Every host discovers exactly seven tools:
|
|
|
59
59
|
|---|---|
|
|
60
60
|
| `ultra.context` | Side-effect-free, bounded Context Envelope read |
|
|
61
61
|
| `ultra.record` | Typed, idempotent recording of facts, decisions, artifacts, tasks, outcomes, and observations |
|
|
62
|
-
| `ultra.checkpoint` |
|
|
62
|
+
| `ultra.checkpoint` | Caller-declared Stage Checkpoint with structural, scope, byte, digest, and publication validation |
|
|
63
63
|
| `ultra.sync` | Inspect, migrate, import, or publish the Git team checkpoint |
|
|
64
64
|
| `ultra.session` | Lease/worktree acquisition plus immutable Worker Packet handoff |
|
|
65
|
-
| `ultra.archive` | Crash-safe
|
|
65
|
+
| `ultra.archive` | Crash-safe caller-declared local handoff and immutable archive |
|
|
66
66
|
| `ultra.doctor` | Mechanical diagnosis and backup-first repair |
|
|
67
67
|
|
|
68
68
|
Retired fine-grained tool names are not registered and return `UNKNOWN_TOOL`. The
|
|
@@ -119,8 +119,10 @@ draft N -> accepted N -> superseded by accepted N+1
|
|
|
119
119
|
```
|
|
120
120
|
|
|
121
121
|
There is no fixed step authorization table. Skills decide which evidence is relevant
|
|
122
|
-
|
|
123
|
-
scope
|
|
122
|
+
and whether the actual work is semantically sufficient. Checkpoint validation verifies
|
|
123
|
+
declared facts, files, digests, scope, idempotency, and safe publication. Semantic
|
|
124
|
+
warnings remain recorded but do not prevent an explicit caller acceptance; a hard
|
|
125
|
+
authority conflict leaves the draft mutable.
|
|
124
126
|
|
|
125
127
|
### Worker Packets
|
|
126
128
|
|
|
@@ -44,7 +44,7 @@ these surfaces independently owns all three roles.
|
|
|
44
44
|
|---|---|---|
|
|
45
45
|
| Owner | Goals, acceptance, non-goals, material choices, risk acceptance, and authorization for irreversible or external effects | Supply facts the checkout or runtime can establish directly |
|
|
46
46
|
| Host model | Inspect evidence, recommend a route, ask only for unresolved owner choices, normalize the answer, call the owning write, update semantic artifacts, read back the result, and present the next recommendation | Fabricate evidence, infer owner authorization, or bypass mechanical safety |
|
|
47
|
-
| Ultra MCP | Persist normalized inputs, validate structure
|
|
47
|
+
| Ultra MCP | Persist normalized inputs, validate structure/current bytes/digests, record facts and provenance, commit caller-declared Stage Checkpoints, project local views, publish/import the Git checkpoint, and expose recovery | Judge semantic completeness, choose product direction, prove a UI click, pre-authorize reasoning steps, force a semantic route, or replace model judgment |
|
|
48
48
|
| Host adapter | Render the shared interaction contract through the host-native question and tool surfaces | Become a second workflow authority |
|
|
49
49
|
| Hook | Observe lifecycle, inject compact DB-derived recovery context, and protect MCP-owned checkpoint and generated projection paths | Select a semantic route or block ordinary development |
|
|
50
50
|
|
|
@@ -112,11 +112,13 @@ document's before/after digest, delta and acceptance references, verification, a
|
|
|
112
112
|
verified consumer or explicit no-consumer reason. Standard and major delivery require
|
|
113
113
|
one current reconciliation even when its document set is empty.
|
|
114
114
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
115
|
+
The Deliver Skill owns the evidence-based semantic handoff and records any deliberate
|
|
116
|
+
stage omission. `change.archive` does not infer completeness or require a fixed
|
|
117
|
+
Plan/Dev/Test/Review/Deliver sequence. It preflights the caller-declared target set
|
|
118
|
+
before writing, validates reconciliation structure, applies overlay bytes through a
|
|
119
|
+
recoverable local transaction, refreshes baseline digests, moves the complete Change
|
|
120
|
+
root to its archive location, and rebinds registry paths. A conflict, crash, or DB
|
|
121
|
+
failure must roll back or resume the whole packet; no subset is reported as delivered.
|
|
120
122
|
|
|
121
123
|
## Context and plan authority
|
|
122
124
|
|
|
@@ -141,7 +143,8 @@ A current plan is a Change-owned pair:
|
|
|
141
143
|
task contracts.
|
|
142
144
|
|
|
143
145
|
The Plan checkpoint selects both paths from the owning Change and accepts no arbitrary
|
|
144
|
-
output path.
|
|
146
|
+
output path. The model owns decomposition and semantic coverage. MCP binds the JSON
|
|
147
|
+
digest and the preceding `plan/planning` snapshot;
|
|
145
148
|
the artifact registry records both plan files with that context provenance. Publication
|
|
146
149
|
preflights both path authorities and prior digests, rejects symlinked ancestors or
|
|
147
150
|
targets, and journals the two file replacements so a registry or event failure restores
|
|
@@ -29,7 +29,7 @@ contract and adds stronger authority, recovery, or portability.
|
|
|
29
29
|
| Development uses isolated Git work, TDD, verification, review, commit, and integration | `ultra-dev`, `session.*`, and the session runner create real worktrees and retain task/review/commit evidence | Preserved and strengthened. Process exit cannot complete a task; uncommitted or unintegrated worktrees cannot be deleted. |
|
|
30
30
|
| Test checks wiring, acceptance, regression, build, performance, security, and failures | `ultra-test` emits a change-bound immutable report covering each applicable dimension | Preserved and strengthened with HEAD, context, task-set, and report-digest validation. |
|
|
31
31
|
| Review challenges specification fidelity and engineering quality | `ultra-review` is a first-class stage with independent specification and engineering axes | Strengthened. A coordinated summary cannot replace either complete axis. |
|
|
32
|
-
| Delivery verifies clean readiness, documentation, build, and evidence | `ultra-deliver`
|
|
32
|
+
| Delivery verifies clean readiness, documentation, build, and evidence | `ultra-deliver` assesses the explicitly accepted evidence packet for the actual Change route, records deliberate omissions, reconciles current managed authority, and creates a recoverable local archive and immutable report | Preserved without a fixed stage gate and strengthened by path, digest, reconciliation, idempotency, and recovery validation. Publish, deploy, push, and other external effects remain separate explicitly authorized operations. |
|
|
33
33
|
| Status restores the current workflow position | `ultra-status` reads DB authority, Git, sessions, artifacts, decisions, allowed transitions, and any hard recovery requirement | Strengthened. The host recommends the semantic route; projections and Prompt prose cannot override state. |
|
|
34
34
|
| Thinking synchronizes owner and Agent intent | `ultra-think` plus `decision.*` persists one-question dialogue, non-ceremonial completion, and optional artifact checkpoints | Strengthened. Observable facts are resolved first; only load-bearing owner choices block. |
|
|
35
35
|
|
|
@@ -15,19 +15,24 @@ flowchart TD
|
|
|
15
15
|
RESEARCH --> THINK["ultra-think when a material decision remains"]
|
|
16
16
|
THINK --> RESEARCH
|
|
17
17
|
RESEARCH --> CHANGE["ultra-change"]
|
|
18
|
-
CHANGE --> ROUTE{"
|
|
19
|
-
ROUTE -->|"
|
|
20
|
-
CR -->
|
|
21
|
-
ROUTE -->|"
|
|
18
|
+
CHANGE --> ROUTE{"What does this Change actually need?"}
|
|
19
|
+
ROUTE -->|"Evidence gap"| CR["bounded ultra-research"]
|
|
20
|
+
CR --> ROUTE
|
|
21
|
+
ROUTE -->|"Implementation"| PLAN["ultra-plan"]
|
|
22
22
|
PLAN --> DEV["ultra-dev for one owned Task"]
|
|
23
23
|
DEV --> MORE{"More executable Tasks?"}
|
|
24
24
|
MORE -->|"Yes"| DEV
|
|
25
|
-
MORE -->|"No"|
|
|
25
|
+
MORE -->|"No"| ASSESS{"What evidence is still warranted?"}
|
|
26
|
+
ROUTE -->|"No implementation; current evidence is sufficient"| ASSESS
|
|
27
|
+
ASSESS -->|"Risk-selected verification"| TEST["ultra-test"]
|
|
28
|
+
ASSESS -->|"Independent review"| REVIEW["ultra-review"]
|
|
29
|
+
ASSESS -->|"Caller accepts current packet and explicit omissions"| DELIVER["ultra-deliver"]
|
|
26
30
|
TEST -->|"implementation gap"| DEV
|
|
27
|
-
TEST -->|"
|
|
31
|
+
TEST -->|"review warranted"| REVIEW
|
|
32
|
+
TEST -->|"caller accepts evidence"| DELIVER
|
|
28
33
|
REVIEW -->|"implementation issue"| DEV
|
|
29
34
|
REVIEW -->|"contract issue"| PLAN
|
|
30
|
-
REVIEW -->|"accepted"| DELIVER
|
|
35
|
+
REVIEW -->|"accepted"| DELIVER
|
|
31
36
|
DELIVER --> CHANGE
|
|
32
37
|
STATUS["ultra-status"] -.-> INIT
|
|
33
38
|
STATUS -.-> CHANGE
|
|
@@ -35,10 +40,12 @@ flowchart TD
|
|
|
35
40
|
DOCTOR -.-> CHANGE
|
|
36
41
|
```
|
|
37
42
|
|
|
38
|
-
The graph is guidance, not database authorization.
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
43
|
+
The graph is guidance, not database authorization. The host model selects the evidence
|
|
44
|
+
needed by the actual Change route and records every deliberate omission in the delivery
|
|
45
|
+
handoff. When implementation occurs, its Plan, Task contract, and Context remain
|
|
46
|
+
mandatory execution authority; Research, Test, and Review are used according to the
|
|
47
|
+
actual evidence and risk rather than as universal archive gates. `ultra-status` is
|
|
48
|
+
read-only. `ultra-doctor` repairs mechanical authority only.
|
|
42
49
|
|
|
43
50
|
## Shared command contract
|
|
44
51
|
|
|
@@ -99,10 +106,12 @@ draft revision N
|
|
|
99
106
|
-> accepted revision N+1 supersedes N
|
|
100
107
|
```
|
|
101
108
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
109
|
+
Semantic diagnostics remain recorded but do not reject the model's explicit
|
|
110
|
+
checkpoint conclusion. A structural, digest, path, publication, or concurrency
|
|
111
|
+
conflict keeps the same draft mutable. Plan export is part of Plan checkpoint
|
|
112
|
+
publication, so changing a Task contract before acceptance cannot invalidate an
|
|
113
|
+
already-recorded “export step.” There is no locked intermediate run to cancel or
|
|
114
|
+
manually repair.
|
|
106
115
|
|
|
107
116
|
Accepted checkpoints are immutable evidence. New facts create a replacement draft.
|
|
108
117
|
Only archive history is terminal; subsequent product work opens a new Change.
|
|
@@ -118,9 +127,11 @@ active -> archived
|
|
|
118
127
|
```
|
|
119
128
|
|
|
120
129
|
`blocked`, `ready`, and `needs_attention` are derived diagnostics, not absorbing Change
|
|
121
|
-
states. An active Change may be revised.
|
|
122
|
-
Context, test, review, documentation, and delivery
|
|
123
|
-
|
|
130
|
+
states. An active Change may be revised. The Deliver Skill inspects the relevant Task,
|
|
131
|
+
Context, test, review, documentation, and delivery evidence, decides semantic
|
|
132
|
+
sufficiency, and records deliberate omissions. Archive validates the explicit handoff,
|
|
133
|
+
current authority, reconciliation structure, and safe recoverable filesystem/DB
|
|
134
|
+
transaction without enforcing a fixed stage sequence. Archived bytes remain immutable.
|
|
124
135
|
|
|
125
136
|
Older `ready` or `blocked` rows are readable migration history. They do not authorize
|
|
126
137
|
new work until migration/revalidation derives current checkpoint authority.
|
|
@@ -130,14 +141,18 @@ new work until migration/revalidation derives current checkpoint authority.
|
|
|
130
141
|
Task durable outcomes remain portable:
|
|
131
142
|
|
|
132
143
|
```text
|
|
133
|
-
pending -> completed
|
|
134
|
-
|
|
|
144
|
+
pending -> in_progress -> completed
|
|
145
|
+
| | |
|
|
146
|
+
| -> blocked -> in_progress (explicit reopen)
|
|
135
147
|
-> blocked
|
|
136
148
|
-> cancelled
|
|
137
149
|
```
|
|
138
150
|
|
|
139
151
|
`in_progress`, Worker ownership, leases, PIDs, heartbeats, worktrees, and completion
|
|
140
152
|
commit backfill are checkout-local. They are not published to Git.
|
|
153
|
+
Reopening a completed Task clears the local completion/session fields, preserves the
|
|
154
|
+
prior completion commit in an append-only `task_reopened` event, and requires a new
|
|
155
|
+
durable outcome before it can be completed again.
|
|
141
156
|
|
|
142
157
|
`ultra.session acquire` atomically:
|
|
143
158
|
|
|
@@ -210,6 +225,6 @@ Only these classes fail the tool call:
|
|
|
210
225
|
- permission failure;
|
|
211
226
|
- archive/publish/deploy or another irreversible external-effect failure.
|
|
212
227
|
|
|
213
|
-
Evidence gaps, incomplete exploration, stale optional context, missing reports, or
|
|
214
|
-
|
|
215
|
-
|
|
228
|
+
Evidence gaps, incomplete exploration, stale optional context, missing reports, or
|
|
229
|
+
other semantic insufficiency are structured diagnostics. The model remains responsible
|
|
230
|
+
for investigating, revising, accepting, or explicitly recording an omission.
|
package/hooks/health_check.py
CHANGED
|
@@ -73,26 +73,31 @@ def inspect(root: Path) -> dict:
|
|
|
73
73
|
|
|
74
74
|
envelope = context.get("envelope", {}) if context else {}
|
|
75
75
|
diagnostics = envelope.get("diagnostics", {})
|
|
76
|
-
|
|
76
|
+
baseline_blockers = [
|
|
77
77
|
str(item.get("code"))
|
|
78
78
|
for item in [
|
|
79
79
|
*diagnostics.get("needs_attention", []),
|
|
80
|
-
*diagnostics.get("warnings", []),
|
|
81
80
|
*diagnostics.get("hard_conflicts", []),
|
|
82
81
|
]
|
|
83
82
|
if str(item.get("code", "")).startswith("BASELINE_")
|
|
84
83
|
]
|
|
84
|
+
baseline_warnings = [
|
|
85
|
+
str(item.get("code"))
|
|
86
|
+
for item in diagnostics.get("warnings", [])
|
|
87
|
+
if str(item.get("code", "")).startswith("BASELINE_")
|
|
88
|
+
]
|
|
85
89
|
baseline = envelope.get("baseline")
|
|
86
90
|
baseline_is_ready = isinstance(baseline, dict) and baseline.get("status") == "ready"
|
|
87
91
|
baseline_status = (
|
|
88
|
-
"fail" if
|
|
89
|
-
else "warning" if
|
|
92
|
+
"fail" if baseline_blockers and baseline_is_ready
|
|
93
|
+
else "warning" if baseline_blockers or baseline_warnings
|
|
90
94
|
else "pass"
|
|
91
95
|
)
|
|
92
96
|
report["checks"]["baseline"] = {
|
|
93
97
|
"baseline": baseline,
|
|
94
|
-
"blockers":
|
|
95
|
-
"
|
|
98
|
+
"blockers": baseline_blockers,
|
|
99
|
+
"warnings": baseline_warnings,
|
|
100
|
+
"readiness": "blocked" if baseline_blockers else "ready",
|
|
96
101
|
"status": baseline_status,
|
|
97
102
|
}
|
|
98
103
|
if baseline_status == "fail":
|