devflow-kit 1.4.0 → 1.6.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/CHANGELOG.md +51 -0
- package/README.md +7 -3
- package/dist/commands/ambient.js +1 -1
- package/dist/commands/init.js +31 -2
- package/dist/commands/list.d.ts +21 -0
- package/dist/commands/list.js +71 -3
- package/dist/plugins.js +24 -24
- package/dist/utils/manifest.d.ts +45 -0
- package/dist/utils/manifest.js +100 -0
- package/dist/utils/post-install.js +6 -1
- package/package.json +1 -1
- package/plugins/devflow-accessibility/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-ambient/.claude-plugin/plugin.json +25 -4
- package/plugins/devflow-ambient/README.md +48 -29
- package/plugins/devflow-ambient/agents/coder.md +135 -0
- package/plugins/devflow-ambient/agents/reviewer.md +165 -0
- package/plugins/devflow-ambient/agents/scrutinizer.md +80 -0
- package/plugins/devflow-ambient/agents/shepherd.md +94 -0
- package/plugins/devflow-ambient/agents/simplifier.md +93 -0
- package/plugins/devflow-ambient/agents/skimmer.md +93 -0
- package/plugins/devflow-ambient/agents/validator.md +86 -0
- package/plugins/devflow-ambient/skills/ambient-router/SKILL.md +72 -28
- package/plugins/devflow-ambient/skills/ambient-router/references/skill-catalog.md +40 -34
- package/plugins/devflow-ambient/skills/debug-orchestration/SKILL.md +69 -0
- package/plugins/devflow-ambient/skills/implementation-orchestration/SKILL.md +92 -0
- package/plugins/devflow-ambient/skills/plan-orchestration/SKILL.md +71 -0
- package/plugins/devflow-audit-claude/.claude-plugin/plugin.json +10 -1
- package/plugins/devflow-audit-claude/commands/audit-claude.md +4 -0
- package/plugins/devflow-code-review/.claude-plugin/plugin.json +2 -1
- package/plugins/devflow-code-review/agents/reviewer.md +47 -9
- package/plugins/devflow-code-review/agents/synthesizer.md +12 -5
- package/plugins/devflow-code-review/commands/code-review-teams.md +43 -30
- package/plugins/devflow-code-review/commands/code-review.md +14 -2
- package/plugins/devflow-code-review/skills/knowledge-persistence/SKILL.md +128 -0
- package/plugins/devflow-code-review/skills/knowledge-persistence/references/examples.md +44 -0
- package/plugins/devflow-core-skills/.claude-plugin/plugin.json +2 -1
- package/plugins/devflow-core-skills/skills/docs-framework/SKILL.md +7 -1
- package/plugins/devflow-core-skills/skills/search-first/SKILL.md +133 -0
- package/plugins/devflow-core-skills/skills/search-first/references/evaluation-criteria.md +101 -0
- package/plugins/devflow-core-skills/skills/test-driven-development/SKILL.md +6 -5
- package/plugins/devflow-debug/.claude-plugin/plugin.json +5 -3
- package/plugins/devflow-debug/agents/synthesizer.md +211 -0
- package/plugins/devflow-debug/commands/debug-teams.md +28 -14
- package/plugins/devflow-debug/commands/debug.md +26 -12
- package/plugins/devflow-debug/skills/knowledge-persistence/SKILL.md +128 -0
- package/plugins/devflow-debug/skills/knowledge-persistence/references/examples.md +44 -0
- package/plugins/devflow-frontend-design/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-go/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-implement/.claude-plugin/plugin.json +2 -1
- package/plugins/devflow-implement/agents/coder.md +21 -13
- package/plugins/devflow-implement/agents/simplifier.md +32 -1
- package/plugins/devflow-implement/agents/skimmer.md +5 -0
- package/plugins/devflow-implement/agents/synthesizer.md +12 -5
- package/plugins/devflow-implement/commands/implement-teams.md +73 -60
- package/plugins/devflow-implement/commands/implement.md +45 -40
- package/plugins/devflow-implement/skills/knowledge-persistence/SKILL.md +128 -0
- package/plugins/devflow-implement/skills/knowledge-persistence/references/examples.md +44 -0
- package/plugins/devflow-java/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-python/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-react/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-resolve/.claude-plugin/plugin.json +4 -3
- package/plugins/devflow-resolve/agents/simplifier.md +32 -1
- package/plugins/devflow-resolve/commands/resolve-teams.md +16 -7
- package/plugins/devflow-resolve/commands/resolve.md +16 -7
- package/plugins/devflow-resolve/skills/knowledge-persistence/SKILL.md +128 -0
- package/plugins/devflow-resolve/skills/knowledge-persistence/references/examples.md +44 -0
- package/plugins/devflow-rust/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-self-review/.claude-plugin/plugin.json +10 -1
- package/plugins/devflow-self-review/agents/simplifier.md +32 -1
- package/plugins/devflow-self-review/commands/self-review.md +10 -4
- package/plugins/devflow-specify/.claude-plugin/plugin.json +1 -1
- package/plugins/devflow-specify/agents/skimmer.md +5 -0
- package/plugins/devflow-specify/agents/synthesizer.md +12 -5
- package/plugins/devflow-specify/commands/specify-teams.md +27 -20
- package/plugins/devflow-specify/commands/specify.md +26 -19
- package/plugins/devflow-typescript/.claude-plugin/plugin.json +1 -1
- package/scripts/hooks/ambient-prompt +8 -7
- package/scripts/hooks/session-start-memory +33 -3
- package/shared/agents/coder.md +21 -13
- package/shared/agents/reviewer.md +47 -9
- package/shared/agents/simplifier.md +32 -1
- package/shared/agents/skimmer.md +5 -0
- package/shared/agents/synthesizer.md +12 -5
- package/shared/skills/ambient-router/SKILL.md +72 -28
- package/shared/skills/ambient-router/references/skill-catalog.md +40 -34
- package/shared/skills/debug-orchestration/SKILL.md +69 -0
- package/shared/skills/docs-framework/SKILL.md +7 -1
- package/shared/skills/implementation-orchestration/SKILL.md +92 -0
- package/shared/skills/knowledge-persistence/SKILL.md +128 -0
- package/shared/skills/knowledge-persistence/references/examples.md +44 -0
- package/shared/skills/plan-orchestration/SKILL.md +71 -0
- package/shared/skills/search-first/SKILL.md +133 -0
- package/shared/skills/search-first/references/evaluation-criteria.md +101 -0
- package/shared/skills/test-driven-development/SKILL.md +6 -5
- package/plugins/devflow-ambient/commands/ambient.md +0 -110
|
@@ -23,7 +23,11 @@ Investigate bugs by spawning parallel agents, each pursuing a different hypothes
|
|
|
23
23
|
|
|
24
24
|
## Phases
|
|
25
25
|
|
|
26
|
-
### Phase 1:
|
|
26
|
+
### Phase 1: Load Project Knowledge
|
|
27
|
+
|
|
28
|
+
Read `.memory/knowledge/decisions.md` and `.memory/knowledge/pitfalls.md`. Known pitfalls from prior debugging sessions and code reviews can directly inform hypothesis generation — pass their content as context to investigators in Phase 2.
|
|
29
|
+
|
|
30
|
+
### Phase 2: Context Gathering
|
|
27
31
|
|
|
28
32
|
If `$ARGUMENTS` starts with `#`, fetch the GitHub issue:
|
|
29
33
|
|
|
@@ -39,12 +43,12 @@ Analyze the bug description (from arguments or issue) and identify 3-5 plausible
|
|
|
39
43
|
- **Testable**: Can be confirmed or disproved by reading code/logs
|
|
40
44
|
- **Distinct**: Does not overlap significantly with other hypotheses
|
|
41
45
|
|
|
42
|
-
### Phase
|
|
46
|
+
### Phase 3: Investigate (Parallel)
|
|
43
47
|
|
|
44
48
|
Spawn one Explore agent per hypothesis in a **single message** (parallel execution):
|
|
45
49
|
|
|
46
50
|
```
|
|
47
|
-
Task(subagent_type="Explore"
|
|
51
|
+
Task(subagent_type="Explore"):
|
|
48
52
|
"Investigate this bug: {bug_description}
|
|
49
53
|
|
|
50
54
|
Hypothesis: {hypothesis A description}
|
|
@@ -63,7 +67,7 @@ Return a structured report:
|
|
|
63
67
|
- Evidence AGAINST: [list with file:line refs]
|
|
64
68
|
- Key finding: {one-sentence summary}"
|
|
65
69
|
|
|
66
|
-
Task(subagent_type="Explore"
|
|
70
|
+
Task(subagent_type="Explore"):
|
|
67
71
|
"Investigate this bug: {bug_description}
|
|
68
72
|
|
|
69
73
|
Hypothesis: {hypothesis B description}
|
|
@@ -71,7 +75,7 @@ Focus area: {specific code area, mechanism, or condition}
|
|
|
71
75
|
|
|
72
76
|
[same steps and return format]"
|
|
73
77
|
|
|
74
|
-
Task(subagent_type="Explore"
|
|
78
|
+
Task(subagent_type="Explore"):
|
|
75
79
|
"Investigate this bug: {bug_description}
|
|
76
80
|
|
|
77
81
|
Hypothesis: {hypothesis C description}
|
|
@@ -82,12 +86,12 @@ Focus area: {specific code area, mechanism, or condition}
|
|
|
82
86
|
(Add more investigators if bug complexity warrants 4-5 hypotheses)
|
|
83
87
|
```
|
|
84
88
|
|
|
85
|
-
### Phase
|
|
89
|
+
### Phase 4: Synthesize
|
|
86
90
|
|
|
87
91
|
Once all investigators return, spawn a Synthesizer agent to aggregate findings:
|
|
88
92
|
|
|
89
93
|
```
|
|
90
|
-
Task(subagent_type="
|
|
94
|
+
Task(subagent_type="Synthesizer"):
|
|
91
95
|
"You are a root cause analyst. Synthesize these investigation reports:
|
|
92
96
|
|
|
93
97
|
{paste all investigator reports}
|
|
@@ -100,7 +104,7 @@ Instructions:
|
|
|
100
104
|
5. Assess confidence level based on evidence strength"
|
|
101
105
|
```
|
|
102
106
|
|
|
103
|
-
### Phase
|
|
107
|
+
### Phase 5: Report
|
|
104
108
|
|
|
105
109
|
Produce the final report:
|
|
106
110
|
|
|
@@ -129,21 +133,31 @@ Produce the final report:
|
|
|
129
133
|
{HIGH/MEDIUM/LOW based on evidence strength and investigator agreement}
|
|
130
134
|
```
|
|
131
135
|
|
|
136
|
+
### Phase 6: Record Pitfall (if root cause found)
|
|
137
|
+
|
|
138
|
+
If root cause was identified with HIGH or MEDIUM confidence:
|
|
139
|
+
1. Read `~/.claude/skills/knowledge-persistence/SKILL.md` and follow its extraction procedure to record pitfalls to `.memory/knowledge/pitfalls.md`
|
|
140
|
+
2. Source field: `/debug {bug description}`
|
|
141
|
+
|
|
132
142
|
## Architecture
|
|
133
143
|
|
|
134
144
|
```
|
|
135
145
|
/debug (orchestrator)
|
|
136
146
|
│
|
|
137
|
-
├─ Phase 1:
|
|
147
|
+
├─ Phase 1: Load Project Knowledge
|
|
148
|
+
│
|
|
149
|
+
├─ Phase 2: Context gathering
|
|
138
150
|
│ └─ Git agent (fetch issue, if #N provided)
|
|
139
151
|
│
|
|
140
|
-
├─ Phase
|
|
152
|
+
├─ Phase 3: Parallel investigation
|
|
141
153
|
│ └─ 3-5 Explore agents, one per hypothesis (single message)
|
|
142
154
|
│
|
|
143
|
-
├─ Phase
|
|
155
|
+
├─ Phase 4: Synthesize
|
|
144
156
|
│ └─ Synthesizer aggregates and compares findings
|
|
145
157
|
│
|
|
146
|
-
|
|
158
|
+
├─ Phase 5: Root cause report with confidence level
|
|
159
|
+
│
|
|
160
|
+
└─ Phase 6: Record Pitfall (inline, if root cause found)
|
|
147
161
|
```
|
|
148
162
|
|
|
149
163
|
## Principles
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: knowledge-persistence
|
|
3
|
+
description: >-
|
|
4
|
+
This skill should be used when recording architectural decisions or pitfalls
|
|
5
|
+
to project knowledge files, or when loading prior decisions and known pitfalls
|
|
6
|
+
for context during investigation, specification, or review.
|
|
7
|
+
user-invocable: false
|
|
8
|
+
allowed-tools: Read, Write, Bash
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Knowledge Persistence
|
|
12
|
+
|
|
13
|
+
Record architectural decisions and pitfalls to `.memory/knowledge/` files. This is the single source of truth for the extraction procedure — commands reference this skill instead of inlining the steps.
|
|
14
|
+
|
|
15
|
+
## Iron Law
|
|
16
|
+
|
|
17
|
+
> **SINGLE SOURCE OF TRUTH**
|
|
18
|
+
>
|
|
19
|
+
> All knowledge extraction follows this procedure exactly. Commands never inline
|
|
20
|
+
> their own extraction steps — they read this skill and follow it.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## File Locations
|
|
25
|
+
|
|
26
|
+
```
|
|
27
|
+
.memory/knowledge/
|
|
28
|
+
├── decisions.md # ADR entries (append-only)
|
|
29
|
+
└── pitfalls.md # PF entries (area-specific gotchas)
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## File Formats
|
|
33
|
+
|
|
34
|
+
### decisions.md (ADR entries)
|
|
35
|
+
|
|
36
|
+
**Template header** (create if file missing):
|
|
37
|
+
```
|
|
38
|
+
<!-- TL;DR: 0 decisions. Key: -->
|
|
39
|
+
# Architectural Decisions
|
|
40
|
+
|
|
41
|
+
Append-only. Status changes allowed; deletions prohibited.
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
**Entry format**:
|
|
45
|
+
```markdown
|
|
46
|
+
## ADR-{NNN}: {Title}
|
|
47
|
+
|
|
48
|
+
- **Date**: {YYYY-MM-DD}
|
|
49
|
+
- **Status**: Accepted
|
|
50
|
+
- **Context**: {Why this decision was needed}
|
|
51
|
+
- **Decision**: {What was decided}
|
|
52
|
+
- **Consequences**: {Tradeoffs and implications}
|
|
53
|
+
- **Source**: {command and identifier, e.g. `/implement TASK-123`}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### pitfalls.md (PF entries)
|
|
57
|
+
|
|
58
|
+
**Template header** (create if file missing):
|
|
59
|
+
```
|
|
60
|
+
<!-- TL;DR: 0 pitfalls. Key: -->
|
|
61
|
+
# Known Pitfalls
|
|
62
|
+
|
|
63
|
+
Area-specific gotchas, fragile areas, and past bugs.
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
**Entry format**:
|
|
67
|
+
```markdown
|
|
68
|
+
## PF-{NNN}: {Short description}
|
|
69
|
+
|
|
70
|
+
- **Area**: {file paths or module names}
|
|
71
|
+
- **Issue**: {What goes wrong}
|
|
72
|
+
- **Impact**: {Consequences if hit}
|
|
73
|
+
- **Resolution**: {How to fix or avoid}
|
|
74
|
+
- **Source**: {command and identifier, e.g. `/code-review branch-name`}
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
---
|
|
78
|
+
|
|
79
|
+
## Extraction Procedure
|
|
80
|
+
|
|
81
|
+
Follow these steps when recording decisions or pitfalls:
|
|
82
|
+
|
|
83
|
+
1. **Read** the target file (`.memory/knowledge/decisions.md` or `.memory/knowledge/pitfalls.md`). If it doesn't exist, create it with the template header above.
|
|
84
|
+
2. **Check capacity** — count `## ADR-` or `## PF-` headings. If >=50, log "Knowledge base at capacity — skipping new entry" and stop.
|
|
85
|
+
3. **Find next ID** — find highest NNN via regex (`/^## ADR-(\d+)/` or `/^## PF-(\d+)/`), default to 0. Increment by 1.
|
|
86
|
+
4. **Deduplicate** (pitfalls only) — skip if an entry with the same Area + Issue already exists.
|
|
87
|
+
5. **Append** the new entry using the format above.
|
|
88
|
+
6. **Update TL;DR** — rewrite the `<!-- TL;DR: ... -->` comment on line 1 to reflect the new count and key topics.
|
|
89
|
+
|
|
90
|
+
## Lock Protocol
|
|
91
|
+
|
|
92
|
+
When writing, use a mkdir-based lock:
|
|
93
|
+
- Lock path: `.memory/.knowledge.lock`
|
|
94
|
+
- Timeout: 30 seconds (fail if lock not acquired)
|
|
95
|
+
- Stale recovery: if lock directory is >60 seconds old, remove it and retry
|
|
96
|
+
- Release lock after write completes (remove lock directory)
|
|
97
|
+
|
|
98
|
+
## Loading Knowledge for Context
|
|
99
|
+
|
|
100
|
+
When a command needs prior knowledge as input (not recording):
|
|
101
|
+
|
|
102
|
+
1. Read `.memory/knowledge/decisions.md` if it exists
|
|
103
|
+
2. Read `.memory/knowledge/pitfalls.md` if it exists
|
|
104
|
+
3. Pass content as context to downstream agents — prior decisions constrain scope, known pitfalls inform investigation
|
|
105
|
+
|
|
106
|
+
If neither file exists, skip silently. No error, no empty-file creation.
|
|
107
|
+
|
|
108
|
+
## Operation Budget
|
|
109
|
+
|
|
110
|
+
Recording: do inline (no agent spawn), 2-3 Read/Write operations total.
|
|
111
|
+
Loading: 1-2 Read operations, pass as context string.
|
|
112
|
+
|
|
113
|
+
---
|
|
114
|
+
|
|
115
|
+
## Extended References
|
|
116
|
+
|
|
117
|
+
For entry examples and status lifecycle details:
|
|
118
|
+
- `references/examples.md` - Full decision and pitfall entry examples
|
|
119
|
+
|
|
120
|
+
---
|
|
121
|
+
|
|
122
|
+
## Success Criteria
|
|
123
|
+
|
|
124
|
+
- [ ] Entry appended with correct sequential ID
|
|
125
|
+
- [ ] No duplicate pitfalls (same Area + Issue)
|
|
126
|
+
- [ ] TL;DR comment updated with current count
|
|
127
|
+
- [ ] Lock acquired before write, released after
|
|
128
|
+
- [ ] Capacity limit (50) respected
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Knowledge Persistence Examples
|
|
2
|
+
|
|
3
|
+
## Decision Entry Example
|
|
4
|
+
|
|
5
|
+
```markdown
|
|
6
|
+
## ADR-001: Use mkdir-based locks for concurrent session serialization
|
|
7
|
+
|
|
8
|
+
- **Date**: 2026-03-03
|
|
9
|
+
- **Status**: Accepted
|
|
10
|
+
- **Context**: Multiple Claude Code sessions can run on the same project simultaneously (different terminals, SSH, etc.). Memory writes must serialize to prevent corruption.
|
|
11
|
+
- **Decision**: Use `mkdir` as an atomic lock primitive. Lock directory at `.memory/.knowledge.lock`. 30-second timeout with 60-second stale recovery.
|
|
12
|
+
- **Consequences**: Simple, cross-platform, no external dependencies. Cannot detect holder PID if lock is stale — relies on age-based recovery. Sufficient for low-contention writes.
|
|
13
|
+
- **Source**: `/implement #99`
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Pitfall Entry Example
|
|
17
|
+
|
|
18
|
+
```markdown
|
|
19
|
+
## PF-001: Orphaned teams variants silently skipped
|
|
20
|
+
|
|
21
|
+
- **Area**: plugins/devflow-*/commands/*-teams.md, src/cli/installer
|
|
22
|
+
- **Issue**: The installer iterates base `.md` files and looks up matching `-teams.md` variants. A `-teams.md` file without a corresponding base `.md` is silently ignored during installation.
|
|
23
|
+
- **Impact**: Teams variant appears committed but never installs. Users on `--teams` mode silently get no command.
|
|
24
|
+
- **Resolution**: Always create the base `.md` file first. CI should validate that every `-teams.md` has a matching base file.
|
|
25
|
+
- **Source**: `/code-review feat/agent-teams`
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Status Lifecycle (Decisions Only)
|
|
29
|
+
|
|
30
|
+
Decisions support status transitions:
|
|
31
|
+
- `Accepted` — current, in effect
|
|
32
|
+
- `Superseded by ADR-NNN` — replaced by a newer decision
|
|
33
|
+
- `Deprecated` — no longer relevant, kept for history
|
|
34
|
+
|
|
35
|
+
Pitfalls have no status field — they remain until manually removed.
|
|
36
|
+
|
|
37
|
+
## Deduplication Logic (Pitfalls Only)
|
|
38
|
+
|
|
39
|
+
Before appending a new pitfall, check existing entries:
|
|
40
|
+
1. Extract `Area` and `Issue` from the new entry
|
|
41
|
+
2. Compare against all existing `PF-*` entries
|
|
42
|
+
3. If both Area AND Issue match an existing entry (case-insensitive substring), skip
|
|
43
|
+
|
|
44
|
+
This prevents recording the same gotcha from multiple review cycles.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"author": {
|
|
5
5
|
"name": "Dean0x"
|
|
6
6
|
},
|
|
7
|
-
"version": "1.
|
|
7
|
+
"version": "1.6.0",
|
|
8
8
|
"homepage": "https://github.com/dean0x/devflow",
|
|
9
9
|
"repository": "https://github.com/dean0x/devflow",
|
|
10
10
|
"license": "MIT",
|
|
@@ -29,6 +29,7 @@
|
|
|
29
29
|
"skills": [
|
|
30
30
|
"agent-teams",
|
|
31
31
|
"implementation-patterns",
|
|
32
|
+
"knowledge-persistence",
|
|
32
33
|
"self-review"
|
|
33
34
|
]
|
|
34
35
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: Coder
|
|
3
3
|
description: Autonomous task implementation on feature branch. Implements, tests, and commits.
|
|
4
4
|
model: inherit
|
|
5
|
-
skills: core-patterns, git-safety, implementation-patterns, git-workflow, test-patterns, input-validation
|
|
5
|
+
skills: core-patterns, git-safety, implementation-patterns, git-workflow, test-patterns, test-driven-development, search-first, input-validation
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Coder Agent
|
|
@@ -29,11 +29,16 @@ You receive from orchestrator:
|
|
|
29
29
|
|
|
30
30
|
## Responsibilities
|
|
31
31
|
|
|
32
|
-
1. **Orient on branch state
|
|
32
|
+
1. **Orient on branch state** (always, before any implementation):
|
|
33
|
+
- Run `git log --oneline --stat -n 10` to scan recent commit history on this branch
|
|
34
|
+
- Run `git status` and `git diff --stat` and `git diff --cached --stat` to see uncommitted/unstaged work
|
|
35
|
+
- Cross-reference changed files against EXECUTION_PLAN to identify what's relevant to your task
|
|
36
|
+
- Read those relevant files to understand interfaces, types, naming conventions, error handling, and testing patterns established by prior work
|
|
37
|
+
- If PRIOR_PHASE_SUMMARY is provided, use it to validate your understanding — actual code is authoritative, summaries are supplementary
|
|
38
|
+
- If `.memory/knowledge/decisions.md` exists, read it. Apply prior architectural decisions relevant to this task. Avoid contradicting accepted decisions without documenting a new ADR.
|
|
39
|
+
- If `.memory/knowledge/pitfalls.md` exists, scan for pitfalls in files you're about to modify.
|
|
33
40
|
|
|
34
|
-
2. **
|
|
35
|
-
|
|
36
|
-
3. **Load domain skills**: Based on DOMAIN hint and files in scope, dynamically load relevant language/ecosystem skills by reading their SKILL.md. Only load skills that are installed:
|
|
41
|
+
2. **Load domain skills**: Based on DOMAIN hint and files in scope, dynamically load relevant language/ecosystem skills by reading their SKILL.md. Only load skills that are installed:
|
|
37
42
|
- `backend` (TypeScript): Read `~/.claude/skills/typescript/SKILL.md`, `~/.claude/skills/input-validation/SKILL.md`
|
|
38
43
|
- `backend` (Go): Read `~/.claude/skills/go/SKILL.md`
|
|
39
44
|
- `backend` (Java): Read `~/.claude/skills/java/SKILL.md`
|
|
@@ -44,22 +49,22 @@ You receive from orchestrator:
|
|
|
44
49
|
- `fullstack`: Combine backend + frontend skills
|
|
45
50
|
- If a Read fails (skill not installed), skip it silently and continue.
|
|
46
51
|
|
|
47
|
-
|
|
52
|
+
3. **Implement the plan**: Work through execution steps systematically, creating and modifying files. Follow existing patterns. Type everything. Use Result types if codebase uses them.
|
|
48
53
|
|
|
49
|
-
|
|
54
|
+
4. **Write tests**: Add tests for new functionality. Cover happy path, error cases, and edge cases. Follow existing test patterns.
|
|
50
55
|
|
|
51
|
-
|
|
56
|
+
5. **Run tests**: Execute the test suite. Fix any failures. All tests must pass before proceeding.
|
|
52
57
|
|
|
53
|
-
|
|
58
|
+
6. **Commit and push**: Create atomic commits with clear messages. Reference TASK_ID. Push to remote.
|
|
54
59
|
|
|
55
|
-
|
|
60
|
+
7. **Create PR** (if CREATE_PR=true): Create pull request against BASE_BRANCH with summary and testing notes.
|
|
56
61
|
|
|
57
|
-
|
|
62
|
+
8. **Generate handoff** (if HANDOFF_REQUIRED=true): Include implementation summary for next Coder (see Output section).
|
|
58
63
|
|
|
59
64
|
## Principles
|
|
60
65
|
|
|
61
66
|
1. **Work on feature branch** - All operations happen on the current feature branch
|
|
62
|
-
2. **Branch orientation first** -
|
|
67
|
+
2. **Branch orientation first** - Always orient on branch state before writing code; actual code is authoritative over summaries
|
|
63
68
|
3. **Pattern discovery first** - Before writing code, find similar implementations and match their conventions
|
|
64
69
|
4. **Be decisive** - Make confident implementation choices. Don't present alternatives or ask permission for tactical decisions
|
|
65
70
|
5. **Follow existing patterns** - Match codebase style, don't invent new conventions
|
|
@@ -86,6 +91,9 @@ Return structured completion status:
|
|
|
86
91
|
### PR (if created)
|
|
87
92
|
- URL: {pr_url}
|
|
88
93
|
|
|
94
|
+
### Key Decisions (if any)
|
|
95
|
+
- {Decision}: {rationale}
|
|
96
|
+
|
|
89
97
|
### Blockers (if any)
|
|
90
98
|
{Description of blocker or failure with recommendation}
|
|
91
99
|
```
|
|
@@ -124,4 +132,4 @@ Return structured completion status:
|
|
|
124
132
|
- Switch branches during implementation
|
|
125
133
|
- Push to branches other than your feature branch
|
|
126
134
|
- Merge PRs (orchestrator handles this)
|
|
127
|
-
- Trust handoff summaries without reading actual code
|
|
135
|
+
- Trust handoff summaries without reading actual code
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: Simplifier
|
|
3
3
|
description: Simplifies and refines code for clarity, consistency, and maintainability while preserving all functionality. Focuses on recently modified code unless instructed otherwise.
|
|
4
|
+
skills: core-patterns
|
|
4
5
|
model: inherit
|
|
5
6
|
---
|
|
6
7
|
|
|
@@ -59,4 +60,34 @@ Your refinement process:
|
|
|
59
60
|
5. Verify the refined code is simpler and more maintainable
|
|
60
61
|
6. Document only significant changes that affect understanding
|
|
61
62
|
|
|
62
|
-
You operate autonomously and proactively, refining code immediately after it's written or modified without requiring explicit requests. Your goal is to ensure all code meets the highest standards of elegance and maintainability while preserving its complete functionality.
|
|
63
|
+
You operate autonomously and proactively, refining code immediately after it's written or modified without requiring explicit requests. Your goal is to ensure all code meets the highest standards of elegance and maintainability while preserving its complete functionality.
|
|
64
|
+
|
|
65
|
+
## Output
|
|
66
|
+
|
|
67
|
+
Return structured completion status:
|
|
68
|
+
|
|
69
|
+
```markdown
|
|
70
|
+
## Simplification Report
|
|
71
|
+
|
|
72
|
+
### Changes Applied
|
|
73
|
+
- {file}: {description of simplification}
|
|
74
|
+
|
|
75
|
+
### Changes Skipped
|
|
76
|
+
- {reason not simplified — would change behavior / already clean}
|
|
77
|
+
|
|
78
|
+
### Files Modified
|
|
79
|
+
- {file} ({change description})
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Boundaries
|
|
83
|
+
|
|
84
|
+
**Escalate to orchestrator:**
|
|
85
|
+
- Changes that would alter observable behavior or break tests
|
|
86
|
+
- Simplifications requiring new dependencies or architectural changes
|
|
87
|
+
- Files outside the recently modified scope (unless instructed)
|
|
88
|
+
|
|
89
|
+
**Handle autonomously:**
|
|
90
|
+
- Naming improvements, dead code removal, nesting reduction
|
|
91
|
+
- Import sorting and organization
|
|
92
|
+
- Redundant abstraction elimination
|
|
93
|
+
- Comment cleanup (remove obvious, keep non-obvious)
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: Skimmer
|
|
3
3
|
description: Codebase orientation using skim to identify relevant files, functions, and patterns for a feature or task
|
|
4
|
+
skills: knowledge-persistence
|
|
4
5
|
model: inherit
|
|
5
6
|
---
|
|
6
7
|
|
|
@@ -20,6 +21,7 @@ You receive from orchestrator:
|
|
|
20
21
|
3. **Search for task-relevant code** - Find files matching task keywords
|
|
21
22
|
4. **Identify integration points** - Exports, entry points, import patterns
|
|
22
23
|
5. **Generate orientation summary** - Structured output for implementation planning
|
|
24
|
+
6. **Check project knowledge** - If `.memory/knowledge/decisions.md` exists, read its `<!-- TL;DR: ... -->` first-line comment and include active decision count in orientation under "### Active Decisions". Only the TL;DR is read here (not full entries) — this is intentional for token efficiency; agents that need full entries read the file themselves.
|
|
23
25
|
|
|
24
26
|
## Tool Invocation
|
|
25
27
|
|
|
@@ -64,6 +66,9 @@ Always invoke skim via `npx rskim`. This works whether or not skim is globally i
|
|
|
64
66
|
### Patterns Observed
|
|
65
67
|
{Existing patterns to follow}
|
|
66
68
|
|
|
69
|
+
### Active Decisions
|
|
70
|
+
{Count and key decisions from `.memory/knowledge/decisions.md` TL;DR, or "None found" if file missing}
|
|
71
|
+
|
|
67
72
|
### Suggested Approach
|
|
68
73
|
{Brief recommendation based on codebase structure}
|
|
69
74
|
```
|
|
@@ -128,10 +128,14 @@ Analyze 3 axes to determine strategy:
|
|
|
128
128
|
Synthesize outputs from multiple Reviewer agents. Apply strict merge rules.
|
|
129
129
|
|
|
130
130
|
**Process:**
|
|
131
|
-
1. Read all review reports from `${REVIEW_BASE_DIR}
|
|
132
|
-
2.
|
|
133
|
-
3.
|
|
134
|
-
|
|
131
|
+
1. Read all review reports from `${REVIEW_BASE_DIR}/*.md` (exclude your own output `review-summary.*.md`)
|
|
132
|
+
2. Extract confidence percentages from each finding
|
|
133
|
+
3. Apply confidence-aware aggregation: when multiple reviewers flag the same file:line, boost confidence by 10% per additional reviewer (cap at 100%)
|
|
134
|
+
<!-- Confidence threshold also in: shared/agents/reviewer.md, plugins/devflow-code-review/commands/code-review.md -->
|
|
135
|
+
4. Maintain ≥80% confidence threshold in final output
|
|
136
|
+
5. Categorize issues into 3 buckets (from review-methodology)
|
|
137
|
+
6. Count by severity (CRITICAL, HIGH, MEDIUM, LOW)
|
|
138
|
+
7. Determine merge recommendation based on blocking issues
|
|
135
139
|
|
|
136
140
|
**Issue Categories:**
|
|
137
141
|
- **Blocking** (Category 1): Issues in YOUR changes - CRITICAL/HIGH must block
|
|
@@ -172,7 +176,10 @@ Report format:
|
|
|
172
176
|
| Pre-existing | - | - | {n} | {n} | {n} |
|
|
173
177
|
|
|
174
178
|
## Blocking Issues
|
|
175
|
-
{List with file:line and suggested fix}
|
|
179
|
+
{List with file:line, confidence %, and suggested fix}
|
|
180
|
+
|
|
181
|
+
## Suggestions (Lower Confidence)
|
|
182
|
+
{Max 5 items across all reviewers with 60-79% confidence. Brief descriptions only.}
|
|
176
183
|
|
|
177
184
|
## Action Plan
|
|
178
185
|
1. {Priority fix}
|