The Psychology of Reinforcement: Instrumental Control
Classical conditioning was prediction; instrumental conditioning is control. Thorndike's Law of Effect is trial-and-error control — selection plus association, search plus memory — and Skinner's shaping and schedules are reward engineering.
╌╌╌╌
This builds on The Psychology of Reinforcement, which followed the prediction half of the correspondence: classical conditioning, the Rescorla–Wagner rule, and its real-time TD extension. This part takes up the other half — control. Where classical conditioning taught the animal what to expect, instrumental conditioning teaches it what to do, and that maps onto the control algorithms of this course: the Law of Effect is trial-and-error control, and the habitual/goal-directed distinction is the model-free/model-based split.
Instrumental conditioning and the Law of Effect
Instrumental conditioning is control. The reinforcer is contingent on behavior,
and the animal learns to produce behavior that pays. Its founding observation is
Thorndike's: cats placed in puzzle boxes,
able to escape by the right sequence
of actions, escaped faster and faster over repeated trials. Successful actions
were stamped in,
unsuccessful ones stamped out.
1 From this
Thorndike drew the Law of Effect.
The Law of Effect is a compact description of a reinforcement learning algorithm. Two features line up exactly, and each distinguishes it from a neighboring learning paradigm:2
| Feature | Law of Effect | Contrast |
|---|---|---|
| Selectional | tries alternatives, selects by consequence | supervised learning is told the correct answer |
| Associative | binds selected actions to the states where they worked | natural selection selects but does not associate |
Selection plus association is search plus memory: search by trying actions, memory by linking situations to the actions that worked. Both are essential to every control algorithm here. Search requires exploration — the animal must try alternatives — which is why the control methods carry -greedy or upper-confidence-bound action selection.3 Thorndike's cats selected from their instinctual impulses, not every conceivable action: the animal-learning image of an admissible action set .
Skinner extended this line with shaping: reinforcing successive approximations of a target behavior. Waiting for the full behavior to occur by chance can take forever; instead you reward anything resembling it, then progressively raise the bar. Shaping is directly useful for training reinforcement learning agents when reward is too sparse for the agent ever to stumble onto it — start with an easier version of the problem and increase difficulty as the agent improves.4
Skinner also formalized the rule by which the apparatus delivers reinforcement, the reinforcement schedule — part of the environment's reward function, fixing the mapping from behavior to reward. The animal's steady-state response rate is a policy adapted to it.5
| Schedule | Reinforces | Variants |
|---|---|---|
| Continuous | every target response | — |
| Partial — ratio | after a count of responses | fixed / variable |
| Partial — interval | first response after an elapsed time | fixed / variable |
Partial reinforcement is an analogue of the stochastic-reward setting the control methods already face: a variable-ratio schedule delivers reward intermittently and unpredictably, so the learner acts under high return variance — the condition that makes exploration and value averaging matter. Behavior trained under partial reinforcement also extinguishes more slowly, since intermittent reward looks, locally, like the training regime.
Habitual and goal-directed behavior
The last correspondence is the closest. Psychologists distinguish two modes of controlling learned behavior, and they map cleanly onto the model-free / model-based split from planning and learning.6
| Habitual | Goal-directed | |
|---|---|---|
| RL analogue | model-free | model-based |
| Control by | antecedent stimulus | consequence / outcome value |
| Reads | cached or policy | learned model , |
| Decision | look up value | simulate action sequences, pick best return |
| Execution | fast | slow |
| Adapts to a payoff shift | slowly, only by re-experience | immediately, on model update |
Habitual behavior is triggered by antecedent stimuli and runs off automatically: decisions read off cached state-action values built up over many trials. Goal-directed behavior consults an internal model, simulates the consequences of candidate action sequences, and chooses the best outcome — slower, but able to change the moment the model's knowledge of the goal changes, no re-experience required.
The experimental test that separates the two is outcome devaluation. Train a rat to press a lever for food pellets. Then devalue the pellets — pair them with a nausea-inducing injection so the rat no longer wants them — without the rat ever pressing the lever while sick. Now put the lever back and see whether the rat still presses.7 A goal-directed (model-based) rat presses less right from the start: it knows lever pressing leads to pellets, and it now knows pellets are bad, so it combines the two and stops — without ever having experienced lever-pressing-then-sickness. A purely habitual (model-free) rat keeps pressing, because its cached lever-press value was never updated by direct experience.
The logic hangs on the fact that devaluation happens in a context separate from lever pressing. Reading it as a timeline makes the dissociation clear: only the model-based agent has a stored link from lever to pellet that it can re-evaluate when the pellet's value changes; the model-free agent has only a cached number on the lever action, and that number was set before devaluation and never revisited.
Both systems are present, and behavior shifts between them. Adams showed that extended training converts goal-directed behavior into habit: modestly trained rats stayed sensitive to devaluation, overtrained rats kept pressing.8 Daw, Niv, and Dayan model the animal as running both processes and deferring to whichever is more trustworthy, measured by the uncertainty each maintains — control follows over the two posterior uncertainties. Early on the model-based process is more reliable, chaining short-term predictions that sharpen quickly; with experience the model-free values become well-estimated and cheaper to consult, and control shifts toward habit. This is arbitration between model-free and model-based control, expressed in the animal.9
Delayed reinforcement
One thread runs through both paradigms: reinforcement is often delayed. In instrumental conditioning the reward can arrive well after the action that earned it; in classical conditioning the US can follow CS offset by a gap. This is the credit-assignment problem — how to distribute credit for an outcome among the earlier decisions that led to it.10
Animal-learning theory proposed two mechanisms for bridging the gap, each with an exact counterpart here:11
| Animal-learning mechanism | RL counterpart | Role |
|---|---|---|
| Stimulus trace (Pavlov, Hull's goal gradient) | eligibility trace in | decaying record of recent state visitations |
| Conditioned (secondary) reinforcer | value function | moment-by-moment stand-in for delayed reward |
A stimulus leaves a decaying trace in the nervous system, and learning occurs while the CS trace still overlaps the US — the ancestor of the eligibility trace. A stimulus that reliably predicts reward becomes reinforcing itself, supplying immediate reinforcement when the primary reward is delayed — the role of a value function. In an actor–critic architecture the critic's TD error acts as exactly such a conditioned reinforcer for the actor, giving immediate feedback even when primary reward is far off.
The two mechanisms are the two answers this course gives to delayed reinforcement, and animal-learning theory arrived at both first: the eligibility trace was proposed for rats before it was proposed for algorithms, and the value function is the formal version of a secondary reinforcer.
From conditioning models to deep RL and meta-learning
The line from Rescorla–Wagner to the algorithms of this course does not stop at the classical-conditioning models; it runs directly into modern deep reinforcement learning, and it loops back into experiments on human choice.
The behavioral ancestor of the training signal in deep RL is the prediction error these models formalized. In the Deep Q-Network of Mnih and colleagues (2015, Nature), which learned to play Atari games from pixels, the quantity that drives every weight update is the temporal-difference error — the same that the TD model of conditioning uses, now applied to a deep network's value estimate. Actor–critic deep methods carry the same TD error as the critic's teaching signal for the actor. The Rescorla–Wagner rule and its real-time TD extension are the behavioral lineage of that signal, not a loose metaphor for it.12
The habit/goal-directed distinction this lesson draws has been measured directly in people. Daw, Gershman, Seymour, Dayan, and Dolan (2011, Neuron) introduced the two-step task, a sequential choice in which model-free and model-based control predict different patterns of how a reward changes the next choice. Human choices showed a mixture of the two strategies rather than either alone — the empirical counterpart of the two-system picture above. Earlier, Gläscher, Daw, Dayan, and O'Doherty (2010, Neuron) used fMRI to dissociate two error signals during learning: a state-prediction error that tracks the learning of the transition model (the model-based component) and a separate reward-prediction error (the model-free component), each with its own neural correlate. The habit/goal-directed contrast is not only a behavioral description; it corresponds to distinct, measurable learning signals.13
The two modes have also been shown to emerge from one another. Wang and
colleagues (2018, Nature Neuroscience), in Prefrontal cortex as a meta-reinforcement learning system,
trained a recurrent network with a plain model-free RL algorithm
across a distribution of related tasks. The slow model-free training shaped the
network's recurrent dynamics into a faster inner learning loop that behaved in a
model-based-like way on each new task — model-based behavior arising from model-free
learning, a meta-reinforcement-learning account of how a flexible controller can be
built from an inflexible learning rule. Botvinick and colleagues (2020, Nature
Reviews Neuroscience) survey the broader set of contact points between deep
reinforcement learning and neuroscience that this lineage opened up.14
Why this matters
Reinforcement learning was designed for engineering, and it remains a theory of effective learning algorithms, not a catalogue of animal behavior. But the correspondences are not superficial. The prediction/control split is the classical/instrumental split. The Rescorla–Wagner prediction error is the TD error with the time removed. The Law of Effect is trial-and-error control. Habit is model-free, deliberation is model-based, and the shift between them is arbitration. Eligibility traces are stimulus traces, and value functions are secondary reinforcers.
None of this means the brain runs our exact equations. It means the abstract structure of the learning problem is the same whether the learner is silicon or tissue, and that the theory built to solve it computationally keeps rediscovering the mechanisms that evolution found. The next lesson follows this contact point into the brain itself, where the dopamine signal turns out to behave like a TD error.
Footnotes
- Sutton & Barto, §14.3 — Instrumental Conditioning: Thorndike's cats escaped puzzle boxes faster over repeated trials; successful actions were
stamped in
and unsuccessful onesstamped out,
leading to the Law of Effect, the classic statement of learning by trial and error. ↩ - Sutton & Barto, §14.3 — Instrumental Conditioning: reinforcement learning algorithms correspond to the Law of Effect in being selectional (trying alternatives and selecting by consequence) and associative (connecting selected actions to the states in which they worked), unlike supervised learning (associative not selectional) or natural selection (selectional not associative). ↩
- Sutton & Barto, §14.3 — Instrumental Conditioning: a reinforcement learning algorithm's need to search means it must explore; the -greedy and upper-confidence-bound methods used here are among the simplest such schemes, and Thorndike's cats selected from their instinctual impulses, echoing an admissible action set . ↩
- Sutton & Barto, §14.3 — Instrumental Conditioning: Skinner's shaping reinforces successive approximations of a target behavior; it is an effective, sometimes indispensable, tool for training reinforcement learning agents when reward is too sparse to be encountered by initial behavior. ↩
- Sutton & Barto, §14.3 — Instrumental Conditioning: Skinner studied reinforcement schedules (continuous vs. partial, the latter split into ratio and interval, fixed or variable) and their effect on steady-state response rate. The schedule is part of the environment's reward contingency; a variable-ratio schedule delivers reward intermittently and unpredictably, a stochastic-reward setting analogous to the high-variance returns that make exploration and value averaging matter in this course's control methods. ↩
- Sutton & Barto, §14.6 — Habitual and Goal-directed Behavior: the model-free/model-based distinction corresponds to the psychologists' habitual/goal-directed distinction; habits are controlled by antecedent stimuli, goal-directed behavior by knowledge of the value of goals and the action–outcome relationship. ↩
- Sutton & Barto, §14.6 — Habitual and Goal-directed Behavior: in the Adams and Dickinson (1981) outcome-devaluation experiment, rats trained to lever-press for pellets, then made to find the pellets aversive (via lithium chloride) without pressing while sick, pressed less from the start of extinction — evidence of a cognitive map linking lever-pressing to pellets to nausea. ↩
- Sutton & Barto, §14.6 — Habitual and Goal-directed Behavior: Adams (1982) showed extended (overtraining) reduces sensitivity to outcome devaluation — overtrained rats kept lever-pressing after devaluation while modestly-trained rats did not — evidence that extended training converts goal-directed behavior into a habit. ↩
- Sutton & Barto, §14.6 — Habitual and Goal-directed Behavior: Daw, Niv, and Dayan (2005) proposed animals use both model-free and model-based processes, executing the action from whichever is judged more trustworthy by maintained confidence measures, predicting a shift from goal-directed to habitual control as experience accumulates. ↩
- Sutton & Barto, §14.4 — Delayed Reinforcement: learning can occur with a long delay between action and consequent reward or between CS offset and US onset; this is the delayed-reinforcement problem, related to Minsky's (1961) credit-assignment problem of distributing credit among many decisions. ↩
- Sutton & Barto, §14.4 — Delayed Reinforcement: their algorithms address delayed reinforcement with eligibility traces (corresponding to the stimulus traces of Pavlov and Hull) and with TD-learned value functions (corresponding to conditioned/secondary reinforcement), the actor–critic critic's TD error acting as a conditioned reinforcer that gives immediate feedback when primary reward is delayed. ↩
- Mnih et al. (2015), Nature 518,
Human-level control through deep reinforcement learning
: the Deep Q-Network learns Atari games from pixels, trained by minimizing the temporal-difference error — the same TD error the TD model of conditioning uses, applied to a deep value network. Actor–critic deep methods likewise use the critic's TD error as the actor's teaching signal. ↩ - Daw, Gershman, Seymour, Dayan & Dolan (2011), Neuron 69,
Model-based influences on humans' choices and striatal prediction errors
: the two-step task shows human choices reflect a mixture of model-free and model-based control. Gläscher, Daw, Dayan & O'Doherty (2010), Neuron 66, dissociated a model-based state-prediction error from the model-free reward-prediction error with fMRI. ↩ - Wang et al. (2018), Nature Neuroscience 21,
Prefrontal cortex as a meta-reinforcement learning system
: a recurrent network trained by model-free RL across related tasks develops a faster, model-based-like inner learning loop in its recurrent dynamics. Botvinick et al. (2020), Nature Reviews Neuroscience 21,Deep reinforcement learning and its neuroscientific implications,
survey the contact points between deep RL and neuroscience. ↩
╌╌ END ╌╌