pi-feature-dev 1.0.0 → 1.1.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
@@ -1,13 +1,17 @@
1
1
  # pi-feature-dev
2
2
 
3
- Pi-native guided feature development workflow.
3
+ Portable guided feature development workflow, packaged as a Pi skill.
4
4
 
5
- This package adapts a Claude Code-style feature development workflow to Pi using Pi packages and tools:
5
+ The skill describes a tool-agnostic process for non-trivial feature work:
6
6
 
7
- - `pi-subagents` for scout/planner/worker/reviewer fanout
8
- - `@juicesharp/rpiv-todo` for phase tracking
9
- - `@juicesharp/rpiv-ask-user-question` for structured choices
10
- - optional `context-mode`, `pi-web-access`, and `pi-intercom` for large-output handling, web/code research, and session coordination
7
+ - clarify requirements before coding
8
+ - explore the existing codebase before design
9
+ - compare implementation approaches and get approval
10
+ - implement with one writer
11
+ - review the diff from multiple perspectives
12
+ - validate and summarize results
13
+
14
+ It does not require specific task-tracking, question, delegation, or review tools. If the current environment provides equivalent capabilities, use them; otherwise follow the same workflow directly in chat and with normal code tools.
11
15
 
12
16
  ## Install
13
17
 
@@ -35,27 +39,13 @@ If installing for a project, run from that project and use Pi's local install fl
35
39
  pi install -l ~/Projects/pi-feature-dev
36
40
  ```
37
41
 
38
- ## Required companion packages
39
-
40
- This workflow expects these Pi tools to be available:
41
-
42
- ```bash
43
- pi install npm:pi-subagents
44
- pi install npm:@juicesharp/rpiv-todo
45
- pi install npm:@juicesharp/rpiv-ask-user-question
46
- ```
47
-
48
- Recommended optional packages:
42
+ ## Optional companion packages
49
43
 
50
- ```bash
51
- pi install npm:context-mode
52
- pi install npm:pi-web-access
53
- pi install npm:pi-intercom
54
- ```
44
+ No companion package is required. Optional Pi packages can improve specific parts of the workflow, such as progress tracking, structured choices, delegation, large-output handling, web/code research, or session coordination.
55
45
 
56
46
  ## Usage
57
47
 
58
- Skill command:
48
+ Skill command in Pi:
59
49
 
60
50
  ```text
61
51
  /skill:feature-dev Add OAuth login with Google and GitHub
@@ -67,18 +57,20 @@ Natural language also works when Pi's skill matcher triggers:
67
57
  Use feature-dev to implement API rate limiting.
68
58
  ```
69
59
 
70
- This package is intentionally skill-only. It does not provide a `/feature-dev` prompt template shortcut; use `/skill:feature-dev` for explicit invocation.
60
+ The `skills/feature-dev/SKILL.md` file is portable markdown and can be adapted for other coding assistant environments.
61
+
62
+ This package is intentionally skill-only. It does not provide a `/feature-dev` prompt template shortcut; use `/skill:feature-dev` for explicit Pi invocation.
71
63
 
72
64
  ## What it does
73
65
 
74
- The skill guides Pi through a seven-phase process:
66
+ The skill guides a coding assistant through a seven-phase process:
75
67
 
76
- 1. Discovery — understand the feature and create todos
77
- 2. Codebase exploration — inspect relevant code and patterns, optionally with parallel subagents
68
+ 1. Discovery — understand the feature and establish lightweight progress tracking
69
+ 2. Codebase exploration — inspect relevant code and patterns, optionally with read-only helper passes
78
70
  3. Clarifying questions — resolve ambiguity before design
79
71
  4. Architecture design — compare minimal, clean, and pragmatic approaches
80
72
  5. Implementation — only after approval, with a single writer
81
- 6. Quality review — parallel fresh-context reviewers inspect the diff
73
+ 6. Quality review — inspect the diff from correctness, validation, and maintainability perspectives
82
74
  7. Validation and summary — run focused checks and summarize changes
83
75
 
84
76
  ## Package contents
@@ -91,8 +83,6 @@ pi-feature-dev/
91
83
  └── SKILL.md
92
84
  ```
