ultra-builder-pro-cli 0.22.0 → 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 +38 -0
- package/README.md +55 -25
- package/adapters/_shared/codex-assets.cjs +8 -3
- package/adapters/_shared/interaction-contract.cjs +13 -6
- package/adapters/_shared/runtime-assets.cjs +1 -1
- package/adapters/claude.js +1 -1
- package/adapters/kimi.js +1 -1
- package/adapters/opencode.js +1 -1
- package/docs/AGENT-CONTEXT.md +38 -40
- package/docs/ARCHITECTURE.md +29 -33
- package/docs/ARTIFACT-AUTHORITY.md +15 -16
- package/docs/ROADMAP.md +2 -2
- package/docs/RUNTIME-COMPAT-MATRIX.md +7 -6
- package/docs/STATE-DB-ACCESS-POLICY.md +14 -14
- package/docs/WORKFLOW-LIFECYCLE.md +39 -33
- package/mcp-server/lib/artifact-registry.cjs +25 -1
- package/mcp-server/lib/change-workflow.cjs +42 -6
- package/mcp-server/lib/ultra-facade.cjs +646 -0
- package/mcp-server/lib/workflow-state.cjs +166 -2
- package/mcp-server/server.cjs +73 -21
- package/package.json +1 -1
- package/skills/ultra-change/SKILL.md +38 -98
- package/skills/ultra-deliver/SKILL.md +42 -65
- package/skills/ultra-dev/SKILL.md +34 -88
- package/skills/ultra-doctor/SKILL.md +35 -57
- package/skills/ultra-init/SKILL.md +37 -78
- package/skills/ultra-plan/SKILL.md +52 -132
- package/skills/ultra-research/SKILL.md +41 -100
- package/skills/ultra-review/SKILL.md +25 -46
- package/skills/ultra-status/SKILL.md +21 -44
- package/skills/ultra-test/SKILL.md +25 -61
- package/skills/ultra-think/SKILL.md +29 -48
- package/skills/ultra-think/references/decision-dialogue.md +6 -4
- package/spec/cli-protocol.md +12 -0
- package/spec/mcp-tools.yaml +159 -0
- package/spec/schemas/mcp-tools.schema.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,44 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.23.0] — 2026-07-30
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- Added a seven-tool public MCP kernel: `ultra.context`, `ultra.record`,
|
|
15
|
+
`ultra.checkpoint`, `ultra.sync`, `ultra.session`, `ultra.archive`, and
|
|
16
|
+
`ultra.doctor`.
|
|
17
|
+
- Added idempotent batched recording, content-addressed Context snapshots, and
|
|
18
|
+
semantic checkpoints that commit accepted workflow authority in one model
|
|
19
|
+
round trip.
|
|
20
|
+
- Added mutable diagnostic envelopes for rejected draft checkpoints and
|
|
21
|
+
archive preflights so the host model can correct or abandon the same draft.
|
|
22
|
+
|
|
23
|
+
### Changed
|
|
24
|
+
|
|
25
|
+
- Moved workflow sequencing and semantic judgment back into the eleven public
|
|
26
|
+
Skills. MCP now owns persistence, schema, transaction, concurrency, path,
|
|
27
|
+
recovery, and irreversible-effect boundaries instead of directing the model.
|
|
28
|
+
- Reduced the unconditional `tools/list` surface from 60 fine-grained tools to
|
|
29
|
+
seven high-level tools. The 0.22 fine-grained contracts remain callable but
|
|
30
|
+
hidden for one compatibility release.
|
|
31
|
+
- Made draft Changes and nonterminal workflows reversible while keeping
|
|
32
|
+
accepted revisions immutable and replaceable through a new draft.
|
|
33
|
+
- Updated Claude Code, Codex, OpenCode, and Kimi assets to use the same narrow
|
|
34
|
+
capability graph while preserving each host's native question and bounded
|
|
35
|
+
worker surfaces.
|
|
36
|
+
|
|
37
|
+
### Fixed
|
|
38
|
+
|
|
39
|
+
- Fixed Plan drafts becoming permanently self-locked when a task or exported
|
|
40
|
+
artifact changed after validation.
|
|
41
|
+
- Fixed semantic validation failures surfacing as MCP transport errors and
|
|
42
|
+
forcing models into repeated repair calls.
|
|
43
|
+
- Fixed duplicate Context compilation creating competing snapshots for the
|
|
44
|
+
same semantic inputs.
|
|
45
|
+
- Fixed `ultra.context` creating `.ultra` state merely by inspecting an
|
|
46
|
+
uninitialized project.
|
|
47
|
+
|
|
10
48
|
## [0.22.0] — 2026-07-30
|
|
11
49
|
|
|
12
50
|
### Added
|
package/README.md
CHANGED
|
@@ -71,7 +71,7 @@ flowchart TB
|
|
|
71
71
|
end
|
|
72
72
|
|
|
73
73
|
SKILLS["Eleven explicit Ultra Skills<br/>init / research / think / change / plan / dev<br/>test / review / deliver / status / doctor"]
|
|
74
|
-
MCP["Ultra MCP<br/>
|
|
74
|
+
MCP["Ultra MCP safety kernel<br/>7 public tools; 60 hidden compatibility operations"]
|
|
75
75
|
DB[(".ultra/.runtime/state.db<br/>SQLite lifecycle and index authority")]
|
|
76
76
|
LEDGER[".ultra/tasks/tasks.json<br/>Git team checkpoint for portable baseline, Change, and task state"]
|
|
77
77
|
VIEWS[".ultra/.runtime/projections<br/>checkout-local generated views"]
|
|
@@ -103,13 +103,42 @@ The responsibility split is deliberate:
|
|
|
103
103
|
|---|---|
|
|
104
104
|
| **User** | Product intent, semantic route selection, material scope and trade-offs, risk acceptance, destructive actions, publishing and deployment authorization |
|
|
105
105
|
| **Host model** | Fact-finding, synthesis, research-coverage and route recommendations, reversible implementation decisions |
|
|
106
|
-
| **Ultra MCP** |
|
|
106
|
+
| **Ultra MCP** | Durable checkpoints, evidence references, digests, team sync, leases, archive transactions, and mechanical recovery |
|
|
107
107
|
| **Host adapter** | Native Skill discovery, user questions, tool invocation, installation, and runtime wiring |
|
|
108
108
|
| **Hooks** | Fast lifecycle observation, current breadcrumb injection, and protection of MCP-owned checkpoint and generated projection paths |
|
|
109
109
|
|
|
110
|
-
The MCP does not replace the model's judgment
|
|
111
|
-
|
|
112
|
-
|
|
110
|
+
The MCP does not replace the model's judgment or pre-authorize a semantic route. It
|
|
111
|
+
reports draft diagnostics and commits accepted checkpoints. A hook does not decide
|
|
112
|
+
product strategy. A prompt does not become durable authority merely because it
|
|
113
|
+
appeared in a conversation.
|
|
114
|
+
|
|
115
|
+
### The seven-tool MCP kernel
|
|
116
|
+
|
|
117
|
+
The public model-facing surface is intentionally small:
|
|
118
|
+
|
|
119
|
+
| Tool | Responsibility |
|
|
120
|
+
|---|---|
|
|
121
|
+
| `ultra.context` | Read the complete current spine without side effects |
|
|
122
|
+
| `ultra.record` | Batch typed draft facts and events with idempotency |
|
|
123
|
+
| `ultra.checkpoint` | Attempt one semantic stage checkpoint; rejection leaves the draft editable |
|
|
124
|
+
| `ultra.sync` | Inspect, import, or publish the Git team checkpoint |
|
|
125
|
+
| `ultra.session` | Own the transactional execution lease |
|
|
126
|
+
| `ultra.archive` | Converge and archive through the recoverable filesystem/DB boundary |
|
|
127
|
+
| `ultra.doctor` | Inspect or repair mechanical health, backup first |
|
|
128
|
+
|
|
129
|
+
The 0.22 fine-grained tools remain callable but undiscoverable for one compatibility
|
|
130
|
+
release. Skills and new sessions use only the seven tools above. Workflow prose stays
|
|
131
|
+
in Skills, model judgment stays with the host, and SQLite records what happened rather
|
|
132
|
+
than deciding what the model is allowed to think next.
|
|
133
|
+
|
|
134
|
+
The enforcement gradient is:
|
|
135
|
+
|
|
136
|
+
```text
|
|
137
|
+
exploration and iteration: advisory
|
|
138
|
+
durable semantic checkpoint: validated and recoverable
|
|
139
|
+
corruption / unsafe path / real concurrency / permission: fail closed
|
|
140
|
+
irreversible external effect: explicit owner authority plus fail closed
|
|
141
|
+
```
|
|
113
142
|
|
|
114
143
|
### How owner intent becomes durable authority
|
|
115
144
|
|
|
@@ -121,9 +150,9 @@ flowchart TD
|
|
|
121
150
|
CLEAR -->|"Yes"| NORMALIZE["Normalize the accepted intent"]
|
|
122
151
|
CLEAR -->|"No: a material choice remains"| ASK["Ask one dependent question through the host-native question tool"]
|
|
123
152
|
ASK --> NORMALIZE
|
|
124
|
-
NORMALIZE -->
|
|
125
|
-
|
|
126
|
-
|
|
153
|
+
NORMALIZE --> RECORD["Batch the normalized result through ultra.record"]
|
|
154
|
+
RECORD --> CHECKPOINT["Attempt the owning ultra.checkpoint when authority is ready"]
|
|
155
|
+
CHECKPOINT --> AUTHORITY["Bind state, artifact digest, provenance, and downstream effects"]
|
|
127
156
|
AUTHORITY --> READBACK["Read back the authoritative result"]
|
|
128
157
|
READBACK --> RESUME["Resume the exact workflow step and recommend the next explicit capability"]
|
|
129
158
|
```
|
|
@@ -299,9 +328,9 @@ already resolves the route. The normalized accepted coverage is then stored in
|
|
|
299
328
|
- `deferred` — record the consequence and accepted owner.
|
|
300
329
|
|
|
301
330
|
The catalog is not a mandatory document set or questionnaire. Omitted areas
|
|
302
|
-
create no workflow rows; an explicit exclusion is recorded only when retaining
|
|
303
|
-
that rationale is useful. MCP validates
|
|
304
|
-
does not store or prove the preceding UI interaction.
|
|
331
|
+
create no workflow rows; an explicit exclusion is recorded only when retaining
|
|
332
|
+
that rationale is useful. MCP validates accepted checkpoints and mechanical
|
|
333
|
+
integrity; it does not store or prove the preceding UI interaction.
|
|
305
334
|
|
|
306
335
|
Older projection-only Ultra projects are preserved and routed through a
|
|
307
336
|
backup-first migration or rebaseline. The first supported checkpoint publication
|
|
@@ -358,19 +387,19 @@ The next piece of daily work starts with a new `ultra-change`.
|
|
|
358
387
|
| `ultra-test` | Run the risk-selected verification profile and persist the gate result |
|
|
359
388
|
| `ultra-review` | Coordinate independent specification-fidelity and engineering review |
|
|
360
389
|
| `ultra-deliver` | Reconcile specifications, close local authority, and archive the change |
|
|
361
|
-
| `ultra-status` | Read the current
|
|
390
|
+
| `ultra-status` | Read the current context, warnings, blockers, and evidence |
|
|
362
391
|
| `ultra-doctor` | Diagnose installation or project-state faults and expose safe recovery |
|
|
363
392
|
|
|
364
|
-
These eleven capabilities are the complete public Ultra command graph.
|
|
365
|
-
|
|
366
|
-
capability starts only after an explicit
|
|
393
|
+
These eleven capabilities are the complete public Ultra command graph. The host model
|
|
394
|
+
recommends the next capability from current context and owner intent; SQLite does not
|
|
395
|
+
encode the semantic route. Another public capability starts only after an explicit
|
|
396
|
+
user command or skill invocation.
|
|
367
397
|
|
|
368
398
|
### Command interaction graph
|
|
369
399
|
|
|
370
|
-
Every solid handoff below means: the current capability returns
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
silently launches another.
|
|
400
|
+
Every solid handoff below means: the current capability returns context and checkpoint
|
|
401
|
+
diagnostics, the model recommends a route, and the owner explicitly invokes the next
|
|
402
|
+
public capability. It does not mean that one public command silently launches another.
|
|
374
403
|
|
|
375
404
|
```mermaid
|
|
376
405
|
flowchart TD
|
|
@@ -459,8 +488,8 @@ health without selecting product intent.
|
|
|
459
488
|
|
|
460
489
|
Together, `.ultra/` is Ultra's project-local cross-session workflow memory. The
|
|
461
490
|
host model writes semantic specifications and evidence through the active
|
|
462
|
-
|
|
463
|
-
accepted intent, then
|
|
491
|
+
capability. MCP records lifecycle state, references, digests, provenance, and
|
|
492
|
+
accepted intent, then validates durable checkpoints and mechanical integrity. The DB is the
|
|
464
493
|
lifecycle and index authority for one checkout; registered digest-bound files carry
|
|
465
494
|
the semantic or evidence bodies that the DB references. The Git checkpoint is a
|
|
466
495
|
portable, digest-chained handoff of baseline, Change, and durable task records. It is
|
|
@@ -551,12 +580,13 @@ host's existing model session.
|
|
|
551
580
|
- **Project state is unhealthy:** invoke `ultra-doctor` or run
|
|
552
581
|
`ultra-tools system doctor`. Repairs and schema migrations are backup-first.
|
|
553
582
|
- **The team checkpoint disagrees with local state:** run `ultra-status`, inspect the
|
|
554
|
-
typed ledger condition, then use
|
|
555
|
-
|
|
583
|
+
typed ledger condition, then use `ultra.sync` to import or publish after reviewing
|
|
584
|
+
any real conflict. Never edit `.ultra/tasks/tasks.json` by hand.
|
|
556
585
|
- **A generated view disagrees with MCP:** trust `.ultra/.runtime/state.db`; never edit
|
|
557
586
|
`.ultra/.runtime/projections/` by hand.
|
|
558
|
-
- **A
|
|
559
|
-
|
|
587
|
+
- **A draft checkpoint is rejected:** use `ultra-status` to read the exact warnings
|
|
588
|
+
and blockers, fix the same mutable draft, and retry. Use `workflow.abandon` through
|
|
589
|
+
`ultra.record` only when intentionally cancelling the attempt.
|
|
560
590
|
- **Kimi reports a native-module ABI error:** ensure an external Node.js 22+
|
|
561
591
|
executable is available on `PATH`; the generated Kimi MCP launcher uses
|
|
562
592
|
`env node`.
|
|
@@ -96,7 +96,7 @@ function adaptCodexPrimaryText(input, skillName) {
|
|
|
96
96
|
let text = String(input);
|
|
97
97
|
if (skillName === 'ultra-review') {
|
|
98
98
|
text = text.replace(
|
|
99
|
-
/the current host's native bounded-worker\s+mechanism/g,
|
|
99
|
+
/(?:the current host's native|the host-native) bounded-worker\s+mechanism/g,
|
|
100
100
|
'native Codex custom agents installed for the selected review workers',
|
|
101
101
|
);
|
|
102
102
|
}
|
|
@@ -470,7 +470,11 @@ main().catch((error) => {
|
|
|
470
470
|
|
|
471
471
|
const sourceToolsFile = path.join(repoRoot, 'spec', 'mcp-tools.yaml');
|
|
472
472
|
const upstreamManifest = yaml.load(fs.readFileSync(sourceToolsFile, 'utf8'));
|
|
473
|
-
const {
|
|
473
|
+
const {
|
|
474
|
+
LEGACY_TOOLS,
|
|
475
|
+
PUBLIC_TOOLS,
|
|
476
|
+
REGISTERED_TOOLS,
|
|
477
|
+
} = require(path.join(repoRoot, 'mcp-server', 'server.cjs'));
|
|
474
478
|
const registered = new Set(REGISTERED_TOOLS);
|
|
475
479
|
const liveFamilies = new Set(
|
|
476
480
|
upstreamManifest.tools.filter((tool) => registered.has(tool.name)).map((tool) => tool.family),
|
|
@@ -495,7 +499,8 @@ main().catch((error) => {
|
|
|
495
499
|
fs.copyFileSync(sourceToolsFile, path.join(specRoot, 'upstream-mcp-tools.yaml'));
|
|
496
500
|
writeAtomic(path.join(specRoot, 'codex-capability-map.json'), JSON.stringify({
|
|
497
501
|
runtime: 'codex',
|
|
498
|
-
live_mcp_tools:
|
|
502
|
+
live_mcp_tools: PUBLIC_TOOLS,
|
|
503
|
+
compatibility_mcp_tools: LEGACY_TOOLS,
|
|
499
504
|
codex_native_replacements: CODEX_NATIVE_MCP_REPLACEMENTS,
|
|
500
505
|
}, null, 2) + '\n');
|
|
501
506
|
}
|
|
@@ -32,7 +32,7 @@ function interactionContract(runtime) {
|
|
|
32
32
|
const question = SURFACES[runtime];
|
|
33
33
|
if (!question) throw new Error(`unsupported interaction runtime: ${runtime}`);
|
|
34
34
|
return {
|
|
35
|
-
schema_version: '1.
|
|
35
|
+
schema_version: '1.3',
|
|
36
36
|
runtime,
|
|
37
37
|
public_capability_graph: PUBLIC_CAPABILITY_GRAPH,
|
|
38
38
|
authority: {
|
|
@@ -50,9 +50,9 @@ function interactionContract(runtime) {
|
|
|
50
50
|
'accepted_intent_normalization',
|
|
51
51
|
],
|
|
52
52
|
ultra_mcp: [
|
|
53
|
-
'
|
|
54
|
-
'
|
|
55
|
-
'
|
|
53
|
+
'durable_checkpoints_and_evidence_refs',
|
|
54
|
+
'digests_freshness_leases_archives_and_recovery',
|
|
55
|
+
'mutable_semantic_diagnostics',
|
|
56
56
|
],
|
|
57
57
|
},
|
|
58
58
|
interaction: {
|
|
@@ -85,8 +85,15 @@ function interactionContract(runtime) {
|
|
|
85
85
|
routing: {
|
|
86
86
|
semantic_recommendation_owner: 'host_model',
|
|
87
87
|
durable_recommendation_authority: false,
|
|
88
|
-
|
|
89
|
-
|
|
88
|
+
current_context_tool: 'ultra.context',
|
|
89
|
+
checkpoint_diagnostic_fields: ['warnings', 'blockers'],
|
|
90
|
+
hard_blocker_boundary: [
|
|
91
|
+
'corruption',
|
|
92
|
+
'unsafe_path',
|
|
93
|
+
'concurrency_conflict',
|
|
94
|
+
'permission',
|
|
95
|
+
'irreversible_external_effect',
|
|
96
|
+
],
|
|
90
97
|
},
|
|
91
98
|
};
|
|
92
99
|
}
|
|
@@ -41,7 +41,7 @@ const PUBLIC_CAPABILITY_GRAPH = Object.freeze(Object.fromEntries(
|
|
|
41
41
|
Object.freeze({
|
|
42
42
|
mode: PUBLIC_CAPABILITY_MODES[name],
|
|
43
43
|
activation: 'explicit_only',
|
|
44
|
-
next_capability_source: '
|
|
44
|
+
next_capability_source: 'host_model_from_ultra_context',
|
|
45
45
|
recommendation_owner: 'host_model',
|
|
46
46
|
selection_owner: 'user',
|
|
47
47
|
automatic_invocation: false,
|
package/adapters/claude.js
CHANGED
|
@@ -66,7 +66,7 @@ function copySkills(repoRoot, target, names) {
|
|
|
66
66
|
let adaptedBody = adaptInteractionGuidance(body, 'claude');
|
|
67
67
|
if (name === 'ultra-review') {
|
|
68
68
|
adaptedBody = adaptedBody.replace(
|
|
69
|
-
/the current host's native bounded-worker\s+mechanism/g,
|
|
69
|
+
/(?:the current host's native|the host-native) bounded-worker\s+mechanism/g,
|
|
70
70
|
'Claude Code Task workers using the installed review agent definitions',
|
|
71
71
|
);
|
|
72
72
|
}
|
package/adapters/kimi.js
CHANGED
|
@@ -96,7 +96,7 @@ function kimiTextTransform(input, assetName = '') {
|
|
|
96
96
|
}
|
|
97
97
|
if (assetName === 'ultra-review') {
|
|
98
98
|
text = text.replace(
|
|
99
|
-
/the current host's native bounded-worker\s+mechanism/g,
|
|
99
|
+
/(?:the current host's native|the host-native) bounded-worker\s+mechanism/g,
|
|
100
100
|
'Kimi `AgentSwarm` for parallel reviewers or one foreground Kimi `Agent` for a single reviewer, using the worker prompt files under `$KIMI_PLUGIN_ROOT/agents/`',
|
|
101
101
|
);
|
|
102
102
|
}
|
package/adapters/opencode.js
CHANGED
|
@@ -93,7 +93,7 @@ function openCodeTextTransform(input, assetName = '') {
|
|
|
93
93
|
}
|
|
94
94
|
if (assetName === 'ultra-review') {
|
|
95
95
|
text = text.replace(
|
|
96
|
-
/the current host's native bounded-worker\s+mechanism/g,
|
|
96
|
+
/(?:the current host's native|the host-native) bounded-worker\s+mechanism/g,
|
|
97
97
|
'the OpenCode `task` tool using the installed bounded review agents',
|
|
98
98
|
);
|
|
99
99
|
}
|
package/docs/AGENT-CONTEXT.md
CHANGED
|
@@ -25,18 +25,18 @@ not put it in a plugin until that allowlist classifies it.
|
|
|
25
25
|
## 2. Three-layer architecture
|
|
26
26
|
|
|
27
27
|
```text
|
|
28
|
-
native command or skill -> MCP
|
|
28
|
+
native command or skill -> 7-tool MCP safety kernel -> .ultra/.runtime/state.db
|
|
29
29
|
| \
|
|
30
30
|
| -> .ultra/tasks/tasks.json (Git checkpoint)
|
|
31
31
|
| -> .ultra/.runtime/projections/ (local views)
|
|
32
32
|
^
|
|
33
|
-
|
|
33
|
+
CLI diagnostics / orchestration
|
|
34
34
|
```
|
|
35
35
|
|
|
36
36
|
| Layer | Artifact | Contract |
|
|
37
37
|
|---|---|---|
|
|
38
38
|
| Skill/command | `skills/*/SKILL.md`, `commands/*.md` | Model-facing workflow and host-native entry point |
|
|
39
|
-
| MCP | `mcp-server/server.cjs` |
|
|
39
|
+
| MCP | `mcp-server/server.cjs` | Persistence, semantic checkpoints, team sync, leases, archive transactions, and mechanical recovery |
|
|
40
40
|
| CLI | `ultra-tools`, `ubp-orchestrator` | Selected initialization, backup-first recovery, automation, and diagnostics; not a change-state mirror |
|
|
41
41
|
|
|
42
42
|
`.ultra/` is project-local cross-session workflow memory for normalized intent,
|
|
@@ -51,28 +51,29 @@ authority. Generated task views, runtime checkpoints, and collaboration scratch
|
|
|
51
51
|
not independent authority. See
|
|
52
52
|
[`ARTIFACT-AUTHORITY.md`](./ARTIFACT-AUTHORITY.md).
|
|
53
53
|
|
|
54
|
-
## 3.
|
|
54
|
+
## 3. Public MCP kernel and compatibility layer
|
|
55
55
|
|
|
56
|
-
|
|
57
|
-
nine families:
|
|
56
|
+
Every host discovers the same seven model-facing tools:
|
|
58
57
|
|
|
59
|
-
|
|
|
58
|
+
| Public tool | Contract |
|
|
60
59
|
|---|---|
|
|
61
|
-
| `
|
|
62
|
-
| `
|
|
63
|
-
| `
|
|
64
|
-
| `
|
|
65
|
-
| `
|
|
66
|
-
| `
|
|
67
|
-
| `
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
60
|
+
| `ultra.context` | side-effect-free current authority and evidence spine |
|
|
61
|
+
| `ultra.record` | idempotent batch recording of typed draft facts and events |
|
|
62
|
+
| `ultra.checkpoint` | one semantic stage commit; rejection keeps the draft mutable |
|
|
63
|
+
| `ultra.sync` | Git team-checkpoint inspect/import/publish |
|
|
64
|
+
| `ultra.session` | transactional execution lease |
|
|
65
|
+
| `ultra.archive` | recoverable convergence and archive boundary |
|
|
66
|
+
| `ultra.doctor` | mechanical diagnosis and backup-first repair |
|
|
67
|
+
|
|
68
|
+
The public schemas stay below a 12KB discovery budget. The sixty 0.22 fine-grained
|
|
69
|
+
task/session/baseline/change/decision/workflow/artifact/system/plan tools remain
|
|
70
|
+
callable but undiscoverable for one compatibility release. They are implementation
|
|
71
|
+
operations, not a second public API, and Skills must not call them directly.
|
|
72
|
+
|
|
73
|
+
Semantic rejections return `accepted: false`, `mutable: true`, and diagnostics. Hard
|
|
74
|
+
MCP errors are reserved for corruption, unsafe paths, real concurrency conflicts,
|
|
75
|
+
permissions, or irreversible effects. Review, repository discovery, model reasoning,
|
|
76
|
+
and owner interaction remain host-native.
|
|
76
77
|
|
|
77
78
|
The complete write, transition, invalidation, and recovery contract lives in
|
|
78
79
|
[`WORKFLOW-LIFECYCLE.md`](./WORKFLOW-LIFECYCLE.md).
|
|
@@ -91,23 +92,20 @@ review, and deliver route back to the same thread instead of deciding for the ow
|
|
|
91
92
|
One partial unique index permits only one open item per thread. `decision.resolve`,
|
|
92
93
|
`decision.delegate`, and `decision.defer` preserve the source of authority;
|
|
93
94
|
`decision.supersede` preserves history when evidence or intent changes.
|
|
94
|
-
After normalization, the host
|
|
95
|
-
|
|
96
|
-
authority
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
material accepted cluster to current artifact digests when interruption recovery needs
|
|
101
|
-
that boundary. Status and breadcrumb return the current unresolved question, accepted
|
|
102
|
-
intent relevant to the active authority, and allowed or mechanically required
|
|
103
|
-
transitions, so recovery does not require replaying conversation history.
|
|
95
|
+
After normalization, the host records accepted intent in one `ultra.record` batch,
|
|
96
|
+
reads it back through `ultra.context`, and attempts an owning `ultra.checkpoint` only
|
|
97
|
+
when durable authority is ready. Active proposals are never recalled as accepted
|
|
98
|
+
intent. Status returns the current unresolved question, accepted intent, evidence,
|
|
99
|
+
warnings, and hard blockers so recovery does not require replaying conversation
|
|
100
|
+
history. The host model, not SQLite, recommends the next capability.
|
|
104
101
|
|
|
105
102
|
## 5. Context Spine contract
|
|
106
103
|
|
|
107
104
|
Context Manifest v3 is an immutable DB-backed role handoff, not a static codebase summary.
|
|
108
|
-
`
|
|
109
|
-
|
|
110
|
-
|
|
105
|
+
`ultra.checkpoint` compiles or reuses a content-addressed Context Manifest containing
|
|
106
|
+
required references, digests, readiness, context budget, public seam, exact verification
|
|
107
|
+
command, and Change/task authority digests for `plan`, `implement`, `check`, or
|
|
108
|
+
`review`. Compilation never updates
|
|
111
109
|
Change or provider authority; provider metadata changes through `change.update`.
|
|
112
110
|
Snapshots are selected exactly by `change_id`, nullable `task_id`, `role`, and `gate`,
|
|
113
111
|
so a review packet cannot satisfy implementation or planning evidence.
|
|
@@ -125,9 +123,9 @@ not block work or require raising a threshold. Prefer direct reads, bounded
|
|
|
125
123
|
excerpts, or a smaller slice when they preserve correctness, and retain all
|
|
126
124
|
necessary context when they do not.
|
|
127
125
|
|
|
128
|
-
|
|
129
|
-
role, gate, readiness, blockers, bounded normalized accepted intent
|
|
130
|
-
|
|
126
|
+
The compact breadcrumb is a hook-only compatibility reader. Hooks may inject its
|
|
127
|
+
change/task, role, gate, readiness, blockers, and bounded normalized accepted intent.
|
|
128
|
+
They must not inject raw prompts,
|
|
131
129
|
interaction transcripts, external-memory payloads, or graph payloads. Missing references,
|
|
132
130
|
required digest drift, HEAD drift, or a missing execution seam blocks readiness. Context
|
|
133
131
|
size and baseline drift are advisory for a change that is already active. New ordinary
|
|
@@ -176,7 +174,7 @@ the shared read-only `context_spine.py` breadcrumb helper:
|
|
|
176
174
|
and types, never transcript paths or messages.
|
|
177
175
|
|
|
178
176
|
`workflow_context.py`, `active_task_context.py`, `workflow_resume.py`, and the
|
|
179
|
-
OpenCode plugin invoke the same bundled JavaScript
|
|
177
|
+
OpenCode plugin invoke the same bundled JavaScript hook-only breadcrumb reader
|
|
180
178
|
through the thin `context_spine.py` bridge. No hook reimplements the state query.
|
|
181
179
|
`health_check.py` and
|
|
182
180
|
`workflow_context.py` may inspect any initialized project;
|
|
@@ -185,7 +183,7 @@ projection but limits ordinary
|
|
|
185
183
|
edit guidance to an active workflow. Compact/stop/subagent hooks remain
|
|
186
184
|
active-workflow scoped. OpenCode natively injects baseline/change context and
|
|
187
185
|
protects both managed task paths; full health inspection is available through
|
|
188
|
-
`
|
|
186
|
+
`ultra.doctor` rather than a session-start health hook.
|
|
189
187
|
Advisory baseline or context-budget warnings are presentation only and never
|
|
190
188
|
reject an edit, stop, or tool call.
|
|
191
189
|
Generic command blocking, post-edit governance, and unrelated user hooks are not
|
package/docs/ARCHITECTURE.md
CHANGED
|
@@ -55,14 +55,14 @@ memory under `.ultra/`.
|
|
|
55
55
|
| Layer | Role | Form |
|
|
56
56
|
|--------------|----------------------------------------------|-------------------------------------------------------|
|
|
57
57
|
| **skill** | knowledge carrier; tells the runtime *what to do* | `skills/<name>/SKILL.md` discovered natively by all supported runtimes |
|
|
58
|
-
| **MCP** |
|
|
58
|
+
| **MCP** | persistence and safety kernel for checkpoints, evidence, sync, leases, archive, and recovery | stdio MCP server exposing seven public `ultra.*` tools; sixty 0.22 fine-grained operations remain hidden for one compatibility release |
|
|
59
59
|
| **CLI** | explicit initialization, recovery, diagnostics, and orchestration | `ultra-tools` / `ubp-orchestrator`; only commands listed by `--help` are executable (see [`spec/cli-protocol.md`](../spec/cli-protocol.md)) |
|
|
60
60
|
|
|
61
|
-
Why three: skills
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
61
|
+
Why three: skills preserve adaptable model behavior across runtimes; MCP gives durable
|
|
62
|
+
checkpoint and safety primitives without supervising every reasoning step; the CLI
|
|
63
|
+
supplies bounded maintenance and recovery when MCP cannot start. Semantic draft
|
|
64
|
+
diagnostics are report-first. Corruption, unsafe paths, real concurrency, permissions,
|
|
65
|
+
and irreversible effects remain fail-closed.
|
|
66
66
|
|
|
67
67
|
The skill layer is **read-only by design** (D29) and is discovered directly by
|
|
68
68
|
each host. Ultra exposes no `skill.*` MCP family: skills are documentation, not
|
|
@@ -222,15 +222,11 @@ current question per thread. The host ends that turn and waits.
|
|
|
222
222
|
|
|
223
223
|
The next response becomes a normalized owner decision, explicit reversible delegation,
|
|
224
224
|
or consequence-bearing deferral. Prompts and transcripts are never persisted. The host
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
boundary moves through prepare/confirm checkpointing. Matching workflow steps fail
|
|
231
|
-
closed while a blocking question, blocking deferral, prepared checkpoint, or stale
|
|
232
|
-
checkpoint artifact remains. Supersession preserves prior history and reopens alignment
|
|
233
|
-
instead of silently editing an old decision. The shared procedure lives in
|
|
225
|
+
batches the normalized result and owning mutation through `ultra.record`, reads it back
|
|
226
|
+
through `ultra.context`, and attempts a semantic checkpoint only when durable authority
|
|
227
|
+
is ready. Failed semantic checks leave the draft editable. Accepted revisions remain
|
|
228
|
+
immutable; a changed decision opens a replacement draft while preserving history. The
|
|
229
|
+
shared procedure lives in
|
|
234
230
|
`skills/ultra-think/references/decision-dialogue.md`; status, breadcrumb, and doctor expose
|
|
235
231
|
only the current recovery surface.
|
|
236
232
|
|
|
@@ -262,9 +258,10 @@ consumer trace. Standard and major convergence requires both current authorities
|
|
|
262
258
|
only after all writes and baseline reconciliation succeed does it rebind the complete
|
|
263
259
|
Change root into the archive.
|
|
264
260
|
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
261
|
+
Draft revisions remain editable and recoverable. A failed checkpoint can be repaired
|
|
262
|
+
and retried in place or intentionally abandoned. Accepted runs are immutable; a later
|
|
263
|
+
candidate supersedes them only after its own accepted checkpoint, and the artifact graph
|
|
264
|
+
invalidates only true transitive consumers.
|
|
268
265
|
|
|
269
266
|
### Context Spine
|
|
270
267
|
|
|
@@ -277,25 +274,24 @@ implementation, checking, review, convergence, and recovery. Each snapshot recor
|
|
|
277
274
|
execution contract;
|
|
278
275
|
- advisory attention budgets (12 files / about 12k tokens / 40% by default);
|
|
279
276
|
- a DB-derived execution contract (`slice_kind`, public seam, exact verification command);
|
|
280
|
-
-
|
|
281
|
-
hard invariant leaves one recovery route;
|
|
277
|
+
- warnings and hard mechanical blockers without a semantic next-action command;
|
|
282
278
|
- a digest of the accepted Change authority so semantic updates invalidate the
|
|
283
279
|
snapshot.
|
|
284
280
|
|
|
285
|
-
|
|
281
|
+
Checkpoint input may identify the intended role/gate, add bounded reference candidates,
|
|
286
282
|
and lower advisory budgets. It cannot supply or override the task seam, verification
|
|
287
283
|
command, task context references, evidence digest, gate verdict, workflow summary, or
|
|
288
284
|
machine transitions. A host may attach a clearly non-authoritative recommendation.
|
|
289
285
|
Critical dev/test/review/deliver workflow steps record the matching
|
|
290
286
|
snapshot as an output; test, review, and delivery reports carry its digest forward.
|
|
291
287
|
|
|
292
|
-
|
|
288
|
+
The hook-only breadcrumb derives the compact current position from state.db. Session,
|
|
293
289
|
edit, resume, and OpenCode lifecycle hooks invoke one bundled read-only reader
|
|
294
290
|
and inject it only while state.db proves an active, blocked, or ready workflow,
|
|
295
291
|
never the intent body,
|
|
296
292
|
provider content, or a conversation summary. A changed Git HEAD, task contract, or
|
|
297
|
-
Change semantic authority marks the snapshot stale and permits
|
|
298
|
-
`
|
|
293
|
+
Change semantic authority marks the snapshot stale and permits content-addressed
|
|
294
|
+
recompilation through the next `ultra.checkpoint`.
|
|
299
295
|
|
|
300
296
|
PRD decomposition and complex-task subdivision use the active host model. The
|
|
301
297
|
MCP accepts the resulting structured tasks, validates schema, topology,
|
|
@@ -305,9 +301,9 @@ model API credential.
|
|
|
305
301
|
|
|
306
302
|
Plugin installation does not activate a semantic workflow and never edits the
|
|
307
303
|
user's `CLAUDE.md`, `AGENTS.md`, or equivalent durable instructions. Public
|
|
308
|
-
workflows require explicit user invocation.
|
|
309
|
-
|
|
310
|
-
|
|
304
|
+
workflows require explicit user invocation. The host reads `ultra.context`, recommends
|
|
305
|
+
the next capability from evidence and owner intent, then stops; SQLite never launches
|
|
306
|
+
or semantically selects the next public workflow. OpenCode realizes this boundary
|
|
311
307
|
with explicit commands backed by private plugin workflow assets, while Claude,
|
|
312
308
|
Codex, and Kimi use their native implicit-invocation controls.
|
|
313
309
|
|
|
@@ -334,8 +330,8 @@ Mutating MCP calls enqueue durable `projection_jobs`. Success is exposed in MCP
|
|
|
334
330
|
response metadata; failure becomes a retryable structured incident instead of a
|
|
335
331
|
swallowed warning. These jobs regenerate only checkout-local views below
|
|
336
332
|
`.ultra/.runtime/projections/`; they never rewrite the Git team checkpoint. Durable
|
|
337
|
-
semantic
|
|
338
|
-
|
|
333
|
+
semantic checkpoints publish team state at baseline, Change, plan, and task handoff
|
|
334
|
+
boundaries. `ultra.doctor` is read-only by default. Explicit repair
|
|
339
335
|
performs backup-first schema upgrade, archive-journal recovery, session and local
|
|
340
336
|
projection recovery, and regenerated local views. It cannot import or publish semantic
|
|
341
337
|
team state, approve a baseline, or replace a corrupt SQLite file silently. `system
|
|
@@ -346,14 +342,14 @@ authority and the legacy task projection before creating a new brownfield adopti
|
|
|
346
342
|
|
|
347
343
|
### Git team checkpoint and checkout merge
|
|
348
344
|
|
|
349
|
-
`
|
|
350
|
-
and durable task contracts to `.ultra/tasks/tasks.json`. Per-record digests and
|
|
345
|
+
`ultra.sync { action: publish }` serializes the current portable baseline, all Change
|
|
346
|
+
summaries, and durable task contracts to `.ultra/tasks/tasks.json`. Per-record digests and
|
|
351
347
|
revisions make independent fast-forward possible; the document state digest, parent
|
|
352
348
|
digest, and bounded ancestor list reject stale or unrelated histories. Local process
|
|
353
349
|
ownership fields are deliberately absent.
|
|
354
350
|
|
|
355
351
|
The MCP server imports the checkpoint once when it opens project authority. A
|
|
356
|
-
long-running host explicitly calls `
|
|
352
|
+
long-running host explicitly calls `ultra.sync { action: import }` after receiving a newer Git
|
|
357
353
|
version. Import is transactional: it validates every record first, preserves local-only
|
|
358
354
|
fields, fast-forwards clean records, and rejects same-record concurrency or an active
|
|
359
355
|
task collision. Re-reading an already imported checkpoint performs no write. A ready
|
|
@@ -451,7 +447,7 @@ repository commit.
|
|
|
451
447
|
`ubp --all --global --doctor [--json]` is read-only: it recomputes hashes and
|
|
452
448
|
validates those entry points, returning a non-zero degraded result for
|
|
453
449
|
missing/corrupt provenance, content drift, or broken host wiring. A single host
|
|
454
|
-
can be selected instead of `--all`. This is separate from `
|
|
450
|
+
can be selected instead of `--all`. This is separate from `ultra.doctor`, which
|
|
455
451
|
diagnoses project state, projection, incidents, sessions, and backup-first
|
|
456
452
|
workflow recovery.
|
|
457
453
|
|