Skip to content

refactor(aidd-refine): lean the brainstorm skill for small models - #1072

Merged
blafourcade merged 2 commits into
nextfrom
refactor/lean-brainstorm-skill
Oct 22, 2026
Merged

blafourcade merged 2 commits into
nextfrom
refactor/lean-brainstorm-skill

Conversation

@blafourcade

Copy link
Copy Markdown
Contributor

🎯 What & why

Lean aidd-refine:01-brainstorm from 13 files and 1506 words to 8 files and about 940, so it runs on Mistral small and medium under opencode as well as on Claude models, at a lower token cost.

🛠️ How it works

  • The loop is one action. probe and integrate become explore: take stock, decide whether to conclude, pick one point, ask, wait, repeat. A skill that alternates between two files forces a re-read on every turn.
  • Three actions, one per phase: capture (once), explore (loop), conclude (once). The router in SKILL.md is one mermaid whose nodes carry the file paths. The action table is gone: it repeated each file's goal.
  • References answer one question each: discovery-map (what to explore, points in order, no labels so the model has nothing to quote), probing (how to ask, 7 techniques), persistence (where the brief lives). Single-use references moved into their action.
  • Rules that must hold on later turns live in SKILL.md, not in an action read once: a stop or a summary request produces the brief; never talk about the skill's steps or files.
  • The brief is Clear / Assumed / Open. A summary can no longer present a guess as a decision. A persisted brief carries status: approved.
  • The router guard test now also mutates citations inside fenced blocks, so a mermaid router is checked like a table one. This removes the 10-batch exception.

🧪 How to verify

  • pnpm exec lefthook run pre-commit
  • node scripts/check-tests-leave-git-alone.js -- node --test 'scripts/__tests__/**/*.test.js' (477 tests)
  • Measured against the original skill on the same scripted scenarios, one run per scenario: Claude haiku / sonnet / opus cost -29% / -47% / -19%; on "stop" the new skill produces the brief with headings on 3 of 3 models, the original on 0 of 3. mistral-medium-2604 holds the loop over 22 turns with no exit from the skill and no empty reply.
  • Two real backlog issues (feat(framework): show installed versions and notify available updates #980 as S, feat(aidd-dev): carry documentation impact through feature delivery #927 as M) replayed with a simulated author: issue decisions recovered on par with the original (15 against 15).

⚠️ Heads-up

  • mistral-small-2603 asks a question on the first turn in about 60% of runs, whatever the wording (20 runs per variant), and does not always produce the brief on "stop".
  • mistral-medium-2604 asks more questions per message than the original (5.4 ? against 2.1). Four fixes were tested over 30 messages each, none helped, none is kept.
  • Invented points in the brief are slightly higher than the original (22 against 16 across the replayed dialogues), partly because the S issue is ambiguous without repo context.
  • Single run per cell for the Claude comparison: only the large gaps are signal.
  • The auto mode of aidd-orchestrator:01-sdlc is untouched: brainstorm still waits for an answer.

🔗 Linked issue

Closes #1071

✅ I certify

  • I DO CERTIFY I READ EACH LINE OF THE PULL REQUEST BECAUSE I AM A SOFTWARE ENGINEER, NOT A AI PUPPY.

🤖 Generated with Claude Code

Merge probe and integrate into explore, rename finalize to conclude, fold the
single-use references into their action, drop the point labels from the
discovery map, and give the brief a Clear / Assumed / Open template saved with
status: approved. The skill goes from 13 files and 1506 words to 8 files and
about 940.

Extend the router citation guard to fenced blocks, which covers the mermaid
routers and drops the 10-batch exception.

Refs #1071

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015M5pyeN9UkURg1E85cHMU5
@blafourcade
blafourcade marked this pull request as ready for review October 21, 2026 07:39
@blafourcade
blafourcade requested a review from a team as a code owner October 21, 2026 07:39
@github-project-automation github-project-automation Bot moved this to Ideation in AIDD Roadmap Oct 21, 2026

@alexsoyes alexsoyes left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

J'ai rien à dire 😗

@alexsoyes

Copy link
Copy Markdown
Contributor

@blafourcade blafourcade added this to the This week milestone Oct 22, 2026 — with Claude
@blafourcade
blafourcade merged commit f9a1ba2 into next Oct 22, 2026
29 checks passed
@blafourcade
blafourcade deleted the refactor/lean-brainstorm-skill branch October 22, 2026 08:02
@github-project-automation github-project-automation Bot moved this from Ideation to Done in AIDD Roadmap Oct 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants