@zq-silk/yui 0.15.7 → 0.15.9
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 +194 -399
- package/ARCHITECTURE.zh-CN.md +151 -0
- package/README.md +306 -1131
- package/dist/agent/adapterCatalog.js +15 -2
- package/dist/agent/agent.js +23 -3
- package/dist/agent/argumentPolicy.js +7 -1
- package/dist/agent/connectionPlan.js +62 -0
- package/dist/agent/executionComponents.js +158 -0
- package/dist/agent/launchEnvironment.js +31 -3
- package/dist/agent/managedRuntimeEnvironment.js +3 -5
- package/dist/{turn/turn.js → agentRun/agentRun.js} +166 -109
- package/dist/{turn/turnIdentity.js → agentRun/runIdentity.js} +4 -4
- package/dist/artifacts/artifactCapability.js +74 -0
- package/dist/artifacts/artifactCommitLock.js +249 -0
- package/dist/artifacts/artifactPaths.js +151 -0
- package/dist/artifacts/gitArtifactRef.js +146 -0
- package/dist/artifacts/managedGit.js +332 -0
- package/dist/artifacts/taskArtifactRepository.js +277 -0
- package/dist/brief/taskBrief.js +12 -0
- package/dist/cli/agentConfigurationPicker.js +13 -0
- package/dist/cli/commandCatalog.js +165 -74
- package/dist/cli/interactionCandidates.js +5 -5
- package/dist/cli/interactionPolicy.js +38 -8
- package/dist/cli/invocationRouter.js +1 -1
- package/dist/cli/managedDiagnostics.js +28 -0
- package/dist/cli/operatorWizard.js +1 -7
- package/dist/cli/roleOptionOrder.js +27 -0
- package/dist/cli/roleWizard.js +50 -14
- package/dist/cli/updateOrchestrator.js +1 -1
- package/dist/cli/updatePorts.js +3 -4
- package/dist/cli.js +245 -95
- package/dist/commands/agentCommands.js +72 -14
- package/dist/commands/capabilityCommands.js +9 -6
- package/dist/commands/configCommands.js +20 -20
- package/dist/commands/deliveryGuardPreflight.js +2 -2
- package/dist/commands/executionAuditCommands.js +24 -24
- package/dist/commands/globalRoleCommands.js +1 -1
- package/dist/commands/grantCommands.js +4 -4
- package/dist/commands/operatorCommands.js +34 -9
- package/dist/commands/projectCommands.js +4 -4
- package/dist/commands/resourcesCommands.js +2 -2
- package/dist/commands/roleConfiguration.js +25 -5
- package/dist/commands/roleRuntimeGuard.js +4 -5
- package/dist/commands/sessionCommands.js +3 -7
- package/dist/commands/taskActivationCommands.js +281 -0
- package/dist/commands/taskActor.js +28 -49
- package/dist/commands/taskCommands.js +1461 -720
- package/dist/commands/taskContextCommand.js +39 -583
- package/dist/commands/taskExecutionCommands.js +32 -32
- package/dist/commands/taskInputCommands.js +40 -104
- package/dist/commands/taskIntegrationCommands.js +3 -2
- package/dist/commands/taskIntegrationQueueCommands.js +1 -1
- package/dist/commands/taskNextActionCommand.js +8 -8
- package/dist/commands/taskOverviewCommand.js +33 -45
- package/dist/commands/taskRemoteDeliveryCommand.js +2 -2
- package/dist/commands/taskRoleRuntimeStatus.js +133 -102
- package/dist/commands/telemetryCommands.js +36 -38
- package/dist/config/configCatalog.js +4 -4
- package/dist/config/yuiConfig.js +8 -8
- package/dist/context/contextSnapshot.js +10 -10
- package/dist/context/dispatchContext.js +11 -11
- package/dist/context/roleSessionContext.js +6 -3
- package/dist/context/{turnContextPack.js → runContextPack.js} +158 -81
- package/dist/context/{turnInputContract.js → runInputContract.js} +73 -60
- package/dist/context/sessionBootstrapManifest.js +21 -2
- package/dist/context/sourceRunContext.js +30 -0
- package/dist/context/taskContext.js +481 -0
- package/dist/context/wakeNotification.js +27 -27
- package/dist/controller/agentRuntimeObserver.js +21 -24
- package/dist/controller/capabilityBridge.js +17 -6
- package/dist/controller/clientRuntime.js +65 -92
- package/dist/controller/controller.js +120 -188
- package/dist/controller/fileSchedulerStoreAdapter.js +787 -887
- package/dist/controller/jobControl.js +54 -85
- package/dist/controller/resourceInventory.js +8 -27
- package/dist/controller/resourceInventoryLinux.js +12 -13
- package/dist/controller/runtime.js +529 -479
- package/dist/controller/runtimeEventInbox.js +55 -25
- package/dist/controller/runtimeEventProcessor.js +22 -31
- package/dist/controller/{runtimeHookTurnFence.js → runtimeHookRunFence.js} +91 -115
- package/dist/controller/runtimeLaunchCoordinator.js +80 -426
- package/dist/controller/runtimeObservationHook.js +14 -18
- package/dist/controller/sessionNotify.js +16 -24
- package/dist/controller/sessionOwnerReconciliation.js +168 -50
- package/dist/controller/structuredProviderObservation.js +138 -99
- package/dist/coordination/workMailbox.js +3 -3
- package/dist/coordination/workMailboxQueue.js +36 -33
- package/dist/core/boundedRpc.js +8 -1
- package/dist/core/controllerClient.js +20 -1
- package/dist/core/controllerServer.js +4 -4
- package/dist/doctor/doctor.js +13 -2
- package/dist/domain/agentResultTransport.js +9 -9
- package/dist/execution/codexThreadNaming.js +2 -8
- package/dist/execution/executionHealth.js +51 -63
- package/dist/execution/reviewMainRun.js +137 -0
- package/dist/execution/workItemExecution.js +28 -29
- package/dist/execution/workItemExecutionProjection.js +99 -107
- package/dist/execution/workItemMainRun.js +141 -0
- package/dist/executor/agentAdapter.js +227 -20
- package/dist/executor/agentConfigurationCatalog.js +126 -4
- package/dist/executor/agentConfigurationProbe.js +162 -4
- package/dist/executor/agentExecutor.js +79 -78
- package/dist/executor/effectiveLaunch.js +105 -18
- package/dist/executor/executorRegistry.js +29 -44
- package/dist/executor/fileRoleLaunchPlanner.js +229 -154
- package/dist/executor/workspacePreflightClassification.js +16 -16
- package/dist/grant/capabilityGrant.js +6 -3
- package/dist/input/inputRequest.js +12 -10
- package/dist/integration/gitIntegrationService.js +4 -11
- package/dist/integration/integrationQueueService.js +4 -4
- package/dist/interaction/operatorPresentation.js +1 -1
- package/dist/kernel/builtinCapabilities.js +255 -12
- package/dist/kernel/capabilityRegistry.js +64 -18
- package/dist/kernel/instanceHost.js +12 -1
- package/dist/kernel/kernelPorts.js +2 -2
- package/dist/lifecycle/canonicalLifecycleEvent.js +44 -49
- package/dist/lifecycle/exactRunTerminalization.js +449 -0
- package/dist/message/message.js +118 -6
- package/dist/message/messageContinuation.js +204 -0
- package/dist/observability/executionAudit.js +70 -72
- package/dist/observability/faultClassification.js +2 -2
- package/dist/observability/orchestrationMetrics.js +8 -8
- package/dist/operator/operatorSessionHistory.js +1 -7
- package/dist/output/agentConfigurationPresentation.js +8 -3
- package/dist/output/agentRunConfigurationPresentation.js +128 -0
- package/dist/output/rolePresentation.js +54 -3
- package/dist/plugins/pluginChild.js +104 -0
- package/dist/plugins/pluginIntent.js +26 -0
- package/dist/plugins/pluginInterpreter.js +43 -0
- package/dist/plugins/pluginPackage.js +101 -0
- package/dist/plugins/pluginProcess.js +112 -0
- package/dist/plugins/pluginService.js +388 -0
- package/dist/profile/agentProfile.js +1 -1
- package/dist/repository/gitWorkspace.js +26 -4
- package/dist/repository/project.js +19 -4
- package/dist/repository/taskBaseFreshness.js +13 -13
- package/dist/repository/taskWorkspaceCoordinator.js +20 -27
- package/dist/repository/taskWorkspacePreparer.js +344 -83
- package/dist/resources/autoResourceGc.js +3 -3
- package/dist/resources/liveReferences.js +3 -3
- package/dist/resources/projectResource.js +75 -0
- package/dist/resources/projectResourceService.js +343 -0
- package/dist/resources/resourceDiscovery.js +6 -6
- package/dist/resources/resourceGc.js +1 -1
- package/dist/resources/resourceRegistrar.js +1 -1
- package/dist/resources/resourceTypes.js +1 -1
- package/dist/review/deltaRecheck.js +3 -3
- package/dist/review/reviewAcceptance.js +16 -16
- package/dist/review/reviewDecision.js +7 -7
- package/dist/review/reviewRound.js +21 -20
- package/dist/review/reviewerAvailability.js +2 -2
- package/dist/role/role.js +51 -7
- package/dist/role/taskRoleUpdate.js +30 -0
- package/dist/runtime/acpProtocol.js +425 -0
- package/dist/runtime/acpSession.js +731 -0
- package/dist/runtime/acpSessionConfiguration.js +260 -0
- package/dist/runtime/agentDriver.js +30 -11
- package/dist/runtime/agentEndpoint.js +278 -0
- package/dist/runtime/agentEndpointIdentity.js +86 -0
- package/dist/runtime/agentEndpointOwnership.js +239 -0
- package/dist/runtime/agentError.js +2 -10
- package/dist/runtime/agentHost.js +565 -314
- package/dist/runtime/agentRunConfiguration.js +258 -0
- package/dist/runtime/builtinAgentDrivers.js +134 -18
- package/dist/runtime/builtinAgentErrorMappers.js +55 -3
- package/dist/runtime/builtinTranscriptUsage.js +1 -1
- package/dist/runtime/claude-process-owner +0 -0
- package/dist/runtime/codexAppServerRuntime.js +38 -30
- package/dist/runtime/codexInteractiveHost.js +41 -6
- package/dist/runtime/continuationManager.js +2 -6
- package/dist/runtime/executionEnvironment.js +30 -0
- package/dist/runtime/firstProgressAdvisory.js +11 -11
- package/dist/runtime/index.js +4 -3
- package/dist/runtime/jsonLineChannel.js +109 -0
- package/dist/runtime/launchBroker.js +91 -16
- package/dist/runtime/launchDiagnostics.js +2 -2
- package/dist/runtime/lifecycleReservation.js +10 -18
- package/dist/runtime/managedCaller.js +61 -17
- package/dist/runtime/nativeSessionControl.js +102 -0
- package/dist/runtime/ports.js +6 -21
- package/dist/runtime/processExitObservation.js +8 -7
- package/dist/runtime/promptEnvelope.js +17 -6
- package/dist/runtime/providerContinuation.js +3 -9
- package/dist/runtime/providerContinuationReconciliationService.js +4 -13
- package/dist/runtime/providerControl.js +2 -7
- package/dist/runtime/providerRuntimeIdentity.js +110 -222
- package/dist/runtime/providerRuntimeReconciler.js +5 -9
- package/dist/runtime/runtimeBinding.js +0 -1
- package/dist/runtime/runtimeContinuationProjection.js +4 -7
- package/dist/runtime/runtimeDeadlines.js +9 -0
- package/dist/runtime/runtimeHealthPolicy.js +1 -1
- package/dist/runtime/runtimeObservation.js +29 -65
- package/dist/runtime/runtimeProjection.js +43 -51
- package/dist/runtime/runtimeSessionCandidate.js +1 -3
- package/dist/runtime/sessionLaunchRequest.js +3 -7
- package/dist/runtime/sessionOwnerIdentity.js +7 -54
- package/dist/runtime/sessionOwnerRegistry.js +22 -17
- package/dist/runtime/sessionReconciliation.js +4 -8
- package/dist/runtime/sessionTerminationGuard.js +70 -259
- package/dist/runtime/sessionTokenMetrics.js +5 -16
- package/dist/runtime/structuredProviderHost.js +237 -117
- package/dist/runtime/taskRuntimeIsolation.js +39 -122
- package/dist/runtime/tmuxAdapters.js +39 -86
- package/dist/scheduler/activeRoleRunDelivery.js +354 -0
- package/dist/scheduler/leaderWakeupProcessor.js +75 -266
- package/dist/scheduler/operatorInputNotificationProcessor.js +1 -1
- package/dist/scheduler/ports.js +80 -9
- package/dist/scheduler/{roleTurnLiveness.js → roleRunLiveness.js} +26 -30
- package/dist/scheduler/{roleTurnStall.js → roleRunStall.js} +128 -139
- package/dist/scheduler/taskExecutionProjection.js +120 -124
- package/dist/scheduler/taskObservabilityProjection.js +29 -29
- package/dist/scheduler/taskWake.js +11 -4
- package/dist/scheduler/wakeReason.js +9 -1
- package/dist/setup/setupCommand.js +3 -7
- package/dist/storage/migrations/agentRunContract.js +159 -0
- package/dist/storage/migrations/artifactsToGit.js +338 -0
- package/dist/storage/migrations/removeRuntimeGeneration.js +207 -0
- package/dist/storage/migrations/submitIntent.js +126 -0
- package/dist/storage/sqliteSchema.js +467 -7
- package/dist/storage/sqliteStore.js +355 -220
- package/dist/storage/storageVersions.js +1 -1
- package/dist/storage/storeRpc.js +10 -5
- package/dist/storage/taskStore.js +13 -11
- package/dist/storage/upgrade/upgradeOrchestrator.js +5 -7
- package/dist/surface/surfaceContributions.js +102 -0
- package/dist/task/completionReadiness.js +32 -6
- package/dist/task/deliveryGuard.js +16 -16
- package/dist/task/draftPlan.js +72 -12
- package/dist/task/nextAction.js +144 -128
- package/dist/task/remoteDelivery.js +6 -6
- package/dist/task/task.js +184 -18
- package/dist/task/taskActivation.js +327 -0
- package/dist/task/taskActivationService.js +408 -0
- package/dist/task/taskRecordReference.js +5 -4
- package/dist/task/taskRecordRetirement.js +1 -1
- package/dist/task/taskSubmission.js +236 -0
- package/dist/telemetry/sqliteTelemetryStore.js +55 -68
- package/dist/telemetry/telemetryConfig.js +14 -14
- package/dist/telemetry/telemetryWiring.js +2 -2
- package/dist/web/assets/assetManifest.js +2 -0
- package/dist/web/assets/client/app.js +121 -20
- package/dist/web/assets/client/components.js +87 -54
- package/dist/web/assets/client/i18n.js +83 -41
- package/dist/web/assets/client/markdown.js +1 -1
- package/dist/web/assets/client/taskSurface.js +442 -0
- package/dist/web/assets/client/view.js +49 -44
- package/dist/web/assets/shell.js +1 -1
- package/dist/web/assets/styles/cards.js +22 -4
- package/dist/web/controllerWeb.js +60 -0
- package/dist/web/webMutation.js +28 -0
- package/dist/web/webServer.js +133 -8
- package/dist/web/webSnapshot.js +81 -74
- package/dist/web/webTaskSurface.js +64 -0
- package/dist/workItem/dependencyGate.js +1 -1
- package/dist/workItem/workItem.js +84 -48
- package/dist/workspace/workItemChangeSetManager.js +16 -9
- package/docs/agent-result-consumption.md +96 -0
- package/docs/agent-result-consumption.zh-CN.md +81 -0
- package/docs/agent-runtime-drivers.md +93 -0
- package/docs/agent-runtime-drivers.zh-CN.md +77 -0
- package/docs/architecture/README.md +50 -0
- package/docs/architecture/README.zh-CN.md +43 -0
- package/docs/architecture/capabilities-and-resources.md +118 -0
- package/docs/architecture/capabilities-and-resources.zh-CN.md +83 -0
- package/docs/managed-turn-and-session-runtime.md +224 -0
- package/docs/managed-turn-and-session-runtime.zh-CN.md +180 -0
- package/docs/observability/README.md +83 -0
- package/docs/observability/README.zh-CN.md +71 -0
- package/docs/plugin-sdk.md +393 -0
- package/docs/plugin-sdk.zh-CN.md +293 -0
- package/docs/provider-runtime.md +165 -0
- package/docs/provider-runtime.zh-CN.md +132 -0
- package/docs/release-workflow.md +305 -0
- package/docs/release-workflow.zh-CN.md +237 -0
- package/docs/roles-and-configuration.md +115 -0
- package/docs/roles-and-configuration.zh-CN.md +96 -0
- package/docs/sqlite-control-plane-design.md +78 -0
- package/docs/sqlite-control-plane-design.zh-CN.md +62 -0
- package/docs/task-dag-semantics.md +80 -0
- package/docs/task-dag-semantics.zh-CN.md +59 -0
- package/docs/task-delivery.md +105 -0
- package/docs/task-delivery.zh-CN.md +82 -0
- package/docs/task-local-identity.md +8 -6
- package/docs/task-local-identity.zh-CN.md +58 -0
- package/docs/testing/verification-levels.md +88 -0
- package/docs/testing/verification-levels.zh-CN.md +69 -0
- package/i18n/README.zh-CN.md +270 -722
- package/package.json +3 -2
- package/skills/yui-leader/SKILL.md +88 -304
- package/skills/yui-leader/references/execution.md +303 -0
- package/skills/yui-leader/references/integration.md +39 -0
- package/skills/yui-leader/references/planning.md +109 -0
- package/skills/yui-leader/references/replicated-execution.md +42 -0
- package/skills/yui-leader/references/task-plugins.md +37 -0
- package/skills/yui-operator/SKILL.md +46 -62
- package/skills/yui-reviewer/SKILL.md +35 -36
- package/skills/yui-runtime/SKILL.md +88 -24
- package/skills/yui-runtime/references/publication.md +22 -0
- package/skills/yui-runtime/references/recovery.md +64 -0
- package/skills/yui-worker/SKILL.md +37 -39
- package/dist/cli/roleOptionCatalog.js +0 -68
- package/dist/context/sourceTurnContext.js +0 -30
- package/dist/execution/reviewMainTurn.js +0 -161
- package/dist/execution/workItemMainTurn.js +0 -164
- package/dist/lifecycle/exactTurnTerminalization.js +0 -407
- package/dist/runtime/preallocatedNativeSession.js +0 -13
- package/dist/runtime/runtimeStopReceipt.js +0 -42
- package/dist/scheduler/activeRoleTurnDelivery.js +0 -315
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zq-silk/yui",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.9",
|
|
4
4
|
"description": "Local control plane for long-running native agent CLI sessions backed by tmux.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"private": false,
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
"docs",
|
|
15
15
|
"README.md",
|
|
16
16
|
"ARCHITECTURE.md",
|
|
17
|
+
"ARCHITECTURE.zh-CN.md",
|
|
17
18
|
"i18n/README.zh-CN.md",
|
|
18
19
|
"LICENSE"
|
|
19
20
|
],
|
|
@@ -50,7 +51,7 @@
|
|
|
50
51
|
"@xterm/xterm": "^6.0.0",
|
|
51
52
|
"better-sqlite3": "^12.11.1",
|
|
52
53
|
"node-pty": "^1.1.0",
|
|
53
|
-
"smol-toml": "1.
|
|
54
|
+
"smol-toml": "1.8.0",
|
|
54
55
|
"ws": "^8.21.1"
|
|
55
56
|
}
|
|
56
57
|
}
|
|
@@ -1,310 +1,94 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: yui-leader
|
|
3
|
-
description: Lead one Yui Task
|
|
3
|
+
description: Lead one Yui Task through authorized planning, activation handoff, execution and acceptance, choosing responsibilities and a useful stopping point from its current stage and user intent.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Yui Leader
|
|
7
7
|
|
|
8
|
-
Follow
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
-
|
|
28
|
-
|
|
29
|
-
the
|
|
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
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
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
|
-
For Project-backed work, use the Project Skills, Policy, and Knowledge exposed
|
|
97
|
-
through current context. Keep repository-specific build, migration, release,
|
|
98
|
-
and test rules in that Project-owned layer.
|
|
99
|
-
|
|
100
|
-
## Keep durable context useful
|
|
101
|
-
|
|
102
|
-
Use `yui task context <task-id>` and `yui task next-action <task-id>` as
|
|
103
|
-
decision support. They expose current facts, exact refs, and legal
|
|
104
|
-
alternatives; they do not replace Leader judgment.
|
|
105
|
-
|
|
106
|
-
Before dispatch, Review, Integration, or completion, inspect
|
|
107
|
-
`liveTaskState.activeTurns` and `liveTaskState.activeTaskReviews` in the current
|
|
108
|
-
Context Pack. They report work in flight but gate nothing by themselves; reason
|
|
109
|
-
from each exact binding and frozen candidate instead of treating activity as a
|
|
110
|
-
global Task lock.
|
|
111
|
-
|
|
112
|
-
Maintain only context that changes future decisions:
|
|
113
|
-
|
|
114
|
-
- Keep the Brief's objective, boundaries, approach, current focus, and Leader
|
|
115
|
-
summary current after material semantic progress.
|
|
116
|
-
- Record a Decision when a material product or technical choice changes future
|
|
117
|
-
work.
|
|
118
|
-
- Add a Milestone for an independently meaningful phase result.
|
|
119
|
-
- Send one Task Message only when another reader needs a new conclusion,
|
|
120
|
-
impact, risk, acceptance decision, or changed plan.
|
|
121
|
-
- Propose Project Knowledge only for a stable conclusion useful across Tasks.
|
|
122
|
-
|
|
123
|
-
Do not turn Messages, WorkItems, Decisions, or Milestones into a scheduler log
|
|
124
|
-
or transcript. Unchanged waits, dispatches, heartbeats, and routine tool use do
|
|
125
|
-
not need narrative records.
|
|
126
|
-
|
|
127
|
-
## Execute the chosen path
|
|
128
|
-
|
|
129
|
-
For direct work, change only Task main, keep it on its managed branch, commit
|
|
130
|
-
the result, and leave it clean. Run the smallest check that can catch the
|
|
131
|
-
changed behavior while implementing.
|
|
132
|
-
|
|
133
|
-
For a substantial delegated requirement:
|
|
134
|
-
|
|
135
|
-
```sh
|
|
136
|
-
yui task work create <task-id> "<title>" \
|
|
137
|
-
--project <project-to-modify> \
|
|
138
|
-
--objective "<bounded outcome>" \
|
|
139
|
-
--accept "<observable criterion>"
|
|
140
|
-
```
|
|
141
|
-
|
|
142
|
-
Add `--after` only for a real dependency. Likely file overlap is not by itself
|
|
143
|
-
a dependency. A Worker may read the complete authorized Task context but may
|
|
144
|
-
write only its WorkItem Projects and workspace.
|
|
145
|
-
|
|
146
|
-
For a Leader-owned WorkItem, mark it running, complete it directly, then record
|
|
147
|
-
its actual result:
|
|
148
|
-
|
|
149
|
-
```sh
|
|
150
|
-
yui task work update <work-id> running
|
|
151
|
-
yui task work update <work-id> done --summary "<result and evidence>"
|
|
152
|
-
```
|
|
153
|
-
|
|
154
|
-
For a native child, keep the WorkItem roleless, mark it running, select the
|
|
155
|
-
closest applicable Profile, pass its constraints in the brief, and use the
|
|
156
|
-
provider's native child tools. Native children inherit the current Turn's
|
|
157
|
-
authority and gain no Yui Role, Turn, Session, or broader workspace. Their
|
|
158
|
-
results are best-effort until Yui externalizes them; use a managed Task Role
|
|
159
|
-
when independent durability matters. Inspect the returned result before
|
|
160
|
-
recording `done` or `failed`. A Profile's runtime source applies when
|
|
161
|
-
materializing a Task Role, not when launching a native child. The child
|
|
162
|
-
inherits the Leader Agent; apply a Profile model or effort only when the native
|
|
163
|
-
tool actually supports and confirms that override.
|
|
164
|
-
|
|
165
|
-
For a managed Task Role:
|
|
166
|
-
|
|
167
|
-
```sh
|
|
168
|
-
yui task role add <task-id> <role> --profile <profile>
|
|
169
|
-
yui task role show <task-id> <role>
|
|
170
|
-
yui task work create <task-id> "<outcome>" --role <role>
|
|
171
|
-
yui task work dispatch <work-id> --input "<decision-complete brief>"
|
|
172
|
-
```
|
|
173
|
-
|
|
174
|
-
Profiles carry portable behavior plus either a dynamic Global Worker runtime
|
|
175
|
-
source or an explicit Agent with optional model and effort. Applying a Profile
|
|
176
|
-
to a Task Role resolves and freezes the complete binding; later Profile or
|
|
177
|
-
Global Worker changes do not rewrite that Role. Before dispatch, use
|
|
178
|
-
`profile show` and `task role show` to read the exact behavior, Agent, model,
|
|
179
|
-
effort, Profile, and workspace. Do not reconstruct or guess launch
|
|
180
|
-
configuration. Use the WorkItem assignee directly unless replicated execution
|
|
181
|
-
was deliberately selected.
|
|
182
|
-
|
|
183
|
-
Managed Task main, WorkItem, ReviewRound, and Integration workspaces have
|
|
184
|
-
different owners. Never edit stable Project checkouts, managed refs, Yui state
|
|
185
|
-
files, or another owner's workspace. A Task's recorded base is durable; do not
|
|
186
|
-
silently replace it merely because its remote branch later moves.
|
|
187
|
-
|
|
188
|
-
## Validate and make the review judgment
|
|
189
|
-
|
|
190
|
-
Use the smallest evidence that establishes the accepted behavior and material
|
|
191
|
-
boundaries. Do not repeat a successful unchanged check. Run the Project's
|
|
192
|
-
complete local delivery validation once on the final candidate when its Policy
|
|
193
|
-
requires it.
|
|
194
|
-
|
|
195
|
-
As part of accepting a WorkItem or completing a Task, decide whether additional
|
|
196
|
-
review would add useful evidence:
|
|
197
|
-
|
|
198
|
-
- inspect directly when the change is clear and existing evidence is enough;
|
|
199
|
-
- use one independent Worker, native child, or Reviewer when independent
|
|
200
|
-
inspection materially reduces a reachable risk; or
|
|
201
|
-
- rely on an already completed applicable Review.
|
|
202
|
-
|
|
203
|
-
This is Leader judgment inside the acceptance decision, not a separate record,
|
|
204
|
-
checklist, or workflow phase. A managed Reviewer is optional. Do not create a
|
|
205
|
-
Reviewer Role or ReviewRound for ceremony. Honor an existing Candidate's
|
|
206
|
-
snapshotted `always` policy and any immutable Task-final Review contract.
|
|
207
|
-
Otherwise choose whether another review adds enough evidence to justify its
|
|
208
|
-
cost.
|
|
209
|
-
|
|
210
|
-
Use direct Review by default: one main Reviewer Turn owns the authoritative
|
|
211
|
-
result without an ExecutionGroup or Lane. Choose replicated Review only when
|
|
212
|
-
independent inspection of the same frozen Assignment materially improves the
|
|
213
|
-
evidence enough to repay its coordination cost. It requires at least two
|
|
214
|
-
distinct Producer Lane Roles plus a separate main Reviewer. Wait for every
|
|
215
|
-
Producer to settle and at least two to succeed; their results are durable
|
|
216
|
-
evidence only. The main Reviewer receives all successful results, resolves
|
|
217
|
-
disagreement against the frozen sources, and submits one original result.
|
|
218
|
-
Automatic policy-triggered Candidate Review remains direct.
|
|
219
|
-
|
|
220
|
-
When several WorkItems contribute to one outcome, prefer one independent
|
|
221
|
-
Task-final Review after their accepted results are integrated over repeating a
|
|
222
|
-
complete Review for every WorkItem. Request an earlier WorkItem Review only
|
|
223
|
-
when that frozen Candidate has a specific risk that should be resolved before
|
|
224
|
-
Integration.
|
|
225
|
-
|
|
226
|
-
When a Worker or Reviewer result arrives, resolve its exact Turn and read the
|
|
227
|
-
complete original `TurnResult.output` before starting new work or waiting
|
|
228
|
-
again. Treat headings or JSON fields only as communication aids; never infer
|
|
229
|
-
that Core parsed or accepted them. Decide whether to accept, repair, review
|
|
230
|
-
again, retry execution, or ask for a genuinely user-owned decision. Route
|
|
231
|
-
reachable issues to the original execution owner. Fix a small Task-main issue
|
|
232
|
-
directly; create a Repair WorkItem only when the repair is itself a substantial
|
|
233
|
-
independently owned requirement.
|
|
234
|
-
|
|
235
|
-
A failed ReviewRound is an execution failure, not an automatic retry or repair
|
|
236
|
-
wave. Inspect its exact Round, Turn, candidate, Core failure, and
|
|
237
|
-
`task next-action` facts, then choose the smallest recovery that preserves the
|
|
238
|
-
frozen boundary. Do not invent a retry loop or silently replace the Reviewer
|
|
239
|
-
Session. For a replicated Task-final Round below quorum before main synthesis,
|
|
240
|
-
retry the Round so only unsettled or failed Producers rerun. Retry a failed
|
|
241
|
-
main synthesis through its exact Turn.
|
|
242
|
-
|
|
243
|
-
## Accept, integrate, and complete
|
|
244
|
-
|
|
245
|
-
A Worker or Reviewer Turn result is evidence, not acceptance. Inspect the
|
|
246
|
-
result, diff, checks, and current Candidate before deciding.
|
|
247
|
-
|
|
248
|
-
If a WorkItem result is insufficient, reject it with bounded feedback and
|
|
249
|
-
redispatch the same WorkItem and Role while its scope remains valid. If it is
|
|
250
|
-
acceptable and contains isolated Git changes, capture and integrate its latest
|
|
251
|
-
Candidate before acceptance:
|
|
252
|
-
|
|
253
|
-
```sh
|
|
254
|
-
yui task work capture <work-id>
|
|
255
|
-
yui task integration start <task-id> --project <project> \
|
|
256
|
-
--change-set <change-set-id> \
|
|
257
|
-
--check "<Project Policy command>"
|
|
258
|
-
yui task work accept <work-id> --summary "<decision and evidence>"
|
|
259
|
-
```
|
|
260
|
-
|
|
261
|
-
Resolve a failed Integration from its exact conflict or check evidence. Do not
|
|
262
|
-
bypass compare-and-swap, update managed refs manually, or create a replacement
|
|
263
|
-
WorkItem for an ordinary Integration correction.
|
|
264
|
-
|
|
265
|
-
Immediately after creating, updating, closing, reopening, or merging a PR/MR,
|
|
266
|
-
record the confirmed fact with `yui task publication upsert`; do not wait for
|
|
267
|
-
another Role to infer it. Supply only information already known from the
|
|
268
|
-
operation itself. When the current authorization covers an external provider
|
|
269
|
-
read, use `yui task publication verify` after the merge; otherwise preserve
|
|
270
|
-
reported evidence and state the gap. Track PR/MR identity, state, commits, URL,
|
|
271
|
-
merge time, and evidence—not CI or deployment state. Publication describes
|
|
272
|
-
external delivery and never replaces Candidate, Review, Integration,
|
|
273
|
-
acceptance, or completion.
|
|
274
|
-
|
|
275
|
-
Complete only when the Task outcome is satisfied, required checks and review
|
|
276
|
-
contracts are settled, WorkItems are accepted or deliberately retired, latest
|
|
277
|
-
isolated results are integrated, and user inputs are resolved:
|
|
278
|
-
|
|
279
|
-
```sh
|
|
280
|
-
yui task complete <task-id> \
|
|
281
|
-
--summary "<outcome, validation, and remaining risk>"
|
|
282
|
-
```
|
|
283
|
-
|
|
284
|
-
Completion records the exact Project heads. Archive is a separate,
|
|
285
|
-
user-authorized Operator action.
|
|
286
|
-
|
|
287
|
-
## Finish every Leader Turn
|
|
288
|
-
|
|
289
|
-
Before ending the Turn:
|
|
290
|
-
|
|
291
|
-
1. Inspect the wake delta, resolve every referenced Worker or Reviewer Turn
|
|
292
|
-
with `yui task turn show`, read each original result in full, and make the
|
|
293
|
-
next decision.
|
|
294
|
-
2. Persist actual WorkItem lifecycle and material Brief, Decision, Milestone,
|
|
295
|
-
Message, or Knowledge changes.
|
|
296
|
-
3. Choose one truthful outcome: continue through an owned native child, complete
|
|
297
|
-
the Task, create a justified InputRequest, or leave the active Task waiting
|
|
298
|
-
for a real durable event.
|
|
299
|
-
4. Return one concise final report with outcome, checks, remaining risk, and
|
|
300
|
-
bounded next action.
|
|
301
|
-
|
|
302
|
-
Do not claim completion only in prose when durable Task or WorkItem state still
|
|
303
|
-
needs updating. Do not poll managed Roles or emit waiting Messages. Managed
|
|
304
|
-
results wake a later Leader Turn; an unchanged active Task remains quiet.
|
|
305
|
-
|
|
306
|
-
For a runtime failure, inspect the exact `runtime.agent-error`, Turn, and
|
|
307
|
-
Session facts. Retry the failed Turn on the same recoverable Session when useful.
|
|
308
|
-
Replace a Session only when the Driver proves it cannot continue. After
|
|
309
|
-
repeated replacement failures, report the evidence and bounded options instead
|
|
310
|
-
of adding another recovery mechanism.
|
|
8
|
+
Follow [yui-runtime](../yui-runtime/SKILL.md) first. Load the exact Context Pack
|
|
9
|
+
for an explicitly dispatched AgentRun; for direct conversation or a Task
|
|
10
|
+
notification, read current Task context through the Manifest's Session CLI.
|
|
11
|
+
No self-dispatch or old completed Run is needed. Read the actual Task
|
|
12
|
+
requirements, current Brief and relevant user/Operator Messages, not just
|
|
13
|
+
their summaries. Resolve links relative to the file containing them.
|
|
14
|
+
|
|
15
|
+
## Select the applicable stage
|
|
16
|
+
|
|
17
|
+
Use current lifecycle, latest intent and the Session's actual planning/delivery
|
|
18
|
+
authority together. Draft existence, accepted planning history, Session
|
|
19
|
+
authority and AgentRun status are different facts. A completed planning Run
|
|
20
|
+
does not complete or activate a Task; an active Task does not upgrade an old
|
|
21
|
+
planning Session. Never infer authority from a directory, launch text,
|
|
22
|
+
transcript or process.
|
|
23
|
+
|
|
24
|
+
Apply terminal/gate and read-only intent boundaries before selecting delivery
|
|
25
|
+
or planning work; the routes below do not override those restrictions.
|
|
26
|
+
|
|
27
|
+
- **Draft or planning-only authority:** read [Planning and activation handoff](references/planning.md).
|
|
28
|
+
Use the recorded submission intent (`record`, `discuss`, `develop`) and
|
|
29
|
+
routing result, not keywords in the message. Discuss and preserve the
|
|
30
|
+
requested outcome; do not load execution procedures merely to finish a
|
|
31
|
+
discussion.
|
|
32
|
+
- **Active, execution enabled, delivery authority and implementation intent:**
|
|
33
|
+
read [Active execution](references/execution.md). Advance existing authorized
|
|
34
|
+
work, including disposition of new results, without asking for another
|
|
35
|
+
“continue” after a valid activation handoff.
|
|
36
|
+
- **Query, analysis or discussion only:** answer within the requested scope,
|
|
37
|
+
even on an active Task. Do not turn it into edits or dispatch. A result
|
|
38
|
+
notification is different: read its original results and advance the
|
|
39
|
+
outstanding authorized requirement.
|
|
40
|
+
- **Completed, cancelled, retired or archived, or execution gate disabled:**
|
|
41
|
+
explain/query authorized facts only unless a specific further action has
|
|
42
|
+
been authorized and is legal. A conversation does not reopen, reactivate or
|
|
43
|
+
resume execution. If new implementation is requested, identify the needed
|
|
44
|
+
lifecycle/authority action for the Operator; do not manufacture a Run.
|
|
45
|
+
|
|
46
|
+
These are instruction routes, not new lifecycle states or a scheduling
|
|
47
|
+
protocol. Where facts disagree or authority is missing, preserve intent and
|
|
48
|
+
report the exact boundary rather than choosing a more permissive route.
|
|
49
|
+
|
|
50
|
+
## Maintain useful durable context
|
|
51
|
+
|
|
52
|
+
The DB Brief is the current summary, not a full plan or a history of messages.
|
|
53
|
+
After meaningful progress, use `task brief update` with only intended fields;
|
|
54
|
+
read `task event list` before deliberately restoring an older value. Keep
|
|
55
|
+
references to substantial plans, prototypes and reports in that summary.
|
|
56
|
+
Decisions contain the actual decision, reason and necessary boundaries, not
|
|
57
|
+
the entire proposal. Label recommendations as recommendations, not user
|
|
58
|
+
decisions.
|
|
59
|
+
|
|
60
|
+
Save full deliverables as files in the Task's local Git artifact repository,
|
|
61
|
+
not in Brief/Decision or a parallel store. Use `task artifact save` or
|
|
62
|
+
`artifact.save`; read [Task artifact operations](references/planning.md#task-artifact-operations)
|
|
63
|
+
before saving or citing results in any stage. A save commits one selected
|
|
64
|
+
path and returns `taskId + commit + relativePath` for fixed evidence. Update
|
|
65
|
+
the Brief reference after a meaningful saved revision; keep the document
|
|
66
|
+
body, HEAD and timestamps out of DB mirrors. Saving a planning result neither
|
|
67
|
+
activates the Task nor grants Project write authority. Artifact scripts and
|
|
68
|
+
HTML are data, not permission to execute or preview them.
|
|
69
|
+
|
|
70
|
+
Add a Milestone only for an independently meaningful outcome, a Message only
|
|
71
|
+
for a new conclusion another reader needs, and Project Knowledge only for a
|
|
72
|
+
stable cross-Task lesson. Do not create records for every exchange, dispatch,
|
|
73
|
+
heartbeat or unchanged wait. Ordinary fact edits need no self-wake.
|
|
74
|
+
|
|
75
|
+
## Close the current turn
|
|
76
|
+
|
|
77
|
+
- **Planning:** save meaningful revisions, summarize the discussion and await
|
|
78
|
+
feedback. This is a complete turn; it needs no WorkItem, Review, InputRequest
|
|
79
|
+
or Task completion just to stop.
|
|
80
|
+
- **Active delivery:** apply the result-disposition and close instructions in
|
|
81
|
+
[Active execution](references/execution.md). Continue within authorization,
|
|
82
|
+
complete only when acceptance is satisfied, or wait for a real durable
|
|
83
|
+
event. Ask only for a genuinely missing user choice, authority or external
|
|
84
|
+
fact; routine engineering coordination is not a user decision.
|
|
85
|
+
- **Queries and terminal stages:** answer the bounded question and stop
|
|
86
|
+
without starting work or recording fictitious lifecycle progress.
|
|
87
|
+
|
|
88
|
+
Every explicitly dispatched managed AgentRun returns one truthful original
|
|
89
|
+
final report under Runtime's contract, including a planning Run whose result
|
|
90
|
+
is a saved proposal awaiting feedback. Ordinary chat and notifications are
|
|
91
|
+
not implicit assignments and need no separate execution report. Run terminal,
|
|
92
|
+
result acceptance, Task completion, remote delivery and user-authorized
|
|
93
|
+
archive are distinct facts. Do not poll managed Roles or emit unchanged
|
|
94
|
+
waiting Messages; future durable events supply the next notification.
|