@mthanhlm/autodev 0.3.3 → 0.3.4
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 +2 -0
- package/autodev/bin/autodev-tools.cjs +15 -7
- package/autodev/workflows/autodev.md +2 -1
- package/autodev/workflows/execute-phase.md +4 -4
- package/autodev/workflows/help.md +3 -2
- package/autodev/workflows/plan-phase.md +9 -5
- package/autodev/workflows/review-plan.md +53 -0
- package/commands/autodev/execute-phase.md +1 -1
- package/commands/autodev/explore-codebase.md +1 -1
- package/commands/autodev/index.md +1 -1
- package/commands/autodev/review-phase.md +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -60,6 +60,7 @@ Typical brownfield route:
|
|
|
60
60
|
-> new project
|
|
61
61
|
-> explore codebase
|
|
62
62
|
-> plan phase
|
|
63
|
+
-> review phase plan
|
|
63
64
|
-> execute next task
|
|
64
65
|
-> execute next task
|
|
65
66
|
-> review
|
|
@@ -92,6 +93,7 @@ project -> track -> phase -> tasks
|
|
|
92
93
|
|
|
93
94
|
- `/autodev` remains the single entrypoint
|
|
94
95
|
- A phase is planned into one phase overview plus multiple task files
|
|
96
|
+
- `/autodev` stops after planning so the user can review the phase before any execution starts
|
|
95
97
|
- The phase keeps one user-facing orchestration session
|
|
96
98
|
- Each task is preferably executed by a fresh worker agent in the background
|
|
97
99
|
- After each task, the worker reports back with files changed, verification, and blockers
|
|
@@ -507,16 +507,16 @@ function buildRoute(cwd) {
|
|
|
507
507
|
};
|
|
508
508
|
}
|
|
509
509
|
|
|
510
|
-
const
|
|
511
|
-
if (
|
|
510
|
+
const nextPlannedReview = phases.find(phase => phase.planExists && !phase.summaryExists);
|
|
511
|
+
if (nextPlannedReview) {
|
|
512
512
|
return {
|
|
513
|
-
kind: '
|
|
513
|
+
kind: 'plan_review',
|
|
514
514
|
command: '/autodev',
|
|
515
|
-
manualCommand: `/autodev-execute-phase ${
|
|
516
|
-
reason: '
|
|
515
|
+
manualCommand: `/autodev-execute-phase ${nextPlannedReview.number}`,
|
|
516
|
+
reason: 'phase_planned_awaiting_user_review',
|
|
517
517
|
projectType,
|
|
518
518
|
trackSlug: activeTrack,
|
|
519
|
-
phaseNumber:
|
|
519
|
+
phaseNumber: nextPlannedReview.number
|
|
520
520
|
};
|
|
521
521
|
}
|
|
522
522
|
|
|
@@ -702,7 +702,15 @@ function initPayload(cwd, mode, requestedPhase) {
|
|
|
702
702
|
const activeTrack = readActiveTrack(cwd);
|
|
703
703
|
const tracks = listTracks(cwd);
|
|
704
704
|
const track = trackPaths(cwd, activeTrack);
|
|
705
|
-
const phaseMode = mode === 'review-phase'
|
|
705
|
+
const phaseMode = mode === 'review-phase'
|
|
706
|
+
? 'review'
|
|
707
|
+
: mode === 'verify-work'
|
|
708
|
+
? 'verify'
|
|
709
|
+
: mode === 'execute-phase' || mode === 'review-plan'
|
|
710
|
+
? 'execute'
|
|
711
|
+
: mode === 'plan-phase'
|
|
712
|
+
? 'plan'
|
|
713
|
+
: null;
|
|
706
714
|
const phase = phaseMode && activeTrack ? resolvePhase(cwd, activeTrack, requestedPhase, phaseMode) : null;
|
|
707
715
|
const tasks = phase ? listTasksForPhaseDetails(phase) : [];
|
|
708
716
|
const nextTask = nextExecutableTask(tasks);
|
|
@@ -24,7 +24,8 @@ node "$HOME/.claude/autodev/bin/autodev-tools.cjs" status
|
|
|
24
24
|
- `init_project`: read `@~/.claude/autodev/workflows/new-project.md`, then perform that workflow.
|
|
25
25
|
- `explore_codebase`: read `@~/.claude/autodev/workflows/explore-codebase.md`, then perform that workflow.
|
|
26
26
|
- `plan_phase`: read `@~/.claude/autodev/workflows/plan-phase.md`, then perform that workflow.
|
|
27
|
-
- `
|
|
27
|
+
- `plan_review`: read `@~/.claude/autodev/workflows/review-plan.md`, then perform that workflow so the user can review the phase plan before any execution starts.
|
|
28
|
+
- `execute_phase`: read `@~/.claude/autodev/workflows/execute-phase.md`, then perform that workflow, which should advance one task-sized unit in the current phase session by trying a fresh worker agent first and falling back cleanly when agent delegation is unavailable.
|
|
28
29
|
- `review_phase`: read `@~/.claude/autodev/workflows/review-phase.md`, then perform that workflow.
|
|
29
30
|
- `verify_phase`: read `@~/.claude/autodev/workflows/verify-work.md`, then perform that workflow.
|
|
30
31
|
|
|
@@ -9,8 +9,8 @@ Execute an active-track phase through task-sized worker runs, keep the main sess
|
|
|
9
9
|
- Execute one task at a time by default.
|
|
10
10
|
- Do not use waves.
|
|
11
11
|
- Prefer a fresh background worker for each task so the phase session does not bloat.
|
|
12
|
-
- If
|
|
13
|
-
- If a delegation attempt fails with an environment limitation like `specialized agents aren't available`, treat delegation as unavailable for this run and continue cleanly.
|
|
12
|
+
- If agent delegation is available in this environment, delegate task implementation.
|
|
13
|
+
- If a delegation attempt fails with an environment limitation like `specialized agents aren't available`, treat agent delegation as unavailable for this run and continue cleanly.
|
|
14
14
|
- The main phase session should remain orchestration-focused whenever delegation works.
|
|
15
15
|
- The main phase session may update `.autodev/` state and aggregate phase artifacts.
|
|
16
16
|
</rules>
|
|
@@ -48,7 +48,7 @@ node "$HOME/.claude/autodev/bin/autodev-tools.cjs" init execute-phase "$ARGUMENT
|
|
|
48
48
|
- verification plan
|
|
49
49
|
- any dependency note
|
|
50
50
|
|
|
51
|
-
7. If
|
|
51
|
+
7. If agent delegation is available, first try to spawn one fresh background worker using `autodev-task-worker` for the selected task.
|
|
52
52
|
Tell it:
|
|
53
53
|
- phase path
|
|
54
54
|
- task path
|
|
@@ -60,7 +60,7 @@ node "$HOME/.claude/autodev/bin/autodev-tools.cjs" init execute-phase "$ARGUMENT
|
|
|
60
60
|
|
|
61
61
|
8. If worker delegation is unavailable, do not stop on the raw platform message.
|
|
62
62
|
Treat messages like `specialized agents aren't available` as a capability limitation, then:
|
|
63
|
-
- tell the user plainly that
|
|
63
|
+
- tell the user plainly that worker-agent delegation is unavailable in this environment
|
|
64
64
|
- continue with the same task in the current session
|
|
65
65
|
- keep the same task boundaries
|
|
66
66
|
- still write the task summary before moving on
|
|
@@ -5,7 +5,7 @@ Lean Claude Code workflow. No automatic commits. No branches. No worktrees. Git
|
|
|
5
5
|
## Main Entry
|
|
6
6
|
|
|
7
7
|
- `/autodev`
|
|
8
|
-
The normal command. It routes automatically through project setup, codebase mapping, planning, execution, review, verification, and cleanup.
|
|
8
|
+
The normal command. It routes automatically through project setup, codebase mapping, planning, plan review, execution, review, verification, and cleanup.
|
|
9
9
|
|
|
10
10
|
## Manual Commands
|
|
11
11
|
|
|
@@ -18,7 +18,7 @@ Lean Claude Code workflow. No automatic commits. No branches. No worktrees. Git
|
|
|
18
18
|
- `/autodev-plan-phase [phase]`
|
|
19
19
|
Creates or revises one phase plan plus task files in `.autodev/tracks/<track>/phases/NN-type-name/`.
|
|
20
20
|
- `/autodev-execute-phase [phase]`
|
|
21
|
-
Orchestrates one phase task-by-task, preferring a fresh worker per task, and writes `TASK-NN-SUMMARY.md` plus the final `NN-SUMMARY.md`.
|
|
21
|
+
Orchestrates one phase task-by-task, preferring a fresh worker agent per task, and writes `TASK-NN-SUMMARY.md` plus the final `NN-SUMMARY.md`.
|
|
22
22
|
- `/autodev-review-phase [phase]`
|
|
23
23
|
Uses four review agents when available for code quality, security, integration, and polish, then writes `NN-REVIEW.md`.
|
|
24
24
|
- `/autodev-verify-work [phase]`
|
|
@@ -56,6 +56,7 @@ Typical brownfield route:
|
|
|
56
56
|
-> new project
|
|
57
57
|
-> explore codebase
|
|
58
58
|
-> plan
|
|
59
|
+
-> review plan
|
|
59
60
|
-> execute
|
|
60
61
|
-> review
|
|
61
62
|
-> verify
|
|
@@ -77,19 +77,23 @@ Each task file must include:
|
|
|
77
77
|
9. Update the active track `STATE.md` so it points to:
|
|
78
78
|
- `Current Phase: N`
|
|
79
79
|
- `Current Phase Type: <type>`
|
|
80
|
-
- `Current Step:
|
|
80
|
+
- `Current Step: plan_review`
|
|
81
81
|
- `Current Task: 01` if tasks exist, otherwise `none`
|
|
82
|
-
- `Current Task Status:
|
|
82
|
+
- `Current Task Status: pending_review`
|
|
83
83
|
- `Next Command: /autodev`
|
|
84
84
|
- current ISO timestamp
|
|
85
85
|
|
|
86
86
|
10. Update `.autodev/STATE.md` so it points to:
|
|
87
87
|
- `Active Track: <slug>`
|
|
88
|
-
- `Current Step:
|
|
88
|
+
- `Current Step: plan_review`
|
|
89
89
|
- `Current Task: 01` if tasks exist, otherwise `none`
|
|
90
|
-
- `Current Task Status:
|
|
90
|
+
- `Current Task Status: pending_review`
|
|
91
91
|
- `Next Command: /autodev`
|
|
92
92
|
- current ISO timestamp
|
|
93
93
|
|
|
94
|
-
11. End with a short summary and
|
|
94
|
+
11. End with a short summary and stop for review.
|
|
95
|
+
Tell the user:
|
|
96
|
+
- the plan and task files are ready for review
|
|
97
|
+
- `/autodev` will open the review checkpoint before any execution starts
|
|
98
|
+
- `/autodev-execute-phase N` is only the optional manual bypass after review
|
|
95
99
|
</process>
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
<purpose>
|
|
2
|
+
Pause after phase planning so the user can review the generated plan and task breakdown before any execution starts.
|
|
3
|
+
</purpose>
|
|
4
|
+
|
|
5
|
+
<rules>
|
|
6
|
+
- Do not start task execution automatically from a freshly created plan.
|
|
7
|
+
- Keep this as a control checkpoint for the user.
|
|
8
|
+
- Do not edit repository code in this step unless the user explicitly chooses to revise the plan.
|
|
9
|
+
- Prefer `/autodev` as the entrypoint even at this checkpoint.
|
|
10
|
+
</rules>
|
|
11
|
+
|
|
12
|
+
<process>
|
|
13
|
+
1. Run:
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
node "$HOME/.claude/autodev/bin/autodev-tools.cjs" init review-plan "$ARGUMENTS"
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
2. If no planned phase is found, stop and direct the user to `/autodev`.
|
|
20
|
+
|
|
21
|
+
3. Read:
|
|
22
|
+
- `.autodev/STATE.md`
|
|
23
|
+
- the active track `STATE.md`
|
|
24
|
+
- `NN-PLAN.md`
|
|
25
|
+
- all `TASK-*.md`
|
|
26
|
+
|
|
27
|
+
4. Show the user a concise review summary:
|
|
28
|
+
- phase id and phase goal
|
|
29
|
+
- task list with dependencies
|
|
30
|
+
- likely files or areas to change
|
|
31
|
+
- shared verification plan
|
|
32
|
+
|
|
33
|
+
5. Ask the user what to do next with `AskUserQuestion`:
|
|
34
|
+
- execute the next task now
|
|
35
|
+
- revise the phase plan
|
|
36
|
+
- stop here
|
|
37
|
+
|
|
38
|
+
6. If the user chooses to execute now:
|
|
39
|
+
- read `@~/.claude/autodev/workflows/execute-phase.md`
|
|
40
|
+
- perform that workflow in the same turn
|
|
41
|
+
|
|
42
|
+
7. If the user chooses to revise the plan:
|
|
43
|
+
- read `@~/.claude/autodev/workflows/plan-phase.md`
|
|
44
|
+
- revise the same phase in the same turn
|
|
45
|
+
|
|
46
|
+
8. If the user chooses to stop here:
|
|
47
|
+
- keep both state files on:
|
|
48
|
+
- `Current Step: plan_review`
|
|
49
|
+
- `Next Command: /autodev`
|
|
50
|
+
- end with a short note that execution has not started yet
|
|
51
|
+
|
|
52
|
+
9. End with a short outcome summary and `/autodev` as the default next command.
|
|
53
|
+
</process>
|
package/package.json
CHANGED