@winton979/task-cli 1.6.0 → 1.6.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 (3) hide show
  1. package/README.md +4 -0
  2. package/package.json +1 -1
  3. package/src/init.js +38 -12
package/README.md CHANGED
@@ -121,6 +121,10 @@ archive automatically
121
121
  /task-explore → TASK_READY → /task-implement → optional /task-audit
122
122
  ```
123
123
 
124
+ `task-explore` writes a brief that supports a fresh-session handoff when needed. Before `TASK_READY`, it checks that a new implementation session could determine the goal, acceptance criteria, material constraints, and exclusions from the brief alone. This is a readiness check, not a requirement to start implementation in a new session. The brief preserves confirmed execution-critical context without becoming a repository snapshot; the implementing agent revalidates current repository facts. Briefs should stay within 500 words; they may extend to 1000 only when a shorter contract would omit execution-critical information. Requirements that still do not fit should be split before implementation.
125
+
126
+ When more than one active brief could match, identify the intended brief when invoking `task-implement`. The implementing agent rechecks repository facts and resolves local, reversible choices from existing conventions. It asks the user only for unresolved decisions that materially affect the contract, records confirmed narrow clarifications in the active brief, and returns material goal, scope, or acceptance changes to `task-explore`.
127
+
124
128
  ### Bug Fix
125
129
 
126
130
  ```text
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@winton979/task-cli",
3
- "version": "1.6.0",
3
+ "version": "1.6.2",
4
4
  "description": "Lightweight task workflow CLI for AI-assisted development",
5
5
  "license": "MIT",
6
6
  "repository": {
package/src/init.js CHANGED
@@ -278,6 +278,18 @@ ${DECISIONS_READ_GUIDANCE}
278
278
 
279
279
  ${COMPLEXITY_ASSESSMENT_GUIDANCE}
280
280
 
281
+ Cross-session Readiness
282
+
283
+ Before finalizing the brief, verify that it would be sufficient if implementation later began in a fresh session without the exploration conversation. This is a readiness check; implementation may proceed in the current session.
284
+
285
+ Complete this self-check before outputting TASK_READY:
286
+
287
+ * A fresh implementation session can determine the Goal, Acceptance Criteria, material constraints, and material exclusions from the brief alone.
288
+ * Record every confirmed user decision and other confirmed execution-critical context when omitting it could materially change implementation or validation. This includes material constraints on behavior, scope, compatibility, security, data handling, acceptance, or delivery.
289
+ * Record material exclusions when omitting them could cause plausible scope expansion.
290
+ * Do not turn the brief into a repository snapshot. Record repository facts only when needed to interpret a confirmed constraint; the implementing agent revalidates current facts.
291
+ * Do not output TASK_READY while a material user-owned decision remains unresolved.
292
+
281
293
  Task Brief Format
282
294
 
283
295
  # Goal
@@ -306,7 +318,9 @@ Clear success conditions.
306
318
 
307
319
  Requirements
308
320
 
309
- * Maximum 500 words
321
+ * Aim for 500 words or fewer
322
+ * Extend to at most 1000 words only when required to preserve execution-critical scope, constraints, risks, or acceptance criteria
323
+ * If a coherent contract cannot fit within 1000 words, split the requirement and complete exploration for one independently executable task at a time
310
324
  * No code
311
325
  * No architecture design
312
326
  * Stay implementation-agnostic; describe constraints, not solutions
@@ -320,27 +334,39 @@ TASK_READY
320
334
 
321
335
  'task-implement': {
322
336
  name: 'task-implement',
323
- description: 'Implement the latest active task brief and validate it. Archive automatically when complete.',
337
+ description: 'Implement a selected active task brief and validate it. Archive automatically when complete.',
324
338
  content: `---
325
339
  name: task-implement
326
- description: Implement the latest active task brief and validate it. Archive automatically when complete.
340
+ description: Implement a selected active task brief and validate it. Archive automatically when complete.
327
341
  user-invocable: true
328
342
  ---
329
343
 
330
344
  Purpose
331
345
 
332
- Implement a task from the latest file in .ai/tasks/active/.
346
+ Implement the intended task from .ai/tasks/active/.
333
347
 
334
348
  Rules
335
349
 
336
- 1. Read the latest relevant brief from .ai/tasks/active/.
337
- 2. Follow the acceptance criteria strictly.
338
- 3. Prefer minimal changes.
339
- 4. Respect existing project conventions.
340
- 5. Avoid unnecessary refactoring.
341
- 6. State assumptions explicitly.
342
- 7. Validate the result before stopping.
343
- 8. If the work is complete, archive the brief automatically by moving it to .ai/tasks/archive/.
350
+ 1. Identify the intended brief in .ai/tasks/active/. Use a user-specified name or path when provided. Without one, proceed only when a single brief is the clear match. Ask the user when multiple briefs are plausible; do not choose by recency alone.
351
+ 2. Read the selected brief and inspect the relevant current code before planning.
352
+ 3. Follow the acceptance criteria strictly.
353
+ 4. Prefer minimal changes.
354
+ 5. Respect existing project conventions.
355
+ 6. Avoid unnecessary refactoring.
356
+ 7. State assumptions explicitly.
357
+ 8. Validate the result before stopping.
358
+ 9. If the work is complete, archive the selected brief automatically by moving it to .ai/tasks/archive/.
359
+
360
+ Brief Sufficiency
361
+
362
+ Before changing code, and whenever implementation reveals an ambiguity, determine whether the selected brief remains executable against the current project state.
363
+
364
+ * Investigate facts available from the repository or environment instead of asking the user.
365
+ * For a local, reversible implementation choice that does not materially affect behavior, scope, compatibility, security, data, or acceptance, follow existing conventions and choose the simplest option.
366
+ * Do not infer an unresolved user decision that materially affects those concerns. Ask one focused question at a time, include a recommended answer, and wait.
367
+ * After explicit confirmation of a narrow clarification, record it in the selected active brief before continuing implementation.
368
+ * If clarification materially changes the Goal, accepted scope, or Acceptance Criteria, or the unresolved decisions collectively require material contract revision, stop and require renewed task-explore. Do not implement against an outdated brief.
369
+ * If current project state materially contradicts the brief's context, surface the conflict and resolve it under the same rules.
344
370
 
345
371
  When making implementation decisions
346
372