93
85
 
94
- The package intentionally does **not** ship custom subagent definitions. It uses the built-in roles from `pi-subagents` (`scout`, `context-builder`, `planner`, `worker`, `reviewer`, `researcher`, `oracle`) so it stays small and tracks improvements in that package.
95
-
96
86
  ## Release
97
87
 
98
88
  Releases are automated with GitHub Actions and semantic-release.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pi-feature-dev",
3
- "version": "1.0.0",
4
- "description": "Pi-native guided feature development workflow using subagents, todos, clarification questions, implementation, and review loops.",
3
+ "version": "1.1.0",
4
+ "description": "Portable guided feature development workflow for coding assistants, packaged as a Pi skill.",
5
5
  "license": "MIT",
6
6
  "type": "module",
7
7
  "repository": {
@@ -20,7 +20,8 @@
20
20
  "pi",
21
21
  "pi-coding-agent",
22
22
  "feature-development",
23
- "subagents",
23
+ "coding-assistants",
24
+ "workflow",
24
25
  "skills"
25
26
  ],
26
27
  "files": [
@@ -1,47 +1,29 @@
1
1
  ---
2
2
  name: feature-dev
3
- description: Structured feature development workflow for Pi. Use for non-trivial feature work requiring codebase exploration, clarification, architecture trade-offs, implementation approval, subagent review, and final summary.
4
- compatibility: "Pi. Best with pi-subagents, @juicesharp/rpiv-todo, and @juicesharp/rpiv-ask-user-question installed; optional context-mode, pi-web-access, and pi-intercom improve the workflow."
3
+ description: Structured feature development workflow for coding assistants. Use for non-trivial feature work requiring codebase exploration, clarification, architecture trade-offs, implementation approval, review, and final summary.
4
+ compatibility: "Portable across coding assistant environments. Optional task tracking, structured-question, delegation, search, and browser tools can improve the workflow, but are not required."
5
5
  ---
6
6
 
7
- # Feature Dev for Pi
7
+ # Feature Dev
8
8
 
9
- Run a guided, Pi-native feature development workflow. This skill replaces the Claude Code `feature-dev` command/agents with Pi tools:
9
+ Run a guided, tool-agnostic feature development workflow. Adapt each step to the capabilities of the current environment:
10
10
 
11
- - `todo` for phase/progress tracking
12
- - `subagent` from `pi-subagents` for scout/planner/worker/reviewer fanout
13
- - `ask_user_question` for structured decisions and multiple-choice clarification
14
- - `web_search`, `code_search`, and `fetch_content` for external context when needed
15
- - `intercom` only when coordinating with separate live Pi sessions or subagent escalations
11
+ - Track phase/progress state with any available planning mechanism, or keep a concise written checklist in chat.
12
+ - Ask clarification and decision questions in normal chat; use structured-choice UI/tools only if available.
13
+ - Use search, documentation, browser, or repository tools for external context when needed.
14
+ - For broad work, optionally delegate read-only exploration, planning, or review to independent helpers if the environment supports it.
16
15
 
17
- This skill is for the parent/orchestrator session. Child subagents should receive concrete role-specific tasks; do not ask child agents to run this workflow or spawn their own subagents.
16
+ This workflow is for the main orchestrating session. Keep responsibilities clear: one writer owns file edits, while any optional helpers stay read-only unless the user explicitly approves a different handoff.
18
17
 
19
18
  ## Operating Rules
20
19
 
21
20
  1. **Clarify before coding.** Do not implement until scope, acceptance criteria, constraints, and non-goals are clear enough.
22
21
  2. **Explore before designing.** Inspect relevant existing code and patterns before proposing architecture.
23
22
  3. **Ask before implementation.** Present the preferred architecture and wait for explicit user approval before editing.
24
- 4. **Keep writes single-threaded.** Use the parent session or one `worker` subagent as the writer. Never run parallel writers in the same checkout.
25
- 5. **Review after implementation.** Use fresh-context reviewers to inspect the diff, synthesize findings, then apply only approved/worthwhile fixes.
26
- 6. **Use available tools only.** If a recommended tool is unavailable, continue with the closest Pi-native alternative and state the fallback briefly.
27
- 7. **For large outputs.** If context-mode tools are available, use them for test/build/log/git output. Otherwise run focused commands and summarize concise output.
28
-
29
- Before executing any subagent, call `subagent({ action: "list" })` and only use executable/non-disabled agents from the result.
30
-
31
- ## Recommended Agent Mapping
32
-
33
- Use built-in `pi-subagents` roles by default:
34
-
35
- | Need | Pi role |
36
- | --- | --- |
37
- | Codebase exploration | `scout` or `context-builder` |
38
- | Architecture planning | `planner` |
39
- | Implementation handoff | `worker` |
40
- | Quality review | `reviewer` |
41
- | External evidence | `researcher` |
42
- | Decision consistency/advisory review | `oracle` |
43
-
44
- Do not create custom agents unless the user explicitly wants persistent role overrides. This package intentionally works with built-in Pi subagents.
23
+ 4. **Keep writes single-threaded.** Use the main session or one dedicated writer. Never run parallel writers in the same checkout.
24
+ 5. **Review after implementation.** Inspect the diff from fresh perspectives, synthesize findings, then apply only approved/worthwhile fixes.
25
+ 6. **Use available tools only.** If a recommended capability is unavailable, continue with the closest alternative and state the fallback briefly.
26
+ 7. **For large outputs.** Use any available large-output/log-processing tools. Otherwise run focused commands and summarize concise output.
45
27
 
46
28
  ## Workflow
47
29
 
@@ -51,51 +33,30 @@ Goal: understand what needs to be built.
51
33
 
52
34
  Actions:
53
35
 
54
- 1. Create phase todos with `todo` for Discovery, Exploration, Clarification, Architecture, Implementation, Review, and Summary/Validation. Keep exactly one todo `in_progress` at a time.
36
+ 1. Establish lightweight phase tracking for Discovery, Exploration, Clarification, Architecture, Implementation, Review, and Summary/Validation. Keep exactly one phase active at a time when your environment supports explicit progress state.
55
37
  2. If the feature request is unclear, ask concise questions before doing deep work:
56
38
  - What problem should this solve?
57
39
  - What should the user-visible behavior be?
58
40
  - What constraints, deadlines, compatibility requirements, or non-goals matter?
59
41
  3. Summarize your understanding and call out assumptions.
60
42
 
61
- Use `ask_user_question` only for questions with 2-4 clear choices. For open-ended requirements, ask normally in chat.
43
+ Use structured-choice prompts only for questions with 2-4 clear choices. For open-ended requirements, ask normally in chat.
62
44
 
63
45
  ### Phase 2 — Codebase Exploration
64
46
 
65
47
  Goal: understand relevant code and project patterns at high and low levels.
66
48
 
67
- Default subagent fanout for non-trivial features:
68
-
69
- ```ts
70
- subagent({
71
- action: "list"
72
- })
73
-
74
- subagent({
75
- tasks: [
76
- {
77
- agent: "scout",
78
- task: "Find features similar to <feature> and trace their implementation. Return key entry points, data flow, conventions, risks, and 5-10 essential files to read. Do not edit files."
79
- },
80
- {
81
- agent: "context-builder",
82
- task: "Map the architecture, abstractions, module boundaries, and integration points relevant to <feature>. Return file:line references and 5-10 essential files to read. Do not edit files."
83
- },
84
- {
85
- agent: "scout",
86
- task: "Identify tests, validation patterns, UI/API patterns, configuration, and extension points relevant to <feature>. Return concrete files and gaps. Do not edit files."
87
- }
88
- ],
89
- concurrency: 3,
90
- context: "fresh"
91
- })
92
- ```
49
+ For non-trivial features, perform these read-only exploration passes. Use independent helpers only if available; otherwise do the passes yourself:
93
50
 
94
- Adapt the tasks to the project. Use two agents for medium work; three for broad features. Skip subagents for trivial single-file changes, but still inspect relevant files yourself.
51
+ 1. Find features similar to the requested feature and trace their implementation. Return key entry points, data flow, conventions, risks, and 5-10 essential files to read.
52
+ 2. Map architecture, abstractions, module boundaries, and integration points relevant to the feature. Return file:line references and 5-10 essential files to read.
53
+ 3. Identify tests, validation patterns, UI/API patterns, configuration, and extension points relevant to the feature. Return concrete files and gaps.
95
54
 
96
- After subagents return:
55
+ Use two passes for medium work; three for broad features. Skip delegation for trivial single-file changes, but still inspect relevant files yourself.
97
56
 
98
- 1. Read the essential files they identified.
57
+ After exploration:
58
+
59
+ 1. Read the essential files identified.
99
60
  2. Follow imports/callers/tests/config as needed.
100
61
  3. Present a concise findings summary: similar patterns, relevant files, likely integration points, risks, and unknowns.
101
62
 
@@ -114,7 +75,7 @@ Review the feature request plus exploration findings. Identify gaps in:
114
75
  - tests and validation expectations
115
76
  - rollout/feature flags/documentation needs
116
77
 
117
- Ask all necessary questions in one organized batch. Use `ask_user_question` for structured decisions; otherwise ask a numbered free-form list. Wait for answers before architecture design.
78
+ Ask all necessary questions in one organized batch. Use structured-choice prompts for discrete decisions when available; otherwise ask a numbered free-form list. Wait for answers before architecture design.
118
79
 
119
80
  If the user says “whatever you think is best,” state your recommendation and get explicit confirmation unless the decision is low-risk and reversible.
120
81
 
@@ -122,28 +83,18 @@ If the user says “whatever you think is best,” state your recommendation and
122
83
 
123
84
  Goal: compare viable implementation approaches and get approval.
124
85
 
125
- For complex work, run 2-3 planning passes with different trade-off lenses:
126
-
127
- ```ts
128
- subagent({
129
- tasks: [
130
- {
131
- agent: "planner",
132
- task: "Design a minimal-change implementation for <feature> using the exploration findings and clarified requirements below. Include files to change, build sequence, risks, validation. Do not edit files.\n\n<context>..."
133
- },
134
- {
135
- agent: "planner",
136
- task: "Design a clean-architecture implementation for <feature> prioritizing maintainability and testability. Include files to change, build sequence, risks, validation. Do not edit files.\n\n<context>..."
137
- },
138
- {
139
- agent: "planner",
140
- task: "Design a pragmatic balanced implementation for <feature>. Include files to change, build sequence, risks, validation. Do not edit files.\n\n<context>..."
141
- }
142
- ],
143
- concurrency: 3,
144
- context: "fresh"
145
- })
146
- ```
86
+ For complex work, run 2-3 planning passes with different trade-off lenses. These can be separate self-review passes or delegated read-only planning if available:
87
+
88
+ 1. **Minimal-change implementation** — smallest safe diff using existing patterns.
89
+ 2. **Clean-architecture implementation** — prioritize maintainability, testability, and clear boundaries.
90
+ 3. **Pragmatic balanced implementation** — balance implementation cost, maintainability, and risk.
91
+
92
+ Each pass should include:
93
+
94
+ - files to change
95
+ - build sequence
96
+ - risks and trade-offs
97
+ - validation plan
147
98
 
148
99
  Then synthesize:
149
100
 
@@ -153,7 +104,7 @@ Then synthesize:
153
104
  - your recommendation and reasoning
154
105
  - validation plan
155
106
 
156
- Ask the user which approach to use. `ask_user_question` is ideal here with options like Minimal, Pragmatic, Clean.
107
+ Ask the user which approach to use. A structured choice is helpful when available, with options like Minimal, Pragmatic, Clean.
157
108
 
158
109
  ### Phase 5 — Implementation
159
110
 
@@ -163,16 +114,33 @@ Do not start without explicit approval.
163
114
 
164
115
  Implementation options:
165
116
 
166
- - **Parent writes directly** for small/medium scoped changes where you already have enough context.
167
- - **One `worker` subagent** for larger changes after approval. Provide a complete handoff: requirements, chosen approach, files/areas, non-goals, acceptance criteria, validation, and escalation rules.
117
+ - **Main session writes directly** for small/medium scoped changes where enough context is already available.
118
+ - **One dedicated writer** for larger changes after approval, if the environment supports handoff. Provide requirements, chosen approach, files/areas, non-goals, acceptance criteria, validation, and escalation rules.
119
+
120
+ Writer handoff shape:
121
+
122
+ ```text
123
+ Implement the approved <feature> plan.
124
+
125
+ Clarified requirements:
126
+ - ...
127
+
128
+ Chosen approach:
129
+ - ...
130
+
131
+ Likely files/areas:
132
+ - ...
168
133
 
169
- Worker handoff shape:
134
+ Non-goals:
135
+ - ...
170
136
 
171
- ```ts
172
- subagent({
173
- agent: "worker",
174
- task: "Implement the approved <feature> plan.\n\nClarified requirements:\n- ...\n\nChosen approach:\n- ...\n\nLikely files/areas:\n- ...\n\nNon-goals:\n- ...\n\nAcceptance criteria:\n- ...\n\nValidation expected:\n- ...\n\nUse one writer thread only. Ask before unapproved product, API, or architecture changes. Summarize files changed and validation results."
175
- })
137
+ Acceptance criteria:
138
+ - ...
139
+
140
+ Validation expected:
141
+ - ...
142
+
143
+ Use one writer thread only. Ask before unapproved product, API, or architecture changes. Summarize files changed and validation results.
176
144
  ```
177
145
 
178
146
  During implementation:
@@ -180,37 +148,22 @@ During implementation:
180
148
  1. Follow existing patterns discovered earlier.
181
149
  2. Keep changes focused on the approved scope.
182
150
  3. Add or update tests when appropriate.
183
- 4. Update todos as each implementation subtask finishes.
151
+ 4. Update progress tracking as each implementation subtask finishes when such tracking is available.
184
152
  5. If a new major decision appears, stop and ask.
185
153
 
186
154
  ### Phase 6 — Quality Review
187
155
 
188
156
  Goal: catch correctness, test, and maintainability issues.
189
157
 
190
- After implementation, review the current diff. Default parallel review:
191
-
192
- ```ts
193
- subagent({
194
- tasks: [
195
- {
196
- agent: "reviewer",
197
- task: "Review the current diff for correctness, regressions, edge cases, and security issues. Inspect changed files directly. Do not edit files. Report only evidence-backed issues with file/line references."
198
- },
199
- {
200
- agent: "reviewer",
201
- task: "Review the current diff for tests and validation quality. Inspect changed files directly. Do not edit files. Report missing high-value tests or broken validation with file/line references."
202
- },
203
- {
204
- agent: "reviewer",
205
- task: "Review the current diff for simplicity, DRYness, maintainability, and project convention fit. Inspect changed files directly. Do not edit files. Report only important issues with file/line references."
206
- }
207
- ],
208
- concurrency: 3,
209
- context: "fresh"
210
- })
211
- ```
158
+ After implementation, review the current diff. For non-trivial changes, inspect it from these independent perspectives yourself or with read-only review helpers if available:
159
+
160
+ 1. Correctness, regressions, edge cases, and security.
161
+ 2. Tests and validation quality.
162
+ 3. Simplicity, maintainability, duplication, and project convention fit.
163
+
164
+ Each review perspective should inspect changed files directly and report only evidence-backed issues with file/line references.
212
165
 
213
- Synthesize reviewer output into:
166
+ Synthesize review output into:
214
167
 
215
168
  - blockers / must-fix now
216
169
  - fixes worth doing now
@@ -226,8 +179,8 @@ Goal: prove the feature is complete and document outcomes.
226
179
  Actions:
227
180
 
228
181
  1. Run focused validation: tests, typecheck, lint, build, or manual checks appropriate to the project.
229
- 2. If validation fails, keep the current todo `in_progress`, explain the blocker, and fix or ask for direction.
230
- 3. When validation passes or the user accepts known limitations, mark todos complete.
182
+ 2. If validation fails, keep the current phase active, explain the blocker, and fix or ask for direction.
183
+ 3. When validation passes or the user accepts known limitations, mark the workflow complete in whatever progress tracking is available.
231
184
  4. Summarize:
232
185
  - what was built
233
186
  - key decisions made