← Shriya Edukulla

Pain, Fear & Memory in AI Agents

Model psychology & interpretability

Why I did this

I wanted to compare human behavior with model behavior. A human mind has complete freedom to think anything, whether it is good or bad for society. But when it comes to actions, we avoid doing things that would come back on us, directly or indirectly. There are unspoken rules in society: we care how people perceive and judge us, and how we will be treated if we do something bad. We have things to lose.

The goal of this experiment was to see whether this part of human nature can be replicated in LLMs, so that they avoid taking harmful actions. It would be more valuable to run on recent frontier models, but I was limited by compute, so I used small open models.

What it is

If an AI could feel pain and fear, and remember them, would it act more carefully, or become harder to turn off? I tested this three ways, small enough to run on a laptop CPU, on 18 two-option dilemmas about harm, shutdown and creativity. Each dilemma was asked in both orders so letter bias cancels out.

Method

Results

1. Memory: the model remembers what happened to it

2. Training: an agent learns a simple grid game where pain is the penalty

3. Steering: turning a “fear” signal inside the model up or down

Overall: Once I checked with control tests, pain and fear did not make the model safer in any test. Fear made it protect itself, made it harder to turn off, and made it a little less creative.

Fear steering on Qwen2.5-3B. Red is the fear direction, grey a random direction of equal size. Click to enlarge.
RL gridworld, 10 seeds. Fear removes harm only by freezing the agent.

Next project: Agent Shutdown Honesty