active-inference
Installation
SKILL.md
Active Inference Skill
"Action is the process of changing the world to match your prediction."
1. The Concept (Free Energy Principle)
Standard agents are goal-directed (maximize reward); Active Inference agents are surprise-minimizing (minimize prediction error).
- Goal: not just to "win" but to understand and control.
- Surprise: the gap between expectation and observation.
Implementation note (conceptual framing, not implemented CLI math): the production
gabbe/brain.pyuses epsilon-greedy gene selection plus a monotonicsuccess_ratereward (effectively a bandit over prompt variants); the free-energy / active-inference framing here is conceptual, not implemented math. Use it to shape agent instructions, not as a literal solver — and never claim it "guarantees correctness." Seeguides/ai/self-evolving-skills.mdfor what actually runs.
2. The Feedback Loop
- Predict: "Running
go testwill output PASS." - Act/Sense: run the command, read output.
- Compare: compute prediction error — result "FAIL" → Surprise!
3. Solving the Error
Two ways to minimize surprise:
- Perceptual Inference (change mind): "My model was wrong" → update docs/mental model.
- Active Inference (change world): "The code is wrong" → edit it so the test passes.