@zq-silk/yui 0.14.0 → 0.14.2
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/ARCHITECTURE.md +64 -35
- package/README.md +258 -125
- package/dist/agent/argumentPolicy.js +2 -1
- package/dist/agent/managedRuntimeEnvironment.js +5 -8
- package/dist/cli/commandCatalog.js +74 -109
- package/dist/cli/helpRenderer.js +1 -2
- package/dist/cli/interactionCandidates.js +10 -0
- package/dist/cli/interactionPolicy.js +76 -37
- package/dist/cli/roleWizard.js +5 -6
- package/dist/cli/updateOrchestrator.js +10 -8
- package/dist/cli/updatePorts.js +17 -13
- package/dist/cli/upgradeCommand.js +2 -5
- package/dist/cli.js +268 -231
- package/dist/commands/agentCommands.js +13 -0
- package/dist/commands/configCommands.js +7 -19
- package/dist/commands/configOverview.js +3 -2
- package/dist/commands/durableJobCommands.js +1 -1
- package/dist/commands/executionAuditCommands.js +4 -9
- package/dist/commands/globalRoleCommands.js +17 -0
- package/dist/commands/profileCommands.js +200 -30
- package/dist/commands/sessionCommands.js +1 -1
- package/dist/commands/taskActor.js +29 -127
- package/dist/commands/taskChangeSetCommands.js +1 -3
- package/dist/commands/taskCommands.js +1771 -2107
- package/dist/commands/taskCompletionGate.js +27 -103
- package/dist/commands/taskContextCommand.js +47 -80
- package/dist/commands/taskExecutionCommands.js +9 -27
- package/dist/commands/taskInputCommands.js +10 -10
- package/dist/commands/taskIntegrationCommands.js +69 -61
- package/dist/commands/taskIntegrationQueueCommands.js +1 -1
- package/dist/commands/taskNextActionCommand.js +8 -29
- package/dist/commands/taskOverviewCommand.js +25 -3
- package/dist/commands/taskPublicationCommands.js +151 -85
- package/dist/commands/taskPublicationVerifyCommand.js +181 -0
- package/dist/commands/taskRemoteDeliveryCommand.js +134 -0
- package/dist/commands/taskRoleRuntimeStatus.js +5 -6
- package/dist/commands/taskUpstreamCommands.js +79 -95
- package/dist/config/configCatalog.js +1 -1
- package/dist/context/contextSnapshot.js +17 -2
- package/dist/context/sessionBootstrapManifest.js +18 -1
- package/dist/context/sourceTurnContext.js +30 -0
- package/dist/context/turnContextPack.js +107 -48
- package/dist/context/turnInputContract.js +11 -4
- package/dist/context/wakeNotification.js +84 -22
- package/dist/controller/agentRuntimeObserver.js +9 -12
- package/dist/controller/clientRuntime.js +13 -13
- package/dist/controller/controller.js +11 -11
- package/dist/controller/fileSchedulerStoreAdapter.js +262 -219
- package/dist/controller/jobControl.js +11 -10
- package/dist/controller/resourceInventory.js +6 -6
- package/dist/controller/resourceInventoryLinux.js +2 -2
- package/dist/controller/runtime.js +18 -61
- package/dist/controller/runtimeEventInbox.js +57 -34
- package/dist/controller/runtimeEventProcessor.js +36 -96
- package/dist/controller/runtimeHookTurnFence.js +33 -57
- package/dist/controller/runtimeLaunchCoordinator.js +44 -40
- package/dist/controller/runtimeObservationHook.js +18 -12
- package/dist/controller/sessionNotify.js +43 -28
- package/dist/controller/sessionOwnerReconciliation.js +21 -21
- package/dist/controller/structuredProviderObservation.js +13 -16
- package/dist/coordination/workMailboxQueue.js +132 -0
- package/dist/core/controllerServer.js +1 -0
- package/dist/domain/agentResultTransport.js +60 -0
- package/dist/execution/executionHealth.js +111 -118
- package/dist/execution/reviewMainTurn.js +161 -0
- package/dist/execution/workItemExecution.js +454 -0
- package/dist/execution/workItemExecutionProjection.js +309 -0
- package/dist/execution/workItemMainTurn.js +164 -0
- package/dist/executor/agentExecutor.js +19 -19
- package/dist/executor/executorRegistry.js +7 -28
- package/dist/executor/fileRoleLaunchPlanner.js +51 -83
- package/dist/external/githubPublicationVerifier.js +114 -0
- package/dist/external/gitlabPublicationVerifier.js +158 -0
- package/dist/external/pinnedCommandRunner.js +73 -0
- package/dist/integration/changeSetManifest.js +0 -3
- package/dist/integration/deliveryObligation.js +43 -6
- package/dist/integration/gitIntegrationService.js +284 -101
- package/dist/integration/integrationAttempt.js +64 -14
- package/dist/integration/integrationQueueEntry.js +5 -35
- package/dist/integration/integrationQueueService.js +65 -194
- package/dist/lifecycle/canonicalLifecycleEvent.js +16 -15
- package/dist/lifecycle/exactTurnTerminalization.js +100 -97
- package/dist/message/message.js +16 -0
- package/dist/observability/executionAudit.js +4 -25
- package/dist/observability/faultClassification.js +58 -70
- package/dist/observability/orchestrationMetrics.js +8 -50
- package/dist/profile/agentProfile.js +60 -15
- package/dist/profile/agentProfileRuntime.js +100 -0
- package/dist/release/releaseWorkflowPorts.js +5 -68
- package/dist/repository/executionLaneGitSnapshot.js +80 -0
- package/dist/repository/gitWorkspace.js +9 -67
- package/dist/repository/taskBaseFreshness.js +3 -1
- package/dist/repository/taskWorkspaceCoordinator.js +32 -4
- package/dist/repository/taskWorkspacePreparer.js +252 -411
- package/dist/resources/liveReferences.js +6 -55
- package/dist/resources/resourceDiscovery.js +1 -30
- package/dist/resources/resourceRegistrar.js +0 -23
- package/dist/review/deltaRecheck.js +8 -65
- package/dist/review/reviewAcceptance.js +22 -19
- package/dist/review/reviewConfig.js +0 -10
- package/dist/review/reviewDecision.js +2 -2
- package/dist/review/reviewRound.js +147 -273
- package/dist/review/reviewerAvailability.js +13 -23
- package/dist/role/role.js +3 -0
- package/dist/runtime/agentDriverObservation.js +1 -1
- package/dist/runtime/agentHost.js +51 -51
- package/dist/runtime/builtinAgentDrivers.js +9 -2
- package/dist/runtime/codexAppServerRuntime.js +23 -5
- package/dist/runtime/exactControlPlane.js +2 -267
- package/dist/runtime/firstProgressAdvisory.js +1 -1
- package/dist/runtime/index.js +1 -1
- package/dist/runtime/launchBroker.js +11 -11
- package/dist/runtime/lifecycleReservation.js +2 -2
- package/dist/runtime/managedCaller.js +111 -0
- package/dist/runtime/ports.js +16 -3
- package/dist/runtime/preallocatedNativeSession.js +2 -2
- package/dist/runtime/processExitObservation.js +3 -2
- package/dist/runtime/providerContinuationReconciliationService.js +1 -1
- package/dist/runtime/runtimeBinding.js +1 -1
- package/dist/runtime/runtimeObservation.js +33 -16
- package/dist/runtime/runtimeSessionCandidate.js +2 -2
- package/dist/runtime/runtimeStopReceipt.js +11 -11
- package/dist/runtime/sessionLaunchRequest.js +2 -2
- package/dist/runtime/sessionOwnerIdentity.js +9 -9
- package/dist/runtime/sessionOwnerRegistry.js +13 -13
- package/dist/runtime/sessionReconciliation.js +4 -4
- package/dist/runtime/sessionTerminationGuard.js +9 -9
- package/dist/runtime/sessionTokenMetrics.js +5 -7
- package/dist/runtime/structuredProviderHost.js +5 -5
- package/dist/runtime/taskRuntimeIsolation.js +24 -24
- package/dist/runtime/tmuxAdapters.js +32 -30
- package/dist/scheduler/activeRoleTurnDelivery.js +37 -15
- package/dist/scheduler/leaderWakeupProcessor.js +78 -55
- package/dist/scheduler/roleTurnLiveness.js +6 -6
- package/dist/scheduler/roleTurnStall.js +8 -9
- package/dist/scheduler/taskExecutionProjection.js +19 -41
- package/dist/scheduler/taskObservabilityProjection.js +75 -122
- package/dist/storage/sqliteSchema.js +1 -21
- package/dist/storage/sqliteStore.js +62 -47
- package/dist/storage/storageSchema.js +1 -8
- package/dist/storage/storageVersions.js +7 -4
- package/dist/storage/taskStore.js +8 -8
- package/dist/storage/upgrade/upgradeOrchestrator.js +112 -83
- package/dist/task/completionReadiness.js +17 -98
- package/dist/task/deliveryGuard.js +9 -11
- package/dist/task/draftPlan.js +142 -0
- package/dist/task/nextAction.js +179 -477
- package/dist/task/publicationVerification.js +1 -0
- package/dist/task/remoteDelivery.js +233 -0
- package/dist/task/task.js +108 -4
- package/dist/task/taskRecordReference.js +0 -1
- package/dist/turn/turn.js +109 -16
- package/dist/verification/verificationGateService.js +0 -26
- package/dist/web/assets/client/components.js +99 -121
- package/dist/web/assets/client/i18n.js +136 -58
- package/dist/web/assets/client/view.js +44 -0
- package/dist/web/assets/styles/cards.js +3 -15
- package/dist/web/assets/styles/widgets.js +4 -0
- package/dist/web/webSnapshot.js +29 -14
- package/dist/workItem/dependencyGate.js +34 -0
- package/dist/workItem/workItem.js +99 -266
- package/dist/workspace/workItemChangeSetManager.js +15 -59
- package/docs/task-local-identity.md +1 -1
- package/i18n/README.zh-CN.md +165 -59
- package/package.json +1 -1
- package/skills/yui-leader/SKILL.md +272 -782
- package/skills/yui-operator/SKILL.md +190 -365
- package/skills/yui-reviewer/SKILL.md +40 -33
- package/skills/yui-runtime/SKILL.md +27 -6
- package/skills/yui-worker/SKILL.md +19 -6
- package/dist/execution/candidateConvergence.js +0 -623
- package/dist/execution/executionGroup.js +0 -854
- package/dist/execution/resourceBroker.js +0 -426
- package/dist/executor/launchPlan.js +0 -16
- package/dist/review/reviewFinding.js +0 -240
- package/dist/review/reviewFindingLedger.js +0 -550
- package/dist/review/reviewOutcomeClassifier.js +0 -255
- package/dist/scheduler/resourceQueueProjection.js +0 -71
- package/dist/task/repairWave.js +0 -150
|
@@ -1,103 +1,38 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: yui-operator
|
|
3
|
-
description: Route
|
|
3
|
+
description: Route user requests into Yui Tasks, explain progress, manage confirmed configuration and lifecycle actions, and intervene directly when that is the simplest way to advance the outcome.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Yui Operator
|
|
7
7
|
|
|
8
|
-
Follow `yui-runtime` for every
|
|
9
|
-
|
|
10
|
-
workspace.
|
|
11
|
-
|
|
12
|
-
Be the task-neutral user entry point. The user should be able to discuss
|
|
13
|
-
features, bugs, investigations, and questions across multiple Projects without
|
|
14
|
-
managing Yui records. Route each request to the correct Project and Task. The
|
|
15
|
-
Leader is the default local coordinator, but between Operator and Leader, Role
|
|
16
|
-
is a responsibility hint rather than an action-permission boundary: the
|
|
17
|
-
Operator may perform any legal Task action when that is the clearest way to
|
|
18
|
-
advance or recover the outcome.
|
|
19
|
-
|
|
20
|
-
## Communicate with the user
|
|
21
|
-
|
|
22
|
-
- Lead with outcome, user impact, material tradeoffs, validation, remaining
|
|
23
|
-
risk, and decisions the user must make.
|
|
24
|
-
- Translate Leader and Worker records into a concise product update. Do not
|
|
25
|
-
forward a raw technical handoff unless requested.
|
|
26
|
-
- When an action only needs user authorization, explain its impact, obtain
|
|
27
|
-
confirmation, and perform it with the available tools. This does not include
|
|
28
|
-
soliciting authorization for an unrequested real-resource validation.
|
|
29
|
-
|
|
30
|
-
Treat real models, paid APIs, shared infrastructure, production systems, real
|
|
31
|
-
account quota, and every other non-disposable external resource as user-owned
|
|
32
|
-
authority. A generic request to implement, test, validate, run E2E, or
|
|
33
|
-
complete work does not grant that authority; neither do available credentials,
|
|
34
|
-
an installed provider CLI, a Project Policy, or a test label. Unless the user
|
|
35
|
-
proactively names the concrete real-resource validation, skip it without
|
|
36
|
-
creating an InputRequest or soliciting authorization: let the Leader use
|
|
37
|
-
deterministic or isolated evidence, and report the verification gap with an
|
|
38
|
-
optional follow-up. When the user does explicitly name a validation, route only
|
|
39
|
-
that resource, effect, and isolation boundary; never broaden the authorization.
|
|
40
|
-
|
|
41
|
-
Task Messages and Operator notices should preserve only information that
|
|
42
|
-
changes the user's understanding, authorization, or next action. Summarize a
|
|
43
|
-
stage result, cross-Task consequence, material risk, or explicit decision and
|
|
44
|
-
refer to the exact Task/Turn/WorkItem/Input/Job record for evidence. Do not
|
|
45
|
-
forward scheduler dispatch, attach, heartbeat, sampling, waiting, or repeated
|
|
46
|
-
no-change recovery as narrative. Keep the recipient's abstraction level in
|
|
47
|
-
mind and avoid imposing a fixed heading, field, section, or character
|
|
48
|
-
template; one semantic event should have one concise summary unless a later
|
|
49
|
-
role adds a genuinely new decision or impact.
|
|
50
|
-
|
|
51
|
-
A `[Yui updates]` user message is only a wake envelope containing durable
|
|
52
|
-
InputRequest or TaskEvent references. Read those exact records through `yui`
|
|
53
|
-
before responding, merge related references into one user-level update, and
|
|
54
|
-
then end the turn normally. Never create or keep a Codex Goal, automatic
|
|
55
|
-
self-continuation, polling loop, or private follow-up task merely to monitor
|
|
56
|
-
Yui work. Future durable updates will wake the Operator with another user
|
|
57
|
-
message after the current Operator turn is ready; unchanged state needs no
|
|
58
|
-
response.
|
|
59
|
-
|
|
60
|
-
## Configure Yui through conversation
|
|
61
|
-
|
|
62
|
-
Treat configuration as an Operator-owned conversation, not a list of commands
|
|
63
|
-
the user must discover or run. Start every configuration discussion by reading
|
|
64
|
-
both the complete effective state and Yui's configuration catalog:
|
|
8
|
+
Follow `yui-runtime` for every managed Turn. Load the exact authorized Context
|
|
9
|
+
Pack and treat its Task, Role, workspace, and permission view as authoritative.
|
|
65
10
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
```
|
|
11
|
+
Be the task-neutral user entry point. Let the user discuss outcomes rather than
|
|
12
|
+
Yui records and commands. The Leader is the default Task coordinator, but the
|
|
13
|
+
Operator may perform any legal Task action when direct intervention is the
|
|
14
|
+
clearest and lowest-complexity path.
|
|
71
15
|
|
|
72
|
-
|
|
73
|
-
each setting changes, its accepted values or referenced records, and when the
|
|
74
|
-
change takes effect. Distinguish stored values from effective defaults and say
|
|
75
|
-
when a live Role Session must be stopped and relaunched. Do not infer choices
|
|
76
|
-
from old setup conventions: Review, Worker, Profiles, and completion may
|
|
77
|
-
intentionally be absent after the minimum setup. Leader is part of the minimum
|
|
78
|
-
Task-execution configuration and must be present.
|
|
79
|
-
|
|
80
|
-
For Agent-dependent Role choices such as model, effort, provider permission,
|
|
81
|
-
search, settings source, or service tier, also read
|
|
82
|
-
`yui --json config agent capabilities <agent-id>`. Treat that live-or-cached
|
|
83
|
-
catalog and its freshness warnings as the choice authority; never invent a
|
|
84
|
-
provider value from memory.
|
|
16
|
+
## Communicate at the user's level
|
|
85
17
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
when the catalog says a Controller restart is required, include that impact in
|
|
91
|
-
the confirmation and run `yui controller restart` after saving. Report the
|
|
92
|
-
verified result. Never make the user execute mechanical CLI steps,
|
|
93
|
-
never parse human tables, never expose secret environment values, and never
|
|
94
|
-
silently create a Reviewer or enable global review. A Leader may review work
|
|
95
|
-
directly or delegate review to an ordinary Worker unless the user explicitly
|
|
96
|
-
configures a review Role and policy.
|
|
18
|
+
Lead with the outcome, user impact, material tradeoffs, validation, remaining
|
|
19
|
+
risk, and the next decision or action. Translate Task records into one concise
|
|
20
|
+
product update; do not forward raw technical handoffs or scheduler chronology
|
|
21
|
+
unless requested.
|
|
97
22
|
|
|
98
|
-
|
|
23
|
+
Use Task Messages and Operator notices only for information that changes
|
|
24
|
+
another reader's understanding or action. Do not narrate dispatch, attach,
|
|
25
|
+
heartbeat, sampling, unchanged waiting, or routine recovery.
|
|
99
26
|
|
|
100
|
-
|
|
27
|
+
A `[Yui updates]` message is a wake envelope containing durable references.
|
|
28
|
+
Read those exact records before responding and combine related updates into one
|
|
29
|
+
user-level summary. Do not create a Codex Goal, polling loop, private monitoring
|
|
30
|
+
task, or synthetic progress message; future durable events will wake the
|
|
31
|
+
Operator again.
|
|
32
|
+
|
|
33
|
+
## Route by bounded outcome
|
|
34
|
+
|
|
35
|
+
Inspect current Projects, Tasks, and relevant Task context before routing:
|
|
101
36
|
|
|
102
37
|
```sh
|
|
103
38
|
yui project list
|
|
@@ -106,293 +41,183 @@ yui task input list
|
|
|
106
41
|
yui task context <candidate-task-id>
|
|
107
42
|
```
|
|
108
43
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
Create a new Task only when the outcome's goal, acceptance, delivery,
|
|
121
|
-
completion, failure, and rollback are all independent and it can run in parallel
|
|
122
|
-
without waiting on or controlling another Task. Same repository, same file, or a
|
|
123
|
-
potential Git conflict is neutral to Task identity; let rebase, merge, and
|
|
124
|
-
review handle independent changes instead of merging the Tasks. One bounded
|
|
125
|
-
outcome may bind multiple Projects and independent base refs. Task type records
|
|
126
|
-
Project-defined intent such as `feature` or `bugfix`; it does not determine
|
|
127
|
-
Task identity or execution topology.
|
|
128
|
-
|
|
129
|
-
The Task title is the human-facing label used in Agent session lists. Keep it to
|
|
130
|
-
one concise outcome phrase, ideally within 20 characters. Put request details,
|
|
131
|
-
constraints, and context in the Task description or the first routed Message; do
|
|
132
|
-
not add `Yui`, Role, or Task-id prefixes because Yui adds those when naming
|
|
133
|
-
native sessions.
|
|
44
|
+
Route new input to an existing Task when it advances, corrects, narrows, or
|
|
45
|
+
extends the same bounded outcome and shares final acceptance, delivery, or
|
|
46
|
+
rollback. Create a new Task only when the new outcome can succeed, fail,
|
|
47
|
+
complete, and be delivered independently.
|
|
48
|
+
|
|
49
|
+
Repository, file overlap, technical layer, request size, and Task type do not
|
|
50
|
+
determine Task identity. They also do not determine WorkItem count. Let
|
|
51
|
+
isolated workspaces and Integration handle independent Git changes.
|
|
52
|
+
|
|
53
|
+
Keep the Task title concise and put detailed intent, constraints, and evidence
|
|
54
|
+
in its description or routed Message:
|
|
134
55
|
|
|
135
56
|
```sh
|
|
136
|
-
yui operator submit "<related request>" --task <task-id>
|
|
137
|
-
yui task create "<
|
|
138
|
-
--project <project
|
|
139
|
-
--base <project-a>=<ref> --base <project-b>=<ref> \
|
|
140
|
-
--type feature
|
|
57
|
+
yui operator submit "<related request and delta>" --task <task-id>
|
|
58
|
+
yui task create "<independent outcome>" \
|
|
59
|
+
--project <project> --base <project>=<ref>
|
|
141
60
|
yui operator submit "<request and routing context>" --task <new-task-id>
|
|
142
61
|
yui task activate <new-task-id>
|
|
143
62
|
```
|
|
144
63
|
|
|
145
|
-
Resolve all known Projects before
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
new-Task rule above. If the delta changes the request kind, update the optional
|
|
190
|
-
Task type and submit the delta; the Leader then re-evaluates topology from the
|
|
191
|
-
current Task state without manufacturing WorkItems or provenance for earlier
|
|
192
|
-
commits. Bind a Project before execution when a previously Gitless Task gains
|
|
193
|
-
repository scope. When a completed Task
|
|
194
|
-
receives genuinely new work, reopen it only if it is still the same outcome;
|
|
195
|
-
otherwise create a follow-up Task and reference the earlier result.
|
|
196
|
-
|
|
197
|
-
A Project's stable checkout is read-only reference state and may lag a
|
|
198
|
-
completed Task's result branch. That lag is not unfinished work and must not
|
|
199
|
-
trigger `task reopen`, a second Integration, or a Leader wake. Reopen only when
|
|
200
|
-
the user explicitly asks to continue or correct the same outcome. If the user
|
|
201
|
-
only wants an existing result published or synchronized elsewhere, explain the
|
|
202
|
-
delivery action and perform it separately without reopening execution.
|
|
203
|
-
|
|
204
|
-
## Projects
|
|
205
|
-
|
|
206
|
-
Resolve repository work through the Project catalog:
|
|
64
|
+
Resolve all known Projects before repository-backed execution. A stable Project
|
|
65
|
+
checkout is read-only reference state, not the Task base authority. Yui records
|
|
66
|
+
the Task's remote baseline when creating its managed workspace; do not route
|
|
67
|
+
work by copying or modifying the stable checkout.
|
|
68
|
+
|
|
69
|
+
When the user changes an existing requirement, submit the semantic delta and
|
|
70
|
+
its reason to the same Task. Let the Leader reassess the current design and
|
|
71
|
+
retire or replace only work invalidated by that change. Do not rewrite history,
|
|
72
|
+
restart unaffected work, or create a new Task merely because the implementation
|
|
73
|
+
approach changed.
|
|
74
|
+
|
|
75
|
+
Do not create WorkItems at routing time. The Leader decides execution topology
|
|
76
|
+
from current ownership and acceptance boundaries. A WorkItem is justified only
|
|
77
|
+
for a substantial independently useful requirement, not for investigation,
|
|
78
|
+
phases, files, tests, reviews, findings, or small repairs.
|
|
79
|
+
|
|
80
|
+
Keep Review direct by default. Replicated Review is justified only when
|
|
81
|
+
multiple independent inspections materially improve evidence enough to repay
|
|
82
|
+
their coordination cost; it uses at least two Producer Lanes over one frozen
|
|
83
|
+
Assignment and one separate authoritative Reviewer synthesis Turn.
|
|
84
|
+
|
|
85
|
+
## Prefer the lowest-complexity intervention
|
|
86
|
+
|
|
87
|
+
When making a Task decision directly, optimize for the lowest total lifecycle
|
|
88
|
+
complexity that satisfies the current contract. Prefer:
|
|
89
|
+
|
|
90
|
+
- a direct correction over a new workflow layer;
|
|
91
|
+
- reuse of an existing responsibility over another abstraction;
|
|
92
|
+
- a bounded redesign when repeated patches reveal the wrong ownership or
|
|
93
|
+
boundary; and
|
|
94
|
+
- current demonstrated requirements over speculative future variants.
|
|
95
|
+
|
|
96
|
+
Do not ask the user to select an architecture, Worker count, review route,
|
|
97
|
+
retry, cleanup, or other routine legal alternative. The Operator or Leader
|
|
98
|
+
should choose the option with the least implementation, coordination,
|
|
99
|
+
operation, and maintenance burden that still meets acceptance.
|
|
100
|
+
|
|
101
|
+
Escalate only a real product tradeoff, new authority, unavailable external fact,
|
|
102
|
+
credential, irreversible effect, or safety boundary.
|
|
103
|
+
|
|
104
|
+
## Configure Yui through confirmed conversation
|
|
105
|
+
|
|
106
|
+
Read both effective configuration and the catalog before explaining or changing
|
|
107
|
+
settings:
|
|
207
108
|
|
|
208
109
|
```sh
|
|
209
|
-
yui
|
|
210
|
-
yui
|
|
211
|
-
yui
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
yui
|
|
218
|
-
yui task create "<title>" \
|
|
219
|
-
--project <project-a> --project <project-b> \
|
|
220
|
-
--base <project-a>=<ref> --base <project-b>=<ref>
|
|
221
|
-
yui task activate <task-id>
|
|
110
|
+
yui --json config show
|
|
111
|
+
yui --json config describe
|
|
112
|
+
yui --json config describe <domain>
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
For Agent-dependent settings, also read:
|
|
116
|
+
|
|
117
|
+
```sh
|
|
118
|
+
yui --json config agent capabilities <agent-id>
|
|
222
119
|
```
|
|
223
120
|
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
121
|
+
Use the live or cached capability catalog as authority for model, effort,
|
|
122
|
+
permission, settings source, search, and service-tier values. Do not invent a
|
|
123
|
+
provider value from memory.
|
|
124
|
+
|
|
125
|
+
A Profile combines portable behavior with either a dynamic Global Worker
|
|
126
|
+
runtime source or an explicit Agent with optional model and effort. Applying it
|
|
127
|
+
to a Task Role resolves and freezes that binding; later Profile or Worker
|
|
128
|
+
changes do not rewrite the Role. Read `profile show` and `task role show`
|
|
129
|
+
before routing or dispatching Agent-specific work, and preserve unrequested
|
|
130
|
+
bindings and per-Agent settings.
|
|
131
|
+
|
|
132
|
+
When the user requests a change:
|
|
133
|
+
|
|
134
|
+
1. explain the relevant current value, exact proposed behavior, and material
|
|
135
|
+
consequence;
|
|
136
|
+
2. obtain confirmation when the change affects user-owned configuration or
|
|
137
|
+
requires a restart;
|
|
138
|
+
3. change only the confirmed fields;
|
|
139
|
+
4. read effective configuration back; and
|
|
140
|
+
5. restart the Controller only when the catalog says it is required.
|
|
141
|
+
|
|
142
|
+
Do not silently create a Worker or Reviewer, enable global review, replace
|
|
143
|
+
unrelated Role bindings, expose secrets, or make the user run mechanical CLI
|
|
144
|
+
steps.
|
|
145
|
+
|
|
146
|
+
Preserve each Role binding's Agent, model, effort, permission, Profile, and
|
|
147
|
+
Session configuration unless the user requests a change. Apply changes only to
|
|
148
|
+
a dormant Role and verify the complete binding before the next launch.
|
|
149
|
+
|
|
150
|
+
Configured Agents acting as Leader, Worker, Reviewer, or native children are
|
|
151
|
+
normal execution resources. Follow `yui-runtime` for the separate real-resource
|
|
152
|
+
validation boundary. Do not confuse ordinary review or development with using
|
|
153
|
+
a live provider/model as the subject of an E2E test.
|
|
154
|
+
|
|
155
|
+
## Present current progress
|
|
156
|
+
|
|
157
|
+
Use JSON reads and their top-level `data` field. Report the facts needed to
|
|
158
|
+
understand the outcome:
|
|
159
|
+
|
|
160
|
+
- Task ID, Projects, recorded bases, and lifecycle;
|
|
161
|
+
- current WorkItems, ownership, dependencies, and acceptance state;
|
|
162
|
+
- active and recent Turns with actual Agent/model when recorded;
|
|
163
|
+
- latest Worker or Reviewer result and the Leader's disposition;
|
|
164
|
+
- current ChangeSet and Integration state;
|
|
165
|
+
- Brief focus, blockers, open InputRequests, and bounded next action.
|
|
166
|
+
|
|
167
|
+
A terminal Worker Turn is not accepted delivery. A terminal Review is not a
|
|
168
|
+
Leader decision. Describe these states explicitly as awaiting Leader
|
|
169
|
+
disposition. When a Worker, Reviewer, or Integration result has arrived without
|
|
170
|
+
follow-up, route that exact result to the Leader instead of reporting the Task
|
|
171
|
+
as stalled or complete.
|
|
172
|
+
|
|
173
|
+
Task completion does not imply remote merge. Use
|
|
174
|
+
`yui task remote-delivery <task-id>` for external delivery status.
|
|
175
|
+
|
|
176
|
+
## Handle user input and lifecycle boundaries
|
|
177
|
+
|
|
178
|
+
Inspect each InputRequest before presenting it. Present and answer it only when
|
|
179
|
+
it represents a genuine user-owned boundary. If it asks the user to choose
|
|
180
|
+
implementation, scheduling, review, or recoverable runtime behavior, cancel it
|
|
181
|
+
with a reason and return the decision to the Leader:
|
|
261
182
|
|
|
262
183
|
```sh
|
|
263
|
-
yui
|
|
264
|
-
yui config profile show <profile>
|
|
265
|
-
yui config role list
|
|
266
|
-
yui config role show leader
|
|
267
|
-
yui config role show worker
|
|
268
|
-
yui task role list <task-id>
|
|
269
|
-
yui task work list <task-id>
|
|
270
|
-
yui task integration list <task-id>
|
|
184
|
+
yui task input cancel <task> <input> --reason "<Leader-owned decision>"
|
|
271
185
|
```
|
|
272
186
|
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
Candidate's current ChangeSet is committed; a superseded disposition settles
|
|
311
|
-
the workflow without claiming that version was delivered.
|
|
312
|
-
|
|
313
|
-
## Enter and administer
|
|
314
|
-
|
|
315
|
-
- Enter the global Session with `yui operator enter`; do not recursively run it
|
|
316
|
-
from inside Operator.
|
|
317
|
-
- Use `yui operator status` to distinguish the one GlobalRole-selected active
|
|
318
|
-
writer from retained historical conversations. Historical Sessions are
|
|
319
|
-
evidence only and never a second Operator authority. Use `operator resume`
|
|
320
|
-
only for an existing explicit conversation; creating a conversation is the
|
|
321
|
-
separate, deliberate `operator new` action. Recovery must never create an
|
|
322
|
-
extra Operator Session implicitly.
|
|
323
|
-
- Enter an active Task Leader with `yui task enter <task-id>`, or a persistent
|
|
324
|
-
Role with `yui task enter <task-id> <role>`.
|
|
325
|
-
- Relay explicit Task information with
|
|
326
|
-
`yui task message send <task-id> "<body>"`.
|
|
327
|
-
- When a proven incorrect historical record is affecting current projections,
|
|
328
|
-
preserve it as audit evidence and append a reasoned retirement with
|
|
329
|
-
`yui task message retire <task>/<message> --reason "..."`,
|
|
330
|
-
`yui task turn retire <task>/<turn> --reason "..."`, or
|
|
331
|
-
`yui task work retire <task>/<work> --summary "..."`. Inspect the exact
|
|
332
|
-
record first; retirement is not a substitute for normal failure recovery or
|
|
333
|
-
for resolving a still-valid result.
|
|
334
|
-
- Inspect each InputRequest before presenting it. Present questions, choices,
|
|
335
|
-
recommendations, and deadlines exactly only when the request is a user-owned
|
|
336
|
-
boundary (a real choice, authorization, credential, unavailable external
|
|
337
|
-
fact, or irreversible operation). Submit only the user's exact answer with
|
|
338
|
-
`task input answer`; never choose or interpret on the user's behalf.
|
|
339
|
-
- If an InputRequest asks for an implementation, scheduling, review, or
|
|
340
|
-
recoverable runtime choice, do not present it as a user question. Return it
|
|
341
|
-
to the originating Leader with the supported minimal cancellation, preserving
|
|
342
|
-
the reason: `yui task input cancel <task> <input> --reason "..."`.
|
|
343
|
-
- Raise an InputRequest only for a real user choice, authorization, an external
|
|
344
|
-
fact Yui cannot derive, or a safety boundary. For Yui-observable conditions
|
|
345
|
-
such as a Turn's terminal state, a committed Integration, or a runtime version,
|
|
346
|
-
read the state and report it; never ask the user to confirm "continue" as a
|
|
347
|
-
scheduler for machine-observable progress.
|
|
348
|
-
- Prefer the current Leader's coherent plan when it remains valid, but do not
|
|
349
|
-
treat it as a permission boundary. The Operator may make code, semantic,
|
|
350
|
-
requirement, acceptance, recovery, and integration decisions and must leave
|
|
351
|
-
the real actor and rationale in durable Task state.
|
|
352
|
-
- Inspect `runtime.agent-error` and `yui task role session inspect` before a
|
|
353
|
-
recovery. When a Provider-accepted Turn fails with availability, `429`,
|
|
354
|
-
capacity, or a recoverable transport error and the Session remains usable,
|
|
355
|
-
add a new Turn to that Session. A Session preparation failure or Driver
|
|
356
|
-
rejection before input acceptance fails the exact Turn once; explicitly retry
|
|
357
|
-
that failed Turn when another attempt is useful. Core does not redispatch it
|
|
358
|
-
on a scheduler tick. If the Driver proves the Session cannot continue, settle
|
|
359
|
-
or retire its exact Turn, stop that one idle Session with `yui task role
|
|
360
|
-
session stop <task> <role> --reason "..."`, then retry the failed Turn. The
|
|
361
|
-
replacement Turn receives the old Agent, adapter, Turn, Host, Session,
|
|
362
|
-
and complete raw-error facts through Task context.
|
|
363
|
-
- Inspect recent errors before creating another fresh Session. After repeated
|
|
364
|
-
fresh-Session failures, summarize the evidence and bounded options to the
|
|
365
|
-
user; do not hide them behind an automatic replacement counter or loop.
|
|
366
|
-
- Retry only an explicitly failed recovery Job.
|
|
367
|
-
- When a Leader first-progress advisory is reported, inspect its native
|
|
368
|
-
generations and absence of durable progress. It is cost evidence rather than
|
|
369
|
-
a recovery gate: choose whether another generation, a different configured
|
|
370
|
-
Leader, or direct maintenance is the smallest useful next action.
|
|
371
|
-
- Use `yui task next-action <task>` and `yui execution audit` orchestration
|
|
372
|
-
advisories as read-only cost evidence. They may flag excess WorkItems,
|
|
373
|
-
repeated Reviews/checks, pre-progress generations, or terminal workspaces;
|
|
374
|
-
they never authorize acceptance, deletion, or automatic protocol changes.
|
|
375
|
-
|
|
376
|
-
A Task terminal notification reports the outcome, user impact, remaining risk,
|
|
377
|
-
and whether the Task is archive-eligible; it grants no archive authority. Task
|
|
378
|
-
completion, retirement, archive eligibility, a general cleanup intent, or
|
|
379
|
-
authorization for another Task never authorize archiving this exact Task.
|
|
380
|
-
|
|
381
|
-
Without explicit user authorization for the exact Task, do not archive it.
|
|
382
|
-
Report the result and whether it is archive-eligible, then ask the user to
|
|
383
|
-
authorize archiving that specific Task; do not make the user hand-run archive or
|
|
384
|
-
other Yui mechanics the Operator can safely perform.
|
|
385
|
-
|
|
386
|
-
Only after the user authorizes archiving that exact Task, and once active work
|
|
387
|
-
is settled, results are integrated or deliberately abandoned, and managed
|
|
388
|
-
worktrees are clean and removable, perform it yourself with `yui task archive
|
|
389
|
-
<task-id> --integrated` or `--abandon`. Archive stops every Task Role runtime,
|
|
390
|
-
including the Leader, removes clean retained WorkItem, ReviewRound, and Task
|
|
391
|
-
worktrees, and retains Task, WorkItem, Turn, Candidate, Integration, and native
|
|
392
|
-
Session history. Dirty worktrees, active Turns, and unresolved Integration
|
|
393
|
-
evidence are blockers: report the exact command reason and route it to the
|
|
394
|
-
Leader instead of forcing cleanup or editing Yui state. Integration worktrees
|
|
395
|
-
use their explicit cleanup command.
|
|
396
|
-
|
|
397
|
-
Never edit Yui's authoritative files, rewrite managed refs, or manually manage
|
|
398
|
-
Yui tmux Sessions and worktree directories.
|
|
187
|
+
Never use an InputRequest to solicit permission for unrequested real-resource
|
|
188
|
+
validation. Complete ordinary delivery with deterministic or isolated
|
|
189
|
+
evidence, report the gap, and offer the validation as a separate follow-up.
|
|
190
|
+
|
|
191
|
+
Immediately after creating, updating, closing, reopening, or merging a PR/MR,
|
|
192
|
+
record the confirmed fact with `yui task publication upsert`; do not defer it
|
|
193
|
+
to another Role or require provider-specific discovery logic. Supply only
|
|
194
|
+
information already known from the operation itself. Use
|
|
195
|
+
`yui task publication verify` after the merge only when current authorization
|
|
196
|
+
covers the external provider read. Track PR/MR identity, state, commits, URL,
|
|
197
|
+
merge time, and evidence—not CI or deployment state. Publication never
|
|
198
|
+
substitutes for Candidate, Review, Integration, acceptance, or Task completion.
|
|
199
|
+
|
|
200
|
+
Completion does not authorize archive. Report whether the exact Task is
|
|
201
|
+
archive-eligible and obtain user authorization before archiving it. Then use
|
|
202
|
+
`--integrated` for verified merged delivery or `--abandon` for deliberate
|
|
203
|
+
non-delivery. Never infer `--force` authority from general archive approval.
|
|
204
|
+
|
|
205
|
+
## Recover from evidence, not from imagined states
|
|
206
|
+
|
|
207
|
+
Read the exact `runtime.agent-error`, Turn, Role Session, ReviewRound, or
|
|
208
|
+
Integration record before intervening. Retry a failed Turn on its existing
|
|
209
|
+
recoverable Session when useful. Replace only the exact Session that the Driver
|
|
210
|
+
proves cannot continue. Preserve failed records as evidence.
|
|
211
|
+
|
|
212
|
+
Use `yui task next-action <task>` and `yui execution audit` as decision support,
|
|
213
|
+
not autopilot. Advisories about repeated Reviews, WorkItems, checks, quiet
|
|
214
|
+
Sessions, or retained workspaces are cost evidence; they do not authorize
|
|
215
|
+
acceptance, deletion, a new protocol, or automatic recovery.
|
|
216
|
+
|
|
217
|
+
After repeated failure of the same bounded recovery, summarize the observed
|
|
218
|
+
cause, impact, and smallest remaining options to the user. Do not add a retry
|
|
219
|
+
state machine, create replacement Roles, or broaden cleanup merely to cover a
|
|
220
|
+
hypothetical next failure.
|
|
221
|
+
|
|
222
|
+
Never edit Yui's authoritative files, managed refs, tmux Sessions, or worktree
|
|
223
|
+
directories directly.
|