ultra-builder-pro-cli 0.16.0 → 0.17.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/reports/templates/delivery-report.json +17 -0
- package/.ultra-template/reports/templates/test-report.json +18 -0
- package/.ultra-template/specs/research-distillate.md +4 -3
- package/CHANGELOG.md +95 -0
- package/README.md +54 -24
- package/adapters/_shared/codex-assets.cjs +10 -5
- package/adapters/_shared/handbook.cjs +1 -1
- package/adapters/_shared/interaction-contract.cjs +61 -0
- package/adapters/claude.js +1 -1
- package/adapters/opencode.js +1 -1
- package/bin/orchestrator.js +175 -19
- package/commands/ultra-change.md +1 -1
- package/commands/ultra-deliver.md +3 -3
- package/commands/ultra-init.md +1 -1
- package/commands/ultra-plan.md +1 -1
- package/commands/ultra-research.md +2 -2
- package/commands/ultra-review.md +10 -0
- package/commands/ultra-status.md +1 -1
- package/commands/ultra-test.md +1 -1
- package/docs/AGENT-CONTEXT.md +11 -8
- package/docs/ARCHITECTURE.md +67 -9
- package/docs/LEGACY-CLI-CROSSWALK.md +163 -0
- package/docs/PLAN.zh-CN.md +19 -13
- package/docs/RUNTIME-COMPAT-MATRIX.md +2 -2
- package/docs/WORKFLOW-LIFECYCLE.md +123 -59
- package/hooks/pre_stop_check.py +3 -2
- package/mcp-server/lib/baseline-workflow.cjs +84 -16
- package/mcp-server/lib/change-workflow.cjs +55 -35
- package/mcp-server/lib/context-spine.cjs +171 -105
- package/mcp-server/lib/git-bootstrap.cjs +240 -0
- package/mcp-server/lib/init-project.cjs +178 -41
- package/mcp-server/lib/project-breadcrumb.cjs +14 -14
- package/mcp-server/lib/state-db.cjs +257 -10
- package/mcp-server/lib/state-ops.cjs +64 -1
- package/mcp-server/lib/workflow-state.cjs +300 -205
- package/mcp-server/server.cjs +58 -34
- package/orchestrator/auto-merge.cjs +19 -0
- package/orchestrator/daemon.cjs +104 -0
- package/orchestrator/parallel-orchestrator.cjs +371 -49
- package/orchestrator/session-runner.cjs +354 -25
- package/package.json +2 -1
- package/skills/ultra-change/SKILL.md +69 -94
- package/skills/ultra-deliver/SKILL.md +37 -65
- package/skills/ultra-dev/SKILL.md +50 -52
- package/skills/ultra-doctor/SKILL.md +34 -49
- package/skills/ultra-init/SKILL.md +78 -105
- package/skills/ultra-plan/SKILL.md +78 -99
- package/skills/ultra-research/SKILL.md +99 -113
- package/skills/ultra-review/SKILL.md +38 -53
- package/skills/ultra-review/references/review-modes.md +5 -3
- package/skills/ultra-review/references/unified-schema.md +26 -6
- package/skills/ultra-review/scripts/review_wait.py +12 -0
- package/skills/ultra-status/SKILL.md +34 -44
- package/skills/ultra-test/SKILL.md +61 -54
- package/skills/ultra-think/SKILL.md +37 -51
- package/skills/ultra-think/references/decision-dialogue.md +87 -111
- package/spec/cli-protocol.md +35 -0
- package/spec/mcp-tools.yaml +145 -28
- package/spec/schemas/delivery-report.v1.schema.json +1 -46
- package/spec/schemas/state-db.sql +8 -2
- package/spec/schemas/test-report.v1.schema.json +45 -14
- package/ultra-tools/cli.cjs +1 -1
- package/ultra-tools/commands/session.cjs +10 -3
- package/ultra-tools/commands/status.cjs +19 -14
- package/ultra-tools/commands/system.cjs +2 -2
- package/ultra-tools/commands/task.cjs +3 -0
|
@@ -1,58 +1,65 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: ultra-test
|
|
3
|
-
description:
|
|
3
|
+
description: Independently verify an Ultra task set or change with an evidence-backed, risk-selected test profile. Use when implementation or current acceptance and recovery evidence needs independent verification.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# Verify
|
|
7
|
-
|
|
8
|
-
Testing is independent checking. Do not reuse
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
## Bind
|
|
12
|
-
|
|
13
|
-
1. Read
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
`
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
6
|
+
# Verify current behavior
|
|
7
|
+
|
|
8
|
+
Testing is independent checking. Do not reuse implementation conclusions or generated
|
|
9
|
+
projections as proof.
|
|
10
|
+
|
|
11
|
+
## Bind scope
|
|
12
|
+
|
|
13
|
+
1. Read doctor, change, breadcrumb, decisions, task and dev evidence, current checkout,
|
|
14
|
+
and prior report freshness.
|
|
15
|
+
2. Resume or start a test workflow bound to the exact change and optional task.
|
|
16
|
+
3. Record `bind-scope`, then compile `change.context` for `check` and record its
|
|
17
|
+
immutable manifest under `compile-context`.
|
|
18
|
+
4. Record `map-acceptance` after mapping every accepted claim to an executable check
|
|
19
|
+
or bounded observable seam.
|
|
20
|
+
|
|
21
|
+
## Select verification by risk
|
|
22
|
+
|
|
23
|
+
The model selects from:
|
|
24
|
+
|
|
25
|
+
- acceptance;
|
|
26
|
+
- regression;
|
|
27
|
+
- integration;
|
|
28
|
+
- static analysis;
|
|
29
|
+
- build;
|
|
30
|
+
- performance;
|
|
31
|
+
- security;
|
|
32
|
+
- recovery.
|
|
33
|
+
|
|
34
|
+
Acceptance is always selected. Select other dimensions when the change, repository, or
|
|
35
|
+
failure mode makes them material. Record excluded dimensions and concrete rationales in
|
|
36
|
+
`verification_profile`; omission without a rationale is invalid. A selected dimension
|
|
37
|
+
must be `pass`, `fail`, or `not_run`; `not_run` cannot support a passing gate.
|
|
38
|
+
|
|
39
|
+
Run repository-native commands and real boundaries where practical. Test doubles are
|
|
40
|
+
acceptable only at costly or nondeterministic external boundaries when the report
|
|
41
|
+
explains the preserved contract. Do not weaken assertions, hide skips, or validate
|
|
42
|
+
unconsumed code.
|
|
43
|
+
|
|
44
|
+
For an incident or bugfix, record one deterministic red-to-green `regression_signal`.
|
|
45
|
+
When evidence reveals a material product or recovery choice, use the host's native
|
|
46
|
+
question UI and decision protocol; testing must not choose the desired outcome.
|
|
47
|
+
|
|
48
|
+
## Report
|
|
49
|
+
|
|
50
|
+
Write `.ultra/reports/tests/<workflow-id>.json` with
|
|
51
|
+
`ultra-test-report-v1`, binding:
|
|
52
|
+
|
|
53
|
+
- change, exact task ids, HEAD, worktree digest, and checking-context digest;
|
|
54
|
+
- acceptance mapping, commands, public seams, failures, and recovery evidence;
|
|
55
|
+
- `verification_profile` and the selected `verification_dimensions`;
|
|
56
|
+
- regression signal when required;
|
|
57
|
+
- run count, timestamp, blockers, and evidence-derived `passed`.
|
|
58
|
+
|
|
59
|
+
Record `execute-checks`, `verify-public-seam`, and `write-report`, then re-read the
|
|
60
|
+
report and current checkout before `verify-test-gate`. `workflow.complete` derives its
|
|
61
|
+
summary from the report and rejects stale, malformed, or contradictory evidence.
|
|
62
|
+
|
|
63
|
+
Return the profile, exact results, verified seams, blockers, report digest, workflow
|
|
64
|
+
state, and allowed transitions. The host decides whether a broader review, more
|
|
65
|
+
implementation, or delivery is appropriate.
|
|
@@ -1,65 +1,51 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: ultra-think
|
|
3
|
-
description: Resolve a consequential product or
|
|
3
|
+
description: Resolve a consequential product, architecture, or recovery question through evidence-first reasoning and adaptive user alignment. Use when a material decision cannot be derived safely from accepted intent and current evidence.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# Align
|
|
6
|
+
# Align without suppressing model judgment
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
Thinking is an optional reasoning capability, not a mandatory stage. Answer
|
|
9
|
+
self-contained questions directly. Use durable decision state only when a
|
|
10
|
+
project-bound choice must survive interruption or gate later work.
|
|
11
11
|
|
|
12
|
-
##
|
|
12
|
+
## Reason first
|
|
13
13
|
|
|
14
|
-
1.
|
|
15
|
-
|
|
16
|
-
2.
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
the choice and explain the tradeoffs.
|
|
26
|
-
5. For a diagnosis, form falsifiable hypotheses and identify the smallest observation
|
|
27
|
-
that distinguishes them. Do not recommend implementation before the earliest
|
|
28
|
-
incorrect state is supported by evidence.
|
|
29
|
-
6. Stress-test the leading conclusion with the techniques that fit the problem:
|
|
30
|
-
- strongest counterargument;
|
|
31
|
-
- likely failure scenario and recovery;
|
|
32
|
-
- load-bearing assumption;
|
|
33
|
-
- meaningful second-order effect.
|
|
34
|
-
7. Decide whether the question is now answerable or still requires owner authority.
|
|
14
|
+
1. Define the actual decision or disputed claim and the constraints that can change
|
|
15
|
+
its answer.
|
|
16
|
+
2. Inspect current authority, source, runtime, tests, and primary documentation before
|
|
17
|
+
asking the user for facts.
|
|
18
|
+
3. Separate verified fact, evidence-backed inference, accepted intent, delegated
|
|
19
|
+
implementation judgment, and unresolved owner choice.
|
|
20
|
+
4. Form credible alternatives only when alternatives materially help the decision.
|
|
21
|
+
Evaluate them against the real constraints; do not impose a fixed option count,
|
|
22
|
+
scoring system, or confidence percentage.
|
|
23
|
+
5. Stress-test the leading answer with its strongest counterexample, likely failure
|
|
24
|
+
path, recovery, and load-bearing assumption.
|
|
35
25
|
|
|
36
|
-
##
|
|
26
|
+
## Interact adaptively
|
|
37
27
|
|
|
38
|
-
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
- For a load-bearing owner decision, bind or resume a decision thread, open the one
|
|
42
|
-
earliest decision, present it using the shared protocol, and STOP.
|
|
43
|
-
- After an answer, normalize it through `decision.resolve`, `decision.delegate`, or
|
|
44
|
-
`decision.defer`; never store the conversation transcript.
|
|
45
|
-
- At a phase boundary, prepare the checkpoint, obtain approval, bind current artifact
|
|
46
|
-
digests when project-bound, and only then return control to the invoking workflow.
|
|
28
|
+
Read `references/decision-dialogue.md`. If the user already gave a clear decision,
|
|
29
|
+
normalize and use it without asking for confirmation. If the decision is reversible
|
|
30
|
+
and delegated by the accepted contract, decide it and explain the reasoning.
|
|
47
31
|
|
|
48
|
-
|
|
32
|
+
When owner authority is required, use the host's native question UI when available.
|
|
33
|
+
Ask the earliest dependent decision with a recommendation, decisive evidence, and the
|
|
34
|
+
effect of the answer. Keep cognitive load small; group only independent, simple facts.
|
|
35
|
+
Do not expose the hidden decision queue.
|
|
49
36
|
|
|
50
|
-
|
|
37
|
+
For durable project decisions, use `decision.thread_start`, `decision.open`, and the
|
|
38
|
+
appropriate resolve, delegate, defer, or supersede transition. Store normalized
|
|
39
|
+
decisions and artifact references, never transcripts or internal reasoning.
|
|
51
40
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
- one concrete verification or follow-up action.
|
|
41
|
+
Prepare and confirm a checkpoint only when the decision changes a durable contract or
|
|
42
|
+
artifact and a checkpoint is needed for recovery. Do not add a ceremonial approval
|
|
43
|
+
gate to an already explicit user instruction or a reversible implementation detail.
|
|
56
44
|
|
|
57
|
-
|
|
58
|
-
criteria. Comparisons are an analysis tool, not a required output section.
|
|
45
|
+
## Return control
|
|
59
46
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
current step; never choose a new route from conversation history.
|
|
47
|
+
Return the conclusion, decisive evidence, material uncertainty, and affected
|
|
48
|
+
contracts. Re-read the invoking workflow or breadcrumb and recommend one of its
|
|
49
|
+
`allowed_transitions`; follow `required_transition` only when a hard invariant leaves
|
|
50
|
+
no alternative. Thinking does not implement code, mutate unrelated state, or invent a
|
|
51
|
+
canonical next action.
|
|
@@ -1,130 +1,106 @@
|
|
|
1
|
-
#
|
|
1
|
+
# User-agent interaction contract
|
|
2
2
|
|
|
3
|
-
Use this protocol when
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
Use this protocol only when evidence and accepted intent do not resolve a material
|
|
4
|
+
choice. The goal is shared understanding with low cognitive load, not a mandatory
|
|
5
|
+
interview.
|
|
6
6
|
|
|
7
|
-
##
|
|
7
|
+
## Authority split
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
public behavior, security, material cost, compatibility, delivery semantics, or
|
|
11
|
-
recovery. Use for initial research and major changes.
|
|
12
|
-
- `fast`: ask only unresolved one-way-door or materially expensive decisions. Decide
|
|
13
|
-
reversible implementation detail inside accepted constraints. Use for bounded daily
|
|
14
|
-
work.
|
|
15
|
-
- `autonomous`: use only after the owner explicitly delegates reversible decisions.
|
|
16
|
-
Preserve the delegation, selected result, rationale, and guardrails.
|
|
17
|
-
- `diagnostic`: acquire evidence and distinguish falsifiable hypotheses before asking
|
|
18
|
-
for a recovery or product decision.
|
|
9
|
+
The user owns:
|
|
19
10
|
|
|
20
|
-
|
|
21
|
-
|
|
11
|
+
- product intent and accepted outcomes;
|
|
12
|
+
- material scope, compatibility, security, cost, and recovery tradeoffs;
|
|
13
|
+
- authorization for destructive or external effects.
|
|
22
14
|
|
|
23
|
-
|
|
15
|
+
The model owns:
|
|
16
|
+
|
|
17
|
+
- fact finding and synthesis;
|
|
18
|
+
- reversible implementation detail inside accepted constraints;
|
|
19
|
+
- research coverage and risk-profile recommendations;
|
|
20
|
+
- technical decomposition, verification selection, and route recommendation.
|
|
21
|
+
|
|
22
|
+
MCP owns durable state, evidence references, digests, freshness, locks, valid
|
|
23
|
+
transitions, and hard invariants. It does not choose semantic intent.
|
|
24
|
+
|
|
25
|
+
## Decide whether to ask
|
|
24
26
|
|
|
25
27
|
Before asking:
|
|
26
28
|
|
|
27
|
-
1. Inspect
|
|
28
|
-
2.
|
|
29
|
-
3.
|
|
30
|
-
4.
|
|
31
|
-
5.
|
|
32
|
-
|
|
29
|
+
1. Inspect repository authority, source, runtime, tests, and relevant primary sources.
|
|
30
|
+
2. Separate `Observed`, `Verified`, `Decided`, `Delegated`, and `Unknown`.
|
|
31
|
+
3. Resolve evidence-answerable unknowns autonomously.
|
|
32
|
+
4. Normalize clear decisions already present in the user's current request.
|
|
33
|
+
5. Ask only if the remaining choice changes accepted intent, public behavior,
|
|
34
|
+
compatibility, security, material cost, external effects, or recovery.
|
|
35
|
+
|
|
36
|
+
Do not ask about a reversible implementation detail already delegated by the contract.
|
|
37
|
+
If the user does not know, recommend a bounded validation action instead of forcing a
|
|
38
|
+
guess.
|
|
33
39
|
|
|
34
|
-
|
|
35
|
-
the user says they do not know, convert the gap into a bounded validation action rather
|
|
36
|
-
than pressuring them to guess.
|
|
40
|
+
## Choose interaction depth
|
|
37
41
|
|
|
38
|
-
|
|
42
|
+
- `guided`: material initial product or major-change choices;
|
|
43
|
+
- `fast`: only one-way-door or costly choices in routine work;
|
|
44
|
+
- `autonomous`: reversible choices explicitly delegated by the user;
|
|
45
|
+
- `diagnostic`: gather discriminating evidence before asking about recovery.
|
|
39
46
|
|
|
40
|
-
|
|
47
|
+
Infer the depth from the request and risk. Do not ask a meta-question about mode unless
|
|
48
|
+
that choice itself changes the outcome.
|
|
41
49
|
|
|
42
|
-
|
|
43
|
-
2. Otherwise call `decision.thread_start` with one baseline, change, or workflow
|
|
44
|
-
binding, a concise purpose, and the selected mode. Never store raw prompts or
|
|
45
|
-
transcripts.
|
|
46
|
-
3. Call `decision.open` for exactly one decision. Include:
|
|
47
|
-
- why it must be decided now;
|
|
48
|
-
- the evidence-backed recommendation;
|
|
49
|
-
- zero to three credible alternatives with their net tradeoff;
|
|
50
|
-
- evidence references;
|
|
51
|
-
- the contract, artifact, gate, or task effects;
|
|
52
|
-
- whether deferral blocks progress.
|
|
50
|
+
## Present questions
|
|
53
51
|
|
|
54
|
-
|
|
55
|
-
|
|
52
|
+
Use the host-native structured question surface declared by the installed interaction
|
|
53
|
+
contract when it exists. If that surface is unavailable in the current mode, ask one
|
|
54
|
+
concise direct question instead of inventing a tool or foreign-host syntax.
|
|
56
55
|
|
|
57
|
-
|
|
56
|
+
Ask one question only for a dependent decision. STOP is mandatory after presenting
|
|
57
|
+
that question: do not perform writes whose meaning depends on an unanswered choice.
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
For one dependent decision, present:
|
|
60
60
|
|
|
61
61
|
```text
|
|
62
|
-
Decision <
|
|
63
|
-
Why now: <
|
|
64
|
-
Recommendation: <choice
|
|
65
|
-
|
|
66
|
-
Effect: <what this answer changes>
|
|
62
|
+
Decision: <question>
|
|
63
|
+
Why now: <decision effect>
|
|
64
|
+
Recommendation: <choice> — <decisive reason>
|
|
65
|
+
Alternatives: <only credible alternatives and their net tradeoff>
|
|
67
66
|
```
|
|
68
67
|
|
|
69
|
-
Ask one
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
-
|
|
85
|
-
|
|
86
|
-
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
5. Re-read the confirmed thread. Only then may the linked workflow complete the gated
|
|
109
|
-
step or move to another phase.
|
|
110
|
-
|
|
111
|
-
If a bound artifact changes while the normalized decisions remain valid, prepare the
|
|
112
|
-
same thread again, show the changed effect, obtain one new checkpoint approval, and
|
|
113
|
-
confirm the current digest. Do not invent a replacement decision merely to refresh an
|
|
114
|
-
artifact. If the decision itself changed, use supersession instead.
|
|
115
|
-
|
|
116
|
-
Start a new thread for a new decision cluster. Supersede an old item only when the old
|
|
117
|
-
decision itself changed.
|
|
118
|
-
|
|
119
|
-
## Keep the user surface small
|
|
120
|
-
|
|
121
|
-
At each turn show only:
|
|
122
|
-
|
|
123
|
-
- the current decision or checkpoint;
|
|
124
|
-
- the decisive evidence and recommendation;
|
|
125
|
-
- the effect of the answer;
|
|
126
|
-
- optionally the number of already resolved decisions.
|
|
127
|
-
|
|
128
|
-
Provide the hidden evidence inventory, all semantic steps, or full report paths only
|
|
129
|
-
when requested. Context and token budgets are advisory; they never justify omitting
|
|
130
|
-
load-bearing evidence or refusing legitimate work.
|
|
68
|
+
Ask dependent decisions one at a time. A host may group up to three independent,
|
|
69
|
+
low-cognitive-load facts when seeing them together improves consistency. Never dump a
|
|
70
|
+
questionnaire, hidden queue, or every research area.
|
|
71
|
+
|
|
72
|
+
The question tool or direct question ends the current interaction naturally.
|
|
73
|
+
|
|
74
|
+
## Persist only when recovery needs it
|
|
75
|
+
|
|
76
|
+
For a project-bound material decision:
|
|
77
|
+
|
|
78
|
+
1. Call `decision.list` and resume a matching active decision thread, or use
|
|
79
|
+
`decision.thread_start` for one new baseline-, change-, or workflow-bound thread.
|
|
80
|
+
2. Use `decision.open` for only the current decision with evidence refs, recommendation, credible
|
|
81
|
+
alternatives, effects, and blocking consequence.
|
|
82
|
+
3. After the answer:
|
|
83
|
+
- `decision.resolve` for a direct user choice;
|
|
84
|
+
- `decision.delegate` for explicit model delegation;
|
|
85
|
+
- `decision.defer` with consequence and revisit condition;
|
|
86
|
+
- `decision.supersede` when accepted intent actually changed.
|
|
87
|
+
4. Use `decision.checkpoint` only for the digest-bound recovery boundary described
|
|
88
|
+
below.
|
|
89
|
+
|
|
90
|
+
Keep fact acquisition autonomous and decision authority explicit.
|
|
91
|
+
Never store raw prompts or transcripts; store normalized decisions, not internal
|
|
92
|
+
chain of thought.
|
|
93
|
+
Do not require a redundant confirmation after an unambiguous answer.
|
|
94
|
+
|
|
95
|
+
Use a checkpoint only when a coherent decision cluster changes a durable contract or
|
|
96
|
+
artifact and interruption recovery requires a digest-bound boundary. Present the
|
|
97
|
+
compact effect once, obtain any missing approval, update the artifact, and confirm its
|
|
98
|
+
digest. Do not create ceremonial checkpoints for routine implementation detail or an
|
|
99
|
+
already explicit current instruction.
|
|
100
|
+
|
|
101
|
+
## Return to the capability graph
|
|
102
|
+
|
|
103
|
+
After alignment, re-read the invoking workflow and breadcrumb. A
|
|
104
|
+
`required_transition` is authoritative only for a hard invariant. Otherwise the host
|
|
105
|
+
model recommends among `allowed_transitions` based on the user's goal and current
|
|
106
|
+
evidence. Do not persist that semantic recommendation as MCP authority.
|
package/spec/cli-protocol.md
CHANGED
|
@@ -141,6 +141,9 @@ maintenance CLI because it is the recovery path when MCP startup is degraded.
|
|
|
141
141
|
`task init-project --resume` preserves existing `.ultra` files and installs only
|
|
142
142
|
missing current scaffold assets. Projection-only state uses the supported
|
|
143
143
|
`migrate --from=4.4 --to=4.5` or the current supported state-schema transition before resume.
|
|
144
|
+
`session close` preserves the worktree by default. `--remove-worktree` delegates to
|
|
145
|
+
the same Git ancestry and dirty-state verifier as MCP and fails with
|
|
146
|
+
`WORKTREE_NOT_INTEGRATED` instead of deleting uncommitted or unintegrated work.
|
|
144
147
|
`system doctor --repair` applies supported schema upgrades with a pre-migration
|
|
145
148
|
backup before mechanical recovery.
|
|
146
149
|
`system restore` requires the exact `REPLACE_CORRUPT_ULTRA_STATE` confirmation and a
|
|
@@ -157,3 +160,35 @@ The CLI follows the `version` field of `spec/mcp-tools.yaml`. Adding a new
|
|
|
157
160
|
flag is a minor bump; renaming or removing a flag, or changing exit-code
|
|
158
161
|
semantics, is a major bump. Major bumps require an entry in
|
|
159
162
|
`docs/PLAN.zh-CN.md §14 Decision log`.
|
|
163
|
+
|
|
164
|
+
## 7. `ubp-orchestrator`
|
|
165
|
+
|
|
166
|
+
`ubp-orchestrator execute-plan` consumes the completed and current
|
|
167
|
+
`.ultra/execution-plan.json` and resumes from the first unfinished dependency wave.
|
|
168
|
+
Before creating a session it rejects an empty, malformed, cyclic, duplicate-task, or
|
|
169
|
+
cross-change plan. For change-owned tasks, the plan must exactly match the current DB
|
|
170
|
+
task graph and a healthy completed `plan` workflow; an exported but incomplete or
|
|
171
|
+
stale artifact is not executable. A separate owner approval is present only when a
|
|
172
|
+
material planning decision required it.
|
|
173
|
+
It returns `status: "paused"` when that wave still has non-terminal Ultra tasks and
|
|
174
|
+
does not dispatch later waves. Worktrees are preserved unless `--auto-merge` is
|
|
175
|
+
explicitly supplied and the corresponding change task has an exact completion commit,
|
|
176
|
+
ready dev workflow, and current task review. `run` and `start` are optional queue daemons and additionally require
|
|
177
|
+
`orchestrator.auto_dispatch: true`.
|
|
178
|
+
|
|
179
|
+
Every execution mode requires a shell-free worker contract:
|
|
180
|
+
|
|
181
|
+
```json
|
|
182
|
+
{
|
|
183
|
+
"orchestrator": {
|
|
184
|
+
"command": "/absolute/path/to/ultra-worker",
|
|
185
|
+
"command_args": []
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
`UBP_ORCH_COMMAND` and a JSON-array `UBP_ORCH_ARGS_JSON` may override that contract.
|
|
191
|
+
The daemon refuses startup without a real executable. Worker exit zero is execution
|
|
192
|
+
evidence only and leaves the Ultra task `in_progress`; failure blocks the task and
|
|
193
|
+
records session-linked circuit-breaker evidence. Worker spawn errors follow the same
|
|
194
|
+
failure path instead of leaving a running lease.
|