{'fraction_non_alphanumeric': 0.04120739896110478, 'fraction_numerical': 0.04706702141137717, 'mean_word_length': 4.6511544657240025, 'pattern_counts': {'":': 0, '<': 1, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 1, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Prefrontal PV interneurons facilitate attention and are linked to attentional dysfunction in a mouse model of absence epilepsy

Absence seizures are characterized by brief periods of unconsciousness accompanied by a lapse in motor function that can occur hundreds of times throughout the day. Outside of these frequent moments of unconsciousness, approximately a third of patients experience treatment-resistant attention impairments. Convergent evidence suggests prefrontal cortex (PFC) dysfunction may underlie attention impairments in affected patients. To test this, we use a combination of slice physiology, fiber photometry, electrocorticography (ECoG), optogenetics, and behavior in the Scn8a+/− mouse model of absence epilepsy. In these mice, we find decreased parvalbumin interneuron (PVIN) recruitment in the medial PFC (mPFC) in vitro and hypoactivity during cue presentation in vivo that is linked to attention dysfunction. Further, we find that low levels of mPFC PVIN activity are predictive of poorer performance in WT littermates. This highlights cue-evoked PVIN activity as an important mechanism for attention and suggests PVINs may represent a therapeutic target for cognitive comorbidities in absence epilepsy.

. AET performance deficits are unrelated to seizure activity in Scn8a +/mice. A, AET design. B, Illustration of ECoG recording and metrics for power analysis. C, Seizures were reduced during the task (Student's T test, p = 0.0155, n = 6 and 6 for home cage versus task animals respectively). D-E, Example ECoG activity from the highly seizure-active somatosensory cortex (S1) recorded during correct and incorrect trials with a 2s cue length. F, Representative time-frequency wavelet decomposition for correct trials (left) and incorrect trials (right). G, Trial-averaged power and variance over time in the Ø * (7-10 Hz) or β (10-20Hz) range with correct trials in purple and incorrect trials in grey. H, An example of a detected absence seizure (top) and the corresponding power in the Ø * (7-10 Hz) or β (10-20Hz) range. I-K, In Scn8a +/mice, there were no differences in power across cue lengths in the Ø * (7-10 Hz) or β (10-20Hz) range between correct and incorrect trials (I, Long cue, two-way ANOVA, accuracy effect, F (1, 16) = 3.998, p = 0.0628; J, Int cue, two-way RM ANOVA, accuracy effect, F (1, 10) = 3.367, p = 0.0964; K, short cue, two-way RM ANOVA, accuracy effect, F (1, 10) = 0.2082, p = 0.6580; n = 6 for all) L, There was no difference in average power between WT and Scn8a +/mice in the Ø * (7-10 Hz) or β (10-20Hz) range (two-way ANOVA, group effect, F (1, 18) = 0.1185, p = 0.5101, n = 5 and 6 for WT and Scn8a +/mice respectively). See also Figure 2  (Ungerleider 2000, Everling et al. 2002. To do so, we implanted optical fibers 189 targeting the prelimbic mPFC in mice with endogenous expression of Channelrhodopsin-2 (ChR2) in 190 neurons expressing the vesicular GABA transporter (VGAT:ChR2). As optogenetic activation of 191 interneurons has been shown to inactivate cortical network activity (Guo et al. 2014), this would 192 allow for inhibition of mPFC during distinct task epochs (Fig. 3). We trained VGAT:ChR2 mice on both 193 the AET (Fig. 3A) and a modified variable delay-to-signal task (VDST, Leite-Almeida et al. 2013), for 194 comparison (Fig. 3B). In the AET, we silenced mPFC during the variable cue period (Fig. 3C) where we 195 hypothesized attention is engaged most heavily, and observed a reduction in performance with 196 continuous light stimulation (Fig. 3D) without a significant change in reaction time. To assess 197 whether our reduction in performance could be reflecting an inability to report the cue in a matter 198 unrelated to attentional load, we utilized the VDST, where we would predict attentional load should 199 be greater in a different task epoch, the delay. When we photo-inhibited mPFC during the fixed cue 200 period in the VDST (Fig. 3E), there were no differences in the percentage of correct choices or 201 reaction time (Fig. 3F). However, when we silenced mPFC activity during the variable delay period 202 ( Fig. 3G), light stimulation reduced performance (Fig. 3H), without a significant difference in reaction 203 time. This suggests that the AET is linked to the mPFC, and that mPFC activation is critical during cue 204 detection in an attention-dependent manner. 205 206

Scn8a +/mice exhibit a loss of GABAergic inhibition in mPFC slice recordings 207
Our optogenetic experiments indicated the AET relies on mPFC function, suggesting a potential 208 frontal locus for performance impairments in Scn8a +/mice. In patients, SWD is prominent over the 209 frontal cortex, also suggesting frontal dysfunction (Archer et al. 2003, Tucker et al. 2007. 210 Additionally, individuals with absence epilepsy exhibit reduced functional activation of the PFC that 211 correlates with attentional impairments (Killory et al. 2011). Given this, we began with an in vitro 212 Figure 3. Cue detection in the AET is mPFC-dependent and linked to attentional load. A-B, Task design for the AET and VDST task. C, Experimental approach for disrupting prelimbic mPFC activity during the variable cue period with continuous blue light in VGAT:ChR2 mice. D, Photoinhibition with blue light reduces performance (left, two-way RM ANOVA, F(1,18) = 6.990, p = 0.0165, n = 6), without affecting reaction time (right, two-way RM ANOVA, F(1,18) = 3.323, p = 0.0850, n = 6) in the AET. E, Approach for photoinhibition during the fixed cue period in the VDST task. F, Performance or reaction time is not altered by light stimulation during the cue in the VDST (performance, paired t test, p = 0.7695; reaction time, paired t test, p = 0.6508; n = 6 for both). G, Approach for delivering continuous light stimulation during the variable delay period. H, Stimulation during the delay reduces performance in the VDST (paired t test, p = 0.0140) without altering reaction time (paired t test, p = 0.1268). approach to test for Scn8a +/related dysfunction in the prelimbic mPFC. We recorded network 214 activity using evoked local field potentials (LFPs) in coronal slices collected from Scn8a +/mice and WT 215 littermates (Fig. 4A, B) and derived a measure of current source density (CSD, Fig. 4C) (Freeman et al. 216 1975). This revealed several sinks or regions where cations flow into cells and out of the extracellular 217 space, such as at excitatory synapses. We also observed nearby current sources, commonly 218 attributed to the return flux of positive ions out of cells and back to the extracellular space. Of note, 219 sources can also indicate sites of inhibitory synapses where anions flow into cells, with nearby sinks 220 reflecting return paths. We developed a pharmacological approach to identify these distinct CSD To determine the participation of GABAergic interneurons during behavior, we utilized fiber 229 photometry to capture bulk Ca 2+ signals. We chose to monitor PVINs because their activity has been 230 classically linked to feedforward inhibition, a type of disynaptic inhibition important for gating 231 cortical responses (Swadlow 2003, Delevich et al. 2015, as well as successful attentional performance 232 and cognitively-associated gamma oscillations . 233 We injected the mPFC of Scn8a +/mice and WT littermates homozygous for Cre expression in PVINs 234 (PV:Cre) with an AAV5-CAG-FLEX-GCaMP6s virus and implanted an optical fiber for light delivery and 235 collection (Fig. 5A). Following recovery from surgery, animals were trained on the AET as described 236 above and GCaMP signals were collected throughout testing. The continuous signal (Fig. 5B) was 237 A, Experimental design of LFP recordings. B, Representative local field potential (LFP) recording in response to a 250 μA electrical pulse. C, Representative current source density (CSD) derived from the LFP recording. Brackets highlight the traces used for quantification (orange = L2/3 sink, purple = L2/3 source, green = L2/3 sink, magenta = L5 sink). D, Representative responses of the pre-and post-synaptic L2/3 sink, L2/3 source, and L5 Sink to 250 μA electrical stim. E-H, Peak amplitude curves (V/mm 2 ) of the response to electrical stim with increasing intensity. H, Only the L2/3 source showed a significant reduction in peak amplitude (twoway ANOVA, group effect, F (1, 60) = 8.125, p = 0.0060, n = 7 slices for both WT and Scn8a +/mice). I, Example of clonazepam's (100 nM) effects on the CSD components. Solid lines represent baseline CSD data, while transparent lines indicate CSD after wash on of clonazepam. See also Figure 4  segmented and aligned to trial initiation, and trials were sorted by cue length and accuracy 239 (representative individual trials and average activity from WT and Scn8a +/mice, Fig. 5C,D). First, we 240 took an average of each animal's change in fluorescence (dF/F) during the baseline (the second 241 immediately prior to the cue) and throughout the cue period for correct and incorrect trials and 242 compared cue-related activity for all cue lengths. We found that for correct trials PVIN activity was 243 consistently modulated at long and intermediate cue lengths (Fig. 5E), but not with the short, most 244 challenging cue length. However, for incorrect trials, we found no significant modulation in PVIN 245 GCaMP signals at any cue length. 246

247
To determine what features of the cue-evoked signal were most important for accuracy we fit a linear 248 regression model that attempted to explain average performance for all data at each cue length by 249 either peak amplitude of dF/F, average dF/F, or the time to peak dF/F ( When we compared these features of cue-evoked PVIN activity during correct trials between groups, 255 the peak amplitude was significantly reduced in Scn8a +/mice at long and intermediate cues, but not 256 the short cue (Fig. 5H). Average dF/F was decreased in Scn8a +/mice at the intermediate cue ( Fig. 5-257 Supp. 1C), however, the time to peak was not different between groups (Fig. 5-Supp. 1E). This 258 suggests that generally increases in PVIN activity co-occur with accuracy (as it is observed with the 259 long and intermediate cue where performance is higher), but only where attention is most heavily 260 and variably recruited does it correlate with overall performance. To examine this specific reliance 261 on PVIN activity at the attention-related intermediate cue more closely, we asked whether these 262 Figure 5. Cue-evoked PVIN activity is correlated with AET performance and reduced in Scn8a +/mice. A, PV:Cre; WT and PV:Cre;Scn8a +/were injected with a FLEX-GCaMP6s virus in the mPFC, and used for AET testing while recording Ca 2+ signals from PVINs using fiber photometry. B, Top, example of the raw data collected from 470 (Ca 2+ -dependent) and 405 (Ca 2+ -independent isosbestic) excitation. Bottom, the same data after calculating the dF/F, with trial initiation and cue presentation indicated. C, Heat maps of all trials of dF/F activity and (D) average dF/F activity from representative animals in both groups and across cue lengths. E, Average dF/F baseline and cue activity at each cue length with groups indicated by line color. There was a significant interaction between the cue presentation and cue length in PVIN FiP signals (twoway RM ANOVA F (4, 45) = 9.956, n = 10) during correct trials that was not observed in incorrect trials (F (4, 45) = 1.680, n = 10). PVIN activity increased during the long and int cue in correct trials (p < 0.0001 for each), but not for the short cue or incorrect trials at any cue length. F, Data points represent each animal's average performance at the long and int cue (G) plotted against the peak amplitude. All data points (PV:Cre;WT and PV:Cre;Scn8a +/-) were fit with a linear regression line. Peak amplitude was not a significant predictor of the percentage of correct choices for the long cue (r 2 = 0.3465, p = 0.0954) but was for the int cue (r 2 = 0.5981, p = 0.0145). H, Peak amplitude was reduced for PV:Cre;Scn8a +/mice compared to PV:Cre;WT (two-way ANOVA, F (1, 24) = 11.06, p = 0.0028, n = 5 for both PV:Cre;WT and PV:Cre;Scn8a +/mice) at the long (p = 0.0210) and int cue (p = 0.0210). I, A random forest classifier trained on the features from all FiP data for the int cue was able to predict trial outcome at a level significantly greater than chance as shown in the ROC-AUC curve (sensitivity vs specificity rate, p = 0.0056). See also Figure 5  measures could predict accuracy on a trial-by-trial basis. We trained a classifier using training data 264 with the features peak amplitude and time to peak from all trials at each cue length, and evaluated 265 its performance on a subset of held-out data. With long and short cues, our classifier was unable to 266 predict trial outcome above chance (Fig. 5-Supp. 2). However, for the intermediate cue (Fig. 5I), the 267 classifier correctly identified correct trials with 92% precision. We generated a receiver operating 268 characteristic (ROC) graph, calculated the area under the curve (Fawcett 2006), and found that the 269 AUC score was significantly greater than that generated by performing the identical classifier To explore whether decreases in PVIN activity were specific to cue perception, we also compared the 280 peak amplitudes of reward-related activity between groups and observed that Scn8a +/mice 281 exhibited reductions in PVIN activity during the time of reward consumption compared to WT mice 282 Our previous findings indicated reductions in cue-evoked PVIN activity in Scn8a +/mice. Given that 287 analysis of ECoG/EEG remains the gold standard for diagnosis of absence epilepsy, we were curious if 288 ECoG recordings might facilitate identification of network-level biomarkers related to attention 289 dysfunction that could be measured in humans. We implanted a cohort of Scn8a +/and WT mice with 290 a gold electrode over the mPFC and recorded ECoG (Fig. 6A) while mice performed the AET. As 291 described above, we performed wavelet decomposition to obtain ECoG spectral power across 292 different frequency bands (Fig. 6B) and compared power between Scn8a +/mice and WT littermates.  A, Experimental design, ECoG activity was recorded using a gold electrode over mPFC and a reference screw over the cerebellum during the AET. Power was measured during the cue period across frequency bands. B, Representative ECoG filtered across different frequency bands during the cue period. C, Performance was decreased in Scn8a +/mice (two-way ANOVA, F (1, 21) = 4.497, p = 0.0460, n = 3 and 6 for WT and Scn8a +/mice respectively). D-F, Scn8a +/mice have reduced power during the long (high gamma, p = 0.0597) and int cues (high gamma, p = 0.0145), but not during the short cue (long, two-way ANOVA, F (1, 35) = 5.623, p = 0.0234; int, two-way ANOVA, F (1, 35) = 4.586, p = 0.0393; short, two-way ANOVA, F (1, 35) = 0.2656, p = 0.6095; n = 3 and 6 for WT and Scn8a +/mice respectively). 7B). Importantly, this effect was not observed in PV:Cre;Scn8a +/mice that underwent the same 312 experimental protocol with a control eYFP virus (Fig. 7-Supp. 1A). 313

314
We also were curious whether the commonly used anti-epileptic drug, Valproic Acid (VPA) would 315 modify performance in the AET, given the lack of efficacy in mitigating cognitive symptoms in 316 patients (Fig. 7C). WT and Scn8a +/mice were treated twice daily with saline and VPA, the latter of 317 which significantly reduced seizure burden in Scn8a +/mice ( Fig. 7-Supp. 1D). Although Scn8a +/mice 318 exhibited reduced performance compared to WTs, there was no effect of VPA on accuracy in either 319 group (Fig. 7D). 320

Discussion 322
Our findings demonstrate that cue-evoked mPFC PVIN activity is strongly linked to and in certain 323 cases, predictive of correct choices during a novel attentional engagement task (AET). Additionally, 324 PVIN activity is positively correlated with performance both in WT and Scn8a +/mice. To our 325 knowledge, this is the first demonstration of a cell type-specific activity pattern during rather than 326 prior to cue perception predicting trial outcome during an attention task. These results also provide 327 the first evidence of both the behavioral manifestation and a circuit biomarker of attention 328 impairments in an animal model of absence epilepsy, one of the most commonly presenting 329 cognitive comorbidities associated with the syndrome. Further, our findings support the recruitment 330 of PVINs and gamma activity as a universal mechanism for visual discrimination and successful goal-331 directed behavior during attentional engagement. 332 333

Attentional and cognitive impairments in absence epilepsy 334
Absence epilepsy is classically defined as an interruption of consciousness due to the emergence of 335 stereotyped spike-and-wave activity ranging from 3-6 Hz in clinical populations (Watanabe 2003). Using our novel attention assay the AET, we confirmed that our model bore several similarities to the 346 human condition. Most importantly we observed a consistent impairment in attention that appeared 347 to exist independent of the seizure pathology. Seizures were reduced in Scn8a +/mice during task 348 engagement, and treatment with VPA, a common AED, had no effect on AET performance. Along 349 with observing no increase in power in seizure-related bands during incorrect trials in Scn8a +/mice 350 or on average in comparison to WTs, we speculate that the attention impairments and seizures arise 351 from distinct mechanisms.

Implications for cognitive therapies in absence epilepsy and other disorders 412
As attentional engagement precludes information perception related to other cognitive domains, 413 such as working memory, attentional shifting, and even information encoding for short or long-term 414 memory, deficits in attention are likely to occur in concert with a host of cognitive abnormalities. In 415 addition to absence epilepsy, attention impairments present as a comorbidity in diseases with 416 complex cognitive behavioral phenotypes, including schizophrenia (Green 1996), autism (Allen et al.

Lead Contact 433
Further information and requests for resources and reagents should be directed to and will be 434 fulfilled by the lead contact, John Huguenard (Huguenar@stanford.edu). 435

Materials Availability 436
This study did not generate any unique reagents. 437

Data and Code Availability 438
Source data to recreate figures presented in this manuscript has been uploaded to Dryad and can be 439 stainless steel ferrule, Doric Lenses) insertion procedure was the same, except it was bilateral rather 475 than unilateral. VGAT:ChR2 mice also were implanted with bilateral optical fibers into the mPFC. 476 Following optical fiber insertion, the optical fiber was stabilized, and the incision was closed using 477 dental cement. After surgery, animals recovered for one week before food restriction, and a week 478 the reward port. Following an incorrect choice, the doors would close, leading to a 30 second 493 timeout, where the animal could not initiate another trial. All mice had to reach a criterion of at least 494 70 % correct for 3 consecutive training days, or 90% correct for 2 days. During testing, after trial 495 initiation, a visual cue of either 5s, 2s, 1s, 500ms, and 100 ms, or 5s, 2s, or 500 ms, indicated the 496 correct location of the food reward. The cue length and correct side varied pseudorandomly, and 497 performance was averaged over 3 test days. Omissions were quantified as trials in which the animal 498 took longer than 5s following cue termination to make a choice. Reaction Time was the time 499 between trial initiation and making a response in one of the reward ports. In single-cue length 500 blocks, trials were organized on to 10-trial blocks of each cue length from longest to shortest that 501 repeated until the end of the session. Repetitive responding was quantified by counting the number 502 of blocks of 5 consecutive trials in which the animal selected the same port normalized by the total 503 trial number in a session. For the VGAT:ChR2 experiments, training for the VDST began immediately 504 following the final AET test day. Animals were trained using the same strategy of reinforcement and 505 punishment as described above to respond to fixed 1s cue following a 2s delay. To avoid 506 overtraining, mice had to complete only one day at 60% correct to continue to testing. During 507 testing, the delay prior to the cue varied between 3s, 4s, and 5s while the cue length remained fixed 508 at 1. Trial logic was controlled by a microcontroller (Arduino Mega 2650), and custom MATLAB scripts 509 were used to analyze data and determine the percentage correct at each cue length. 510 Sociability. To measure sociability, mice were tested in a three-chamber social interaction task (Moy 511 et al., 2004). For the three-chamber paradigm, the apparatus was partitioned into three zones, with a 512 small walkway so the mouse could move freely between chambers. A camera was mounted directly 513 above the apparatus to capture video that was used for later analysis. Animals were habituated to 514 the entire apparatus for ten minutes. Then, an empty cage was positioned in one chamber, a cage 515 containing a novel mouse was placed in the opposite chamber, and the mouse was given ten 516 minutes for exploration. Videos were scored by the experimenter, and active interaction, time spent 517 oriented toward, sniffing, or interacting with the empty cage versus the cage with the novel mouse 518 was measured. 519 Object Recognition. Object recognition was tested as previously described (Barker et al., 2007) in a 520 clear plastic chamber (14 x 16 x 6") in which mice were habituated to for 5 minutes on the day prior 521 to beginning testing. One object pair was a set of four stacked bottle caps, alternating between 522 purple and orange caps. The other was a glass jar of equal height as the tower of caps, filled with 523 purple sand. The testing day consisted of a sample phase and a test phase, with a two-hour delay 524 between. During the sample phase, mice were given 3 minutes to explore two identical objects 525 placed in the center of the arena. For the test phase, one of the objects was replaced, and the animal 526 was allowed to explore both objects freely for five minutes, while video was acquired from above the 527 testing arena. The experimenter scored the videos by measuring the total time spent exploring each 528 object within the first 20 seconds of total exploration. A difference score was calculated by taking the 529 time exploring the object in phase 2 from phase 1, then dividing that difference by the total time (20 530 seconds). Heatmaps of the animal's activity in the during object recognition and social interaction 531 using ezTrack in Jupyter Notebooks (Pennington et al. 2021). 532

Electrocorticography Recordings and Analysis 533
Mice were surgically implanted with bilateral ECoG screw electrodes into the skull above the 534 somatosensory cortex (S1) or gold pin electrodes over the mPFC, and recorded channels were 535 referenced to an ECoG screw electrode above the cerebellum. Data were acquired using the 536 OpenEphys data acquisition board and software (Siegle et al. 2017). Data were bandpass filtered 30 using a Butterworth filter (0.1 -100 Hz) and sampled at 30 kHz. We recorded ECoG from animals over 538 3 sessions where they were initiating trials at a rate of at least 1 trial per minute (engaged in task). For 539 the S1 recordings, this was compared to 3 one-hour home cage sessions. All data processing and 540 analysis were performed using custom MATLAB scripts. Continuous wavelet transformation was used 541 for spectral analysis (Torrence et al. 1998) as described in (Sorokin et al. 2017). For seizure detection, 542 we utilized the full power spectrogram to detect seizures and events were only included if they were 543 between 2 and 30 s in duration. Additionally, events that exhibited maximum power beyond the 544 typical absence seizure spectrums were discarded. Seizures were normalized to session length, and 545 displayed as seizures/minute. For power analysis, data was segregated into by cue length and 546 accuracy, and mean power in the modified theta (Ø * , 7-10 Hz) or β (10-20Hz) range which 547 encompass the fundamental and 2 nd harmonic frequency bands for absence seizures (Sorokin et al. 548 2017) was extracted, and displayed as mean power and variance in relation to the cue. 549 For the mPFC recordings, we extracted data from the cue period across trials and separated data by 550 cue length and accuracy. We generated ECoG power spectrograms (1-100 Hz) using the continuous 551 wavelet transform (Morlet wavelet in the Matlab wavelet toolbox). The spectrograms were 552 normalized to peak, and power was averaged within bands of interest (4-8, 8-12, 12-30, 30-50, 60-90). 553

Extracellular Multi-Unit Electrophysiology 554
To measure differences in network activity, extracellular recordings were obtained from mice who 555 had been previously used for fiber photometry experiments. Mice were anesthetized with 556 pentobarbital (50mg/kg) and perfused with ice-cold sucrose buffer containing (in mM): 234 sucrose, 557 2.5KCl, 1.25 NaH2PO4, 10 MgSO4, 0.5 CaCl2, 26 NaHCO3, and 11 glucose, equilibrated with 95% O2 558 and 5% CO2, pH 7.4). Mice were decapitated, the brain was extracted, and coronal slices (400 μm) 559 were collected using a Leica VT1200S vibratome. Slices were transferred to oxygenated ACSF 560 (containing in mM: 126 NaCl, 2.5 KCl, 1.25 NaH2PO4, 2 MgCl2,2 CaCl2, 26 NaHCO3), that bubbled 561 continuously with 95% O2 and 5% CO2, and incubated at 32°C for 1 hour. Then, slices were 562 incubated at room temperature for 1-5 hours before they were placed in an interface recording 563 chamber, in which they were continuously perfused with oxygenated ACSF (30-32°C) at a flow rate of 564 2-3ml/min. A linear silicon multichannel probe (16 channels, 100 μm inter-electrode spacing, 565 NeuroNexus Technologies) was placed in the prelimbic mPFC perpendicular to the laminar plane, 566 such that the electrode array collected local field potentials (LFPs) from each cortical lamina. A 567 bipolar tungsten electrode was placed immediately ventral to the recording array in layer II/III to 568 deliver electrical pulses (0.1 ms, 100-500 μA in 100 μA increments) to evoke synaptic responses. 569 Signals from all sixteen channels were digitized at 25 kHz, using a 3000 Hz lowpass filter, amplified 570 and stored using a RZ5D processor multichannel workstation (Tucker-Davis Technologies). To better 571 examine the location, direction, and magnitude of currents evoked in response to electrical 572 stimulation, a current source density (CSD) analysis was performed by calculating the second spatial 573 derivative of the LFP (Freeman et al. 1975). When net positive current enters a cell, this creates an 574 extracellular negativity that is reflected in a current "sink," and appears as a negative deflection in the 575 CSD. Conversely, current "sources" indicate net negative current flowing into a cell and will create 576 positive CSD responses. Differentiation of CSD components into pre and post-synaptic as well as 577 determining distinct neurotransmitter contributions were identified. DNQX (25 μM, Sigma, D0540) 578 and CPP (1 μM, Sigma, C104) were used to determine disynaptic and post-synaptic components, 579 while Clonazepam (a benzodiazepine, 100 nM) was used to identify components reflecting or related 580 to GABAergic neurotransmission. Peak amplitudes were quantified using trial-averaged responses at 581 each stimulation intensity (10 trials each). LFP and CSD plots were generated using custom MATLAB 582 scripts. 583

Fiber Photometry 584
Fiber Photometry was used to measure aggregate Ca 2+ signals from GCaMP6s-expressing PVINs 585 during the AET. The set up was designed as described in (C. K. . Briefly, an implanted 586 optical fiber (1.25 diameter stainless steel ferrule) was coupled to a patchcord with ceramic sleeves 587 (Thorlabs, ADAL1). The patchcord terminated in an SMA connector (Thorlabs, SM1SMA), which was 588 with the fiber photometry data. The dF/F was separated into trials by cue length and accuracy, and 602 peak, average, and time-to-peak were quantified using custom MATLAB scripts. Representative 603 heatmaps of individual trial data were generated using the MATLAB function imagesc. 604

Machine Learning Trial Prediction 605
Trial Prediction Analysis was performed in python using built-in functions from the sklearn and 606 imblearn toolkits. Data were organized into tables with trials for each cue length with the features 607 peak and time-to-peak for each trial along with its classifier, correct or incorrect. Data were separated 608 into training and testing data sets using an 80/20 split. Given that there were often much more 609 correct than incorrect trials at longer cue lengths, the incorrect trials (minority class) were 610 oversampled using the synthetic minority oversampling technique (Chawla et al. 2002), then the 611 features from the training and test set were normalized independently. The performance of several 612 classifiers was evaluated on the training data using repeated K-fold cross-validation (k = 10, 10 613 repeats) to get the average f1-scores and receiver operating characteristic-area under the curve (roc-614 auc) scores. Based on this, a random-forest classifier was chosen to make predictions on the test set. 615 To test classifier skill, we generated ROC-AUC curves on the test set, and compared that with curves 616 generated using the identical training and testing procedure described above but with random 617 shuffled data. 618

Optogenetics 619
To deliver optogenetic stimulation during behavior, we utilized several components of the fiber 620 photometry system described above including the LED and LED driver, patchcord, and optical fibers. 621 Once the animal initiated a trial, the Arduino sent TTL pulses directly to the LED driver, such that blue 622 light pulses (470 nm, 40 Hz, 5ms pulse width, 0.5mW) were delivered to through the patchcord to the 623 mPFC throughout the duration of the cue. 624

Pharmacology 625
For evaluation of VPA treatment on AET performance and seizures, animals were treated twice daily 626 with the following schedule: Twice daily saline beginning in the evening two days before testing, 627 and continuing for two days of testing, then twice a day VPA (200 mg/kg) beginning two evenings 628 before day one of VPA testing, and continuing for three days. ECoG was recorded during each 629 behavioral session. Data was analyzed from two days of saline testing and three days of VPA testing 630 and averaged for comparison. Animals were removed from food restriction and allowed a two-week 631 wash out period, then this same approach was repeated without behavioral testing. Animals were 632 A, Mice received a bilateral injection with the FLOX-eYFP virus, and were implanted bilaterally with optical fibers for delivering blue light. B, There is no effect of light (two-way ANOVA, F (1, 15) = .2598, p = 0.6177, n = 5 mice). C, Illustration of ECoG recording over S1 with reference screw in the cerebellum. D, VPA reduces the amount of seizures per minute (Wilcoxon matched-pairs signed rank test, p = 0.0313, n = 6).

Source Data Files 727
Source data files for Figure 1, Figure 2