@codetreker/daynight 0.26.0 → 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.
- package/README.md +56 -11
- package/dist/api/client.d.ts +3 -2
- package/dist/api/client.js +8 -4
- package/dist/api/client.js.map +1 -1
- package/dist/api/parse.d.ts +3 -2
- package/dist/api/parse.js +45 -8
- package/dist/api/parse.js.map +1 -1
- package/dist/api/types.d.ts +71 -0
- package/dist/commands/skill/skills/using-daynight/SKILL.md +52 -162
- package/dist/commands/skill/skills/using-daynight/references/authorization.md +36 -0
- package/dist/commands/skill/skills/using-daynight/references/autopilot-managed-task.md +77 -193
- package/dist/commands/skill/skills/using-daynight/references/create-task.md +31 -186
- package/dist/commands/skill/skills/using-daynight/references/final-acceptance.md +25 -0
- package/dist/commands/skill/skills/using-daynight/references/goal.md +46 -243
- package/dist/commands/skill/skills/using-daynight/references/handbook.md +37 -294
- package/dist/commands/skill/skills/using-daynight/references/handoff.md +33 -91
- package/dist/commands/skill/skills/using-daynight/references/project-management.md +24 -0
- package/dist/commands/skill/skills/using-daynight/references/run-task.md +18 -59
- package/dist/commands/skill/skills/using-daynight/references/setup.md +16 -0
- package/dist/commands/skill/skills/using-daynight/references/task-content.md +80 -177
- package/dist/commands/skill/skills/using-daynight/references/task-execution.md +34 -126
- package/dist/commands/skill/skills/using-daynight/references/task-management.md +135 -0
- package/dist/commands/skill/skills/using-daynight/references/write-safety.md +34 -0
- package/dist/commands/task/command.js +5 -3
- package/dist/commands/task/command.js.map +1 -1
- package/dist/commands/task/definition.js +4 -2
- package/dist/commands/task/definition.js.map +1 -1
- package/dist/commands/task/rendering.d.ts +1 -0
- package/dist/commands/task/rendering.js +10 -1
- package/dist/commands/task/rendering.js.map +1 -1
- package/dist/commands/worker/coordinator.d.ts +3 -1
- package/dist/commands/worker/coordinator.js +15 -5
- package/dist/commands/worker/coordinator.js.map +1 -1
- package/dist/commands/worker/herdr/command.d.ts +11 -2
- package/dist/commands/worker/herdr/command.js +23 -8
- package/dist/commands/worker/herdr/command.js.map +1 -1
- package/dist/commands/worker/herdr/instance.d.ts +5 -1
- package/dist/commands/worker/herdr/instance.js +30 -0
- package/dist/commands/worker/herdr/instance.js.map +1 -1
- package/dist/commands/worker/herdr/preflight.js +4 -6
- package/dist/commands/worker/herdr/preflight.js.map +1 -1
- package/dist/commands/worker/herdr/version-probe.d.ts +13 -0
- package/dist/commands/worker/herdr/version-probe.js +21 -0
- package/dist/commands/worker/herdr/version-probe.js.map +1 -0
- package/dist/commands/worker/herdr.js +2 -6
- package/dist/commands/worker/herdr.js.map +1 -1
- package/dist/commands/worker/index.d.ts +2 -0
- package/dist/commands/worker/index.js +1 -1
- package/dist/commands/worker/index.js.map +1 -1
- package/dist/commands/worker/remote.d.ts +3 -1
- package/dist/commands/worker/remote.js +4 -0
- package/dist/commands/worker/remote.js.map +1 -1
- package/dist/commands/worker/reporter.d.ts +14 -0
- package/dist/commands/worker/reporter.js +174 -0
- package/dist/commands/worker/reporter.js.map +1 -0
- package/dist/commands/worker/runtime.d.ts +2 -0
- package/dist/commands/worker/runtime.js +14 -1
- package/dist/commands/worker/runtime.js.map +1 -1
- package/dist/commands/worker/telemetry.d.ts +22 -0
- package/dist/commands/worker/telemetry.js +265 -0
- package/dist/commands/worker/telemetry.js.map +1 -0
- package/package.json +2 -2
|
@@ -1,294 +1,37 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
Use the installed `daynight` CLI.
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
|
22
|
-
|
|
|
23
|
-
|
|
|
24
|
-
|
|
|
25
|
-
|
|
|
26
|
-
| `task
|
|
27
|
-
|
|
|
28
|
-
| `task
|
|
29
|
-
| `task
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
credential never expires by default. The Web account's token manager can set a
|
|
39
|
-
future expiry, restore “Never expires”, or revoke it; changing expiry preserves the same
|
|
40
|
-
credential and does not require another login. Expired or revoked credentials
|
|
41
|
-
cannot be revived. `daynight logout` revokes the current credential and clears its saved value
|
|
42
|
-
after confirmation or an already-invalid response; network or unconfirmed
|
|
43
|
-
failures remain visible. Login does not execute any pending business operation.
|
|
44
|
-
|
|
45
|
-
A service command without a saved credential fails before dispatch and points
|
|
46
|
-
to `daynight login`; a server 401 gives the same guidance. Do not automatically
|
|
47
|
-
start login, retry anonymously, or blindly repeat a mutation. Reconcile an
|
|
48
|
-
unconfirmed write before another mutation. Project discovery and explicit project
|
|
49
|
-
IDs grant no access; current service membership decides authorization.
|
|
50
|
-
|
|
51
|
-
For a test service or noninteractive automation, provision the existing
|
|
52
|
-
`serverUrl` and `serverToken` fields in `~/.daynight/config.yml` through a trusted
|
|
53
|
-
configuration or secret source. Omit `serverUrl` only for `https://daynight.cc`.
|
|
54
|
-
Never put a token in command arguments, chat, task descriptions, checkpoints or
|
|
55
|
-
attachments. Keep credential files private, with POSIX mode `0600`. Pair each
|
|
56
|
-
credential with its intended normalized origin; when changing services externally,
|
|
57
|
-
remove or replace the old token before another request. External file writes do
|
|
58
|
-
not run CLI credential cleanup or participate in its write lock. Credentials
|
|
59
|
-
require HTTPS except for literal localhost or numeric-loopback HTTP. File
|
|
60
|
-
provisioning performs no network or login checks. There is no top-level `setup`
|
|
61
|
-
command; `completion setup` remains the independent shell startup installer.
|
|
62
|
-
|
|
63
|
-
**Project discovery.** Inside a Git worktree, task commands can omit `--project`:
|
|
64
|
-
the CLI matches the origin repository URL to a project on the configured
|
|
65
|
-
service. An explicit project overrides discovery for that invocation. Resolve
|
|
66
|
-
missing or ambiguous matches rather than guessing an ID or creating a project
|
|
67
|
-
to make a query succeed.
|
|
68
|
-
|
|
69
|
-
**Read scope.** Ready is a candidate page of todo tasks, ordered by
|
|
70
|
-
creation rather than relevance. An empty page does not rule out in-progress or dependency-blocked work. List traverses every matching page but
|
|
71
|
-
excludes `done` by default; include completed tasks explicitly when checking the
|
|
72
|
-
full backlog or prior registrations. Its grouping is in-progress, ready todo,
|
|
73
|
-
blocked todo, then done when included; this does not rank relevance.
|
|
74
|
-
Human lists are summaries; JSON lists omit only `description` and preserve every
|
|
75
|
-
other task field. Use show when a description is needed; ready, details and write
|
|
76
|
-
results retain full tasks. Graph provides compact dependency context without
|
|
77
|
-
full descriptions, PR properties, or versions. Read the selected task's details
|
|
78
|
-
before acting. A graph-limit error still permits bounded candidate and
|
|
79
|
-
individual task reads.
|
|
80
|
-
|
|
81
|
-
**Task status.** Creation starts in `todo` with no task approval stage and does
|
|
82
|
-
not start execution. `task set-status <task-id> <status> --if-version <version>`
|
|
83
|
-
sets any of `todo`, `in_progress`, or `done` through ordinary status setting.
|
|
84
|
-
To finish an explicitly supplied active worker claim, use
|
|
85
|
-
`task set-status <task-id> done --claim-id <claim-id> --if-version <version>`.
|
|
86
|
-
The claim ID must be a UUID and is valid only with `done`; the CLI never infers
|
|
87
|
-
it from task data or the environment. This path uses the existing worker
|
|
88
|
-
completion operation: a real completion requires the current owner, active
|
|
89
|
-
claim, in-progress task, and exact version, and retains worker history with
|
|
90
|
-
`state=completed`. Omit `--claim-id` for ordinary status setting; refusal never
|
|
91
|
-
causes fallback between these operations. Read the
|
|
92
|
-
[managed autopilot reference](autopilot-managed-task.md) only when the worker
|
|
93
|
-
startup prompt explicitly selects that mode; ordinary status operations do not
|
|
94
|
-
load its execution rules. A valid worker-managed assignment already has sufficient
|
|
95
|
-
authorization for its in-scope delivery and PR merge. Its executor merges once the
|
|
96
|
-
required checks, current-head approvals, blocking-thread resolution, and
|
|
97
|
-
mergeability conditions are met without requesting additional permission, while
|
|
98
|
-
honoring explicit user restrictions, pause, and revocation.
|
|
99
|
-
|
|
100
|
-
The service checks the exact version
|
|
101
|
-
before a same-status no-op; it preserves all fields for a current-version no-op
|
|
102
|
-
and refuses stale versions. A real change increments the version once. Generic
|
|
103
|
-
metadata updates cannot write status. Status, materials, and readiness grant no
|
|
104
|
-
implementation, publication, deployment, or merge permission.
|
|
105
|
-
|
|
106
|
-
Entering in_progress or done requires every direct prerequisite done. Reopening
|
|
107
|
-
done to todo or in_progress is refused when a direct successor is in_progress or
|
|
108
|
-
done; successors are never changed automatically. Entering in_progress starts a
|
|
109
|
-
new execution interval and clears completion; returning to todo clears both
|
|
110
|
-
endpoints. In_progress to done retains the nullable start and records completion.
|
|
111
|
-
Todo to done records only completion, with unknown duration. Same-status and
|
|
112
|
-
metadata updates preserve timing. Ordinary status changes provide no process ownership,
|
|
113
|
-
release, withdrawal, stop, or lease semantics. The Web confirms every status choice,
|
|
114
|
-
including the current status; cancel and Escape submit no request.
|
|
115
|
-
|
|
116
|
-
**Task deletion.** `task delete <task-id> [--remove-depends] --if-version <version>`
|
|
117
|
-
removes a task from normal lists, graphs, readiness, and detail access while
|
|
118
|
-
retaining its stored data, its own prerequisite references, and attachment files.
|
|
119
|
-
Deletion is independent of the task's status. Without `--remove-depends`, an
|
|
120
|
-
undeleted task depending on the target prevents deletion; a task with no such
|
|
121
|
-
references can be deleted directly. The service checks this in the deletion
|
|
122
|
-
transaction; the CLI does not download the graph to decide whether deletion is
|
|
123
|
-
allowed.
|
|
124
|
-
|
|
125
|
-
`--remove-depends` is an optional switch with no value. It explicitly authorizes
|
|
126
|
-
removing all other tasks' ordinary and external dependencies on the target in the
|
|
127
|
-
same transaction as soft deletion, including references added before that
|
|
128
|
-
transaction executes. This can make affected tasks ready. Each task whose
|
|
129
|
-
relationships change receives a new version; its status, execution times, worker
|
|
130
|
-
ownership, and other data are preserved. The target's own prerequisite references
|
|
131
|
-
are retained. An active worker claim on the target always prevents deletion;
|
|
132
|
-
release the stopped worker through the authorized workflow before reconsidering
|
|
133
|
-
it. Deleting a task requires explicit user authorization for that task; removing
|
|
134
|
-
other tasks' dependencies requires that additional authorization. Deletion is not
|
|
135
|
-
a completion action.
|
|
136
|
-
|
|
137
|
-
Read the full task and preserve the exact version used for the deletion decision.
|
|
138
|
-
Without `--if-version`, the CLI reads the latest version immediately before
|
|
139
|
-
submitting; that read cannot protect an earlier decision. A successful deletion
|
|
140
|
-
returns no task resource or removed-reference count. An authorized read of a
|
|
141
|
-
deleted task returns `410 task_deleted`, distinct from a missing task or
|
|
142
|
-
inaccessible project. On a lost response, GET the task to reconcile:
|
|
143
|
-
`task_deleted` confirms it is deleted; a live resource requires a new decision,
|
|
144
|
-
and a permission or transport failure leaves the outcome unconfirmed. Never
|
|
145
|
-
replay deletion automatically. The Web confirmation explicitly authorizes
|
|
146
|
-
removing other tasks' dependencies together with deletion; the CLI submits its
|
|
147
|
-
selected mode directly.
|
|
148
|
-
|
|
149
|
-
**Automatic execution permission.** Tasks expose the required boolean
|
|
150
|
-
`allowAgents`, independent of status and dependency readiness. New tasks
|
|
151
|
-
start false; public creation cannot set it. Existing tasks receive true through
|
|
152
|
-
the database migration. Use `task update <task-id> --allow-agents true|false --if-version <version>` only
|
|
153
|
-
for an explicitly authorized permission change.
|
|
154
|
-
Omission preserves the current value, including explicit false. Actual changes
|
|
155
|
-
are locked during in_progress; exact-version same-value requests keep the
|
|
156
|
-
version and timestamps, while stale versions still conflict. Status changes and other metadata updates preserve the flag.
|
|
157
|
-
|
|
158
|
-
`task list` and `task ready` accept `--allow-agents true|false`. The server
|
|
159
|
-
combines that condition with other filters before pagination and the ready limit;
|
|
160
|
-
an unfiltered ready page may contain tasks without automatic-execution permission.
|
|
161
|
-
Automatic selection requires true and does not enable permission itself.
|
|
162
|
-
Only explicitly authorized [handoff](handoff.md) reviews the task against
|
|
163
|
-
[the content standard](task-content.md) before enabling it; creation, breakdown,
|
|
164
|
-
and execution do not do so implicitly. An explicitly user-selected task may still
|
|
165
|
-
use manual execution regardless of the flag. Permission does not grant execution, publication or merge authority.
|
|
166
|
-
A lost permission PATCH response is an unconfirmed write: read actual task state
|
|
167
|
-
before reconsidering the operation, without resubmitting automatically.
|
|
168
|
-
|
|
169
|
-
**Execution platform.** Complete tasks, inventory items and graph nodes expose
|
|
170
|
-
`requiredPlatform` as `null`, `windows`, `linux` or `macos`; null means unrestricted.
|
|
171
|
-
Set a requirement with `task create --required-platform <platform>` or
|
|
172
|
-
`task update <task-id> --required-platform <platform> --if-version <version>`.
|
|
173
|
-
Clear it with `task update <task-id> --clear-required-platform --if-version <version>`;
|
|
174
|
-
setting and clearing in one command is invalid. Omitting both update options
|
|
175
|
-
preserves the requirement. Existing and new tasks without a requirement are
|
|
176
|
-
unrestricted. Actual changes are locked during in_progress; an exact-version
|
|
177
|
-
same-value request keeps version and timestamps, while stale versions conflict.
|
|
178
|
-
Explicitly user-selected tasks and fixed queues retain their manual execution
|
|
179
|
-
path independently of platform compatibility. Automatic selections keep their
|
|
180
|
-
actual-platform context and recheck full-task eligibility before set-status.
|
|
181
|
-
|
|
182
|
-
`task list` and `task ready` accept `--compatible-platform <platform>`. The
|
|
183
|
-
server includes unrestricted tasks and exact matches, combining this condition
|
|
184
|
-
with status, readiness and `--allow-agents` before pagination or the ready limit.
|
|
185
|
-
Platform compatibility does not change readiness or enable automatic execution.
|
|
186
|
-
Preserve the filter when requesting additional candidate inventory; do not filter
|
|
187
|
-
a bounded unfiltered ready page locally. A query option selects a candidate
|
|
188
|
-
platform and does not establish the actual execution environment. Worker runtime
|
|
189
|
-
must identify its own platform; a Linux runtime in WSL is Linux.
|
|
190
|
-
|
|
191
|
-
**Task concurrency.** Bind each metadata update and status change to
|
|
192
|
-
the exact version read for that decision using `--if-version`; the CLI's default
|
|
193
|
-
pre-submit read cannot protect an earlier decision. Preserve full int64 decimal
|
|
194
|
-
digits without numeric rounding. Entering in_progress is a versioned transition, not an
|
|
195
|
-
assignee lock, renewable lease or proof that existing work belongs to this
|
|
196
|
-
session. On a conflict, reread and reconsider; a new action needs a fresh
|
|
197
|
-
decision, not merely a newer version. Never retry a mutation automatically.
|
|
198
|
-
|
|
199
|
-
**Dependency classification.** `dependsOn` contains every direct prerequisite;
|
|
200
|
-
`externalDependsOn` is its explicit external subset. Ordinary prerequisites are
|
|
201
|
-
`dependsOn` minus that subset. Both are canonical, duplicate-free UUID sets,
|
|
202
|
-
not insertion order. Every prerequisite must be done before entering in_progress or done,
|
|
203
|
-
including external ones; cycle checks and project access rules use all edges.
|
|
204
|
-
External means cross-chain within the same project, not a cross-project
|
|
205
|
-
reference. It separates chain ownership, not blocking or authorization. Use
|
|
206
|
-
ordinary relationships for confirmed same-chain work and external relationships
|
|
207
|
-
for verified prerequisites owned by another chain. Confirm task content and
|
|
208
|
-
ownership; done status, a similar title, current graph roots or the displayed
|
|
209
|
-
component do not establish the classification.
|
|
210
|
-
|
|
211
|
-
### Dependency reduction
|
|
212
|
-
|
|
213
|
-
When creating tasks or registering a Goal breakdown, keep only necessary direct
|
|
214
|
-
prerequisites. Read the relevant dependency paths before writing. In
|
|
215
|
-
`A → B → C`, arrows run from prerequisite to successor: C declares B, not both A
|
|
216
|
-
and B. Omit `A → C` because the retained path already supplies A. Keep independent
|
|
217
|
-
prerequisites that have no alternative path.
|
|
218
|
-
|
|
219
|
-
An ordinary edge is redundant only when another path made entirely of ordinary
|
|
220
|
-
edges supplies the same prerequisite; this preserves chain ownership and the
|
|
221
|
-
Goal's ordinary design gate. An external edge may be supplied by an alternative
|
|
222
|
-
path containing either kind. Preserve the classification of every retained edge.
|
|
223
|
-
Check the retained graph as a whole, and read it back after registration to verify
|
|
224
|
-
that required paths remain and no redundant direct edges were added. Source
|
|
225
|
-
references do not require additional execution dependencies. This registration
|
|
226
|
-
rule does not authorize cleanup of unrelated existing relationships.
|
|
227
|
-
|
|
228
|
-
### Relationship and content writes
|
|
229
|
-
|
|
230
|
-
**CLI relationship replacement.** `--depends-on` declares ordinary prerequisites;
|
|
231
|
-
`--external-depends-on` declares external ones. Supplying either option compiles
|
|
232
|
-
their full union as `dependsOn` and the exact external set as `externalDependsOn`.
|
|
233
|
-
This replaces every relationship and its classification. An external-only option
|
|
234
|
-
replaces the set with only those external edges; it does not append or merely
|
|
235
|
-
mark an existing edge. An ordinary-only option makes every supplied edge ordinary
|
|
236
|
-
by explicitly sending an empty external subset. Repeat options for the complete
|
|
237
|
-
intended sets. Duplicate or cross-declared IDs fail, including case-equivalent
|
|
238
|
-
UUIDs. Omit both options to preserve relationships; `--clear-dependencies` sends
|
|
239
|
-
both empty sets and conflicts with either option. Before a dependency edit, read
|
|
240
|
-
all D/E values and derive the ordinary set D−E, then preserve every still-needed
|
|
241
|
-
relationship under its intended declaration. Read back the full sets afterward.
|
|
242
|
-
Installed command help owns exact syntax.
|
|
243
|
-
|
|
244
|
-
**Direct API patches.** API fields are independently optional. Omitting both
|
|
245
|
-
preserves relationships. Supplying only `dependsOn` replaces IDs, preserves
|
|
246
|
-
classification on surviving edges and makes new edges ordinary. Supplying only
|
|
247
|
-
`externalDependsOn` preserves IDs and replaces the complete external subset;
|
|
248
|
-
supplying both replaces both sets exactly. The external set must belong to the
|
|
249
|
-
final complete set. This API partial-patch rule differs from the CLI compiler's
|
|
250
|
-
explicit full relationship replacement; do not infer CLI append semantics from it.
|
|
251
|
-
|
|
252
|
-
**Other replacement fields.** Descriptions and PR reference lists replace the
|
|
253
|
-
whole supplied field. Preserve every still-needed value. Omitted fields stay
|
|
254
|
-
unchanged; clearing and option-pairing syntax is in command help.
|
|
255
|
-
|
|
256
|
-
**Markdown descriptions.** Write task-specific Markdown descriptions following
|
|
257
|
-
[create-task](create-task.md) and [the task content standard](task-content.md).
|
|
258
|
-
The description and actual references jointly supply the task definition and
|
|
259
|
-
produced results; complete inline content needs no primary attachment. Execution
|
|
260
|
-
and discussion plans, processes, and operational authorization stay in the
|
|
261
|
-
session under the shared content boundary. The Web displays CommonMark/GFM, while
|
|
262
|
-
API and CLI reads preserve the original string, including line breaks and fenced code. There
|
|
263
|
-
is no format flag. Relative description links and images start at the current
|
|
264
|
-
task's attachment root; Markdown attachment internals start at their containing
|
|
265
|
-
file's directory. Keep real case-sensitive paths inside the task root, confirm
|
|
266
|
-
uploaded contents before linking them, and preserve Markdown and valid references
|
|
267
|
-
when replacing a description. Shared inputs retain their owning task ID and
|
|
268
|
-
content location: description with applicable sections for inline content, full
|
|
269
|
-
path for an actual attachment, or verified immutable repository URL. Read source
|
|
270
|
-
descriptions with `task show --json` and attachment contents separately. They
|
|
271
|
-
are not cross-task relative links, and inline content needs no fabricated path.
|
|
272
|
-
|
|
273
|
-
**Attachment independence.** Task reads contain no attachment inventory.
|
|
274
|
-
Attachments use case-sensitive relative paths; uploads to the same path replace
|
|
275
|
-
that file, so keep mock UI resources at their referenced relative locations.
|
|
276
|
-
Attachment changes do not change the task's version, status, or update timestamp.
|
|
277
|
-
Task versions therefore cannot protect attachment writes. Multiple file
|
|
278
|
-
operations are independent, and file bytes and metadata can change partially;
|
|
279
|
-
confirm actual contents as well as metadata when reconciling a write.
|
|
280
|
-
|
|
281
|
-
**Unconfirmed writes.** A timeout, cancellation or lost response may follow an
|
|
282
|
-
applied change. Read back current task fields or attachment contents before
|
|
283
|
-
another mutation; cancellation does not prove rollback. For an unconfirmed
|
|
284
|
-
create, establish identity from complete fields and operation context; a matching
|
|
285
|
-
title or an empty lookup alone is insufficient. Preserve actual errors and
|
|
286
|
-
resource IDs rather than reporting success or blindly resending a write.
|
|
287
|
-
|
|
288
|
-
Task registration, ordinary execution, and requested handoff follow
|
|
289
|
-
[create-task](create-task.md), [run-task](run-task.md), and [handoff](handoff.md),
|
|
290
|
-
respectively. For a chain of independently tracked delivery stages, use
|
|
291
|
-
[the Goal protocol](goal.md). Every stage and delivery task follows the same
|
|
292
|
-
todo/in_progress/done contract. Registration and discussion confirmation grant
|
|
293
|
-
no delivery execution permission. Each execution remains on its specified task;
|
|
294
|
-
listing ready work does not select or start it.
|
|
1
|
+
# CLI handbook
|
|
2
|
+
|
|
3
|
+
Use the installed `daynight` CLI.
|
|
4
|
+
This file maps command entry points; consult that version's `--help` for arguments, defaults, and option combinations.
|
|
5
|
+
|
|
6
|
+
## Find help
|
|
7
|
+
|
|
8
|
+
```bash
|
|
9
|
+
daynight --version
|
|
10
|
+
daynight --help
|
|
11
|
+
daynight task --help
|
|
12
|
+
daynight task update --help
|
|
13
|
+
daynight task attachment put --help
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
Navigate from top-level help down to the required command.
|
|
17
|
+
Do not treat this skill's workflow names as CLI commands or infer commands from field names.
|
|
18
|
+
|
|
19
|
+
## Command map
|
|
20
|
+
|
|
21
|
+
| Purpose | Command entry points | Guidance |
|
|
22
|
+
| --- | --- | --- |
|
|
23
|
+
| Sign in or out | `login`, `logout` | [Setup](setup.md) |
|
|
24
|
+
| Shell completion | `completion setup` | [Setup](setup.md) |
|
|
25
|
+
| Create, list, or inspect projects | `project create`, `project list`, `project show` | [Project management](project-management.md) |
|
|
26
|
+
| Query tasks | `task list`, `task ready`, `task show` | [Task management](task-management.md#task-queries) |
|
|
27
|
+
| Read task dependency graphs | `task graph <task-id>` | [Verify dependency changes](task-management.md#verify-dependency-changes) |
|
|
28
|
+
| Create tasks | `task create` | [Create task](create-task.md) |
|
|
29
|
+
| Change metadata | `task update` | [Task management](task-management.md#metadata) |
|
|
30
|
+
| Set or remove task properties | `set-property`, `remove-property` | [Managed task user interaction signals](autopilot-managed-task.md#request-user-interaction) |
|
|
31
|
+
| Change status | `task set-status` | [Task management](task-management.md#status-and-timing) |
|
|
32
|
+
| Delete tasks | `task delete` | [Task management](task-management.md#task-deletion) |
|
|
33
|
+
| Upload, list, read, or remove attachments | `task attachment put/list/read/remove` | [Task content standard](task-content.md#attachments-and-references) |
|
|
34
|
+
| Set up and manage workers | `worker` | See `daynight worker --help`; for execution within an assignment, see [managed task execution](autopilot-managed-task.md). |
|
|
35
|
+
|
|
36
|
+
Follow [write safety](write-safety.md) for writes.
|
|
37
|
+
CLI help explains command syntax; reference files explain when to use commands, what they affect, and how to confirm outcomes.
|
|
@@ -1,105 +1,47 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Task handoff
|
|
2
2
|
|
|
3
|
-
Use
|
|
4
|
-
|
|
5
|
-
request authorizes content review and, after it passes, enabling `allowAgents`
|
|
6
|
-
for those tasks. Creating, breaking down, or automatically discovering tasks does
|
|
7
|
-
not authorize permission changes. Read [the handbook](handbook.md) for CLI
|
|
8
|
-
operations and [the task content standard](task-content.md) for sufficiency.
|
|
3
|
+
Use for a task or fixed group of tasks that the user explicitly requests to hand off: review content, enable automatic execution permission after it passes, then return.
|
|
4
|
+
See [authorization and scope](authorization.md) for boundaries; handoff does not start execution in this session or change status, dependencies, or platform.
|
|
9
5
|
|
|
10
|
-
|
|
11
|
-
It does not start this session's task execution, change status,
|
|
12
|
-
dependencies or platform, or grant independent implementation, merge, mainline
|
|
13
|
-
push, deployment, or external-communication authority. Existing execution and
|
|
14
|
-
delivery authorization remains applicable to later scheduling.
|
|
6
|
+
## Content review
|
|
15
7
|
|
|
16
|
-
|
|
8
|
+
Read the project and complete task, preserving the exact version, status, permission, platform, dependencies, and worker records.
|
|
9
|
+
Read actually required sources under the [task content standard](task-content.md), checking definitions, stage requirements, producer and consumer contracts, and the [Goal architecture index](goal.md#register-the-delivery-breakdown).
|
|
17
10
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
actual attachments, and necessary further references under the content standard.
|
|
22
|
-
Check current-stage sufficiency, responsibility boundaries, relevant
|
|
23
|
-
producer/consumer contracts, and Goal delivery tasks' direct architecture index.
|
|
24
|
-
Check the task definition, actual required inputs, and produced results; do not
|
|
25
|
-
require a session execution plan or record the handoff review process in task
|
|
26
|
-
material.
|
|
11
|
+
For todo tasks with permission false, organize confirmed content within existing authorization; missing decisions prevent approval, and material changes require user confirmation.
|
|
12
|
+
Incomplete predecessor tasks need not block handoff when existing designs and interfaces sufficiently define the work, but do not claim that future outputs are already readable.
|
|
13
|
+
Tasks with permission already true may be selected at any time; review them read-only, without assuming execution is paused.
|
|
27
14
|
|
|
28
|
-
|
|
29
|
-
source documents only from existing confirmed information. Missing decisions
|
|
30
|
-
block review. Obtain user confirmation for material scope or behavior changes,
|
|
31
|
-
then reread the changed description and affected actual sources. Unfinished
|
|
32
|
-
prerequisites need not prevent handoff when the design and agreed interfaces
|
|
33
|
-
already define the future work; preserve their real blockers and do not claim
|
|
34
|
-
pending outputs are readable.
|
|
15
|
+
## Act on observed state
|
|
35
16
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
17
|
+
| State | Action |
|
|
18
|
+
| --- | --- |
|
|
19
|
+
| todo, permission false, review passed | Enable permission using the exact version on which the final review decision was based, then reconcile. Real dependency blockers may remain. |
|
|
20
|
+
| todo, permission false, review failed | Keep permission false and report specific gaps. |
|
|
21
|
+
| todo, permission true | Review read-only; do not rewrite the same value as a review marker. |
|
|
22
|
+
| in_progress, permission false | Report that permission is locked; do not change status to bypass it. |
|
|
23
|
+
| in_progress, permission true | Review read-only and report execution status; review does not pause, stop, release, or withdraw execution. |
|
|
24
|
+
| done | Report that it is complete and needs no handoff; do not reopen or change permission. This is handoff policy, not an API restriction. |
|
|
39
25
|
|
|
40
|
-
|
|
26
|
+
Preserve ownership and history for active or released workers.
|
|
27
|
+
New claims, workspaces, or native sessions for released tasks require an authorized administrative decision; enabling permission does not restore old execution or deleted resources.
|
|
41
28
|
|
|
42
|
-
|
|
43
|
-
|---|---|
|
|
44
|
-
| `todo`, permission false, review passes | Enable using the reviewed exact version, then reconcile. Dependency blockers may remain. |
|
|
45
|
-
| `todo`, permission false, review fails | Keep permission false and report concrete gaps. Confirmed-information organization follows the review rules above. |
|
|
46
|
-
| `todo`, permission true | Read-only re-audit; do not rewrite the same flag as an audit marker. |
|
|
47
|
-
| `in_progress`, permission false | Report the permission lock; do not newly enable or reset status to evade it. |
|
|
48
|
-
| `in_progress`, permission true | Read-only re-audit and report actual execution state. Review does not pause, stop, release, or withdraw execution. |
|
|
49
|
-
| `done` | Report completion and no handoff needed; do not reopen or update permission. This is mode policy, not an API prohibition on completed-task updates. |
|
|
50
|
-
| Active or released worker record | Preserve ownership and execution history. An active execution keeps its original resources. A released task starts a fresh claim/worktree/native session only through an authorized management decision; enabling permission neither resumes it nor restores deleted source resources. |
|
|
29
|
+
## Update and reconcile
|
|
51
30
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
handoff or an implicit suspension.
|
|
31
|
+
1. Finish authorized content organization, read back and compare required mutable sources again, not just metadata.
|
|
32
|
+
2. Use `task update` to enable `allowAgents` under [write safety](write-safety.md); write the final description in the same operation if needed, omitting unrelated options.
|
|
33
|
+
3. Check the response and read back the complete task and required sources.
|
|
34
|
+
A worker may claim the task immediately after permission is enabled; a higher final version or a transition to in-progress with a worker is not a failure and must not trigger a retry.
|
|
57
35
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
Recheck required mutable references against the contents reviewed; compare actual
|
|
62
|
-
contents, not merely inventory or timestamps. Resolve changes before proceeding.
|
|
63
|
-
Attachment writes and cross-task references are not atomically protected by the
|
|
64
|
-
task version, and handoff does not provide server-side certification or freezing.
|
|
65
|
-
|
|
66
|
-
For a reviewed false-permission `todo`, use the installed CLI's versioned
|
|
67
|
-
`task update --allow-agents true` with the exact version on which the final
|
|
68
|
-
review decision was based. A final description may be included in that same
|
|
69
|
-
update. Omit unrelated options and preserve dependencies, platform, PR references,
|
|
70
|
-
worker data, and other fields. Do not update status to make the task eligible.
|
|
71
|
-
|
|
72
|
-
Check the write result and read back the complete task and required sources.
|
|
73
|
-
On a version conflict, reread and reassess rather than merely replacing the
|
|
74
|
-
version and replaying. If a write response is lost or uncertain, reconcile by
|
|
75
|
-
reads only before considering any new mutation; do not automatically replay it.
|
|
76
|
-
An unreadable reconciliation leaves the outcome unconfirmed: preserve the actual
|
|
77
|
-
error and do not report successful handoff.
|
|
78
|
-
|
|
79
|
-
Scheduling can claim the task immediately after enabling permission, so the final
|
|
80
|
-
GET may show a higher version and `in_progress` with a worker. Report the actual
|
|
81
|
-
observation; do not require equality with the update response's version or retry
|
|
82
|
-
because execution was observed. Another writer may have set the same flag during
|
|
83
|
-
an uncertain outcome. Without a confirmed write result, report only the observed
|
|
84
|
-
state rather than attributing the change to this operation.
|
|
85
|
-
|
|
86
|
-
If final source verification fails or reveals material changes, report review
|
|
87
|
-
incomplete or failed and the actual permission/state, including continued
|
|
88
|
-
scheduling exposure when true. Do not claim success or automatically revoke the
|
|
89
|
-
flag. Further action follows the same explicit authorization and state rules.
|
|
36
|
+
If review fails or source verification fails after the update, report the actual permission and that scheduling may still occur; do not claim successful handoff or automatically revoke permission.
|
|
37
|
+
Revocation or stopping execution requires separately defined scope and the administrative workflow.
|
|
38
|
+
Without a confirmed response, report only actual observations, without attributing the change to this operation.
|
|
90
39
|
|
|
91
40
|
## Report and return
|
|
92
41
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
claim is reported under the state rules rather than treated as proof of failure.
|
|
96
|
-
Report each task's content-review result, changes or concrete gaps, observed
|
|
97
|
-
version, permission and status, remaining dependency blockers, and applicable
|
|
98
|
-
worker ownership and management constraints. Distinguish a confirmed permission
|
|
99
|
-
update from an uncertain write and a read-only re-audit. Permission true alone proves neither
|
|
100
|
-
execution started nor completion; report either only from actual evidence.
|
|
42
|
+
Before reporting, read back the complete task and reassess changes that affect the review.
|
|
43
|
+
For each task, report the review conclusion, changes or gaps, observed version, permission, status, dependency blockers, and applicable worker ownership; distinguish confirmed updates, uncertain writes, and read-only review.
|
|
101
44
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
permission values.
|
|
45
|
+
Handle each task in a fixed group individually; one passing does not mean the others passed.
|
|
46
|
+
Permission true is neither permanent proof of review nor proof that execution has started or finished.
|
|
47
|
+
Return without selecting or starting work.
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Project management
|
|
2
|
+
|
|
3
|
+
A Project is associated with a Git repository.
|
|
4
|
+
Project identity determines the scope of task operations; confirm the service, access identity, and project before operating on tasks.
|
|
5
|
+
|
|
6
|
+
## Discovery and selection
|
|
7
|
+
|
|
8
|
+
Within a Git repository and its worktrees, task commands may omit `--project`; the CLI matches the `origin` URL to projects on the configured service.
|
|
9
|
+
An explicit project overrides automatic discovery for that invocation.
|
|
10
|
+
|
|
11
|
+
Use `project list` to find accessible projects and `project show` to verify the selected project.
|
|
12
|
+
If there is no match or the match is ambiguous, confirm the repository, service, and target project.
|
|
13
|
+
Do not guess IDs or create projects merely to make a query succeed.
|
|
14
|
+
See the relevant `--help` for details.
|
|
15
|
+
|
|
16
|
+
## Register a project
|
|
17
|
+
|
|
18
|
+
With authorization, use `project create` to register the repository as a project.
|
|
19
|
+
Reuse an existing project when exactly one matches; resolve identity first when the match is ambiguous.
|
|
20
|
+
Retain the returned project ID, then read the project details to confirm the repository and name.
|
|
21
|
+
|
|
22
|
+
If the creation response is uncertain, establish the actual outcome first under [write safety](write-safety.md).
|
|
23
|
+
An identical name does not prove project identity.
|
|
24
|
+
Consult `daynight project --help` for available project configuration operations.
|
|
@@ -1,66 +1,25 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Ordinary task execution
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
[
|
|
5
|
-
This mode owns the ordinary task lifecycle. It returns without choosing a
|
|
6
|
-
successor, except for the explicit user-directed requirements-to-solution
|
|
7
|
-
transition under [the Goal protocol](goal.md).
|
|
3
|
+
Use for one task explicitly specified by the user.
|
|
4
|
+
Apply [authorization and scope](authorization.md) first, read the complete task with `daynight task show <task-id> --json`, and verify inputs and completion conditions under [shared task execution](task-execution.md).
|
|
8
5
|
|
|
9
|
-
##
|
|
6
|
+
## Start or resume
|
|
10
7
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
| Observed status | Behavior |
|
|
9
|
+
| --- | --- |
|
|
10
|
+
| todo | Once ready and authorized for execution, use `task set-status` with the exact observed version to enter `in_progress`; confirm success before starting. |
|
|
11
|
+
| in_progress | Reconcile existing work and session context, coordinate and resume through established repository mechanisms, and do not treat status as an execution lock. |
|
|
12
|
+
| done | Report that it is already complete; consider reopening only when the explicit request includes it. |
|
|
15
13
|
|
|
16
|
-
An
|
|
17
|
-
|
|
18
|
-
selection, not an explicit task assignment. They do not remove dependencies,
|
|
19
|
-
stage inputs, or execution and delivery authorization. This mode does not select
|
|
20
|
-
candidates or automatically advance a fixed task queue.
|
|
14
|
+
An explicit ordinary assignment is not restricted by `allowAgents` or platform filtering for automatic selection; see [task management](task-management.md#metadata).
|
|
15
|
+
This workflow does not select candidate tasks or advance a queue automatically.
|
|
21
16
|
|
|
22
|
-
|
|
23
|
-
start the current Goal discussion, or the user-directed transition that starts
|
|
24
|
-
solution discussion, authorizes entering `in_progress` for that discussion under
|
|
25
|
-
the Goal protocol; registration alone does not. Existing execution authorization
|
|
26
|
-
remains limited to its stated scope. Task status never expands implementation
|
|
27
|
-
or delivery authorization.
|
|
17
|
+
## Complete or wait
|
|
28
18
|
|
|
29
|
-
|
|
19
|
+
Follow the shared execution rules.
|
|
20
|
+
Once all completion conditions are met, reread the in-progress task, set it to done using its observed version, and confirm the service result.
|
|
21
|
+
Handle all changes and uncertain responses under [write safety](write-safety.md); ordinary completion does not include a worker claim.
|
|
30
22
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
exact version observed for that decision and confirm `in_progress` before
|
|
35
|
-
starting. A stale version or changed prerequisite requires rereading and
|
|
36
|
-
reconsidering, with no automatic mutation retry.
|
|
37
|
-
|
|
38
|
-
For `in_progress`, recover existing work and coordinate using the project's
|
|
39
|
-
established mechanisms; the state is not an assignee lock or lease. A task
|
|
40
|
-
already `done` is reported as such unless reopening is within the explicit
|
|
41
|
-
requested scope. An authorized reopening uses the same versioned status setter
|
|
42
|
-
and dependency protection.
|
|
43
|
-
|
|
44
|
-
Perform the authorized work and establish acceptance readiness under
|
|
45
|
-
[shared task execution](task-execution.md). Starting a task is not evidence that
|
|
46
|
-
its delivery or acceptance is complete.
|
|
47
|
-
|
|
48
|
-
## Complete or return waiting
|
|
49
|
-
|
|
50
|
-
When all task acceptance and delivery conditions are satisfied and its required
|
|
51
|
-
results are readable, reread the complete in-progress task and use
|
|
52
|
-
`task set-status <task-id> done --if-version <observed-version>` with its exact
|
|
53
|
-
observed version. Only service confirmation establishes the status update;
|
|
54
|
-
reconcile uncertain results before reporting success. Do not replay an
|
|
55
|
-
unconfirmed mutation automatically.
|
|
56
|
-
|
|
57
|
-
For Goal discussions, completion follows the confirmation gates and accepted
|
|
58
|
-
materials in the Goal protocol. After requirements completion is confirmed, an
|
|
59
|
-
explicit user direction can start the specified solution discussion under that
|
|
60
|
-
protocol. It grants no automatic successor selection or delivery authorization.
|
|
61
|
-
Whole-Goal acceptance follows the Goal protocol.
|
|
62
|
-
|
|
63
|
-
Otherwise return after this task completes or needs external intervention.
|
|
64
|
-
Unstarted work stays `todo`; active work stays `in_progress`. Keep the target and
|
|
65
|
-
waiting checkpoint when necessary PR merges, human confirmation, permission, or
|
|
66
|
-
acceptance remain pending; do not select another task to bypass the wait.
|
|
23
|
+
When merging, human confirmation, authorization, or acceptance is still missing, keep the task in progress and preserve the waiting context.
|
|
24
|
+
Tasks not yet started remain todo.
|
|
25
|
+
Return when complete or when external intervention is needed, without selecting a successor; follow the [Goal protocol](goal.md) for discussion-stage transitions explicitly directed by the user.
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# Setup
|
|
2
|
+
|
|
3
|
+
Use this when first connecting to Daynight or confirming the current repository is ready to use. See the [CLI handbook](handbook.md) for finding commands and arguments.
|
|
4
|
+
|
|
5
|
+
1. Run `daynight --version` and `daynight --help` to confirm the CLI is available.
|
|
6
|
+
If it is not installed, obtain user authorization and follow the [installation guide](https://daynight.cc/setup).
|
|
7
|
+
2. Confirm the target service and signed-in identity. When authentication is needed, use `daynight login` and have the user follow the prompts to verify the code and account in the browser and authorize access.
|
|
8
|
+
See `daynight login --help` for remote-terminal options. Do not ask the user to provide credentials in chat.
|
|
9
|
+
3. Confirm the project for the current Git repository under [project management](project-management.md). If there is no project, obtain registration authorization before creating one; service or permission failures do not mean the project is absent.
|
|
10
|
+
4. Read the repository's `AGENTS.md` and `CLAUDE.md` to establish task tracking, language, workspace, delivery, and authorization rules.
|
|
11
|
+
If repository instructions need to be added or adjusted, confirm the content and editing permission first; setup does not imply permission to rewrite instructions.
|
|
12
|
+
5. Confirm that project and task queries are accessible. Report actual failures and preserve completed configuration; do not bypass problems by creating duplicate projects.
|
|
13
|
+
|
|
14
|
+
Configure interactive completion with `daynight completion setup`.
|
|
15
|
+
Setting up and running a worker environment are separate operations; consult `daynight worker --help` first.
|
|
16
|
+
Ordinary task management does not require starting a worker.
|