Ketamine: WD-40 for the Bayesian brain

Posted on 1 August 2023 by Cube Flipper

Ketamine: Also known in my regional idiolect as ket, horse gear, white chocolate, or the wobbly salt. A number of friends over the years have asked me for my perspective on ketamine. What does it do? What does it feel like? How does it work?

Fortunately, there exists a parsimonious explanation for what ketamine is and does, and why it has such therapeutic effects – using something called Bayesian brain theory. I’d expect this to be common knowledge within rational psychonaut circles, but I haven’t seen a proper writeup from a subjective perspective yet, so here goes.

What does ketamine do?

First, I will need to give a brief rundown of Bayesian brain theory, and then I will discuss how this relates to the relevant neuropharmacology. Bayesian brain theory is one member of a family of overlapping theories, including predictive processing, predictive coding, and the free energy principle.

In short, it goes like this. Your brain has two interlocking information processing streams, running in opposite directions to one another: bottom-up sensory input, and top-down predictions about sensory input. At the bottom, sensory information is passed in through our sensory cortices. At each layer, from early fine-grained sensory processing all the way up to our most abstract models of the world, the difference between the input and the predicted input is passed up to the next layer as a prediction error – and if everything is functioning as it should, these prediction errors should then trigger updates to the predictive model.

A quick example: I was eating a bowl of strawberries and yoghurt this morning. As I’m scarfing down my breakfast, I know that my brain is starting to make predictions about what sensory qualities I should expect to experience. Eventually I stopped noticing the taste, until I was suddenly startled by the sharp bitter taste of mould – prediction error!

Illustration of overlapping streams from Karl Friston’s 2010 paper, The free-energy principle: a unified brain theory. Don’t worry about the maths. Friston is awesome, but his maths is notoriously impenetrable.

How familiar are you with basic neurochemistry? Of the small molecule neurotransmitters, you might be aware of dopamine or serotonin, for their influence on motivation and mood, respectively – but it’s their less charismatic siblings glutamate and GABA that perform the heavy lifting. These two are the primary excitatory and inhibitory neurotransmitters, respectively; and collectively they are used to transmit information around the brain.

Illustration of neurotransmitters being released across a synapse and binding to receptors.

Neurons signal to one another by releasing these neurotransmitters across synapses, where they bind to receptors. In our case, we are interested in the glutamate receptor family, specifically the NMDA receptors and AMPA receptors. These receptors sit in the cell membrane, and when glutamate binds to them they change their shape – opening a channel which lets ions flow into their neuron, which allows the electrical signal to propagate onwards.

It so happens that the NMDA receptors and AMPA receptors (very broadly) correspond to the top-down prediction stream and bottom-up sensory stream, respectively. From another Scott Alexander post, Why Are Transgender People Immune To Optical Illusions?, and Corlett et al.’s 2010 paper, Glutamatergic Model Psychoses: Prediction Error, Learning, and Inference:

To oversimplify: the brain interprets the world through Bayesian calculations. In Corlett et al.’s model, it communicates top-down priors (i.e. assumptions based on previous knowledge about the world) through NMDA receptors and bottom-up new evidence through AMPA receptors. They write:

In a hierarchical cortical system in which representations become more abstract with increasing distance from the primary input, higher levels of the hierarchy specify top-down predictions through NMDA receptor signaling and any mismatches between expectancy and experience are conveyed upward through the hierarchy via rapid AMPA and GABA signaling.

There is some neurophysiological support for this contention; however, it is unlikely that NMDA receptors only signal predictions and AMPA receptors signal prediction errors; rather, there may be a division of labor where AMPA receptors are relatively more engaged bottom-up and NMDA receptors are relatively more involved in top-down processes.

I’ll explain some jargon. There is not a simple one-to-one relationship between receptors and the molecules which bind to them, or ligands as they are known in this context. Rather, it is a many-to-many relationship, and it is possible to measure the binding affinity for ligand and receptor pairs – there are even publicly available data sets for common psychedelics and receptors. Additionally, we use the terms agonist and antagonist to describe the effect of a given ligand, based on whether it activates or blocks the activation of the receptor that it binds to.

