Prediction Engine outline

heuristic

The brain predicts what should happen next---in the world and in the body. When predictions fail, you feel something, attention pivots, and behaviour updates.

Have you ever checked your phone expecting a notification---maybe anticipating news from someone---and felt a small deflation when there was nothing there? Or been surprised by unexpected good news and felt that little jolt of delight? Or walked into a room and felt immediately that something was off, even though you couldn't quite say what?

These moments are your prediction engine at work. The brain doesn't passively wait for the world to tell it what's happening. It constantly generates expectations about what should happen next---what you'll see, hear, feel, and what you'll need to do about it. Perception isn't a camera recording reality; it's the brain's best guess about what's out there, shaped by everything it's learned before. And action isn't a deliberate choice in response to facts; it's often the fastest way to make predictions come true or to resolve the discomfort of surprise.

This is one of the most fundamental features of how brains work: they run a generative model of the world and the body. Top-down predictions flow downward to meet bottom-up sensory signals. When they match, everything is smooth and automatic. When they don't match---when the world violates expectations---you get a prediction error. That error does three things at once: it spikes your sense of salience (this matters!), it charges the moment with affect (you feel something, even if it's subtle), and it pivots your attention and behaviour to deal with the mismatch.

George Mandler, a psychologist studying emotion, called this the interruption theory: we operate with automatic routines until something interrupts them, and that interruption is the emotion. No action without emotion, he argued, because emotions are what tell us the routine isn't working anymore and we need to update.

Crucially, anticipation of a reward activates the same neural machinery as receiving it. When you predict something good will happen---when you imagine the outcome, announce your intention, or make your plan---you're activating the reward circuits. The brain's dopaminergic system responds to expected rewards as strongly (sometimes more strongly) than actual ones. This has powerful implications: expecting something good is nearly as reinforcing as getting it, which is why saying you'll do something can feel so satisfying that you never follow through. The anticipation delivers the reward, and the system relaxes. It's also why threats to your needs trigger the same responses as actual damage to them, and why humans are so predictable once you understand the environment they're responding to.

So what can you do? You have three levers to reduce prediction error. First, you can change the world---act to make reality match your prediction. (You're expecting coffee, so you go make coffee.) Second, you can change yourself---shift your attention, reappraise the situation, adjust your goals. (You're not getting coffee; you decide tea is fine.) Third, you can change the model---learn, update your expectations so future predictions are better. (You learn the café is closed on Tuesdays.) Most of the time, the brain picks whichever option is fastest and cheapest, which is why habits persist: when predictions about what you'll do next are highly confident and usually right, acting is cheaper than thinking. And be mindful of how anticipation can undermine execution: if announcing intentions or planning delivers enough reward, the system may treat the anticipation as progress and stop pushing for actual completion. Channel anticipation into immediate small steps rather than distant goals, or save the announcements for after the work is done.

