feed-the-machine 1.3.0 → 1.3.1

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.
@@ -51,19 +51,73 @@ Never ask the user to provide data you can find yourself. Read the files.
51
51
 
52
52
  ---
53
53
 
54
- ## Scoring Flow
54
+ ## Scoring Dimensions
55
55
 
56
- Score execution across 5 dimensions. Read `references/protocols/SCORING-RUBRICS.md` for the full rubric for each dimension (scale breakpoints, evidence requirements, formula for Dimension 4).
56
+ Score each dimension 0–10 with a citation to specific data. Do not estimate without evidence if data is missing, note it and score conservatively.
57
57
 
58
- **The 5 dimensions:**
58
+ ### 1. Wave Parallelism Efficiency (0–10)
59
59
 
60
- 1. **Wave Parallelism Efficiency** — were independent tasks actually dispatched in parallel?
61
- 2. **Audit Pass Rate** — what percentage of tasks passed ftm-audit on the first attempt?
62
- 3. **Codex Gate Pass Rate** — what percentage of waves passed the ftm-codex-gate on the first attempt?
63
- 4. **Retry and Fix Count** — how many total review-fix cycles were needed? Lower is better.
64
- 5. **Execution Smoothness** — evidence-grounded assessment of blockers, ambiguities, and manual interventions.
60
+ Were independent tasks actually dispatched in parallel? Could more tasks have been parallelized?
65
61
 
66
- Every score requires a citation to specific data. If data for a dimension is unavailable, note the gap and score conservatively.
62
+ - **10**: Every task that could run in parallel did. No serial bottlenecks where parallelism was possible.
63
+ - **7–9**: Minor serial steps that could have been parallel (e.g., final post-processing tasks run sequentially).
64
+ - **4–6**: Significant parallelism opportunities missed. Tasks that had no dependencies ran serially.
65
+ - **1–3**: Nearly all tasks ran serially despite having no dependencies on each other.
66
+ - **0**: Everything was serial regardless of dependency structure.
67
+
68
+ Evidence to cite: wave structure from PROGRESS.md, task dependency graph, agent dispatch timestamps.
69
+
70
+ ### 2. Audit Pass Rate (0–10)
71
+
72
+ What percentage of tasks passed ftm-audit on the first attempt?
73
+
74
+ - **10**: 100% first-pass. No task needed a fix cycle.
75
+ - **8**: 90%+ first-pass. One or two tasks needed minor fixes.
76
+ - **6**: 75–89% first-pass.
77
+ - **4**: 50–74% first-pass. Roughly half the tasks needed audit remediation.
78
+ - **2**: Below 50% first-pass.
79
+ - **0**: Every single task failed audit on the first attempt.
80
+
81
+ Evidence to cite: per-task audit results (pass/fail counts, auto-fix counts, manual-fix counts).
82
+
83
+ ### 3. Codex Gate Pass Rate (0–10)
84
+
85
+ What percentage of waves passed the ftm-codex-gate on the first attempt?
86
+
87
+ - **10**: All waves passed on first gate run.
88
+ - **7–9**: One wave needed a fix-and-retry.
89
+ - **4–6**: Multiple waves needed retries.
90
+ - **1–3**: Most waves failed the gate at least once.
91
+ - **0**: Every wave failed the gate.
92
+
93
+ Evidence to cite: codex gate results per wave (pass/fail, failure types).
94
+
95
+ ### 4. Retry and Fix Count (0–10)
96
+
97
+ How many total review-fix cycles were needed across all tasks and waves? Lower is better.
98
+
99
+ Formula: score = max(0, 10 - (total_retries / task_count) * 5)
100
+
101
+ - **10**: Zero retries.
102
+ - **8**: Fewer than 0.5 retries per task on average.
103
+ - **6**: 0.5–1.0 retries per task.
104
+ - **4**: 1–2 retries per task.
105
+ - **2**: 2–3 retries per task.
106
+ - **0**: More than 3 retries per task on average.
107
+
108
+ Evidence to cite: total retries, broken down by type (audit fix, codex gate retry, manual intervention).
109
+
110
+ ### 5. Execution Smoothness (0–10)
111
+
112
+ Subjective but evidence-grounded assessment. Were there blockers, ambiguous plan steps, confusing errors, or required manual interventions?
113
+
114
+ - **10**: Fully autonomous from start to finish. No blockers, no ambiguity, no manual steps.
115
+ - **7–9**: Minor friction — one clarification needed, one unexpected error handled gracefully.
116
+ - **4–6**: Moderate friction — multiple ambiguities, one blocker that paused execution, one manual intervention.
117
+ - **1–3**: Significant friction — repeated blockers, unclear plan steps that caused wrong-direction work, multiple manual interventions.
118
+ - **0**: Execution could not proceed without constant human steering.
119
+
120
+ Evidence to cite: error log entries, any manual interventions recorded in PROGRESS.md, plan ambiguities encountered.
67
121
 
