@tianhai/pi-workflow-kit 0.8.4 → 0.10.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 +3 -1
- package/docs/developer-usage-guide.md +10 -0
- package/docs/plans/completed/2026-04-28-executing-tasks-redesign-design.md +171 -0
- package/docs/plans/completed/2026-04-28-executing-tasks-redesign-implementation.md +208 -0
- package/docs/plans/completed/2026-04-28-executing-tasks-redesign-progress.md +14 -0
- package/docs/plans/completed/2026-05-01-incorporate-mattpocock-skills-design.md +154 -0
- package/docs/plans/completed/2026-05-01-incorporate-mattpocock-skills-implementation.md +315 -0
- package/docs/plans/completed/2026-05-01-incorporate-mattpocock-skills-progress.md +15 -0
- package/docs/workflow-phases.md +13 -1
- package/package.json +1 -1
- package/skills/brainstorming/SKILL.md +17 -1
- package/skills/diagnose/SKILL.md +56 -0
- package/skills/executing-tasks/SKILL.md +160 -16
- package/skills/finalizing/SKILL.md +26 -2
- package/skills/writing-plans/SKILL.md +41 -0
|
@@ -7,13 +7,29 @@ description: "Use this after all tasks are complete to clean up, document, and s
|
|
|
7
7
|
|
|
8
8
|
Ship the completed work.
|
|
9
9
|
|
|
10
|
+
## Pre-finalization checks
|
|
11
|
+
|
|
12
|
+
### Check for skipped tasks
|
|
13
|
+
|
|
14
|
+
Before archiving, if a progress file exists (`docs/plans/*-progress.md`), read it and check for any `⏭ skipped` tasks. If found, warn:
|
|
15
|
+
|
|
16
|
+
```
|
|
17
|
+
⚠️ Tasks 4 and 7 were skipped. Continue with finalizing, or go back?
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
Wait for the user to confirm before proceeding.
|
|
21
|
+
|
|
10
22
|
## Process
|
|
11
23
|
|
|
12
|
-
1. **Move planning docs** — archive the design
|
|
24
|
+
1. **Move planning docs** — archive the design, implementation, progress docs, and ADRs (if any), then commit:
|
|
13
25
|
```
|
|
14
26
|
mkdir -p docs/plans/completed
|
|
27
|
+
mkdir -p docs/plans/completed/adr
|
|
15
28
|
mv docs/plans/*-design.md docs/plans/completed/
|
|
16
29
|
mv docs/plans/*-implementation.md docs/plans/completed/
|
|
30
|
+
mv docs/plans/*-progress.md docs/plans/completed/
|
|
31
|
+
mv docs/plans/adr/*.md docs/plans/completed/adr/ 2>/dev/null || true
|
|
32
|
+
rmdir docs/plans/adr 2>/dev/null || true
|
|
17
33
|
git add docs/plans/ && git commit -m "chore: archive planning docs"
|
|
18
34
|
```
|
|
19
35
|
|
|
@@ -30,6 +46,14 @@ Ship the completed work.
|
|
|
30
46
|
gh pr create --title "feat: <summary>" --body "<task summary>"
|
|
31
47
|
```
|
|
32
48
|
|
|
49
|
+
Use the progress file to generate the summary. Convert the task table to a bulleted list:
|
|
50
|
+
```
|
|
51
|
+
- ✅ Create User model
|
|
52
|
+
- ✅ Write User model tests
|
|
53
|
+
- ⏭ Add auth middleware (skipped)
|
|
54
|
+
- ✅ Add login endpoint
|
|
55
|
+
```
|
|
56
|
+
|
|
33
57
|
2. **Rebase & merge** *(recommended)* — rebase onto parent, fast-forward merge, push parent, delete branch:
|
|
34
58
|
```
|
|
35
59
|
parent=$(git show-branch -a 2>/dev/null | grep '\*' | grep -v "$(git branch --show-current)" | head -1 | sed 's/.*\[\(.*\)\].*/\1/' | sed 's/[\^~].*//')
|
|
@@ -54,7 +78,7 @@ Ship the completed work.
|
|
|
54
78
|
```
|
|
55
79
|
parent=$(git show-branch -a 2>/dev/null | grep '\*' | grep -v "$(git branch --show-current)" | head -1 | sed 's/.*\[\(.*\)\].*/\1/' | sed 's/[\^~].*//')
|
|
56
80
|
git checkout "$parent" && git pull
|
|
57
|
-
git merge --no-ff -m "Merge branch '<branch>'" -
|
|
81
|
+
git checkout - && git merge --no-ff -m "Merge branch '<branch>'" -
|
|
58
82
|
git push origin "$parent"
|
|
59
83
|
git branch -d - && git push origin --delete -
|
|
60
84
|
```
|
|
@@ -22,6 +22,47 @@ Each task should be 2-5 minutes of work:
|
|
|
22
22
|
- `git commit` after each task
|
|
23
23
|
- Optional `checkpoint: test` or `checkpoint: done` label
|
|
24
24
|
|
|
25
|
+
Each task must use a numbered heading:
|
|
26
|
+
|
|
27
|
+
```markdown
|
|
28
|
+
## Task N: <description>
|
|
29
|
+
|
|
30
|
+
<!-- tdd: new-feature -->
|
|
31
|
+
<!-- checkpoint: none -->
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
...where N starts at 1 and incrementally numbers each task in the plan.
|
|
35
|
+
|
|
36
|
+
The metadata comments (placed right after the heading) are optional but recommended. If present, they help the executing-tasks skill parse the plan correctly.
|
|
37
|
+
|
|
38
|
+
Valid TDD values: `new-feature`, `modifying-tested-code`, `trivial`
|
|
39
|
+
|
|
40
|
+
Valid checkpoint values: `none`, `test`, `done`
|
|
41
|
+
|
|
42
|
+
These comments are optional — if omitted, the agent infers TDD scenario and checkpoint from context.
|
|
43
|
+
|
|
44
|
+
Also use the `<!-- tdd: ... -->` and `<!-- checkpoint: ... -->` metadata comments to specify options explicitly. The inline `checkpoint: test` / `checkpoint: done` label format (e.g. in a task list) is also supported as a fallback, but the metadata comment is the canonical source.
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
## Vertical slices
|
|
48
|
+
|
|
49
|
+
Each task should be a **vertical slice** — a thin path through ALL relevant layers end-to-end, delivering one complete piece of observable behavior.
|
|
50
|
+
|
|
51
|
+
```
|
|
52
|
+
WRONG (horizontal):
|
|
53
|
+
Task 1: Create database schema for users
|
|
54
|
+
Task 2: Write user API endpoints
|
|
55
|
+
Task 3: Build user UI components
|
|
56
|
+
Task 4: Wire everything together
|
|
57
|
+
|
|
58
|
+
RIGHT (vertical):
|
|
59
|
+
Task 1: User can sign up (model + endpoint + validation + test)
|
|
60
|
+
Task 2: User can log in (auth check + token + test)
|
|
61
|
+
Task 3: User can view profile (query + endpoint + test)
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
Vertical slices ensure every committed task leaves the codebase in a testable state and reduces the blast radius of a bad task.
|
|
65
|
+
|
|
25
66
|
## TDD in the plan
|
|
26
67
|
|
|
27
68
|
Label each task with its TDD scenario:
|