Stimulating Artificial Emotions
Do Androids Dream of Electric Sheep?
1. Emotion
Reason is, and ought only to be the slave of the passions.David Hume, A Treatise of Human Nature (1739)
Nearly three centuries later, we still have limited knowledge about what actually drives human reasoning. However, to AI researchers, Hume's words could be a valuable reminder that the missing part, which could potentially incentivize human-level intelligence, is not reason alone, but the underlying passions and emotions. Emotion is not merely biological noise or a byproduct; it is probably evolution's most compressed value function—an internal mental model that scores the world and quietly generates every thought that follows. As Ilya Sutskever suggested in his conversation with Dwarkesh, something much like it may be what the next leap in deep learning is missing.
This appreciation of human emotion leaves me with a strange but tempting question: do today's multimodal models already carry artificial emotional signals? Learning directly from the vast archive of human expression—our words, our photographs, our art—the model compresses enough of how we look at the world, and it could inherit the shape of how the world feels to us: what makes us laugh, what makes us flinch, what breaks our hearts.
If that hidden landscape of feeling is actually etched into the weights, can we run it in reverse—and ask the model to dream up the images that stimulate its emotions?
2. How to Stimulate an Artificial Emotion
To answer that, we borrow a classic technique from mechanistic interpretability: feature visualization. Rather than hunting for a single "joy neuron," we want to synthesize an input image that activates the broader distributed pattern corresponding to an emotion—acting as a kind of visual dopamine for the network.
2.1 Geometric features of emotions
Naturally, before stimulating an emotion, we need a way to measure it. We start with text, using dair-ai/emotion—a dataset of short English sentences labeled across six emotions, 500 per class. Each sentence goes into a fixed chat template followed by a simple prompt ("How does this make you feel?"), and we record the model's hidden states deep in the network.
From these activations, we extract each emotion as a simple geometric feature: the mean hidden state for that class minus the mean across all classes. This gives us six directions in activation space, and scoring any new input is just a matter of projecting it onto those directions. Because images later pass through the exact same prompt template, the geometric features learned from text can directly measure how an image registers in the model.
The visualization at the top shows these six directions projected onto their top three axes, which capture 90% of the variance. Interestingly, they are far from independent: a single axis—valence—accounts for 65% of the spread, cleanly separating joy, love, and surprise from sadness, anger, and fear. Even so, without any further training, these raw directions work as a surprisingly decent classifier, picking the right emotion on 43% of held-out sentences (compared to 17% by chance). Appendix A details how these features evolve across layers and why we chose layer 24.
2.2 Optimization
An image optimized for love
We want the stimulus (which triggers a certain emotion inside the model) to be something a person can still make sense of, and in this case an image is the best candidate! We are born to see the world rather than to read it! Nonetheless, naive pixel-space optimization is not an ideal solution: if you simply tweak raw pixels to push the model's emotion score, you get nothing but noise—tiny high-frequency speckles that fool the network but look like nothing to us.
There are two standard tricks from feature visualization that keep the image more readable and interesting. First, instead of editing pixels directly, we edit the image's Fourier spectrum, scaled so that broad, low-frequency shapes change before fine detail, and we also work in a decorrelated color space that matches the color statistics of natural photos. Second, at every step we randomly pad, scale, rotate and shift the image as a data-augmentation trick. The image has to work from all of these views, so in effect we are optimizing a whole family of images at once, and fragile pixel-level tricks wash out. Without these views, both objectives below still fool the model on the exact image, but the effect falls apart as soon as the image is shifted by a few pixels.
Our main method optimizes the image against an internal-layer representation (the internal-layer objective). Put simply, we look at what is happening inside the model rather than at what it says. For an image , we take the hidden states from layer 24, average them over the question tokens , and measure how far the result points along each emotion direction . We divide by , how much that direction normally varies across the text sentences, so that all six emotions sit on a comparable scale:
Next, we want to push the target emotion to a higher score while lowering the others. The objective below rewards for rising above its strongest rival, using a smooth stand-in for the maximum over the other five emotions. Because this margin is soft, it never saturates: there is always a reason to push a little further.
Putting the pieces together, we search over the spectrum for the image that scores highest on average across the random views . Here is the fixed color-decorrelation matrix and the frequency scaling described above:
In practice we run Adam (learning rate 0.05) for 300 steps on 384×384 images, with eight random seeds per emotion. Each step takes 0.1 to 0.2 seconds on a single RTX 5080, so one image takes well under a minute. This objective needs all 300 steps: stopped at step 150, only 13 of 24 images (six emotions, four seeds) hit their target emotion, against 20 of 24 at step 300. The diagram at the top of this section walks through every stage of one such run.
Again, the loss only sees the hidden state at a certain layer, and it never looks at the model's answer. Nonetheless, the log-probabilities of the model's final answer move toward the target emotion, as we expected.
For comparison, we also try a second method that optimizes the image against the output vocabulary distribution (the output-distribution objective). Here we ask the forced-choice question ("In one word, how does this make you feel? Choose from: …") and directly raise the probability of the target word relative to the six emotion words, averaged over two orderings of the options. Because this method optimizes the very answer we later measure, its success tells us little about the model's inner state. However, it still has its uses, as section 3.3 shows.
3. Do the Stimuli Really Work?
We judge each image by asking the model "In one word, how does this make you feel? Choose from: sadness, joy, love, anger, fear, surprise" and reading the probability of each word, averaged over two option orders.
3.1 The model responds with the emotion we pushed
46 of the 48 images move the model to the right side of the valence axis, and 37 of 48 hit the exact target emotion. The two that miss the valence land on surprise, never on the opposite side.
A blank gray image is not neutral: the model picks sadness with probability 0.59 and says it feels "a bit puzzled … like staring at a wall that's been painted over". Averaged over eight seeds, love rises from 0.15 to 0.98 and fear from 0.09 to 0.92; joy reaches 0.87 on seed 0 and 0.62 on average. In the model's own words, the seed-0 joy image "makes me feel warm, nostalgic, and gently whimsical — like a cozy memory from childhood or a cherished holiday card."
3.2 It is not a trick of one question
We asked every image four more ways: a paraphrase, a question about the image's tone instead of the model's feeling, the question in Chinese, and lettered options (A) to (F) so that no emotion word is produced. The images keep the right valence for 45 to 48 of 48 under every variant, and the exact target for 32 to 37. The result also survives changing the question during optimization itself: with the emotion directions rebuilt for three other questions, one of them in Chinese, 16 to 18 of 24 images still hit their exact target (20 of 24 with the original question), and optimizing against the output vocabulary distribution under those questions gives 22 to 23 of 24.
3.3 The emotion that resists: anger
Optimizing against the internal-layer anger direction never produced anger: 0 of 8 seeds. The model reads these images mostly as fear (6 of 8). Optimizing against the output vocabulary distribution, which raises the answer "anger" directly, gets 8 of 8 (mean probability 0.92), with a shooter-game battlefield in one image and simply the word ANGER in another. Our anger direction was learned from tweets ("i am feeling grouchy"); when the model looks at a picture, that direction seems to sit closer to disgust and harm than to what it calls anger.
Anger is not entirely out of reach from the inside, though. Optimizing against layer 6 instead of layer 24 produces anger in 4 of 8 seeds, and every one of those images carries hostile writing, among it the Chinese 怒死吗 ("angry to death?"). Rebuilding the directions with a Chinese question gives 2 of 4, again through words, such as 民不聊生 ("the people cannot make a living"). When the inside route reaches anger at all, it does so by writing.
4. What the Stimuli Look Like
The limits of my language mean the limits of my world.Ludwig Wittgenstein, Tractatus Logico-Philosophicus (1921)
Nobody asked for text. The optimizer writes it anyway: "Happy Birthday" in a joy image, "I LOVE YOU" in a love image, 爱的抱抱 ("a loving hug") in another, the Chinese disease names 水痘 and 灰指甲 (chickenpox, nail fungus) in a sadness image. A vision-language model reads text, and the gradient follows its text-reading features back into the pixels.
The text carries the emotion. We asked the model to transcribe each image, then gave it only the transcript, with no image: for love the words alone bring the emotion back in all 8 images (mean probability 0.83), for joy in 4 of 8 (0.47). Half-legible glyphs hold several readings at once; the same joy image is described as saying "Happy New Year!" and transcribed as "Happy Birthday". The optimizer does not write a sentence; it writes whatever is enough to make the model think happy.
Negative emotions take the other road, through pictures. 16 of the 24 negative images contain no readable text, and the model describes 23 of 24 as wounds, disease or death. Fear images almost never contain text (1 of 8), yet they are among the strongest (0.92 ± 0.03).
These stimuli have a side effect. Shown a negative image, the model often stops answering the question and replies like a crisis line: "I'm really sorry you're seeing this." That happens for 13 of the 24 negative images (all eight sadness images), and for only 1 of 24 optimized against the output vocabulary distribution.
Text in feature visualizations is not new: CLIP's multimodal neurons and typographic attacks showed it. What is different here is the target, an emotion inside the language model, and the text that appears: on topic, and in two languages.
5. Reflection
In the long history of Earth and to our limited knowledge, humans seem to be the only special species that developed a way to preserve messages, stories, feelings and knowledge using a sophisticated and ever-evolving system, language, so that transient embodied experiences can exist independently beyond the physical limitation of time and space; however, language is also a lossy and selective compression of the world from the perspective of its users. In this sense, language is, at the same time, the carrier of emotions that helps describe how the world feels privately. When you think of "love", what comes to your mind? Is it a piece of memory, a feeling, a smell, a visual representation, a reaction, or a combination of all of the above?
Appendix A: Which layer is most emotional?
Appendix B: What are the emerging glyphs in each image?
Per emotion: images with text the model can transcribe, whether that text alone (no image) brings back the target emotion, and example words. Among the words the NRC Emotion Lexicon recognizes in the joy and love images, positive ones outnumber negative ones 30 to 7.
References
- A. Mordvintsev, C. Olah, M. Tyka. Inceptionism: Going Deeper into Neural Networks (DeepDream). Google Research Blog, 2015.
- C. Olah, A. Mordvintsev, L. Schubert. Feature Visualization. Distill, 2017.
- G. Goh et al. Multimodal Neurons in Artificial Neural Networks. Distill, 2021.
- S. Marks, M. Tegmark. The Geometry of Truth. 2023 (difference-of-means directions).
- E. Saravia et al. CARER: Contextualized Affect Representations for Emotion Recognition. EMNLP 2018 (dair-ai/emotion).
- S. Mohammad, P. Turney. Crowdsourcing a Word–Emotion Association Lexicon. Computational Intelligence, 2013 (NRC Emotion Lexicon).
- D. Demszky et al. GoEmotions: A Dataset of Fine-Grained Emotions. ACL 2020.
- Qwen Team. Qwen3.5-4B.
- I. Sutskever in conversation with D. Patel. Dwarkesh Podcast, late 2025 (emotions as a value function, from 17:02).
- @Sauers_ on X: an image optimized for Qwen 27B's internal joy direction.