Why this matters
What you have just walked through is, at heart, one capability. In a sleeping rat, a closed-loop system can identify which memory is being rehearsed in a given hundred-millisecond window and selectively interrupt only the rehearsals of that memory while leaving everything else alone. From electrode pickup to laser pulse, the system completes a full cycle in roughly one millisecond. That capability did not exist a few years ago. It exists now.
A single replay event, processed through every stage of the closed-loop system. Tetrodes pick up the spike (Ch. 2), the HSE detector flags it within ~10 ms (Ch. 5), the Bayesian decoder classifies its room within roughly one more millisecond (Ch. 6), and the laser TTL fires onto the ArchT-expressing population (Ch. 7). Median spike-to-TTL latency on the actual hardware: 1.04 ms.
Three audiences should care about this for slightly different reasons.
For neurotech
Closed-loop content-specific neural manipulation is the design pattern that next-generation brain-machine interfaces will be built around. The decoder, the latency budget, the marked-point-process trick, the dynamic-threshold detector — each piece transfers. A BMI that reads intent in real time and writes feedback at the single-event scale is the same architectural problem as the one solved here, with rats swapped for humans and optogenetics swapped for whatever the actuator turns out to be (electrical micro-stimulation, focused ultrasound, magnetothermal). The feasibility question for that whole class of system is partly an existence proof. This is one such existence proof.
For memory therapeutics
A long line of pharmacology has tried to perturb memory consolidation with drugs — benzodiazepines, propranolol, NMDA antagonists, sleep-stage modulators. The intervention is almost always systemic and almost always blunt. Closed-loop content-specific disruption is a precision tool that targets one neural pattern during one phase of consolidation, leaving other patterns and other phases unaffected. PTSD reconsolidation, age-related memory decline, addiction-related cue memory: each of these is a candidate domain where pattern-specific intervention during natural sleep would be qualitatively different from the pharmacological state of the art.
For pharma and biotech research
The same infrastructure that triggers a laser can trigger any other intervention — a drug delivery pump, a cooling element, a transcranial pulse, a feedback signal to another system. Real-time content-specific neural decoding gives drug development programs a way to correlate pharmacokinetics with the actual neural patterns they are trying to influence. For nootropic and consolidation-focused programs, that closes a measurement gap that has held the field back for decades.
The system, as software
The closed-loop pipeline that ran all of this lives, open-source, on GitHub. It is a custom C++ codebase running on a real-time Linux kernel, written to be deployable on commodity research hardware (a workstation, an Axona acquisition rig, optic fibres, a 532-nm laser). It has been used in published work (this paper) and is structured for re-use in other labs that need closed-loop spike-level intervention.
- Real-time spike sorting, marked-point-process decoding, and trigger logic
- Dynamic threshold HSE detector with sub-millisecond response
- Modular pipeline configurable per session via a parameter file
- Custom C++, Linux real-time kernel, MIT license
About this work
The PhD this site walks through was completed in the Csicsvari lab at IST Austria. The paper is Gridchyn et al., Neuron, 2020 — “Assembly-specific disruption of hippocampal replay leads to selective memory deficit.” Since the paper came out I have moved further into AI and applied machine learning, with a focus on biotech and pharma; ongoing writing on that lives at the AI in Pharma & Biotech newsletter.
For collaboration, hiring, or technical questions about the closed-loop system, the cleanest path is the GitHub repo or the contact form on the main site.
Thank you for reading.