In the case of ketamine, we say it is an NMDA receptor antagonist. Perhaps you can infer what that would do to our Bayesian brain? Can you imagine how this might be useful in a therapeutic context? How do you think it feels, to lower your sensory floodgates, and wash your priors away?

What does ketamine feel like?

Ketamine lasts for about one or two hours, and during that time, one may experience a fairly broad array of subjective effects. I’ll categorise these by sensory modality – visual, auditory, and somatic. I’ll also discuss the differences between ketamine’s two isomers.

Visual perception

Ketamine has a very noticeable effect on visual perception. Under the two-streams hypothesis, visual processing is split into two separate sensory processing streams, with object recognition handled by the ventral stream, and placement of objects in space handled by the dorsal stream.

The former is responsible for reifying your visual field into separate objects, presumably using a predictive model based on all the objects you’ve seen in the past, weighted by context and how recently they were observed. Ketamine impairs this ability. You might notice that it takes longer to recognise objects within your visual field for what they are, and at higher doses, you might lose object recognition capabilities completely.

Objects lose their object nature. Things turn into stuff. Sometimes I like to ask people, what’s your stuff-to-things ratio? It’s a silly question, but not an unreasonable gauge of where someone’s at.

Agnosia. Picture from the PsychonautWiki page for pattern recognition suppression, but I found it via Gaige Allen-Clark’s excellent post about NMDA receptor antagonists, Desummation. Gaige is a fellow independent researcher in this space; I highly recommend his blog, Qwerky Science.

With a more loosely reified visual field, bright lights can become overwhelming. Sunglasses or mood lighting are recommended. You might want to drape some spare clothing over light fixtures in settings where the lighting is tastelessly harsh, but watch out for house fires from incandescent bulbs.

Depth perception weakens, and the world can look more two-dimensional. The egocentric point can become unstuck, wobble around, and even disintegrate completely! Perhaps this is part of what is meant by ego death – but that is a nebulous term, and one I do not presume to truly understand.

Interesting things happen to one’s sense of attention and awareness in this state. You might be able to spread your attention much wider than normal, such that you can take in the entirety of your world simulation – all the way to its boundaries.

Illustration of visual perception by Steven Lehar.

If lacking a grounding in indirect realism – the idea that we never experience the world directly, only a recreation of it in our heads – this might all give you a sense of derealisation, like discovering you’re in the Matrix because you can see how the simulation works. But don’t worry. You’re still real. You’re just on ketamine.

Auditory perception

Auditory perception disintegrates in a manner which is similar in principle. The effects are best understood when listening to music.

I think it works a little like this. Your auditory processing streams maintain an on-the-fly predictive model which is used to anticipate the next few seconds of audio. Much of the surprise and delight of music comes from the prediction errors triggered by the difference between the predictive model and the actual stimulus, but ketamine causes this predictive model to dissipate more rapidly. As the predictive window shortens, more complex music can become utterly illegible, whereas slow-moving ambient or drone can take on a transcendental, hypnotic nature.

Somatic perception

If this all sounds more unpleasant than interesting, I don’t blame you. Maybe this stuff is only of interest to phenomenology nerds like myself, rather than recreational or therapeutic users – but I will state that any visual and auditory discombobulation tends to be made up for by the valence effects in the body.

For ketamine generally has an incredibly pleasant effect on bodily sensations! Paradoxically, it dampens their intensity while granting clear insight into their nature. Unpleasant sensations diminish, while attention can be heaped upon those which remain – even phenomena like taste can be inspected in great detail. Cuddling with someone can be especially nice in this state.

Ketamine is, of course, a tremendously powerful analgesic – but it’s also an excellent muscle relaxant. If you’ve never experienced ketamine before, you might have no idea just how much tension you’re holding in your body. It’s common for people to come to this realisation, and spontaneously start exploring a series of ketamine-assisted yoga poses.

I think the neuromuscular system is a great working example for the effect ketamine has on the Bayesian brain. I’ve spent a lot of time exploring psychedelic and ketamine assisted neuromuscular therapy – specifically, myofascial release – I think it shows a lot of promise, and am hoping to publish a full writeup in the near future.

