writing-skills
writing-skills
Use when creating new skills, editing existing skills, or verifying skills work before deployment
forage-solutionsAI solution exploration using ant colony optimization — deploying scout hypotheses, reinforcing promising approaches, detecting diminishing returns, and knowing when to abandon a strategy. Use when facing a problem with multiple plausible approaches and no clear winner, when the first approach is not working but alternatives are unclear, when debugging with…
Independent GitHub snapshot · Automated classification · Original documentation governs
Roam a solution space with ant colony optimization ideas — send independent hypotheses as scouts, reinforce hopeful paths through evidence, spot diminishing returns, and know when to abandon a strategy and roam elsewhere.
build-coherence when solution space must be roamed before pickBefore send scouts, describe shape of solution space.
Solution Distribution Types:
┌────────────────────┬──────────────────────────────────────────────────┐
│ Type │ Characteristics and Strategy │
├────────────────────┼──────────────────────────────────────────────────┤
│ Concentrated │ One correct answer exists (bug fix, syntax │
│ (one right fix) │ error). Deploy many scouts quickly to locate │
│ │ it. Exploit immediately when found │
├────────────────────┼──────────────────────────────────────────────────┤
│ Distributed │ Multiple valid approaches (architecture choice, │
│ (many valid paths) │ implementation strategy). Scouts assess quality │
│ │ of each. Use `build-coherence` to choose │
├────────────────────┼──────────────────────────────────────────────────┤
│ Ephemeral │ Solutions depend on timing or sequence (race │
│ (time-sensitive) │ conditions, order-dependent bugs). Fast scouting │
│ │ with immediate exploitation. Cannot revisit │
├────────────────────┼──────────────────────────────────────────────────┤
│ Nested │ Solving the surface problem reveals a deeper one │
│ (layers of cause) │ (config issue masking an architecture problem). │
│ │ Scout at each layer before committing to depth │
└────────────────────┴──────────────────────────────────────────────────┘
Sort current problem. Distribution type picks how many scouts to send and how fast to switch from roam to exploit.
Got: Clear sort of solution landscape that tells scouting strategy. Sort should feel right to problem, not forced.
If fail: Landscape fully unknown? That itself is sort — treat as possibly distributed and send broad scouts. First round of scouting will show landscape character.
Make independent hypotheses as scouts. Each scout probes solution space in different direction.
Scout Deployment Template:
┌───────┬──────────────────────┬──────────────────────┬──────────┐
│ Scout │ Hypothesis │ Test (one action) │ Promise │
├───────┼──────────────────────┼──────────────────────┼──────────┤
│ 1 │ │ │ High/Med/│
│ 2 │ │ │ Low │
│ 3 │ │ │ │
│ 4 │ │ │ │
│ 5 │ │ │ │
└───────┴──────────────────────┴──────────────────────┴──────────┘
Key rule: scouts check, they do not exploit. Goal is quick signal on each hypothesis, not deep dig of first one that looks hopeful.
Got: 3-5 independent hypotheses with cheap tests set. No hypothesis deep roamed yet — this is breadth-first pass.
If fail: Fewer than 3 hypotheses can be made? Problem is either very tight (concentrated type — good, scout aggressive) or grasp too shallow (read more context before hypothesize). Hypotheses not independent (they are all variations of same idea)? Roam too narrow — force at least one hypothesis that clashes with others.
After scout results return, reinforce hopeful trails and let weak ones decay.
Trail Reinforcement Decision:
┌───────────────────────────┬──────────────────────────────────────┐
│ Scout Result │ Action │
├───────────────────────────┼──────────────────────────────────────┤
│ Strong supporting evidence│ REINFORCE — deepen investigation │
│ Weak supporting evidence │ HOLD — one more cheap test before │
│ │ committing │
│ No evidence │ DECAY — deprioritize, scout elsewhere│
│ Contradicting evidence │ INHIBIT — mark as dead end │
│ Ambiguous result │ REFINE — hypothesis was too vague, │
│ │ sharpen and re-scout │
└───────────────────────────┴──────────────────────────────────────┘
Got: Clear priority of trails by evidence, not preference. Strongest trail gets most focus, but at least one alternative stays alive.
If fail: All scouts return empty? Hypotheses were wrong — not the path. Reframe question: "What assumptions am I making that could be wrong?" Make new hypotheses from different angle. All scouts return strong signals? Problem may be distributed (many valid answers) — switch to build-coherence for path pick.
Watch yield of current path. When info gained per unit effort drops below average across all paths, time to switch.
Marginal Value Assessment:
┌────────────────────────┬──────────────────────────────────────────┐
│ Signal │ Action │
├────────────────────────┼──────────────────────────────────────────┤
│ New information per │ CONTINUE — this trail is productive │
│ action is high │ │
├────────────────────────┼──────────────────────────────────────────┤
│ New information per │ PREPARE TO SWITCH — squeeze remaining │
│ action is declining │ value, begin scouting alternatives │
├────────────────────────┼──────────────────────────────────────────┤
│ Last 2-3 actions │ SWITCH — the trail is depleted. The cost │
│ yielded nothing new │ of staying exceeds the cost of switching │
├────────────────────────┼──────────────────────────────────────────┤
│ Information contradicts│ SWITCH IMMEDIATELY — not just depleted │
│ earlier findings │ but misleading. Cut losses │
└────────────────────────┴──────────────────────────────────────────┘
Key: factor in switch cost. Moving to new hypothesis means loading new context, which has cost. Do not switch for marginal gains — switch when current trail clearly depleted.
Got: Deliberate pick to continue or switch by yield check, not habit or frustration. Switches are evidence-based, not impulse-driven.
If fail: Switch happens too often (oscillation between hypotheses)? Switch cost being under-valued. Commit to current trail for N more actions before recheck. Switch never happens (stuck on one trail despite dropping yield)? Set hard cap: after N unproductive actions, switch no matter sunk cost.
By forage results, pick right next phase.
build-coherence to pick among themGot: Strategic pick about next phase that follows logically from forage results. Pick should feel like conclusion, not guess.
If fail: No strategy feels right? Forage has shown real uncertainty — and that is valid outcome. Say uncertainty to user: "I roamed N paths and found X. Most hopeful is Y because Z. Shall I pursue it, or do you have extra context?"
forage-resources — multi-agent forage model that this skill adapts to single-agent solution searchbuild-coherence — used when forage shows many valid paths that need checkcoordinate-reasoning — manages info flow between scout hypotheses and exploit phasesawareness — watches for premature converge and tunnel vision during forage