@staff0rd/assist 0.136.2 → 0.138.0

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 CHANGED
@@ -37,7 +37,6 @@ After installation, the `assist` command will be available globally. You can als
37
37
  - `/commit` - Commit only relevant files from the session
38
38
  - `/devlog` - Generate devlog entry for the next unversioned day
39
39
  - `/draft` - Draft a new backlog item with LLM-assisted questioning
40
- - `/next-backlog-item` - Pick and implement the next backlog item
41
40
  - `/pr` - Raise a PR with a concise description
42
41
  - `/refactor` - Run refactoring checks for code quality
43
42
  - `/restructure` - Analyze and restructure tightly-coupled files
@@ -105,6 +104,7 @@ After installation, the `assist` command will be available globally. You can als
105
104
  - `assist refactor ignore <file>` - Add a file to the refactor ignore list
106
105
  - `assist refactor rename file <source> <destination>` - Rename/move a TypeScript file and update all imports (dry-run by default, use `--apply` to execute)
107
106
  - `assist refactor rename symbol <file> <oldName> <newName>` - Rename a variable, function, class, or type across the project (dry-run by default, use `--apply` to execute)
107
+ - `assist refactor extract <file> <functionName> <destination>` - Extract a function and its private dependencies to a new file (dry-run by default, use `--apply` to execute)
108
108
  - `assist refactor restructure [pattern]` - Analyze import graph and restructure tightly-coupled files into nested directories
109
109
  - `assist devlog list` - Group git commits by date
110
110
  - `assist devlog next` - Show commits for the day after the last versioned entry
@@ -34,10 +34,12 @@ Once you have enough context, propose a complete backlog item. Show it to the us
34
34
 
35
35
  **Plan:**
36
36
  - Phase 1: (name) — tasks...
37
- - Phase 2: (name) — tasks...
37
+ - Phase 2: (name) — tasks... [manual checks: ...]
38
38
 
39
39
  Keep phases small (2-4 tasks each). A typical item should have 2-3 phases.
40
40
 
41
+ Most phases should NOT have manual checks — prefer automated verification via the `verify` field on tasks. Only add `manualChecks` to a phase when the checks are genuinely difficult to automate (e.g. visual appearance, UX flow, hardware interaction). The last phase should always have at least one manual check to confirm the feature works end-to-end.
42
+
41
43
  ## Step 4: Iterate
42
44
 
43
45
  Ask the user if they want to change anything. Iterate until they confirm.
@@ -57,7 +59,8 @@ Once confirmed, pipe the JSON to the CLI. The JSON must match this shape:
57
59
  "name": "Phase name",
58
60
  "tasks": [
59
61
  { "task": "Do something", "verify": "optional verification step" }
60
- ]
62
+ ],
63
+ "manualChecks": ["optional — only for checks that can't be automated"]
61
64
  }
62
65
  ]
63
66
  }
@@ -51,8 +51,7 @@
51
51
  "Bash(assist seq auth list:*)",
52
52
  "Bash(assist screenshot:*)",
53
53
  "Bash(assist roam show-claude-code-icon:*)",
54
- "SlashCommand(/next-backlog-item)",
55
- "SlashCommand(/verify)",
54
+ "SlashCommand(/verify)",
56
55
  "SlashCommand(/commit)",
57
56
  "SlashCommand(/devlog)",
58
57
  "SlashCommand(/refactor)",
@@ -66,8 +65,7 @@
66
65
  "SlashCommand(/voice-logs)",
67
66
  "SlashCommand(/journal)",
68
67
  "SlashCommand(/standup)",
69
- "Skill(next-backlog-item)",
70
- "Skill(verify)",
68
+ "Skill(verify)",
71
69
  "Skill(commit)",
72
70
  "Skill(devlog)",
73
71
  "Skill(refactor)",
package/dist/index.js CHANGED
@@ -6,7 +6,7 @@ import { Command } from "commander";
6
6
  // package.json
7
7
  var package_default = {
8
8
  name: "@staff0rd/assist",
9
- version: "0.136.2",
9
+ version: "0.138.0",
10
10
  type: "module",
11
11
  main: "dist/index.js",
12
12
  bin: {
@@ -2290,7 +2290,8 @@ var planTaskSchema = z2.strictObject({
2290
2290
  });
2291
2291
  var planPhaseSchema = z2.strictObject({
2292
2292
  name: z2.string(),
2293
- tasks: z2.array(planTaskSchema)
2293
+ tasks: z2.array(planTaskSchema),
2294
+ manualChecks: z2.array(z2.string()).optional()
2294
2295
  });
2295
2296
  var backlogItemSchema = z2.strictObject({
2296
2297
  id: z2.number(),
@@ -2611,12 +2612,34 @@ import chalk35 from "chalk";
2611
2612
  import chalk34 from "chalk";
2612
2613
 
2613
2614
  // src/commands/backlog/buildPhasePrompt.ts
2614
- function buildPhasePrompt(item, phaseIndex, phase) {
2615
- const tasks = phase.tasks.map((t) => {
2615
+ function formatTasks(phase) {
2616
+ return phase.tasks.map((t) => {
2616
2617
  let line = `- ${t.task}`;
2617
2618
  if (t.verify) line += ` (verify: ${t.verify})`;
2618
2619
  return line;
2619
2620
  }).join("\n");
2621
+ }
2622
+ function buildManualCheckLines(manualChecks, isLastPhase) {
2623
+ if (manualChecks.length > 0) {
2624
+ return [
2625
+ "",
2626
+ "Before marking this phase as done, ask the user to perform these manual checks:",
2627
+ ...manualChecks.map((c) => `- ${c}`),
2628
+ "",
2629
+ "Wait for the user to confirm all manual checks pass before proceeding."
2630
+ ];
2631
+ }
2632
+ if (isLastPhase) {
2633
+ return [
2634
+ "",
2635
+ "This is the final phase. Before marking it as done, ask the user to manually verify",
2636
+ "that the feature works end-to-end and all acceptance criteria are met.",
2637
+ "Wait for the user to confirm before proceeding."
2638
+ ];
2639
+ }
2640
+ return [];
2641
+ }
2642
+ function buildContextLines(item, phaseIndex, phase) {
2620
2643
  const ac = item.acceptanceCriteria.map((c) => `- ${c}`).join("\n");
2621
2644
  return [
2622
2645
  `You are implementing phase ${phaseIndex + 1} of backlog item #${item.id}: ${item.name}`,
@@ -2628,11 +2651,22 @@ function buildPhasePrompt(item, phaseIndex, phase) {
2628
2651
  "",
2629
2652
  `Phase ${phaseIndex + 1}: ${phase.name}`,
2630
2653
  "Tasks:",
2631
- tasks,
2654
+ formatTasks(phase)
2655
+ ];
2656
+ }
2657
+ function buildPhasePrompt(item, phaseIndex, phase, totalPhases) {
2658
+ const isLastPhase = phaseIndex === totalPhases - 1;
2659
+ const manualChecks = phase.manualChecks ?? [];
2660
+ const needsConfirmation = manualChecks.length > 0 || isLastPhase;
2661
+ const confirmSuffix = needsConfirmation ? " and the user confirms" : "";
2662
+ return [
2663
+ ...buildContextLines(item, phaseIndex, phase),
2632
2664
  "",
2633
2665
  "Focus ONLY on this phase. Do not work on other phases.",
2634
2666
  "When you have completed all tasks for this phase, run /verify to check your work.",
2635
- `Once verify passes, run: assist backlog phase-done ${item.id} ${phaseIndex}`
2667
+ ...buildManualCheckLines(manualChecks, isLastPhase),
2668
+ "",
2669
+ `Once verify passes${confirmSuffix}, run: assist backlog phase-done ${item.id} ${phaseIndex}`
2636
2670
  ].filter((line) => line !== void 0).join("\n");
2637
2671
  }
2638
2672
 
@@ -2757,7 +2791,7 @@ async function executePhase(item, phaseIndex, phases) {
2757
2791
  )
2758
2792
  );
2759
2793
  const { child, done: done2 } = spawnClaude(
2760
- buildPhasePrompt(item, phaseIndex, phase)
2794
+ buildPhasePrompt(item, phaseIndex, phase, phases.length)
2761
2795
  );
2762
2796
  watchForMarker(child);
2763
2797
  await done2;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@staff0rd/assist",
3
- "version": "0.136.2",
3
+ "version": "0.138.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "bin": {
@@ -1,17 +0,0 @@
1
- ---
2
- description: Pick and implement the next backlog item
3
- ---
4
-
5
- Run `assist backlog list --status todo --verbose 2>&1` to see all available backlog items.
6
-
7
- Choose ONE item to implement. You may pick whichever item you like. Read the item's name, description, and acceptance criteria carefully. If anything is unclear or ambiguous, ask the user for clarification before proceeding.
8
-
9
- Once you have chosen an item, run `assist backlog start <id>` to mark it as in-progress.
10
-
11
- Implement the item fully, satisfying ALL acceptance criteria. Do not skip any.
12
-
13
- When implementation is complete, run `/verify` and fix any issues until it passes.
14
-
15
- Then stop and wait for the user. Do NOT call `assist backlog done` yet. Inform the user the item is ready and wait for them to call `/commit`.
16
-
17
- Only after the user has called `/commit` and the commit succeeds, run `assist backlog done <id>` to mark the item as done.