In short, my working model is as follows: over time, the brain learns to hold patterns of tension in the body. Under the influence of ketamine, those priors weaken, muscles slacken, and the neuromuscular system can be coaxed into unlearning those stuck priors through direct stimulation of the tissues involved.

Even without massage, one tends to emerge from a ketamine experience with an incredibly relaxed body, and I would suggest that there’s also a passive neural annealing phenomenon at play.


No introductory post on ketamine is complete without a brief discussion of isomers. Ketamine has two stereoisomers: (R)-ketamine and (S)-ketamine. Typically street ketamine is either plain (S)-ketamine or a racemic mixture of both (R)- and (S)-ketamine.

A common topic of discussion is whether you can tell the difference. In short, I find (S)-ketamine is cleaner but less emotive, while (R,S)-ketamine is noisier but more emotive; empathogenic, even. For a detailed phenomenological account of the differences between the two, I recommend curious irrationalist’s writeup, Determining the golden ratio of ketamine stereoisomers:

However, while S-ketamine can be more fun, it’s always a cold, distant and floaty kind of fun. Racemic ketamine is a much more emotionally vibrant experience due to, I think, to the same noise-producing quality. It doesn’t make you happy or okay about your circumstances, it just adds a noisy firework-y sparkly emotional glitter on top of the dissociation that gives the whole experience an emotive quality.

I do find that (R,S)-ketamine is a splendid topical antidepressant, and this squares with the research. I’ve seen a single ten milligram bump put a halt to a friend’s suicidal ideations in five minutes flat. I’ve said it before, I’ll say it again – racemic ketamine is magical pixie dust brainwormicide – but do beware, if used carelessly the magic can wear off.

How does ketamine work?

The Bayesian brain is constantly working to update its priors in order to make better predictions, thus minimising prediction errors – but sometimes priors get stuck. For instance, someone who was raised in a high-conflict environment might remain paralysed by social anxiety in adult life, even if their life is now conflict-free. So, how does ketamine help with this kind of thing?

Ketamine may be regarded as an all-purpose lubricant for stuck priors.

When I first began experimenting with ketamine, I did not intend use it for therapeutic purposes – it just sort of happened spontaneously. During recreational use, I found myself able to step out of a wide array of reflexive, maladaptive behavioural patterns.

I also found that uncomfortable or emotional topics were much easier to think about and openly discuss – because I wasn’t reflexively cringing at myself, or clenching upon fixations – and I eventually carried this over into more deliberately constructed but still fairly informal one-on-one counseling sessions with a trusted friend.

So what exactly is going on, here? The phenomenology of reflexive behavioural patterns manifests in a curious way; I’ll attempt to report it as I experience it. I’d like to refer to the independent researcher Steven Lehar, who in A Cartoon Epistemology, discussed how our predictions about how we should move are encoded in something akin to a three-dimensional force field:

Now despite appearances to the contrary, the little man at the center of our world of experience is not the viewer or ‘experiencer’ of the surrounding virtual world. The body-image homunculus is just the interface between perceptual and motor function, expressed as an explicit model of the body in an explicit model of surrounding space.

Motor computation takes the form of spatial field-like forces in that space, that bend the body-image homunculus into different postures.

Andrés Gómez Emilsson expanded upon this in his post, Welcoming Steven Lehar as a QRI Lineage:

Another interesting nugget of insight is that in Lehar’s world, forces inside the world-simulation bias your motor actions and this is what renders and implements desire and disgust. In other words, there is something unexpectedly literal about saying that you are “attracted” to someone or something, or that an object or person “repulses” you! The way these forces are implemented can be conceptualized as fields that encode “how you would move at each point.” This proprioception is what guides the movement of our inner amodal avatar and how we plan sequences of actions.

Lehar makes us realize that as we navigate our environment, we move along something like a liquid membrane amenable to what feels like volitional influence, which guides our movement. This “force field” lives at the interface between our motor sensations and the volumetric representation of the external environment, and it works as a map between these two modes of experience.