68
122
  ---
69
123
 
@@ -75,28 +129,122 @@ Every score requires a citation to specific data. If data for a dimension is una
75
129
  mkdir -p ~/.claude/ftm-retros/
76
130
  ```
77
131
 
78
- ### Step 2: Check for past retros
132
+ ### Step 2: Generate plan slug
79
133
 
80
- Before writing anything, check whether any `.md` files exist in `~/.claude/ftm-retros/`. If they do, read them all. You will use them for the Pattern Analysis section.
134
+ Take the plan title, lowercase it, replace spaces with hyphens, strip all non-alphanumeric characters except hyphens.
81
135
 
82
- ### Step 3: Write the report
136
+ Examples:
137
+ - "FTM Ecosystem Expansion" → `ftm-ecosystem-expansion`
138
+ - "Fix Auth Bug + Rate Limiting" → `fix-auth-bug-rate-limiting`
139
+ - "v2.0 API Refactor" → `v20-api-refactor`
140
+
141
+ ### Step 3: Check for past retros
142
+
143
+ Before writing anything, check whether any `.md` files exist in `~/.claude/ftm-retros/`. If they do, read them all. You will use them for the Pattern Analysis section.
83
144
 
84
- Read `references/templates/REPORT-FORMAT.md` for the exact output template, slug generation rules, and section format.
145
+ ### Step 4: Write the report
85
146
 
86
147
  Save to: `~/.claude/ftm-retros/{plan-slug}-{YYYY-MM-DD}.md`
87
148
 
149
+ Use this exact format:
150
+
151
+ ```markdown
152
+ # Retro: {Plan Title}
153
+
154
+ **Date:** {YYYY-MM-DD}
155
+ **Plan:** {absolute path to plan file}
156
+ **Duration:** {total execution time, e.g. "47 minutes"}
157
+
158
+ ## Scores
159
+
160
+ | Dimension | Score | Notes |
161
+ |-----------|-------|-------|
162
+ | Wave Parallelism | X/10 | {1-sentence justification with data} |
163
+ | Audit Pass Rate | X/10 | {N}/{total} tasks first-pass |
164
+ | Codex Gate Pass Rate | X/10 | {N}/{total} waves first-pass |
165
+ | Retry/Fix Count | X/10 | {total retries} across {N} tasks |
166
+ | Execution Smoothness | X/10 | {1-sentence justification} |
167
+
168
+ **Overall: {sum}/50**
169
+
170
+ ## Raw Data
171
+
172
+ - Tasks: {N}
173
+ - Waves: {N}
174
+ - Agents spawned: {N}
175
+ - Audit findings: {N} total ({N} auto-fixed, {N} manual)
176
+ - Codex gate results: Wave 1: pass | Wave 2: fail → pass | Wave 3: pass
177
+ - Errors/blockers: {list any, or "none"}
178
+
179
+ ## What Went Well
180
+
181
+ {2–4 specific observations, each grounded in a data point or task number.}
182
+
183
+ Example format:
184
+ - **Task 3 (auth middleware)** completed in a single commit with zero audit findings. The agent prompt had clear acceptance criteria and a scoped file list — the agent never wandered.
185
+ - **Wave 2 parallelism** was fully utilized: all 4 tasks dispatched simultaneously, cutting estimated serial time from ~32 minutes to ~9 minutes.
186
+
187
+ ## What Was Slow
188
+
189
+ {2–4 specific bottlenecks with timing data or retry counts where available.}
190
+
191
+ Example format:
192
+ - **ftm-audit Phase 1 (knip)** repeated full project analysis for each task in wave 3, even though tasks only touched 2–3 files each. Added ~40s × 5 tasks = ~3.5 minutes of unnecessary scanning.
193
+ - **Task 7 needed 3 audit fix cycles** due to an import path that kept regenerating incorrectly. The agent prompt did not specify the alias configuration in tsconfig.paths.
194
+
195
+ ## Proposed Improvements
196
+
197
+ {3–5 specific, actionable suggestions. Each must identify: which skill to change, what to change exactly, and why it would help.}
198
+
199
+ Format each as:
200
+ **N. {Short title}** — {Skill to change} — {Specific change} — {Expected impact}
201
+
202
+ Examples:
203
+ 1. **Cache knip results within a wave** — ftm-audit — In Phase 1, check whether knip results are already cached for the current wave (via a temp file at `/tmp/ftm-knip-cache-{wave-id}.json`). Only re-run knip if the cache is missing or if the files changed by this task differ from cached scope. Expected: 3× speedup for ftm-audit on large projects with many tasks per wave.
204
+ 2. **Dispatch Instrumentor and Researcher in parallel** — ftm-debug — These two agents have no shared state and currently run sequentially. Dispatch them simultaneously. Expected: ~40% reduction in ftm-debug total runtime.
205
+ 3. **Add tsconfig.paths to agent context for TypeScript projects** — ftm-executor — When generating agent prompts for TypeScript tasks, include the relevant `paths` aliases from `tsconfig.json`. Expected: eliminates the import-alias regeneration loop that caused 3 retries on Task 7.
206
+
207
+ ## Pattern Analysis
208
+
209
+ {Only include this section if past retros exist in ~/.claude/ftm-retros/}
210
+
211
+ ### Recurring Issues
212
+
213
+ {List problems that appeared in 2 or more retros. Format: "Issue description — appeared in: retro-slug-1, retro-slug-2"}
214
+
215
+ ### Score Trends
216
+
217
+ {Compare overall scores across retros. Are they improving, declining, or stable? Cite actual numbers.}
218
+
219
+ Example: Overall scores: 32/50 → 38/50 → 41/50 across the last 3 retros. Parallelism and smoothness improving; audit pass rate stuck at 6/10 for all three runs.
220
+
221
+ ### Unaddressed Suggestions
222
+
223
+ {List proposed improvements from past retros that have not yet been implemented. These get escalated — flag them explicitly.}
224
+
225
+ Format: "**[ESCALATED]** {suggestion} — first proposed in {retro-slug-date}, appeared {N} times"
226
+ ```
227
+
88
228
  ---
89
229
 
90
230
  ## Key Behaviors
91
231
 
232
+ ### Evidence-first scoring
233
+
234
+ Every score needs a citation. "Tasks passed audit" is not a citation. "12/14 tasks passed audit on first attempt; Tasks 3 and 9 each needed one auto-fix cycle" is a citation. If the data to score a dimension is genuinely unavailable, note the gap explicitly and score conservatively (assume worst case for that dimension).
235
+
92
236
  ### Improvement specificity
93
237
 
94
- "Improve parallelism" is not an improvement proposal. "Add a dependency pre-check step to ftm-executor Phase 2 that flags tasks with no declared dependencies as parallelizable, and warn when they are dispatched serially" is an improvement proposal. Every proposed improvement must be concrete enough that a future session could implement it from the description alone.
238
+ "Improve parallelism" is not an improvement proposal. "Add a dependency pre-check step to ftm-executor Phase 2 that flags tasks with no declared dependencies as parallelizable, and warn when they are dispatched serially" is an improvement proposal. Every proposed improvement must be concrete enough that a future session could implement it from the description alone without asking clarifying questions.
95
239
 
96
240
  ### Pattern escalation
97
241
 
98
242
  Recurring issues that have appeared in 3+ retros without being addressed should be flagged with `[ESCALATED - 3+ occurrences]` and moved to the top of the Proposed Improvements list. These are systemic problems, not one-off noise.
99
243
 
244
+ ### No vibes
245
+
246
+ Do not write "the execution felt smooth" or "agents seemed efficient." Write "0 manual interventions were required and all errors were caught and auto-resolved by ftm-audit Phase 2." The report is read by future executions that need to calibrate behavior, not by humans looking for encouragement.
247
+
100
248
  ---
101
249
 
102
250
  ## Output
@@ -111,7 +259,7 @@ Top issue: {single most impactful bottleneck in one sentence}
111
259
  Top suggestion: {single highest-value proposed improvement in one sentence}
112
260
  ```
