@codetreker/daynight 0.25.4 → 0.27.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.
Files changed (214) hide show
  1. package/README.md +160 -11
  2. package/config.example.yml +3 -0
  3. package/dist/api/client.d.ts +3 -2
  4. package/dist/api/client.js +10 -6
  5. package/dist/api/client.js.map +1 -1
  6. package/dist/api/parse.d.ts +3 -2
  7. package/dist/api/parse.js +59 -10
  8. package/dist/api/parse.js.map +1 -1
  9. package/dist/api/types.d.ts +75 -1
  10. package/dist/api/worker-mode.d.ts +6 -0
  11. package/dist/api/worker-mode.js +14 -0
  12. package/dist/api/worker-mode.js.map +1 -0
  13. package/dist/cli/commands.js +2 -0
  14. package/dist/cli/commands.js.map +1 -1
  15. package/dist/commands/controller/command-controls.d.ts +4 -0
  16. package/dist/commands/controller/command-controls.js +33 -0
  17. package/dist/commands/controller/command-controls.js.map +1 -0
  18. package/dist/commands/controller/definition.d.ts +3 -0
  19. package/dist/commands/controller/definition.js +22 -0
  20. package/dist/commands/controller/definition.js.map +1 -0
  21. package/dist/commands/controller/independent.d.ts +3 -0
  22. package/dist/commands/controller/independent.js +344 -0
  23. package/dist/commands/controller/independent.js.map +1 -0
  24. package/dist/commands/controller/index.d.ts +12 -0
  25. package/dist/commands/controller/index.js +73 -0
  26. package/dist/commands/controller/index.js.map +1 -0
  27. package/dist/commands/controller/launch-ticket.d.ts +49 -0
  28. package/dist/commands/controller/launch-ticket.js +99 -0
  29. package/dist/commands/controller/launch-ticket.js.map +1 -0
  30. package/dist/commands/controller/lifecycle-store.d.ts +84 -0
  31. package/dist/commands/controller/lifecycle-store.js +278 -0
  32. package/dist/commands/controller/lifecycle-store.js.map +1 -0
  33. package/dist/commands/controller/local-client.d.ts +44 -0
  34. package/dist/commands/controller/local-client.js +75 -0
  35. package/dist/commands/controller/local-client.js.map +1 -0
  36. package/dist/commands/controller/local-content.d.ts +23 -0
  37. package/dist/commands/controller/local-content.js +103 -0
  38. package/dist/commands/controller/local-content.js.map +1 -0
  39. package/dist/commands/controller/process-proof.d.ts +13 -0
  40. package/dist/commands/controller/process-proof.js +121 -0
  41. package/dist/commands/controller/process-proof.js.map +1 -0
  42. package/dist/commands/controller/providers/claude.d.ts +2 -0
  43. package/dist/commands/controller/providers/claude.js +470 -0
  44. package/dist/commands/controller/providers/claude.js.map +1 -0
  45. package/dist/commands/controller/providers/codex.d.ts +2 -0
  46. package/dist/commands/controller/providers/codex.js +254 -0
  47. package/dist/commands/controller/providers/codex.js.map +1 -0
  48. package/dist/commands/controller/providers/controls-claude.d.ts +26 -0
  49. package/dist/commands/controller/providers/controls-claude.js +138 -0
  50. package/dist/commands/controller/providers/controls-claude.js.map +1 -0
  51. package/dist/commands/controller/providers/controls-codex.d.ts +38 -0
  52. package/dist/commands/controller/providers/controls-codex.js +199 -0
  53. package/dist/commands/controller/providers/controls-codex.js.map +1 -0
  54. package/dist/commands/controller/providers/controls-copilot.d.ts +20 -0
  55. package/dist/commands/controller/providers/controls-copilot.js +143 -0
  56. package/dist/commands/controller/providers/controls-copilot.js.map +1 -0
  57. package/dist/commands/controller/providers/controls.d.ts +21 -0
  58. package/dist/commands/controller/providers/controls.js +53 -0
  59. package/dist/commands/controller/providers/controls.js.map +1 -0
  60. package/dist/commands/controller/providers/copilot-interactions.d.ts +47 -0
  61. package/dist/commands/controller/providers/copilot-interactions.js +295 -0
  62. package/dist/commands/controller/providers/copilot-interactions.js.map +1 -0
  63. package/dist/commands/controller/providers/copilot-projection.d.ts +11 -0
  64. package/dist/commands/controller/providers/copilot-projection.js +93 -0
  65. package/dist/commands/controller/providers/copilot-projection.js.map +1 -0
  66. package/dist/commands/controller/providers/copilot-runtime.d.ts +9 -0
  67. package/dist/commands/controller/providers/copilot-runtime.js +127 -0
  68. package/dist/commands/controller/providers/copilot-runtime.js.map +1 -0
  69. package/dist/commands/controller/providers/copilot.d.ts +2 -0
  70. package/dist/commands/controller/providers/copilot.js +309 -0
  71. package/dist/commands/controller/providers/copilot.js.map +1 -0
  72. package/dist/commands/controller/providers/interactions.d.ts +3 -0
  73. package/dist/commands/controller/providers/interactions.js +79 -0
  74. package/dist/commands/controller/providers/interactions.js.map +1 -0
  75. package/dist/commands/controller/providers/native-rpc.d.ts +28 -0
  76. package/dist/commands/controller/providers/native-rpc.js +85 -0
  77. package/dist/commands/controller/providers/native-rpc.js.map +1 -0
  78. package/dist/commands/controller/providers/projection.d.ts +23 -0
  79. package/dist/commands/controller/providers/projection.js +99 -0
  80. package/dist/commands/controller/providers/projection.js.map +1 -0
  81. package/dist/commands/controller/providers/turns.d.ts +7 -0
  82. package/dist/commands/controller/providers/turns.js +21 -0
  83. package/dist/commands/controller/providers/turns.js.map +1 -0
  84. package/dist/commands/controller/providers/types.d.ts +44 -0
  85. package/dist/commands/controller/providers/types.js +2 -0
  86. package/dist/commands/controller/providers/types.js.map +1 -0
  87. package/dist/commands/controller/recovery.d.ts +6 -0
  88. package/dist/commands/controller/recovery.js +22 -0
  89. package/dist/commands/controller/recovery.js.map +1 -0
  90. package/dist/commands/controller/relay.d.ts +18 -0
  91. package/dist/commands/controller/relay.js +299 -0
  92. package/dist/commands/controller/relay.js.map +1 -0
  93. package/dist/commands/controller/resume.d.ts +18 -0
  94. package/dist/commands/controller/resume.js +193 -0
  95. package/dist/commands/controller/resume.js.map +1 -0
  96. package/dist/commands/controller/runtime.d.ts +5 -0
  97. package/dist/commands/controller/runtime.js +455 -0
  98. package/dist/commands/controller/runtime.js.map +1 -0
  99. package/dist/commands/controller/windows-job.d.ts +3 -0
  100. package/dist/commands/controller/windows-job.js +59 -0
  101. package/dist/commands/controller/windows-job.js.map +1 -0
  102. package/dist/commands/controller/wire-display.d.ts +5 -0
  103. package/dist/commands/controller/wire-display.js +11 -0
  104. package/dist/commands/controller/wire-display.js.map +1 -0
  105. package/dist/commands/skill/skills/using-daynight/SKILL.md +52 -162
  106. package/dist/commands/skill/skills/using-daynight/references/authorization.md +36 -0
  107. package/dist/commands/skill/skills/using-daynight/references/autopilot-managed-task.md +77 -193
  108. package/dist/commands/skill/skills/using-daynight/references/create-task.md +31 -186
  109. package/dist/commands/skill/skills/using-daynight/references/final-acceptance.md +25 -0
  110. package/dist/commands/skill/skills/using-daynight/references/goal.md +46 -243
  111. package/dist/commands/skill/skills/using-daynight/references/handbook.md +37 -294
  112. package/dist/commands/skill/skills/using-daynight/references/handoff.md +33 -91
  113. package/dist/commands/skill/skills/using-daynight/references/project-management.md +24 -0
  114. package/dist/commands/skill/skills/using-daynight/references/run-task.md +18 -59
  115. package/dist/commands/skill/skills/using-daynight/references/setup.md +16 -0
  116. package/dist/commands/skill/skills/using-daynight/references/task-content.md +80 -177
  117. package/dist/commands/skill/skills/using-daynight/references/task-execution.md +34 -126
  118. package/dist/commands/skill/skills/using-daynight/references/task-management.md +135 -0
  119. package/dist/commands/skill/skills/using-daynight/references/write-safety.md +34 -0
  120. package/dist/commands/task/command.js +5 -3
  121. package/dist/commands/task/command.js.map +1 -1
  122. package/dist/commands/task/definition.js +4 -2
  123. package/dist/commands/task/definition.js.map +1 -1
  124. package/dist/commands/task/rendering.d.ts +1 -0
  125. package/dist/commands/task/rendering.js +10 -1
  126. package/dist/commands/task/rendering.js.map +1 -1
  127. package/dist/commands/worker/backend.d.ts +7 -0
  128. package/dist/commands/worker/backend.js +7 -0
  129. package/dist/commands/worker/backend.js.map +1 -0
  130. package/dist/commands/worker/backends/grant-renewal.d.ts +13 -0
  131. package/dist/commands/worker/backends/grant-renewal.js +42 -0
  132. package/dist/commands/worker/backends/grant-renewal.js.map +1 -0
  133. package/dist/commands/worker/backends/session-api.d.ts +66 -0
  134. package/dist/commands/worker/backends/session-api.js +84 -0
  135. package/dist/commands/worker/backends/session-api.js.map +1 -0
  136. package/dist/commands/worker/backends/web-process.d.ts +79 -0
  137. package/dist/commands/worker/backends/web-process.js +156 -0
  138. package/dist/commands/worker/backends/web-process.js.map +1 -0
  139. package/dist/commands/worker/backends/web-store.d.ts +49 -0
  140. package/dist/commands/worker/backends/web-store.js +323 -0
  141. package/dist/commands/worker/backends/web-store.js.map +1 -0
  142. package/dist/commands/worker/backends/web-types.d.ts +83 -0
  143. package/dist/commands/worker/backends/web-types.js +3 -0
  144. package/dist/commands/worker/backends/web-types.js.map +1 -0
  145. package/dist/commands/worker/backends/web.d.ts +26 -0
  146. package/dist/commands/worker/backends/web.js +178 -0
  147. package/dist/commands/worker/backends/web.js.map +1 -0
  148. package/dist/commands/worker/config.js +12 -5
  149. package/dist/commands/worker/config.js.map +1 -1
  150. package/dist/commands/worker/control.d.ts +2 -0
  151. package/dist/commands/worker/control.js +11 -4
  152. package/dist/commands/worker/control.js.map +1 -1
  153. package/dist/commands/worker/coordinator.d.ts +10 -1
  154. package/dist/commands/worker/coordinator.js +153 -24
  155. package/dist/commands/worker/coordinator.js.map +1 -1
  156. package/dist/commands/worker/herdr/agents.js +5 -4
  157. package/dist/commands/worker/herdr/agents.js.map +1 -1
  158. package/dist/commands/worker/herdr/arguments.js +9 -4
  159. package/dist/commands/worker/herdr/arguments.js.map +1 -1
  160. package/dist/commands/worker/herdr/claude-input.d.ts +2 -0
  161. package/dist/commands/worker/herdr/claude-input.js +20 -0
  162. package/dist/commands/worker/herdr/claude-input.js.map +1 -0
  163. package/dist/commands/worker/herdr/command.d.ts +11 -2
  164. package/dist/commands/worker/herdr/command.js +23 -8
  165. package/dist/commands/worker/herdr/command.js.map +1 -1
  166. package/dist/commands/worker/herdr/instance.d.ts +5 -1
  167. package/dist/commands/worker/herdr/instance.js +31 -1
  168. package/dist/commands/worker/herdr/instance.js.map +1 -1
  169. package/dist/commands/worker/herdr/preflight.d.ts +1 -1
  170. package/dist/commands/worker/herdr/preflight.js +34 -15
  171. package/dist/commands/worker/herdr/preflight.js.map +1 -1
  172. package/dist/commands/worker/herdr/version-probe.d.ts +13 -0
  173. package/dist/commands/worker/herdr/version-probe.js +21 -0
  174. package/dist/commands/worker/herdr/version-probe.js.map +1 -0
  175. package/dist/commands/worker/herdr.js +7 -7
  176. package/dist/commands/worker/herdr.js.map +1 -1
  177. package/dist/commands/worker/index.d.ts +2 -0
  178. package/dist/commands/worker/index.js +1 -1
  179. package/dist/commands/worker/index.js.map +1 -1
  180. package/dist/commands/worker/prompts.js +5 -1
  181. package/dist/commands/worker/prompts.js.map +1 -1
  182. package/dist/commands/worker/remote.d.ts +3 -1
  183. package/dist/commands/worker/remote.js +4 -0
  184. package/dist/commands/worker/remote.js.map +1 -1
  185. package/dist/commands/worker/reporter.d.ts +14 -0
  186. package/dist/commands/worker/reporter.js +174 -0
  187. package/dist/commands/worker/reporter.js.map +1 -0
  188. package/dist/commands/worker/repositories.js +2 -2
  189. package/dist/commands/worker/repositories.js.map +1 -1
  190. package/dist/commands/worker/runtime.d.ts +2 -0
  191. package/dist/commands/worker/runtime.js +76 -11
  192. package/dist/commands/worker/runtime.js.map +1 -1
  193. package/dist/commands/worker/setup-environment.d.ts +2 -1
  194. package/dist/commands/worker/setup-environment.js +10 -4
  195. package/dist/commands/worker/setup-environment.js.map +1 -1
  196. package/dist/commands/worker/setup.js +5 -5
  197. package/dist/commands/worker/setup.js.map +1 -1
  198. package/dist/commands/worker/store.d.ts +2 -1
  199. package/dist/commands/worker/store.js +19 -9
  200. package/dist/commands/worker/store.js.map +1 -1
  201. package/dist/commands/worker/telemetry.d.ts +22 -0
  202. package/dist/commands/worker/telemetry.js +265 -0
  203. package/dist/commands/worker/telemetry.js.map +1 -0
  204. package/dist/commands/worker/types.d.ts +4 -1
  205. package/dist/session/controller-protocol.d.ts +245 -0
  206. package/dist/session/controller-protocol.js +218 -0
  207. package/dist/session/controller-protocol.js.map +1 -0
  208. package/dist/session/controls.d.ts +28 -0
  209. package/dist/session/controls.js +37 -0
  210. package/dist/session/controls.js.map +1 -0
  211. package/dist/session/protocol.d.ts +290 -0
  212. package/dist/session/protocol.js +307 -0
  213. package/dist/session/protocol.js.map +1 -0
  214. package/package.json +7 -2