The say-do-gap? That reflects a prediction engine optimised for past contexts. The model predicted you'd check your phone, eat the biscuit, follow the old route---and it was confident enough that the action fired before your goal even got a vote. To change outcomes, you need to change the model's priors (practice new narratives and actions in context), change its precision (shift what you attend to), or change the inputs (redesign the environment so the cues don't trigger the old predictions).

Let's look at the neural architecture that helps us understand this heuristic better.

What neural architecture makes this happen?

The neural hardware

The underlying neural systems that make this heuristic possible

Neural Pathways
Architecture: Neural Pathways Neural circuits map perceptions to actions, stimuli to response, context to behaviour. We call these neural pathways, and they are stronger the more they're trained. The stronger they are, the more they determine our behaviour.

Neural pathways are the brain's learned mappings from perception to action. They're also the substrate of prediction: the more often a particular input has led to a particular outcome, the stronger the pathway connecting them, and the more confidently the brain predicts that outcome will happen again. This is why familiar contexts make predictions cheap and fast---the pathways are well-worn, and the model is confident. But it's also why changing behaviour is hard: the prediction is baked into the infrastructure.

To update predictions, you need to retrain the pathways in context. Practice the new prediction until it's the confident one.

Key takeaway: strong pathways make predictions fast and sticky; change requires building alternative routes.

Circuit Reuse
Architecture: Circuit Reuse Many neural circuits are reused across behaviours---the brain likes to recycle. This sharing of neural infrastructure means that changing one routine can spill into others.

Circuits are reused across many different mappings, which means predictions about one thing can interfere with predictions about another. When two routines share infrastructure, the prediction errors in one can spill over into the other. This is why practicing a new routine can jostle old patterns---you're updating shared circuitry, and the model has to reconcile competing predictions.

The practical move is to separate contexts as much as possible when retraining, so the old and new predictions don't fight for the same neural real estate.

Key takeaway: circuit reuse means prediction updates can have spillover effects; design contexts to minimise interference.

Plasticity & Stability

The more you run a prediction, the more stable it becomes. Repetition consolidates the pathway, building infrastructure around it that makes it faster but harder to change. This trade-off is central to how prediction engines work: you want confident, stable predictions for familiar contexts (speed and efficiency), but that stability makes it costly to update when the context changes.

Adolescents, with less white matter infrastructure, have more plastic prediction systems---they update faster, but they're also less efficient. Adults have more stable predictions---efficient but inertial.

Key takeaway: stability speeds up familiar predictions but makes updating costly; plan for the trade-off.

Task Sets
Architecture: Task-sets Transient control configurations that select the features, rules, and responses relevant to the current goal, binding them into a brief attentional episode.

Task sets configure which predictions are active right now. When you shift into 'making tea' mode, the brain loads a set of expectations about what you'll see, what you'll do, and what outcomes matter. That set biases which predictions run and which sensory signals get attention.

If the wrong task set is loaded at the cue, the brain generates the wrong predictions, and you get prediction errors even when nothing surprising is actually happening. Preload the right set to align predictions with context.

Key takeaway: task sets gate which predictions run; preload the intended set at the cue.

Hierarchical Control
Architecture: Hierarchical Control Control is layered: higher goals set constraints and subgoals; lower controllers implement sequences---supporting flexible, multi‑step behaviour.

Predictions are layered: high-level goals generate predictions about subgoals, which generate predictions about actions, which generate predictions about sensory outcomes. Errors at any level can propagate up or down. A violated high-level prediction (the café is closed) cascades down into action updates (go somewhere else). A violated low-level prediction (this coffee tastes wrong) can bubble up into goal revision (maybe I don't want coffee after all).

The hierarchy lets you resolve errors at the right level: sometimes you fix the action, sometimes you revise the subgoal, sometimes you change the whole plan.

Key takeaway: errors propagate through the hierarchy; adjust at the level that makes most sense.

Neuromodulation
Architecture: Neuromodulation Modulatory signals tune how the nervous system responds---changing learning rates, adjusting precision, and gating which pathways are active.

Neuromodulators tune how the brain responds to prediction errors. Dopamine, for instance, seems to signal the magnitude of prediction error---how surprising the outcome was relative to expectation. Norepinephrine and acetylcholine tune which errors get attention and how much the model updates in response.

This is why context and state matter so much for learning and behaviour. High arousal amplifies prediction errors; calm states allow subtler updates.

Key takeaway: neuromodulation tunes how prediction errors drive learning and action; state shapes updating.

Interoception & Affect

Predictions aren't just about the external world; they're also about the body. The brain predicts your heart rate, your hunger, your tension, and when those predictions fail, you feel it as affect. That affect colours how you interpret external prediction errors: the same surprise can feel threatening or exciting depending on your bodily state.

This is Mandler's insight: emotions are interrupted predictions about bodily states, and those interruptions shape how you respond to the world. Regulate the body, and you regulate how prediction errors feel and what actions they trigger.

Key takeaway: bodily prediction errors generate affect; state management is prediction management.

Contextual Cues & Retrieval

Predictions depend on context. The brain uses environmental cues to decide which model to load---which set of predictions is relevant right now. Walk into your kitchen, and the brain predicts you're about to make food. Walk into your bedroom, and it predicts you're about to sleep or change clothes.

If the cues are wrong or ambiguous, the brain loads the wrong predictions, and you get errors even when your behaviour is fine. Build clear, consistent cues into contexts where you want particular predictions to run.

Key takeaway: context cues which predictions load; design cues to align predictions with intended behaviour.

Reconstruction & Attribution

Memory isn't playback; it's reconstruction guided by prediction. When you recall something, the brain generates a prediction about what should have happened based on current schemas, and fills in gaps with plausible details. This is why memory feels vivid even when it's wrong---the prediction is confident, even if it's not accurate.

This also explains confabulation and false memories: the brain's prediction engine produces a coherent story, and you experience that story as memory. The lesson is that what you 'remember' is shaped by your current predictions about what makes sense.

Key takeaway: memory is reconstructed via prediction; current models shape what you recall.

Sources

  • analects/making-meaning-in-the-brain.md
  • analects/predicting-human-behaviour.md
  • analects/addictive-work.md
  • articles/interruption-theory-of-emotion-mandler.md