A diverse array of chronic pain syndromes are refractory to almost all treatment but involve pathological activity in similar brain regions. This suggests therapeutic potential for deep brain stimulation (DBS) for refractory pain disorders, but despite early promise, long-term efficacy is lacking. Current DBS devices are limited in anatomical reach, targeting only a subset of the distinct brain regions known to be important. Further, DBS therapy is bluntly applied in an "open-loop," continuous fashion without regard to underlying physiology. As a result of these shortcomings, DBS for pain is often ineffective or shows diminished effect over time. Loss of therapeutic effect may be due to nervous system adaptation or a failure of stimulation to accommodate patient- specific dynamics of pain processing. DBS could be significantly improved by seeking individually optimized brain targets or by using neural biomarkers of pain to selectively control stimulation when it is needed ("closed-loop" DBS). Better brain targets would also address the different dimensions of pain such as somatosensory (location, intensity and duration), affective (mood and motivation) and cognitive (attention and memory). The main goal of this study is to test the feasibility of personalized targeting of brain regions that support multiple pain dimensions and to develop new technology for "closed-loop" DBS for pain. The study team will develop data-driven stimulation control algorithms to treat chronic pain using a novel device (Medtronic Summit RC+S or Percept RC) that allows longitudinal intracranial signal recording in an ambulatory setting. By building this technology in an implanted device, chronic pain DBS is tailored to each patient and will advance precision methods for DBS more generally.

Beginning with an inpatient trial period, subjects with various refractory chronic pain syndromes will undergo bilateral surgical implant of temporary electrodes in the thalamus, anterior cingulate, prefrontal cortex, insula and amygdala. These regions have been implicated in the multiple dimensions of pain. The goal of the trial period is to identify candidate biomarkers of pain and optimal stimulation parameters for each individual, and to select subjects who show likelihood to benefit from the trial. A subgroup of 6 such patients will then proceed to chronic implantation of up to 3 "optimal" brain regions for long-term recording and stimulation. The invstigators will first validate biomarkers of low- and high-pain states to define neural signals for pain prediction in individuals (Aim 1). The investigators will then use these pain biomarkers to develop personalized closed-loop algorithms for DBS and test the feasibility of performing closed-loop DBS for chronic pain in weekly blocks (Aim 2). Finally, the investigators will assess efficacy of closed-loop DBS algorithms against traditional open-loop DBS or sham in a double-blinded crossover trial (Aim 3) and measure mechanisms of DBS tolerance. Our main outcome measures will be a combination of pain, mood and functional scores together with quantitative sensory testing. Successful completion of this study would result in the first algorithms to predict real-time fluctuations in chronic pain states and development of a new therapy for currently untreatable diseases.