@@ -1,182 +1,85 @@
1
1
  # Task content standard
2
2
 
3
- Read this reference when creating, breaking down, handing off, or executing a
4
- task. The description and its readable references must explain the task without
5
- the originating chat, memory, private worktree, or temporary files. Use the
6
- target repository's document and language rules.
3
+ Applies to creation, breakdown, handoff, and execution.
4
+ Descriptions and their actual references should let an independent reader understand the task without the original chat, private worktrees, or temporary files.
5
+ Follow the target repository's documentation and language rules.
7
6
 
8
7
  ## Task and session boundary
9
8
 
10
- Tasks describe what must be achieved and delivered. Sessions hold how the task
11
- is executed or discussed. Keep task definitions, required inputs, deliverables,
12
- acceptance criteria, and resulting artifacts in task content. Keep execution and
13
- discussion plans, steps, tool choices, collaboration, operational authorization,
14
- progress, blockers, and recovery context in the session. Apply this boundary to
15
- descriptions, attachments, and referenced task material.
16
-
17
- A design supplied as a required input or produced as the task's deliverable is
18
- task content; the session's plan for producing that deliverable is session
19
- context. Classify information by its purpose, not its filename or words such as
20
- "plan", "method", or "steps". A requested migration design, test strategy, or
21
- runbook can be a task deliverable. Do not invent such a deliverable to upload a
22
- session checkpoint or execution log.
23
-
24
- | Information | Location |
25
- |---|---|
26
- | Required sorting behavior; an upstream API contract; a design task's current architecture | Task definition, input, or result |
27
- | "Register only; do not execute or enable agents in this session"; chosen commands, agent assignments, review rounds | Session context; current operations still obey its restrictions |
28
- | Required deliverable platform or compatibility threshold; a human-confirmation completion condition | Task scope or acceptance criteria |
29
- | Authorization to push or merge; CI/review progress, waiting items, claim/worktree/head and next action | Session context or the corresponding platform |
30
- | A final deliverable's immutable revision; an acceptance conclusion and the key observations needed to support it | Task result, without the execution history |
31
-
32
- Operational authorization does not become task content because another session
33
- might need it. Preserve it in the host's session state or existing local
34
- checkpoint. Missing authorization or assignment cannot be reconstructed from a
35
- task's description, attachments, acceptance state, or status.
36
-
37
- ## Task definition and results
38
-
39
- Provide the following substantive information in the description, clearly
40
- referenced documents, or a mixture of both. These are not mandatory headings.
41
- Complete inline content needs no primary attachment; do not duplicate complete
42
- documents or keep empty template sections.
43
-
44
- | Definition | Required information |
45
- |---|---|
46
- | Objective and requirements | The concrete problem, intended outcome, and required behavior. Use requirement IDs when they help acceptance. |
47
- | Scope and constraints | This task's responsibility and delivery boundaries, including constraints on the product or deliverable and applicable parts of shared documents. |
48
- | Inputs and sources | Actual required requirements, designs, prototypes, protocols, or deliveries, with accurate source identities, applicable sections, and purpose. |
49
- | Deliverables and contracts | Expected outputs, delivery and reading locations, and the structure and semantics needed by actual producers or consumers. Explicitly say when there is no task-to-task exchange. |
50
- | Acceptance criteria | Observable completion conditions, applicable success/failure/boundary behavior, required thresholds, and any human-confirmation gate. |
51
-
52
- Save results as they are produced: current reviewable requirements or designs,
53
- actual deliverables, acceptance conclusions, defects, and material limitations.
54
- An immutable revision or verified resource location may identify a result.
55
- Keep the accepted content and its effective state, not successive discussion or
56
- confirmation records. Acceptance results may include the assessed source and
57
- key observations needed to understand the conclusion; commands, debugging
58
- history, CI logs, and review handling remain execution context.
59
-
60
- A task does not universally require a separate solution, implementation plan,
61
- verification procedure, confirmation record, or evidence location. Its starting
62
- content depends on the stage and actual inputs. Do not require unfinished
63
- results or prefilled result sections at registration.
64
-
65
- The description must identify the concrete current work and responsibility and
66
- make its content sources discoverable. Judge completeness from the description
67
- and the contents actually read, not heading presence or whether the description
68
- repeats the documents. A bare generic problem plus unexplained links, "see the
69
- previous discussion", unreadable resources, and missing required decisions are
70
- insufficient. Absence of a session execution plan is not a task-content gap.
71
-
72
- ## Content ownership
73
-
74
- Each detailed explanation has one owner: the description, a referenced task
75
- attachment, or its actual shared source. Keep shared requirements, architecture,
76
- and protocols at their owning task. Save this task's results at their actual
77
- owner and make them discoverable from its description. Rewrite the owning
78
- material coherently when its facts change; do not accumulate an execution log.
79
-
80
- For example, an upload retry task may define its required behavior and
81
- acceptance inline and reference the architecture task's `design/upload.md` for
82
- shared interfaces. A design task may own that architecture in its description
83
- or an actual attachment. Neither needs an attachment containing the session's
84
- implementation steps. Those source identities and paths must be real and
85
- verified.
86
-
87
- ## Resolve and read sources
88
-
89
- Description-relative links and images start at the current task's attachment
90
- root; references inside a Markdown attachment start at its containing directory.
91
- Keep paths inside the task root and preserve case and resource identity. Confirm
92
- uploaded contents before adding their links. Shared task sources identify the
93
- owning task ID and content location: its description and applicable sections for
94
- inline content, or the complete attachment path for an actual attachment. Name
95
- the whole description when all of it applies; sections only delimit a larger
96
- source and do not require invented headings. Read source task descriptions with
97
- `task show --json`; list and read attachment contents separately with the
98
- installed attachment commands. Repository documents need accurate paths and the
99
- required verified immutable source revision. State the sections, requirements,
100
- or interfaces applicable to this task when a source covers more. Do not invent
101
- an attachment path for inline content, relocate or copy it merely to satisfy a
102
- reference format, or invent a URL scheme, cross-task relative link, or fixed
103
- service host.
104
-
105
- Read the required source contents, including further references needed for the
106
- current stage. Track already-read resource identities to avoid circular reading.
107
- A reference cycle that supplies no actual required content cannot pass. Limit
108
- traversal to this task's requirements; it does not authorize redesigning a Goal
109
- or executing related tasks. Resolve material conflicts between the description
110
- and sources or between sources before declaring the content sufficient.
111
-
112
- Every Goal delivery task's description must directly list the architecture task
113
- ID and all required architecture source locations, including indirect successors.
114
- For inline architecture, name the source task's description and applicable
115
- sections. For each actual required attachment document, include its full path;
116
- for repository architecture, retain the owning task ID and a verified immutable
117
- reference. An entry only in another task or inside an attachment is insufficient.
118
- [The Goal protocol](goal.md) owns this additional source-index requirement and
119
- its registration checks.
120
-
121
- ## Input and output contracts
122
-
123
- Describe actual exchanges rather than inventing an interface to fill a template.
124
- As applicable, include fields, types, requiredness, format or version, examples,
125
- and the units, states, errors, and null semantics needed by consumers. APIs, CLI
126
- output, files, database records, attachments, and design conclusions can all be
127
- exchanged outputs. Check the relevant producer and consumer explanations for
128
- consistency and distinguish their responsibilities.
129
-
130
- For example, an upload protocol may define a required multipart `file`, a
131
- 10 MiB limit, a `201` response containing a UUID `id`, `name`, and byte-count
132
- `size`, a nonretryable `413 file_too_large`, and a `503 temporarily_unavailable`
133
- that permits user-initiated retry. Provider and consumer tasks reference the same
134
- protocol and state their own delivery locations and availability.
135
-
136
- Necessary direct prerequisites remain in the complete `dependsOn` set and its
137
- `externalDependsOn` subset, following
138
- [the handbook's dependency reduction rule](handbook.md#dependency-reduction).
139
- Contract source identities do not form a second complete dependency list, and a
140
- source reference does not create an execution dependency. Use
141
- [the handbook](handbook.md) for relationship semantics. Existing status, PR,
142
- permission, platform, and worker fields keep their own service semantics; do not
143
- copy them into prose as a second operational record.
144
-
145
- ## Apply the current stage
146
-
147
- | Stage | Sufficient starting content | Stage results |
148
- |---|---|---|
149
- | Requirements discussion | Known problem, outcome, scope, constraints, open requirements questions, and completion conditions | Current and confirmed requirements and applicable prototype |
150
- | Solution or architecture discussion | Confirmed requirements, applicable prototype, design questions, intended deliverables, and completion conditions | Current architecture, key decisions, and delivery breakdown |
151
- | Implementation or document delivery | Defined requirements and scope, required design and applicable prototype, contracts, deliverables, and acceptance criteria | The scoped deliverable and its actual location or version |
152
- | Independent final acceptance | Whole agreed requirements and confirmed changes, actual deliveries, and acceptance criteria | Requirement-based conclusions, defects, and unverified items |
153
-
154
- A stage's unfinished outputs are not prerequisites for starting that stage.
155
- Preserve human confirmation as an actual completion condition where required;
156
- the execution protocol handles the confirmation action and advancement.
157
- Explicit prerequisite-produced implementation outputs may still be pending when
158
- preparing a blocked task, provided the necessary design and agreed interfaces
159
- already define the successor's work. Do not label future output as an existing
160
- readable input. Execution still waits for real prerequisites and required inputs.
161
-
162
- ## Check sufficiency
163
-
164
- Before reporting creation, breakdown, or handoff ready, check the task
165
- definition, source readability and applicability, existing result ownership, and
166
- the stage's additional conditions. Check both directions: session context stays
167
- out, and actual requirements, required design inputs, and task results remain
168
- complete. Unknown requirements, design choices, acceptance thresholds, and
169
- interface decisions are concrete blockers, not details to invent. Only organize
170
- confirmed information within existing authorization. A material scope or
171
- behavior change requires user confirmation.
172
-
173
- Apply the boundary when reading existing material and when authoring or
174
- rewriting authorized task content. It does not authorize bulk edits of historical
175
- tasks or automatic changes to fields, permissions, or recorded history.
176
-
177
- Task versions protect task metadata, not independently mutable attachments or
178
- cross-task references. Verify mutable contents before enabling permission and
179
- read the required contents again before execution. Reassess affected content
180
- when it changes. A content check is not an atomic freeze or permanent
181
- certification of future sources. [Handoff](handoff.md) owns permission-update
182
- and read-only re-audit behavior.
9
+ Tasks store what must be implemented and delivered; sessions store how to execute or discuss it.
10
+ Apply the same boundary to descriptions, attachments, and referenced material.
11
+
12
+ | Store in the task | Store in the session or relevant platform |
13
+ | --- | --- |
14
+ | Objectives, requirements, scope, delivery constraints, required inputs, acceptance criteria | Execution steps, tool choices, agent assignments, operational authorization |
15
+ | Current requirements or architecture, accepted conclusions and essential rationale, substantive open questions | Discussion rounds, confirmation process, debugging history, CI and review progress |
16
+ | Deliverables, immutable revisions, acceptance conclusions, key observations and limitations | Worktree, HEAD, claim, blocker, waiting, and recovery context |
17
+
18
+ Classify by purpose, not by filenames or words such as "plan" or "method".
19
+ User-requested migration designs, test strategies, and operating manuals can be deliverables; the session steps that produce them do not belong in tasks.
20
+ Do not invent delivery requirements to justify uploading execution logs.
21
+ Operational authorization still constrains current behavior, but does not become task content merely because a later session needs it.
22
+
23
+ ## Definitions and results
24
+
25
+ The description and readable references together provide the following information, without mandatory headings or empty templates:
26
+
27
+ | Information | Content |
28
+ | --- | --- |
29
+ | Objectives and requirements | Specific problem, expected outcome, required behavior, and requirement IDs when needed. |
30
+ | Scope and constraints | This task's responsibilities, delivery boundaries, and applicable shared constraints. |
31
+ | Inputs and sources | Source identifiers, locations, applicable sections, and purposes of genuinely required material. |
32
+ | Deliverables and contracts | Outputs, read locations, and semantics needed by producers and consumers; state when there is no exchange between tasks. |
33
+ | Acceptance criteria | Observable completion conditions, success and failure behavior, thresholds, and human confirmation points. |
34
+
35
+ The description must identify this task's specific work and where to find its sources.
36
+ When attachment delivery is not specified, complete inline content needs no primary attachment; references or a mix of inline content and references are also valid.
37
+ Do not duplicate complete documents.
38
+ The [complete delivery standard](autopilot-managed-task.md#complete-delivery-standard) governs managed tasks' attachment and separate review-file requirements; the general inline-content rule cannot waive them.
39
+ Generic questions, unexplained links, unreadable sources, or "see the previous discussion" are insufficient.
40
+
41
+ Save stage results promptly: current reviewable artifacts, accepted content and its effective status, actual deliverables, acceptance conclusions, and important limitations.
42
+ Each detailed explanation has one owner; rewrite it coherently when it changes rather than accumulating logs.
43
+ The requirements stage does not require completed requirements in advance, nor does the design stage require a completed design.
44
+ Do not present future prerequisite outputs as existing inputs. See the [Goal protocol](goal.md) for stage requirements.
45
+
46
+ ## Attachments and references
47
+
48
+ Task details contain neither an attachment listing nor attachment bytes; use `task attachment list/read` separately.
49
+ Uploading to the same path replaces the file.
50
+ See [write safety](write-safety.md#attachments-and-multi-step-operations) for content concurrency limits.
51
+
52
+ Relative links and images in a description resolve from this task's attachment root; references inside a Markdown attachment resolve from the file's directory.
53
+ Preserve case and actual resource paths, and do not escape the task root.
54
+ Upload and read back resources before adding links.
55
+ Preserve valid relative locations for prototype HTML, CSS, JavaScript, images, and other resources, and follow the [prototype requirements](create-task.md#prepare-content).
56
+
57
+ Keep shared inputs in their owning tasks and cite the owning task ID and source location: identify the description and applicable sections for inline content, the full path for actual attachments, and the exact path and required, verified immutable revision reference for repository sources.
58
+ Read source descriptions with `task show --json` and read attachments separately.
59
+ The whole description may be referenced when no section restriction is needed.
60
+ Do not invent attachments, cross-task relative links, URL schemes, or fixed service hosts, or copy or move content merely to satisfy formatting requirements.
61
+
62
+ Read further references genuinely needed by the current task, tracking resources already read to avoid cycles.
63
+ Reference cycles without substantive content cannot pass checks; resolve substantive conflicts between sources before declaring inputs sufficient.
64
+ See the [Goal protocol](goal.md#register-the-delivery-breakdown) for the additional architecture-index requirements for every Goal delivery task.
65
+
66
+ ## Markdown and exchange contracts
67
+
68
+ Descriptions use Markdown; the Web renders CommonMark/GFM and displays raw HTML as text.
69
+ The CLI/API preserves the original string and has no format field.
70
+ Preserve newlines, code, syntax, and valid references when replacing the full content.
71
+
72
+ Describe only exchanges that actually exist, specifying fields, types, requiredness, formats or versions, examples, units, statuses, errors, and null semantics as needed.
73
+ APIs, CLI output, files, databases, attachments, and design conclusions can all form contracts.
74
+ Verify consistent producer and consumer responsibilities; do not invent interfaces to fill a template.
75
+ Citing sources does not create execution dependencies; see [task management](task-management.md#dependency-classification) for relationship rules.
76
+
77
+ ## Content sufficiency
78
+
79
+ Before creation, handoff, or execution, check definitions, source readability and applicability, result ownership, and stage requirements.
80
+ Unknown requirements, interface decisions, design choices, and acceptance thresholds are specific gaps, not details to invent.
81
+ If completing a task requires an architecture or execution plan, it is a required input and cannot be omitted on the grounds that "session plans do not belong in tasks"; actual session steps still follow the content boundary.
82
+ Handle input gaps in managed tasks through the [user interaction workflow](autopilot-managed-task.md#request-user-interaction).
83
+
84
+ Organize confirmed information only within the authorized scope; substantive scope or behavior changes require user confirmation.
85
+ This standard does not authorize bulk rewrites of historical tasks or automatic changes to permissions, statuses, or records.
@@ -1,142 +1,50 @@
1
1
  # Shared task execution
2
2
 
3
- Read this reference after the selected execution mode establishes the task's
4
- identity. It owns required inputs, authorized work, delivery, results, and
5
- acceptance readiness. The execution mode owns starting or resuming the task,
6
- its final status operation, and returning to its caller.
3
+ Read this file after identifying the task in both ordinary and managed execution.
4
+ It governs shared inputs, work, results, and completion conditions; the mode-specific files govern startup, final status operations, interaction, and return.
5
+ Managed execution must also meet its [complete delivery standard](autopilot-managed-task.md#complete-delivery-standard).
7
6
 
8
- ## Read the task and stage inputs
7
+ ## Inputs and readiness
9
8
 
10
- Read the complete task and its actual required references under
11
- [the task content standard](task-content.md), including the task definition,
12
- actual required design inputs, acceptance criteria, and existing results. Its
13
- Markdown description must identify the concrete current work, responsibility,
14
- and content sources. Complete inline content needs no primary attachment;
15
- document-owned and mixed organization are valid when their combined contents
16
- provide the stage-appropriate task definition. A missing session execution plan
17
- is not a missing task input.
9
+ Read the complete task, actually required references, and existing results under the [task content standard](task-content.md).
10
+ For Goal tasks, also apply the [stage protocol](goal.md) and check responsibilities, stage inputs, and the architecture index.
11
+ Inspect required prototypes with their assets and actually interact with them.
18
12
 
19
- Resolve description-relative links and images from the current task's attachment
20
- root; links inside a Markdown attachment use its own directory. Resolve real
21
- shared input references using the owning task ID and description/sections,
22
- complete paths for actual attachments, or a verified immutable repository
23
- reference. Read source descriptions through `task show --json` and actual
24
- attachment contents through the attachment commands; a task read does not load
25
- attachment inventory or bytes.
13
+ Verify status and all direct prerequisites under [task management](task-management.md), and apply [authorization and scope](authorization.md).
14
+ Execution is not ready when required content or authorization is missing, sources are unreadable, or dependencies are incomplete; report the specific blocker without executing predecessor tasks to bypass it.
26
15
 
27
- For a Goal stage or delivery task, read [the Goal protocol](goal.md) and identify
28
- its role from the actual task content and context. Apply that stage's input and
29
- output requirements. Requirements and solution discussions start from their
30
- stage briefs; the completed requirements, applicable UI prototype, and
31
- architecture are outputs of the stages that produce them. Delivery tasks
32
- require the delivered design and applicable prototype. Before implementation,
33
- read every required architecture source listed in the delivery task's
34
- description: the owning architecture task's inline description and applicable
35
- sections, full paths for actual attachment documents, or verified immutable
36
- repository references. This also applies when the architecture task is only an
37
- indirect prerequisite. Confirm that the description's references satisfy the
38
- Goal protocol. When a prototype is a required input, view and exercise it with
39
- its resources. An unfinished output of the current stage is not a missing input.
16
+ ## Work and results
40
17
 
41
- ## Verify prerequisites and scope
18
+ Work within the confirmed scope, design, and acceptance criteria, following the target repository's rules for worktrees, implementation, research, review, verification, and delivery.
19
+ For independent final acceptance, apply the [acceptance standard](final-acceptance.md), not inapplicable development workflows.
42
20
 
43
- Check state, every direct prerequisite, authorized scope, and required stage
44
- inputs. Read `dependsOn` and its `externalDependsOn` subset: ordinary edges
45
- express same-chain prerequisites, and external marks distinguish verified
46
- cross-chain ownership. Both kinds must be done before starting or completing
47
- work. Classification never grants permission to execute a prerequisite, enable
48
- automatic execution, or remove a blocker.
21
+ When authorized changes occur, coherently rewrite the actual owning material and affected references, preserving the strength of requirements and acceptance criteria; reconfirm material revisions at the corresponding confirmation points.
22
+ Follow [task management](task-management.md) and [write safety](write-safety.md) when updating fields and editing dependencies.
49
23
 
50
- Missing required content, an unreadable required source, or a missing required
51
- architecture reference or input leaves execution unready. Resolve it within
52
- existing authorization or return the concrete issue. Do not infer requirements
53
- from a title or silently invent acceptance criteria. Do not execute prerequisites
54
- as an implicit expansion of the requested task.
24
+ When creating a PR, its description must clearly explain the problem being solved and how the change addresses it.
25
+ If the PR is associated with a Daynight task, include the task's ID and title.
55
26
 
56
- Before analysis, questions, or proposals, establish this task's confirmed scope
57
- and acceptance criteria and apply the [shared scope constraint](../SKILL.md#shared-constraints)
58
- to execution and discussion.
27
+ Save the URLs and titles of all required delivery PRs in the complete `properties.pullRequests` list, preserving existing entries. Save actual deliverables, current conclusions, and acceptance results in the owning task's material; keep implementation steps, CI, reviews, merge handling, and operational authorization in the session or corresponding platform under the content standard.
59
28
 
60
- ## Execute and maintain continuity
29
+ ## Completion conditions
61
30
 
62
- Identify [final acceptance](../SKILL.md#final-acceptance) from the task's confirmed
63
- outcome before applying a development or PR delivery lifecycle. Read the complete
64
- requirements and actual deliveries for the task or Goal being assessed, and
65
- apply the shared rule to verification methods, temporary helpers, and result
66
- ownership.
31
+ | Task type | Completion conditions |
32
+ | --- | --- |
33
+ | Goal discussion | The user confirms the current material, and the corresponding Goal stage requirements are met; generic PR rules cannot replace or add confirmation requirements. |
34
+ | PR delivery | The hosting platform confirms that all required delivery PRs are merged, and stage acceptance criteria are met; finished code, passing CI, approval, an open PR, or entry into a merge queue is not enough. |
35
+ | No PR delivery | Meet stage acceptance criteria and the selected mode's delivery requirements, without inventing PRs or unrelated approvals. |
36
+ | Final acceptance | Also meet the [acceptance requirements](final-acceptance.md) for the complete task or Goal. |
67
37
 
68
- Follow the target repository's instructions for worktrees, implementation,
69
- review, validation, and delivery. Use the task's required design inputs and
70
- acceptance criteria, including applicable final-style prototype interactions.
71
- Keep the implementation or discussion plan in the session.
72
- Requirements discussion defines the problem without architecture decisions or
73
- production implementation. Solution discussion keeps its draft architecture and
74
- breakdown in its owning task. Preserve the Goal's user-confirmation gates:
75
- completed text, a review result, or successful checks cannot replace the user's
76
- confirmation or authorize delivery. Keep an unconfirmed discussion in progress;
77
- a material revision after confirmation needs renewed user confirmation.
38
+ Verify actual merges through the hosting platform's native client or API, without assuming a specific platform.
39
+ When the user requires PRs to remain open for review or prohibits merging, deliver reviewable results and keep the task in progress, without enabling auto-merge.
40
+ Completion remains pending when permission is missing, verification is impossible, or merge conditions are unmet.
78
41
 
79
- Resolve material changes to the agreed solution or acceptance within the current
80
- authorization. Rewrite the owning artifact and affected task summaries and input
81
- references coherently. Preserve requirements; do not silently weaken acceptance.
82
- Descriptions remain self-contained Markdown task summaries. Preserve valid
83
- syntax, required task content, and actual resource references during full-field
84
- updates; confirm new or replaced resources before linking them. Apply the content
85
- boundary to authorized rewrites without modifying unrelated historical tasks.
86
- Dependency edits
87
- must follow the handbook's CLI replacement contract: read full D/E, retain needed
88
- ordinary D−E and external E declarations, submit their intended complete sets
89
- with the observed version, and read back both. Omit all dependency options for
90
- unrelated metadata updates. Keep detailed task content and produced results at
91
- their identified owners; shared inputs remain at their verified source.
42
+ Before returning to the mode-specific file for completion operations, confirm that required deliverables and acceptance conclusions are readable.
43
+ Completing a stage establishes only that stage's results, not completion of the whole Goal.
92
44
 
93
- Advance only this task. Subagents collaborate on it, and waiting for CI, review,
94
- approval, or merge remains part of it. Keep all required delivery PR URLs and
95
- titles in the complete `properties.pullRequests` list, preserving existing
96
- entries. Save actual task results and acceptance conclusions at their owners.
97
- Use verified artifact locations or immutable revisions when needed to identify
98
- the final deliverable. Rewrite current results coherently rather than
99
- accumulating an execution log. Keep operational authorization, implementation
100
- steps, CI/review/merge handling, progress, blockers, waiting items, and next
101
- action in the conversation or existing execution checkpoint, retaining the task
102
- ID and needed PR and workspace references. Recover authorization and assignment
103
- from that session context, not task material or status.
45
+ ## Waiting context
104
46
 
105
- ## Confirm acceptance readiness
106
-
107
- Goal requirements and solution discussion tasks use the user-confirmed material
108
- and stage acceptance in the Goal protocol. A generic repository PR rule does not
109
- add a PR-merge prerequisite to these Daynight discussions. If particular
110
- repository artifacts or PR delivery are explicitly part of that discussion
111
- task's acceptance, honor that requirement under its delivery rules.
112
- Unconfirmed discussion material keeps its discussion task in progress.
113
-
114
- Development tasks and design or documentation delivery tasks with PRs remain
115
- in progress until the hosting platform confirms **every necessary delivery PR
116
- is merged** and all stage acceptance criteria are satisfied. Code completion,
117
- passing CI, approved review, and an open PR do not satisfy this condition. Verify
118
- actual merge state through the host's native client or API; do not assume a
119
- particular host.
120
-
121
- Completion rules grant no merge, deployment, external communication, or mainline
122
- push permission. Follow existing authorization without asking again for actions
123
- it covers. If the user requests an open PR for review or forbids merging, deliver
124
- the reviewable PR and preserve the waiting checkpoint. Do not enable auto-merge.
125
- Missing permission, unavailable merge visibility, or an unmet merge check keeps
126
- completion pending and successors blocked.
127
-
128
- For tasks without a development or PR delivery path, use their stated stage
129
- acceptance. For [final acceptance](../SKILL.md#final-acceptance), also apply the
130
- shared whole-task or whole-Goal completion rule. In every case, confirm the
131
- required deliverables and acceptance conclusions are readable before returning
132
- to the execution mode's completion operation; retain operational verification
133
- in the session. Discussion completion establishes that stage's accepted
134
- output; it does not establish whole-Goal completion.
135
-
136
- ## Preserve waiting context
137
-
138
- Continue CI and review waits as this task. When progress requires external
139
- intervention, preserve the target, actual state, concrete blocker, existing work,
140
- and next action in the checkpoint, then return the waiting result through the
141
- selected execution mode. Do not declare completion or select other work to
142
- bypass a wait. Preserve the task ID through recovery and waiting.
47
+ CI, review, and merge waits belong to the current task; the execution mode defines continued waiting, signaling, and return behavior.
48
+ When intervention is needed, preserve the task ID, actual status, existing work, specific blocker, PR and workspace references, existing authorization, and next step in the session checkpoint, not a task execution log.
49
+ Recover the assignment and authorization from this context, not by inferring them from task status.
50
+ Waiting neither completes the task nor permits selecting other work.
@@ -0,0 +1,135 @@
1
+ # Task management
2
+
3
+ Covers query scope, metadata, lifecycle, and dependency semantics.
4
+ See [authorization and scope](authorization.md) for operational permissions.
5
+ Follow [write safety](write-safety.md) for all writes.
6
+ Consult the relevant `--help` for arguments and field-clearing syntax.
7
+
8
+ ## Task queries
9
+
10
+ | Read operation | Scope and limits |
11
+ | --- | --- |
12
+ | `task ready` | One capped page of candidate `todo` tasks whose direct prerequisites are all complete, ordered by creation, not relevance. An empty page does not rule out in-progress or blocked work. |
13
+ | `task list` | Traverse all matching pages. Excludes `done` by default; explicitly include completed tasks when checking for duplicates or inspecting history. |
14
+ | `task show` | A single task's full description, metadata, and exact version. Read it before operating on the selected task. |
15
+ | `task graph <task-id>` | The target's full bidirectionally connected component of ordinary dependencies, plus one layer of external prerequisites for those tasks. Includes all statuses without recursively expanding external tasks. |
16
+
17
+ Human-readable lists are summaries; JSON lists omit only `description`.
18
+ Ready results, task details, and write results that return tasks contain complete tasks.
19
+ Dependency graphs provide compact relationship context without full descriptions, PR properties, or versions and cannot replace task details. `--depends-only --json` returns only `id`, the full `dependsOn` set, and its `externalDependsOn` subset.
20
+ Graph nodes retain complete dependency references, which may point outside the graph; read the relevant tasks or their dependency graphs when those paths need assessment.
21
+ Reaching the graph limit fails the command rather than returning a truncated graph.
22
+ A candidate page or a single task cannot replace complete relationship verification.
23
+
24
+ Lists group tasks into in-progress, ready todo, blocked todo, and, when explicitly included, done.
25
+ These groups are not relevance rankings. See command help for filter syntax.
26
+
27
+ ## Metadata
28
+
29
+ `task update` cannot change status.
30
+ A supplied description or PR reference list fully replaces that field; retain content that must remain and omit unrelated fields.
31
+ PR URLs are paired with titles; see help for syntax.
32
+ See the [task content standard](task-content.md) for organizing descriptions and attachments.
33
+
34
+ | Field | Semantics and limits |
35
+ | --- | --- |
36
+ | `allowAgents` | Permission for automatic selection. False for new tasks and cannot be enabled during creation. Enable only after an explicit [handoff](handoff.md) review. Omitting it from an update preserves its value. |
37
+ | `requiredPlatform` | `null`, `windows`, `linux`, or `macos`; null means unrestricted. Can be specified during creation or updates and cleared during updates. |
38
+
39
+ Actual changes to either field are prohibited while `in_progress`.
40
+ Same-value requests preserve the version and timestamps, but stale versions still conflict.
41
+ Status operations and other metadata operations preserve these fields.
42
+
43
+ List and ready support filtering by automatic-execution permission and platform compatibility.
44
+ The service combines filters before pagination or candidate limits.
45
+ Platform compatibility includes unrestricted and exact-match tasks without changing dependency readiness.
46
+ Preserve filters across pages; do not locally filter a capped, unfiltered ready page.
47
+
48
+ Ordinary execution explicitly targeted by the user is not restricted by automatic-selection permission or platform compatibility, but must still satisfy dependency, input, and authorization requirements.
49
+ Automatic execution must use the actual runtime platform and recheck full task eligibility before starting.
50
+ Query arguments do not prove the actual environment; a Linux runtime in WSL is Linux.
51
+
52
+ ## Status and timing
53
+
54
+ New tasks are `todo`, have no approval status, and do not execute automatically.
55
+ Use `task set-status` to set `todo`, `in_progress`, or `done`.
56
+ Ordinary operations carry no claim; completion of a worker assignment must use [original-claim completion](autopilot-managed-task.md#complete-the-original-claim).
57
+ If either path is rejected, do not fall back to the other.
58
+
59
+ All direct prerequisites must be done before entering `in_progress` or `done`.
60
+ A completed prerequisite cannot be reopened while a direct successor is `in_progress` or `done`; successors are not modified automatically.
61
+
62
+ | Transition | Timing result |
63
+ | --- | --- |
64
+ | Enter `in_progress` | Start a new execution interval and clear the completion time. |
65
+ | Return to `todo` | Clear the start and completion times. |
66
+ | `in_progress` -> `done` | Preserve the nullable start time and record the completion time. |
67
+ | `todo` -> `done` | Record only the completion time; elapsed time is unknown. |
68
+
69
+ An actual status change increments the version once; a same-status operation with the current version changes no fields.
70
+ Metadata updates and same-status operations preserve timing.
71
+ Ordinary status changes have no process ownership, release, withdrawal, stop, or lease semantics.
72
+
73
+ ## Dependency classification
74
+
75
+ `dependsOn` is the set D of all direct prerequisites, and `externalDependsOn` is its external subset E; ordinary dependencies are D minus E.
76
+ These are normalized UUID sets without duplicates or ordering semantics.
77
+
78
+ Ordinary dependencies belong to the same task chain; external dependencies are verified cross-chain prerequisites within the same project, not cross-project references.
79
+ Both kinds block starting and completion and participate in cycle and access checks.
80
+ Verify actual content and ownership; do not infer classification from done status, similar titles, graph roots, or connected components.
81
+
82
+ ### CLI relationship replacement
83
+
84
+ `--depends-on` supplies the ordinary set, and `--external-depends-on` supplies the external set.
85
+ Supplying either option replaces all relationships and their classification: supplying only the ordinary option clears the external subset; supplying only the external option retains only those external relationships.
86
+ This is not an append operation.
87
+
88
+ Before editing, read the full D/E sets, compute D minus E, and declare every relationship that must remain with its intended classification.
89
+ Duplicate UUIDs, including equivalent UUIDs repeated across options, fail.
90
+ Omitting both options preserves relationships; the dependency-clearing option empties both sets and cannot be combined with dependency declarations.
91
+ After writing, [verify dependency changes](#verify-dependency-changes) across the complete relationships.
92
+
93
+ Partial updates through direct API patches differ from CLI semantics; do not infer that the CLI preserves undeclared relationships.
94
+ Omit all dependency options when updating only other metadata.
95
+
96
+ ### Dependency reduction
97
+
98
+ Before creating tasks, registering a Goal breakdown, or changing dependencies, read the relevant dependency paths and retain only necessary direct prerequisites.
99
+ In `A -> B -> C`, arrows point from prerequisites to successors; C declares only B, not A again.
100
+
101
+ An ordinary edge is redundant only when another path consisting entirely of ordinary edges supplies the same prerequisite; an external edge may be supplied by an alternative path containing either kind of edge.
102
+ Preserve classification and check that all necessary paths still exist after reduction.
103
+ Source references do not require extra execution dependencies; this rule does not authorize cleaning up unrelated existing relationships.
104
+
105
+ ### Verify dependency changes
106
+
107
+ After creating, replacing, or clearing dependencies, you must call `task graph` to read back the actual dependency graphs of the tasks involved, for example:
108
+
109
+ ```bash
110
+ daynight task graph <task-id> --depends-only --json
111
+ ```
112
+
113
+ Compare the D/E sets and classification with expectations, check that required prerequisite paths are complete, and check for direct edges removable under the reduction rules.
114
+ Disconnecting relationships may split the graph into multiple components; read each component starting from the tasks involved, not just the portion still connected to one starting task after the change.
115
+ Also read any paths outside the graph that require verification; an absent node does not prove that a dependency is missing or that no redundancy exists.
116
+
117
+ Do not report dependency checks as passed if graph reads fail or required paths remain unverified.
118
+ If missing or redundant relationships are found, reread task details, decide on changes, and verify again only within the authorized scope.
119
+ Consult `daynight task graph --help` for command arguments.
120
+
121
+ ## Task deletion
122
+
123
+ `task delete` soft-deletes a task, removing it from ordinary lists, dependency graphs, ready results, and detail access while retaining stored data, its own prerequisite references, and attachments.
124
+ Deletion is independent of status and is not completion.
125
+
126
+ Deletion is strict by default: it is rejected if any undeleted task has a dependency pointing to the target.
127
+ When `--remove-depends` is explicitly authorized, the same transaction deletes the target and removes other tasks' ordinary and external dependencies on it, including references added before the transaction; this may make successors ready.
128
+ Tasks whose relationships change increment their versions while preserving status, timing, worker ownership, and other fields.
129
+
130
+ Deletion is always prohibited while the target has an active worker claim.
131
+ Reconsider deletion only after the stopped worker is released through an authorized management workflow; status changes cannot replace release.
132
+
133
+ Successful deletion returns neither a task resource nor a count of removed references.
134
+ If the response is uncertain, read the task: `410 task_deleted` confirms deletion; if the task still exists, decide again; permission or transport failures leave the outcome unconfirmed.
135
+ Do not equate inaccessibility or absence with deletion, and do not automatically replay deletion.