113
261
 
114
- Do not print the full report to the terminal — it lives in the file.
262
+ Do not print the full report to the terminal — it lives in the file. The summary above is sufficient for the user to know the run completed and where to find details.
115
263
 
116
264
  ---
117
265
 
@@ -137,7 +285,7 @@ Confidence: [low/medium/high]"
137
285
 
138
286
  ### Experience Entry Creation
139
287
 
140
- Write a structured experience entry to `~/.claude/ftm-state/blackboard/experiences/YYYY-MM-DD_task-slug.json`.
288
+ Write a structured experience entry to `~/.claude/ftm-state/blackboard/experiences/YYYY-MM-DD_task-slug.json` following the schema in blackboard-schema.md.
141
289
 
142
290
  Key fields:
143
291
  - `task_type`: derived from the task
@@ -177,17 +325,6 @@ During the first ~10 interactions (when `experiences/index.json` has `total_coun
177
325
  - Set `confidence: "low"` on all entries
178
326
  - Prioritize breadth of recording over depth of analysis
179
327
 
180
- ## Blackboard Write
181
-
182
- After completing, update:
183
- 1. `~/.claude/ftm-state/blackboard/context.json`:
184
- - Set current_task status to "complete"
185
- - Append decision summary to recent_decisions (cap at 10)
186
- - Update session_metadata.skills_invoked and last_updated
187
- 2. Write experience file to `~/.claude/ftm-state/blackboard/experiences/YYYY-MM-DD_task-slug.json`
188
- 3. Update `experiences/index.json` with the new entry
189
- 4. Emit `task_completed`
190
-
191
328
  ## Requirements
192
329
 
193
330
  - reference: `PROGRESS.md` | optional | executor progress log for auto-triggered mode
@@ -13,7 +13,7 @@ description: Self-upgrade mechanism for ftm skills ecosystem. Checks GitHub Rele
13
13
 
14
14
  # ftm-upgrade
15
15
 
16
- Self-upgrade mechanism for the ftm skills ecosystem. Fetches the latest release from `kkudumu/ftm-brain` on GitHub, compares it to the locally installed version, and copies updated skill files in place.
16
+ Self-upgrade mechanism for the ftm skills ecosystem. Fetches the latest release from `kkudumu/ftm-skills` on GitHub, compares it to the locally installed version, and copies updated skill files in place.
17
17
 
18
18
  ---
19
19
 
@@ -135,7 +135,7 @@ Map `CHECK_FAILED <reason>` codes to user-facing messages:
135
135
  |---|---|
136
136
  | `gh_not_installed` | GitHub CLI is not installed. Install it with: `brew install gh` (macOS) or see https://cli.github.com |
137
137
  | `no_internet` | Cannot reach GitHub. Check your internet connection and try again. |
138
- | `repo_not_found` | Repository `kkudumu/ftm-brain` not found. Verify you have access to the repository. |
138
+ | `repo_not_found` | Repository `kkudumu/ftm-skills` not found. Verify you have access to the repository. |
139
139
  | `no_releases_found` | No releases found in the repository yet. Check back later. |
140
140
  | any other reason | Version check failed: `<reason>`. Try running manually: `bash ~/.claude/skills/ftm-upgrade/scripts/check-version.sh` |
141
141
 
@@ -148,9 +148,9 @@ Map `CHECK_FAILED <reason>` codes to user-facing messages:
148
148
  | `~/.claude/skills/ftm-upgrade/scripts/check-version.sh` | Query GitHub for latest release, cache result 60 min |
149
149
  | `~/.claude/skills/ftm-upgrade/scripts/upgrade.sh` | Download and install latest release |
150
150
 
151
- **Cache location**: `~/.cache/ftm-brain/version-check`
151
+ **Cache location**: `~/.cache/ftm-skills/version-check`
152
152
  **Version file**: `~/.claude/skills/ftm-version.txt`
153
- **Repo**: `kkudumu/ftm-brain`
153
+ **Repo**: `kkudumu/ftm-skills`
154
154
 
155
155
  ## Requirements
156
156
 
@@ -14,6 +14,7 @@
14
14
 
15
15
  set -euo pipefail
16
16
 
17
+ # shellcheck disable=SC2034
17
18
  INPUT=$(cat)
18
19
 
19
20
  STATE_DIR="$HOME/.claude/ftm-state"
package/install.sh CHANGED
@@ -117,7 +117,12 @@ for dir in "$REPO_DIR"/ftm*/; do
117
117
  echo " LINK $name/"
118
118
  done
119
119
 
120
- SKILL_COUNT=$(ls "$REPO_DIR"/ftm*.yml 2>/dev/null | grep -v '.default.' | wc -l | tr -d ' ')
120
+ SKILL_COUNT=0
121
+ for _f in "$REPO_DIR"/ftm*.yml; do
122
+ [ -e "$_f" ] || continue
123
+ case "$_f" in *.default.*) continue ;; esac
124
+ SKILL_COUNT=$((SKILL_COUNT + 1))
125
+ done
121
126
  echo ""
122
127
  echo " $SKILL_COUNT skills linked."
123
128
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "feed-the-machine",
3
- "version": "1.3.0",
3
+ "version": "1.3.1",
4
4
  "description": "A unified intelligence layer for Claude Code — 22 skills with OODA-based reasoning, persistent memory, multi-model deliberation, and optional operator cockpit inbox",
5
5
  "license": "MIT",
6
6
  "author": "kkudumu",