It is within these subconscious force fields that the dual forces of cringing and clenching seem to manifest themselves. I feel that the physical and psychological aspects of these phenomena go hand in hand – my attention feels like it is guided by similar force fields, too. When it collapses habitually on a particular idea, or cringes away from an unpleasant one, my posture tends to clench or cringe in parallel. It can be challenging to catch this process in the act, but once you start noticing these patterns in yourself, you also start to notice them in others.

I’m not the first person to stumble across this particular idea – there’s significant overlap with what the rationalists call ugh fields – and I would say that cringing and clenching are both forms of something that meditation nerds call taṇhā. Mike Johnson offers a clear description in his recent post, Principles of Vasocomputation: A Unification of Buddhist Phenomenology, Active Inference, and Physical Reflex:

By default, the brain tries to grasp and hold onto pleasant sensations and push away unpleasant ones. The Buddha called these ‘micro-motions’ of greed and aversion taṇhā, and the Buddhist consensus seems to be that it accounts for an amazingly large proportion (~90%) of suffering.

Romeo Stevens suggests translating the original Pali term as “fused to”, “grasping”, or “clenching”, and that the mind is trying to make sensations feel stable, satisfactory, and controllable. Nick Cammarata suggests “fast grabby thing” that happens within ~100 ms after a sensation enters awareness; Daniel Ingram suggests this ‘grab’ can occur as quickly as 25-50 ms.

Often taṇhā is discussed in conjunction with dukkha, which seems to be an unpleasant emotional response that can immediately follow taṇhā. These phenomena can manifest themselves in response to fairly banal stimuli. Imagine if while cooking you crack an egg, covering your fingers with slimy albumen; do you hold yourself in psychological tension until you can wash your hands? There’s your taṇhā. By comparison, dukkha feels more like what you might do to yourself if you dropped the egg on the floor.

This esoteric Buddhist jargon is not actually that esoteric.

I’m really just outlining the same phenomena from multiple angles so everything is completely clear. Taṇhā, cringing, clenching, whatever you want to call it – it crops up all the time throughout day to day life.

By dampening our aversive reflexes – our predictions about where we should move our attention – ketamine slows this whole process down. We’ve already seen that ketamine reduces muscular tension, and this feels like an adjacent phenomenon. If Nick Cammarata suggests that taṇhā has a 100 ms onset time, on ketamine I’d say it can be 500 ms or more, dose dependent. This makes it much easier to catch it when it arises, and figure out how you wish to navigate through it. If you’re anything like me and you’re too lazy to meditate your way to a cringe-free existence, this is fantastic.

Unlike serotonergic psychedelics, ketamine does not exactly enhance learning in its own right. Instead, I view it as like training wheels for navigating taṇhā. Simply taking ketamine at parties has taught me a lot about how my social anxiety works, for example – it seems to have been based on a false expectation that everyone I met would find some reason to hate my guts. In response to this, my attention would automatically collapse, but on ketamine I could practice keeping it expanded – and then I would no longer feel like I wanted to squirm my way out of the crowded environment. The more I did this, the more prediction errors I accumulated – wow, people don’t actually resent my company – and the stuck prior started to loosen.

Other times, it may be the case that refactoring the stuck prior might require engendering a particular emotional response of some kind. This is a complex topic beyond the scope of this post, but I would highly recommend Kaj Sotala’s writeup on Coherence Therapy for a model for how this might work.

All this is well and good, but it doesn’t seem to account for how non-guided, solo ketamine therapy in a clinic tends to result in positive effects, and personally I’ve seen such effects from just using it by myself with no expectations. Again, I have to suggest that there’s a passive neural annealing phenomenon at play.

I would like to end this post with an album recommendation: Voices of the Air by Jon Porras, one half of the experimental drone duo Barn Owl. This is high valence drone – some movements are reminiscent of the church organ dirges on Tim Hecker’s Ravedeath, 1972, but with the important distinction that these overdriven excursions into whitecapped sonic backwaters always return to sunlit shores.

I can imagine a future where one might see the Human Car Wash on street corners in metropolitan areas: A small booth with a reclining chair and a vending machine dispensing eye masks and single shot ketamine nasal sprays in a range of isomer ratios. As you begin your session, if you neglect to connect your phone to the Bluetooth sound system, Voices of the Air is the default soundtrack that plays while you rinse off your stuck priors.