Anisotropic hydrogel microelectrodes for intraspinal neural recordings in vivo
Soft-material solutions have advanced motion-adaptive interfaces to enable neural modulation and recording in vivo, particularly within tissues experiencing complex mechanical dynamics, such as the spinal cord – and peripheral nerves , . These nerve tissues often suffer from damage due to a mechanical mismatch between traditional rigid implants and the delicate nervous system, hindering access to deep structures under freely moving behavioral contexts. Therefore, a motion-adaptive soft-material neural interface is required to minimize tissue damage during animal natural movement and achieve optimal recording results from physiological signals. Engineering approaches have been adopted to enhance the electrical functionality of these interfaces. Fractal design concepts provide the capacity to extend conventional silicon-based technologies with soft materials and curvilinear structures . Conductive coatings, such as conductive polymers and micro-cracked metallic films , applied to soft and elastic substrates, have shown substantial success in electrical stimulation and recording in spinal cord tissue and the peripheral nervous system. The soft and elastic polymer matrix ensures flexibility and stretchability, while the conductive pathways formed either through the conjugation of polymer backbone or metallic nano- and micro-structures, maintain conductivity under strain. However, most epidural electronics are designed to interface with the surface of the spinal cord, featuring large areas of flexible surface electrodes but lacking access to single-unit neural recordings, especially in the deep ventral structures. Due to the complex anatomical structures and mechanical conditions in the spinal cord, especially in awake and moving animals, the surface coating designs are also limited by the risk of delamination and fatigue under large strains over long-term implantation. Instead of designing surface epidural electrodes, we hypothesize that penetrating microelectrodes can access deep tissues with improved spatial precision for intraspinal recordings. Embedding conductive fillers directly into the polymeric matrix to achieve stable electrical properties under stretching can create robust, electrically percolative pathways . Particularly, nanocomposite materials containing high-aspect-ratio conductive fillers, allow for the reconstruction of percolation networks through the organization of nanofillers . Such methods address the risk of technical failures of delamination and the diminished overlap of percolation pathways under repeated stretching. Hydrogels show considerable promise as an elastic soft substrate due to their tissue-like mechanical properties (8 kPa – 5 MPa) , biocompatibility and designable functionalities especially suitable for intricate spinal cord tissues – . Semi-crystalline polymers-based hydrogels, such as cross-linked polyvinyl alcohol (PVA) hydrogel, contain both amorphous polymer chains and polymeric nanocrystalline domains and offer a low elastic modulus and high fatigue resistance under complex mechanical conditions , . The integration of conductive nano-fillers within the hydrogel matrix intertwines with polymer chains to create three-dimensional percolative pathways within the elastic substrates. Both computational and experimental studies have demonstrated that the conductive pathways of nanofillers can be regulated and reconstructed through stretch-induced kinematic movements and self-organization , . Additionally, mechanical stretching can induce nanocrystalline re-alignment in hydrogels . In a nanocomposite design, polymeric nanocrystalline support enhances durability and stretchability, while the anisotropic conductive pathways of nanofillers ensure the conductivity necessary for collecting in vivo electrical signals under complex tissue movements. Due to the chemically inert property and high-aspect-ratio structures, carbon-based conductive fillers are particularly suitable for in vivo physiological metabolic environments and the formation of conductive pathways with low concentrations. In this study, inspired by stretch-induced polymeric nanocrystalline growth and nanofillers reconstruction, we introduced carbon nanotubes (CNTs) into fatigue-resistant PVA hydrogels to create a set of conductive CNTs-PVA hydrogel fibers for electrical recording in vivo. We observed a decrease in hydrogel fibers’ impedances after applying cyclic mechanical stretching (5000 cycles at different strains: 5%, 10%, and 20%) and anisotropic conductivity improvement aligned with the stretching direction after cyclic stretching. Electron microscopy, stimulated Raman scattering microscopy and X-ray examination revealed a Tension Reinforcement for AnIsotropic Nano-orientation (TRAIN) mechanisms underlying the directional conductivity improvement (dispersion degree of CNTs in PVA matrix: 9.60 ± 2.22 o ). Representative CNTs-PVA hydrogel fibers maintained 64.5 ± 7.9% stretchability and impedance of 33.20 ± 9.27 kΩ at 1 kHz with a diameter of 187 ± 13 µm. For in vivo testing, we fabricated our CNTs-PVA hydrogel fibers into electronic devices and implanted them into mouse hindlimb muscles and ventral areas of spinal cords. In muscle-implanted transgenic Thy1::ChR2-EYFP mice, we captured light-evoked electromyographic (EMG) signals. In wild-type (WT) mice, we conducted simultaneous EMG recordings from both tibialis anterior (TA) and gastrocnemius soleus (GS) muscles during voluntary wheel running tests. With a miniaturized hydrogel microelectrode device, we successfully recorded the neuron activities from the ventral spinal cord neurons and TA muscle in response to light stimulation in anesthetized transgenic Thy1::ChR2-EYFP mice. When the hydrogel microelectrodes were implanted into the ventral horn of the lumbar region, single-unit neural spiking activity was recorded over long-term observations in both anesthetized and free-moving conditions, which underscores the potential of hydrogel bioelectronics for extended neurophysiological monitoring in naturally behaving animals. 

Stretch-induced conductivity improvement in nanocomposite hydrogel fibers Conductive hydrogels have been applied to biosensors , , wearable electronics , , and neural interface technologies due to mechanical compliance to complex in vivo conditions. Aiming to examine neuromuscular pathways in the spinal cord and peripheral nerves, we designed semi-crystalline hydrogels that embedded conductive nanofillers to adapt to the dynamic environment in vivo during movements (Fig. ). Built upon the phenomenon of stretch-induced nanocrystalline domain alignment in hydrogels , , we utilized the cross-linked PVA hydrogels as the matrix and introduced CNTs with aspect ratios of 2000–10,000:1 as the conductive nanofillers to create conductive hydrogel microelectrodes for in vivo electrical recordings. Our hypothesis centered on the polymeric nanocrystalline of the hydrogels supporting a durable elastic substrate while the reconstruction of conductive percolative networks through nano-fillers re-alignment provides robust conductivity under stretching (Fig. ). We incorporated CNTs during hydrogel chemical cross-linking and then subjected CNTs-PVA hydrogels to cyclic stretching (20% strain for 10,000 cycles, Supplementary Fig. ). Scanning electron microscopy results indicated a reconfiguration of CNTs bundle structure, which aligned along the direction of applied strain (Fig. ). To examine whether these microstructural changes correlated to their functional performance, we first characterized the electrochemical impedances of the conductive nanofillers-embedded hydrogel fibers. We prepared the CNTs-PVA hydrogel fibers with a series of CNTs concentrations in the range of 0.04 wt% to 0.24 wt%, incorporated into a 10 wt% PVA hydrogel matrix and examined their electrochemical impedance spectroscopy results (EIS, Fig. and Supplementary Fig. ). To compare the electrical performance of the CNTs-PVA hydrogel fibers across varying CNTs loadings, we normalized the impedance values relative to the cross-sectional area and the effective length of the uninsulated fibers under examination. At a 0.04 wt% CNTs inclusion, we observed a normalized impedance (specific impedance) of 0.51 ± 0.08 kΩ mm at 1 kHz, a frequency commonly used for single-neuron activity recording. These results suggest that this nanofiller concentration surpasses the percolation threshold – . This analysis revealed a decrease in the specific impedance with an increase in CNTs content, with values declining from 0.51 ± 0.08 kΩ mm to 0.04 ± 0.01 kΩ mm, thereby indicating the role of CNTs in contributing to the conductivity of the hydrogel fibers (Fig. ). Then, we examined the effect of stretching on CNTs-PVA hydrogels impedance change. We included two types of stretching conditions in the evaluation: employing stretching during the hydrogel drying and annealing processes, which was denoted as “pre-stretch” and cyclic stretching under water after the hydrogel fibers underwent drying, annealing, and re-hydration. To compare the stretching effect, we employed a group of CNTs-PVA hydrogel fibers (0.04 wt%, 0.08 wt%, 0.16 wt% and 0.24 wt% CNTs in 10 wt% PVA) with a 200% pre-stretch, a group with the combination of 200% pre-stretch with subsequent cyclic training (denoted as TRAIN hydrogel, 10% strain for 5000 cycles under water), and a group of 0% pre-stretched samples as the control (Fig. ). As a representative example, for fibers with a CNTs loading of 0.16 wt% and a diameter of 187 ± 13 µm, cyclic stretching reduced impedance from 55.47 ± 13.03 kΩ (200% pre-stretched fibers in 1 cm length, in corresponding to 0.43 ± 0.05 kΩ mm as normalized impedance) to 33.20 ± 9.27 kΩ (fibers with 200% pre-stretch and 10% train for 5000 cycles in 1 cm length, in corresponding to 0.10 ± 0.03 kΩ mm as normalized impedance). Furthermore, cyclic stretching not only reduced specific impedance from 0.43 ± 0.05 kΩ mm (0% pre-stretched fibers) to 0.10 ± 0.03 kΩ mm (200% pre-stretch with 10% strain for 5000 cycles ) but also yielded a lower specific impedance than fibers that underwent only a single 200% pre-stretch with the impedance of 0.16 ± 0.02 kΩ mm (Fig. ). To further explore the impact of mechanical training, we adhered to Hooke’s law and defined the first 20% of strain as the elastic zone for establishing training strains in our CNTs-PVA hydrogels and we observed that at 0.24 wt% CNTs, 20% strain of cyclic training further enhanced the conductivity of the hydrogel microelectrodes (Fig. ). To systematically assess the influence of mechanical stretching with different CNTs loadings, we measured the impedance ratio of the hydrogel fibers before and after 5000 cycles of stretching and found over 1.5 ratio across all the groups, indicating a consistent effect of the mechanical stretching on the conductivity improvement (Fig. ). We also observed the decreased impedance associated with pre-stretch and cyclic stretching in different PVA hydrogel matrix (0.16 wt% CNTs into 10 wt% PVA) with a series of PVA molecular weights (MWs) of 30 kDa, 89 kDa, and 146–189 kDa (Supplementary Fig. ). This trend is likely because longer polymer chains in the hydrogel matrix offer a more flexible environment, allowing high-aspect-ratio fillers to form effective conductive pathways when stretched , . In alignment with the reported phenomenon of shakedown after prolonged cycling in tough hydrogels , we observed that extending the stretching process of the CNTs-PVA hydrogel fibers from 20,000 cycles with 20% strain resulted in a steady status after 5000 cycles (Fig. ). We measured the electrochemical impedance of each CNTs-PVA fiber and compared these measurements with the original fibers without any stretching. The impedance continued to decrease during the cycling process until it stabilized at approximately 5000 cycles, maintaining 35.64 ± 18.62% of the original impedance. We also discovered that the water content fraction of TRAIN CNTs-PVA hydrogel fibers reached a steady level after approximately 5000 cycles (78.6 ± 3.5%, Supplementary Fig. ). Given that hydrogel microelectrodes will undergo repetitive stretching conditions in vivo, maintaining the impedance and water content fraction of CNTs-PVA hydrogel fibers within this steady level is crucial for ensuring the stable performance of hydrogel electrodes in detecting electrophysiological signals. Tension reinforcement for anisotropic nano-orientation (TRAIN) strategy To investigate the underlying mechanisms in the observed conductivity improvement after stretching, we measured the morphology change of conductive fillers in hydrogel matrix after stretching treatment. We applied customized stimulated Raman scattering (SRS) microscopy to the CNTs-PVA hydrogels to visualize the alignment of CNTs within the PVA hydrogel matrix with chemical bond information (Fig. ). SRS employs coherent amplification via a pump beam and a Stokes beam, resulting in a substantial enhancement of the Raman signal strength compared to the relatively weak spontaneous Raman scattering process , . We first detected the featured G-band of CNTs at 1596 cm -1 as the indicative C-C bond , (Fig. ). From the SRS microscopy images, we observed that following 10,000 cycles of cyclic stretching at a 20% strain, CNTs within the PVA hydrogels were preferentially aligned along the axis of stretching (Fig. , 0°, denoted as TRAIN hydrogels). This realignment contrasted with the random orientation seen in the untrained CNTs-PVA hydrogels (Fig. ). To quantitatively assess the realignment of CNTs, we adopted an evaluative method to measure the dispersion degree metric , and the results indicated a significant reduction in the dispersion degree in TRAIN hydrogels (9.60 ± 2.22°) as compared to their untrained counterparts (29.32 ± 6.98°) (Fig. ). These results supported the hypothesis that the cyclic stretching led to the re-alignment of nano-fillers in elastic hydrogel matrix. Based on morphological observations of the nanofillers, we then explored whether such structural re-alignment leads to axis-dependent impedance changes. We prepared CNTs-PVA films (2 cm × 2 cm × 180 µm, CNTs concentrations of 0.16 wt%) and applied cyclic stretching (10% strain for 10,000 cycles) to assess impedance change along different axes. We defined impedance along three orthogonal vectors: the x -axis, aligned parallel to the stretch, and the y and z -axes, perpendicular to the stretching direction (Fig. ). To measure the impedance along these respective directions, we designed an electrochemical cell connected to an electrochemical station. For the x and y axes, impedance was measured using two platinum electrodes positioned on the film’s surface (Fig. , left). Conversely, for the z -axis, impedance measurement involved enveloping the film between two platinum films, covering the full area on opposing surfaces (Fig. , right). The impedance of hydrogel films was then normalized based on the distance between electrodes and the contact area of the platinum films. Consistent with our observations in CNTs-PVA hydrogel fibers (Fig. ), we observed a 17.43 ± 11.12% impedance decrease, from 12.02 ± 0.96 kΩ mm to 9.88 ± 1.19 kΩ mm along the stretching direction ( x -axis), with no significant change on the y -axis and a 17.49 ± 6.04% increase along the z -axis (Fig. and Supplementary Fig. ). Along with the change in impedance, we also found the dimensions in x , y and z directions changed post-training, yet the volume of TRAIN CNTs-PVA hydrogel films remained constant (Supplementary Fig. ). Consequently, we linked the evidence of the anisotropic impedance enhancement along the stretching direction and the re-alignment of the conductive nano-fillers CNTs within the PVA matrix, resulting from the reconstructed percolative network. Similar to previously reported phenomena in semi-crystalline hydrogels , , we also observed the re-orientation of polymeric nanocrystalline domains in TRAIN hydrogel fibers using Wide-angle X-ray scattering (WAXS) (Fig. ). These results indicated a global re-alignment of nanostructures in CNTs-PVA hydrogels under stretching. TRAIN hydrogels mechanical properties While the conductive nanofiller CNTs contributed to the electrical characteristics of CNTs-PVA hydrogel fibers (Fig. ), we further investigated how the stretching treatment affects the mechanical properties, especially under consideration for in vivo tissue movements. The single tensile test results revealed that 0.16 wt% CNTs-PVA hydrogel fibers without pre-stretching and mechanical training exhibited a relatively low elastic modulus of 6.45 ± 1.63 MPa (Fig. , Supplementary Figs. and ), along with a maximum elongation of 124.09 ± 50.46% (Fig. , Supplementary Fig. ). However, the elastic modulus of the fibers significantly increased to 32.74 ± 5.74 MPa post a 200% pre-stretch treatment during drying and annealing, due to the internal-stress induced rigid nanofillers’ alignment, similar to previous research , . However, we found further cyclic stretching (20% strain for 10, 000 cycles) underwater led to a reduction in the elastic modulus to 15.97 ± 5.82 MPa and in the stretchability to 64.54 ± 7.94%, potentially attributed to the shakedown phenomenon in hydrogels (Fig. ). Fibers subjected to the TRAIN strategy (20% strain for 10,000 cycles) showed an elastic modulus comparable to that of the untrained fibers, indicating that the TRAIN method did not compromise the inherent softness of the PVA hydrogel, an advantageous feature for motion-adaptive in vivo applications. To delve deeper into the effects of CNTs on the PVA hydrogel nanostructures, we employed differential scanning calorimetry (DSC) to characterize the crystallinity within the TRAIN hydrogel fibers. A shift in the characteristic endothermic peak of PVA nanocrystals was observed, and upon quantifying the enthalpy changes for different CNT concentrations (0.16 wt% and 0.24 wt%), we found that introducing CNTs into the PVA matrix could affect polymeric nanocrystallization , reducing crystallinity from 26.5% to 11.5% (Fig. ). This observation aligns with the report of introducing nano-fillers inhibits the nano-crystallization in hydrogels . Electromyographic (EMG) recording with TRAIN microelectrodes in moving mice To facilitate in vivo studies, we fabricated a miniaturized electrical recording device with CNTs-PVA hydrogel electrodes (187 ± 13 µm in diameter, Fig. ) dip-coated with an insulating layer of styrene-ethylene-butylene-styrene (SEBS) thermoplastic elastomer , , , with the coating thickness of 1.8 ± 0.4 µm. We surgically implanted hydrogel microelectrodes into the mouse tibialis anterior (TA) and gastrocnemius (GS) muscles (Fig. ). The stiffness changes between the hydrated and dehydrated status facilitated the insertion procedures. Once implanted, the rehydrated hydrogel microelectrodes became soft and integrated seamlessly with the muscle tissue (Fig. ). To enable the accurate capture of low-amplitude EMG signals using hydrogel microelectrodes while minimizing environmental noise, we applied a custom-developed system (Supplementary Fig. ) with differential amplification modules (DAM) to simultaneously collect electromyographic (EMG) signals from both TA and GS muscles in anesthetized mice. Transgenic Thy1::ChR2 mice, which express the light-sensitive protein Channelrhodopsin-2 (ChR2) across the nervous system, were deployed to test hydrogel microelectrodes to capture light-triggered EMG, while WT mice without ChR2 expression were tested as the control group. The expression of ChR2 protein fused with a fluorescent protein, enhanced yellow fluorescent protein (eYFP), in mouse sciatic nerves, was confirmed with confocal microscopy (Fig. ). In anesthetized Thy1::ChR2-EYFP mice, transdermal blue light stimulation (473 nm) was applied to the hindlimb muscles, eliciting neural excitation and subsequent muscle contraction (Fig. ). The TRAIN hydrogel microelectrodes reliably recorded EMG signals from both the TA and GS muscles in response to pulsed blue light stimulation (473 nm, 0.5 Hz, pulse width 50 ms), with consistent amplitudes and waveform patterns. These recordings exhibited high signal-to-noise ratios (SNR) of 38.08 in TA muscles and 37.12 in GS muscles (Fig. ). The EMG recording baseline in WT mice exhibited root mean square (RMS) values of 1.22 µV for the TA muscles and 1.97 µV for the GS muscles, with no observed changes upon light stimulation (Fig. ). After confirming TRAIN microelectrodes’ functionality in vivo, we further tested their performance in conditions involving naturalistic animal movement. As a proof-of-concept application, we collected mouse EMG signals with TRAIN microelectrodes during voluntary wheel running tests (VWRTs) , , a standard assay for assessing locomotor activity, and labeled the skeletal landmarks with a network of nodes to track the running behaviors through a markerless motion tracking algorithm, DeepLabCut , . We first evaluated whether the implantation of TRAIN microelectrodes in mouse TA and GS muscles impaired mouse natural movement by performing gait analysis on implanted hindlimbs. Three days after the mouse recovery from the implantation surgeries, we compared the gait of the implanted mice to the sham controls in their gait kinematics during swing and stance phases (Fig. ), which showed no significant differences (Fig. ), indicating surgical implants do not adversely affect mouse basic gait parameters. With the implanted hydrogel microelectrodes remaining in the muscles over 1-week post-implantation, we conducted EMG recordings from TA and GS muscles simultaneously while mice moved freely during VWRT (Fig. , left). and correlated the collected EMG signals to locomotion behaviors. By synchronizing the EMG recordings with locomotion behaviors, we observed alternative EMG signals reflecting the activity of TA and GS muscles (Fig. , right), in line with previous studies that used conventional electrode EMG recordings – . Intraspinal electrophysiology recording with TRAIN microelectrodes Leveraging the TRAIN hydrogel microelectrodes’ capability to detect EMG signals in freely moving animals, we further explored their potential to monitor neuronal electrical activity in live spinal cords. We integrated three TRAIN microelectrodes into a single miniaturized device to simultaneously record electrical activities from mouse spinal cords and muscles (Fig. ). The device was mounted atop the vertebral bone, with one hydrogel microelectrode inserted into the mouse ventral horn of the lumbar (L) 3 region, predominantly housing motor neurons, and another into the hindlimb TA muscle (Fig. ). The implanted Thy1::ChR2-EYFP mice were subjected to transdermal optical stimulation (473 nm, 0.5 Hz, pulse width 50 ms) under anesthesia, with simultaneous electrical recordings from both the spinal cord and the muscles ( Fig. ). When we altered the intensity of the blue light pulses and compared the corresponding electrical signal changes, we found distinct changes in the amplitudes and waveforms of the detected electric peaks ( n = 10 individual peaks) from the spinal cord and muscles (Fig. ), which underscored the responsiveness of hydrogel microelectrodes. To evaluate the stability of our TRAIN hydrogel microelectrodes in contact with biological environments, we conducted accelerated aging tests and monitored their impedance changes. We incubated hydrogel microelectrodes (0.16 wt% CNTs, 200% pre-stretching, cyclically trained at 20% strain for 5000 cycles) in artificial cerebrospinal fluid (aCSF, Table ) under acidic (pH 4), neutral (pH 7), and alkaline (pH 10) conditions at an elevated temperature (45 °C) for 5 weeks. We found that the impedance remained stable across all tested conditions, confirming the reliability of our hydrogel microelectrodes (Supplementary Fig. ). We also evaluated the stability of TRAIN hydrogel microelectrodes through accelerated aging tests and systematically assessed their elastic modulus and stretchability (Supplementary Fig. ). The analysis showed no significant differences, confirming the mechanical stability of the hydrogel microelectrodes under these conditions. Then, we assessed hydrogel microelectrodes’ functionality in detecting neural activities from the intraspinal cord region over time. With a device consisting of a bundle of three hydrogel microelectrodes implanted in the ventral horn at L3, we recorded the spontaneous neural spikes under anesthetized and awake conditions (Fig. ). Single neuron activities were delineated using principal component analysis (PCA) (Fig. , and l). We observed the sorted neural spikes maintained the same waveforms but with a changed firing rate (FR), from a representative FR of 32.60 Hz under anesthesia (Fig. ) to an FR of 51.33 Hz during awake (Fig. ). We also found that the implanted hydrogel microelectrodes were still able to collect neural activities in the mouse spinal cord 8 months post-implantation (Fig. ). When the implanted mouse was freely moving (Fig. ), we observed large-amplitude burst spikes during movement and spontaneous neural spikes with lower amplitudes (Fig. ), indicating the adaptivity and flexibility of TRAIN hydrogel electrodes during in vivo dynamic environments. To verify the hydrogel microelectrodes recorded from the same neurons, we monitored the single-unit waveform characteristics in the same mouse at multiple time points-30 days, 35 days and 45 days post-implantation. The analysis revealed that the single-unit waveforms remained consistent over time (Supplementary Fig. ). Additionally, immunohistology staining of the spinal cord tissues around the implantation sites showed that glial fibrillary acidic protein (GFAP) expression decreased over time, while ionized calcium-binding adapter molecule 1 (IBA1) expression stayed consistent from 3 to 30 days post-implantation (Supplementary Fig. ). Beyond the traditional spinal cord surface epidural recording devices – , fiber-shaped or other penetrating microelectrodes demonstrate a capability to probe deep structures of the spinal cord with single-unit precision , however, the complex motion and the fragile spinal cord tissues require further soft neural-materials interface designs to minimize tissue damage from motion and the proper motion artifact management . Fatigue-resistant soft hydrogels offer motion-adaptive advantages by providing improved material-tissue mechanical matching and stretchability. In addition to the compliant interfaces, the reinforced electrical percolative networks support stable interface impedance and consistent conductive pathways to collect electrophysiological signals during dynamic conditions Moreover, such soft bioelectronics also allow minimal disruption to the natural behaviors of the experimental subjects. Using an integrated bioelectronic device to simultaneously record different sites of muscles and the nervous systems in the context of behavioral tests, this technology offers direct links between nerve and muscle circuit activities. 

Conductive hydrogels have been applied to biosensors , , wearable electronics , , and neural interface technologies due to mechanical compliance to complex in vivo conditions. Aiming to examine neuromuscular pathways in the spinal cord and peripheral nerves, we designed semi-crystalline hydrogels that embedded conductive nanofillers to adapt to the dynamic environment in vivo during movements (Fig. ). Built upon the phenomenon of stretch-induced nanocrystalline domain alignment in hydrogels , , we utilized the cross-linked PVA hydrogels as the matrix and introduced CNTs with aspect ratios of 2000–10,000:1 as the conductive nanofillers to create conductive hydrogel microelectrodes for in vivo electrical recordings. Our hypothesis centered on the polymeric nanocrystalline of the hydrogels supporting a durable elastic substrate while the reconstruction of conductive percolative networks through nano-fillers re-alignment provides robust conductivity under stretching (Fig. ). We incorporated CNTs during hydrogel chemical cross-linking and then subjected CNTs-PVA hydrogels to cyclic stretching (20% strain for 10,000 cycles, Supplementary Fig. ). Scanning electron microscopy results indicated a reconfiguration of CNTs bundle structure, which aligned along the direction of applied strain (Fig. ). To examine whether these microstructural changes correlated to their functional performance, we first characterized the electrochemical impedances of the conductive nanofillers-embedded hydrogel fibers. We prepared the CNTs-PVA hydrogel fibers with a series of CNTs concentrations in the range of 0.04 wt% to 0.24 wt%, incorporated into a 10 wt% PVA hydrogel matrix and examined their electrochemical impedance spectroscopy results (EIS, Fig. and Supplementary Fig. ). To compare the electrical performance of the CNTs-PVA hydrogel fibers across varying CNTs loadings, we normalized the impedance values relative to the cross-sectional area and the effective length of the uninsulated fibers under examination. At a 0.04 wt% CNTs inclusion, we observed a normalized impedance (specific impedance) of 0.51 ± 0.08 kΩ mm at 1 kHz, a frequency commonly used for single-neuron activity recording. These results suggest that this nanofiller concentration surpasses the percolation threshold – . This analysis revealed a decrease in the specific impedance with an increase in CNTs content, with values declining from 0.51 ± 0.08 kΩ mm to 0.04 ± 0.01 kΩ mm, thereby indicating the role of CNTs in contributing to the conductivity of the hydrogel fibers (Fig. ). Then, we examined the effect of stretching on CNTs-PVA hydrogels impedance change. We included two types of stretching conditions in the evaluation: employing stretching during the hydrogel drying and annealing processes, which was denoted as “pre-stretch” and cyclic stretching under water after the hydrogel fibers underwent drying, annealing, and re-hydration. To compare the stretching effect, we employed a group of CNTs-PVA hydrogel fibers (0.04 wt%, 0.08 wt%, 0.16 wt% and 0.24 wt% CNTs in 10 wt% PVA) with a 200% pre-stretch, a group with the combination of 200% pre-stretch with subsequent cyclic training (denoted as TRAIN hydrogel, 10% strain for 5000 cycles under water), and a group of 0% pre-stretched samples as the control (Fig. ). As a representative example, for fibers with a CNTs loading of 0.16 wt% and a diameter of 187 ± 13 µm, cyclic stretching reduced impedance from 55.47 ± 13.03 kΩ (200% pre-stretched fibers in 1 cm length, in corresponding to 0.43 ± 0.05 kΩ mm as normalized impedance) to 33.20 ± 9.27 kΩ (fibers with 200% pre-stretch and 10% train for 5000 cycles in 1 cm length, in corresponding to 0.10 ± 0.03 kΩ mm as normalized impedance). Furthermore, cyclic stretching not only reduced specific impedance from 0.43 ± 0.05 kΩ mm (0% pre-stretched fibers) to 0.10 ± 0.03 kΩ mm (200% pre-stretch with 10% strain for 5000 cycles ) but also yielded a lower specific impedance than fibers that underwent only a single 200% pre-stretch with the impedance of 0.16 ± 0.02 kΩ mm (Fig. ). To further explore the impact of mechanical training, we adhered to Hooke’s law and defined the first 20% of strain as the elastic zone for establishing training strains in our CNTs-PVA hydrogels and we observed that at 0.24 wt% CNTs, 20% strain of cyclic training further enhanced the conductivity of the hydrogel microelectrodes (Fig. ). To systematically assess the influence of mechanical stretching with different CNTs loadings, we measured the impedance ratio of the hydrogel fibers before and after 5000 cycles of stretching and found over 1.5 ratio across all the groups, indicating a consistent effect of the mechanical stretching on the conductivity improvement (Fig. ). We also observed the decreased impedance associated with pre-stretch and cyclic stretching in different PVA hydrogel matrix (0.16 wt% CNTs into 10 wt% PVA) with a series of PVA molecular weights (MWs) of 30 kDa, 89 kDa, and 146–189 kDa (Supplementary Fig. ). This trend is likely because longer polymer chains in the hydrogel matrix offer a more flexible environment, allowing high-aspect-ratio fillers to form effective conductive pathways when stretched , . In alignment with the reported phenomenon of shakedown after prolonged cycling in tough hydrogels , we observed that extending the stretching process of the CNTs-PVA hydrogel fibers from 20,000 cycles with 20% strain resulted in a steady status after 5000 cycles (Fig. ). We measured the electrochemical impedance of each CNTs-PVA fiber and compared these measurements with the original fibers without any stretching. The impedance continued to decrease during the cycling process until it stabilized at approximately 5000 cycles, maintaining 35.64 ± 18.62% of the original impedance. We also discovered that the water content fraction of TRAIN CNTs-PVA hydrogel fibers reached a steady level after approximately 5000 cycles (78.6 ± 3.5%, Supplementary Fig. ). Given that hydrogel microelectrodes will undergo repetitive stretching conditions in vivo, maintaining the impedance and water content fraction of CNTs-PVA hydrogel fibers within this steady level is crucial for ensuring the stable performance of hydrogel electrodes in detecting electrophysiological signals. 

To investigate the underlying mechanisms in the observed conductivity improvement after stretching, we measured the morphology change of conductive fillers in hydrogel matrix after stretching treatment. We applied customized stimulated Raman scattering (SRS) microscopy to the CNTs-PVA hydrogels to visualize the alignment of CNTs within the PVA hydrogel matrix with chemical bond information (Fig. ). SRS employs coherent amplification via a pump beam and a Stokes beam, resulting in a substantial enhancement of the Raman signal strength compared to the relatively weak spontaneous Raman scattering process , . We first detected the featured G-band of CNTs at 1596 cm -1 as the indicative C-C bond , (Fig. ). From the SRS microscopy images, we observed that following 10,000 cycles of cyclic stretching at a 20% strain, CNTs within the PVA hydrogels were preferentially aligned along the axis of stretching (Fig. , 0°, denoted as TRAIN hydrogels). This realignment contrasted with the random orientation seen in the untrained CNTs-PVA hydrogels (Fig. ). To quantitatively assess the realignment of CNTs, we adopted an evaluative method to measure the dispersion degree metric , and the results indicated a significant reduction in the dispersion degree in TRAIN hydrogels (9.60 ± 2.22°) as compared to their untrained counterparts (29.32 ± 6.98°) (Fig. ). These results supported the hypothesis that the cyclic stretching led to the re-alignment of nano-fillers in elastic hydrogel matrix. Based on morphological observations of the nanofillers, we then explored whether such structural re-alignment leads to axis-dependent impedance changes. We prepared CNTs-PVA films (2 cm × 2 cm × 180 µm, CNTs concentrations of 0.16 wt%) and applied cyclic stretching (10% strain for 10,000 cycles) to assess impedance change along different axes. We defined impedance along three orthogonal vectors: the x -axis, aligned parallel to the stretch, and the y and z -axes, perpendicular to the stretching direction (Fig. ). To measure the impedance along these respective directions, we designed an electrochemical cell connected to an electrochemical station. For the x and y axes, impedance was measured using two platinum electrodes positioned on the film’s surface (Fig. , left). Conversely, for the z -axis, impedance measurement involved enveloping the film between two platinum films, covering the full area on opposing surfaces (Fig. , right). The impedance of hydrogel films was then normalized based on the distance between electrodes and the contact area of the platinum films. Consistent with our observations in CNTs-PVA hydrogel fibers (Fig. ), we observed a 17.43 ± 11.12% impedance decrease, from 12.02 ± 0.96 kΩ mm to 9.88 ± 1.19 kΩ mm along the stretching direction ( x -axis), with no significant change on the y -axis and a 17.49 ± 6.04% increase along the z -axis (Fig. and Supplementary Fig. ). Along with the change in impedance, we also found the dimensions in x , y and z directions changed post-training, yet the volume of TRAIN CNTs-PVA hydrogel films remained constant (Supplementary Fig. ). Consequently, we linked the evidence of the anisotropic impedance enhancement along the stretching direction and the re-alignment of the conductive nano-fillers CNTs within the PVA matrix, resulting from the reconstructed percolative network. Similar to previously reported phenomena in semi-crystalline hydrogels , , we also observed the re-orientation of polymeric nanocrystalline domains in TRAIN hydrogel fibers using Wide-angle X-ray scattering (WAXS) (Fig. ). These results indicated a global re-alignment of nanostructures in CNTs-PVA hydrogels under stretching. 

While the conductive nanofiller CNTs contributed to the electrical characteristics of CNTs-PVA hydrogel fibers (Fig. ), we further investigated how the stretching treatment affects the mechanical properties, especially under consideration for in vivo tissue movements. The single tensile test results revealed that 0.16 wt% CNTs-PVA hydrogel fibers without pre-stretching and mechanical training exhibited a relatively low elastic modulus of 6.45 ± 1.63 MPa (Fig. , Supplementary Figs. and ), along with a maximum elongation of 124.09 ± 50.46% (Fig. , Supplementary Fig. ). However, the elastic modulus of the fibers significantly increased to 32.74 ± 5.74 MPa post a 200% pre-stretch treatment during drying and annealing, due to the internal-stress induced rigid nanofillers’ alignment, similar to previous research , . However, we found further cyclic stretching (20% strain for 10, 000 cycles) underwater led to a reduction in the elastic modulus to 15.97 ± 5.82 MPa and in the stretchability to 64.54 ± 7.94%, potentially attributed to the shakedown phenomenon in hydrogels (Fig. ). Fibers subjected to the TRAIN strategy (20% strain for 10,000 cycles) showed an elastic modulus comparable to that of the untrained fibers, indicating that the TRAIN method did not compromise the inherent softness of the PVA hydrogel, an advantageous feature for motion-adaptive in vivo applications. To delve deeper into the effects of CNTs on the PVA hydrogel nanostructures, we employed differential scanning calorimetry (DSC) to characterize the crystallinity within the TRAIN hydrogel fibers. A shift in the characteristic endothermic peak of PVA nanocrystals was observed, and upon quantifying the enthalpy changes for different CNT concentrations (0.16 wt% and 0.24 wt%), we found that introducing CNTs into the PVA matrix could affect polymeric nanocrystallization , reducing crystallinity from 26.5% to 11.5% (Fig. ). This observation aligns with the report of introducing nano-fillers inhibits the nano-crystallization in hydrogels . 

To facilitate in vivo studies, we fabricated a miniaturized electrical recording device with CNTs-PVA hydrogel electrodes (187 ± 13 µm in diameter, Fig. ) dip-coated with an insulating layer of styrene-ethylene-butylene-styrene (SEBS) thermoplastic elastomer , , , with the coating thickness of 1.8 ± 0.4 µm. We surgically implanted hydrogel microelectrodes into the mouse tibialis anterior (TA) and gastrocnemius (GS) muscles (Fig. ). The stiffness changes between the hydrated and dehydrated status facilitated the insertion procedures. Once implanted, the rehydrated hydrogel microelectrodes became soft and integrated seamlessly with the muscle tissue (Fig. ). To enable the accurate capture of low-amplitude EMG signals using hydrogel microelectrodes while minimizing environmental noise, we applied a custom-developed system (Supplementary Fig. ) with differential amplification modules (DAM) to simultaneously collect electromyographic (EMG) signals from both TA and GS muscles in anesthetized mice. Transgenic Thy1::ChR2 mice, which express the light-sensitive protein Channelrhodopsin-2 (ChR2) across the nervous system, were deployed to test hydrogel microelectrodes to capture light-triggered EMG, while WT mice without ChR2 expression were tested as the control group. The expression of ChR2 protein fused with a fluorescent protein, enhanced yellow fluorescent protein (eYFP), in mouse sciatic nerves, was confirmed with confocal microscopy (Fig. ). In anesthetized Thy1::ChR2-EYFP mice, transdermal blue light stimulation (473 nm) was applied to the hindlimb muscles, eliciting neural excitation and subsequent muscle contraction (Fig. ). The TRAIN hydrogel microelectrodes reliably recorded EMG signals from both the TA and GS muscles in response to pulsed blue light stimulation (473 nm, 0.5 Hz, pulse width 50 ms), with consistent amplitudes and waveform patterns. These recordings exhibited high signal-to-noise ratios (SNR) of 38.08 in TA muscles and 37.12 in GS muscles (Fig. ). The EMG recording baseline in WT mice exhibited root mean square (RMS) values of 1.22 µV for the TA muscles and 1.97 µV for the GS muscles, with no observed changes upon light stimulation (Fig. ). After confirming TRAIN microelectrodes’ functionality in vivo, we further tested their performance in conditions involving naturalistic animal movement. As a proof-of-concept application, we collected mouse EMG signals with TRAIN microelectrodes during voluntary wheel running tests (VWRTs) , , a standard assay for assessing locomotor activity, and labeled the skeletal landmarks with a network of nodes to track the running behaviors through a markerless motion tracking algorithm, DeepLabCut , . We first evaluated whether the implantation of TRAIN microelectrodes in mouse TA and GS muscles impaired mouse natural movement by performing gait analysis on implanted hindlimbs. Three days after the mouse recovery from the implantation surgeries, we compared the gait of the implanted mice to the sham controls in their gait kinematics during swing and stance phases (Fig. ), which showed no significant differences (Fig. ), indicating surgical implants do not adversely affect mouse basic gait parameters. With the implanted hydrogel microelectrodes remaining in the muscles over 1-week post-implantation, we conducted EMG recordings from TA and GS muscles simultaneously while mice moved freely during VWRT (Fig. , left). and correlated the collected EMG signals to locomotion behaviors. By synchronizing the EMG recordings with locomotion behaviors, we observed alternative EMG signals reflecting the activity of TA and GS muscles (Fig. , right), in line with previous studies that used conventional electrode EMG recordings – . 

Leveraging the TRAIN hydrogel microelectrodes’ capability to detect EMG signals in freely moving animals, we further explored their potential to monitor neuronal electrical activity in live spinal cords. We integrated three TRAIN microelectrodes into a single miniaturized device to simultaneously record electrical activities from mouse spinal cords and muscles (Fig. ). The device was mounted atop the vertebral bone, with one hydrogel microelectrode inserted into the mouse ventral horn of the lumbar (L) 3 region, predominantly housing motor neurons, and another into the hindlimb TA muscle (Fig. ). The implanted Thy1::ChR2-EYFP mice were subjected to transdermal optical stimulation (473 nm, 0.5 Hz, pulse width 50 ms) under anesthesia, with simultaneous electrical recordings from both the spinal cord and the muscles ( Fig. ). When we altered the intensity of the blue light pulses and compared the corresponding electrical signal changes, we found distinct changes in the amplitudes and waveforms of the detected electric peaks ( n = 10 individual peaks) from the spinal cord and muscles (Fig. ), which underscored the responsiveness of hydrogel microelectrodes. To evaluate the stability of our TRAIN hydrogel microelectrodes in contact with biological environments, we conducted accelerated aging tests and monitored their impedance changes. We incubated hydrogel microelectrodes (0.16 wt% CNTs, 200% pre-stretching, cyclically trained at 20% strain for 5000 cycles) in artificial cerebrospinal fluid (aCSF, Table ) under acidic (pH 4), neutral (pH 7), and alkaline (pH 10) conditions at an elevated temperature (45 °C) for 5 weeks. We found that the impedance remained stable across all tested conditions, confirming the reliability of our hydrogel microelectrodes (Supplementary Fig. ). We also evaluated the stability of TRAIN hydrogel microelectrodes through accelerated aging tests and systematically assessed their elastic modulus and stretchability (Supplementary Fig. ). The analysis showed no significant differences, confirming the mechanical stability of the hydrogel microelectrodes under these conditions. Then, we assessed hydrogel microelectrodes’ functionality in detecting neural activities from the intraspinal cord region over time. With a device consisting of a bundle of three hydrogel microelectrodes implanted in the ventral horn at L3, we recorded the spontaneous neural spikes under anesthetized and awake conditions (Fig. ). Single neuron activities were delineated using principal component analysis (PCA) (Fig. , and l). We observed the sorted neural spikes maintained the same waveforms but with a changed firing rate (FR), from a representative FR of 32.60 Hz under anesthesia (Fig. ) to an FR of 51.33 Hz during awake (Fig. ). We also found that the implanted hydrogel microelectrodes were still able to collect neural activities in the mouse spinal cord 8 months post-implantation (Fig. ). When the implanted mouse was freely moving (Fig. ), we observed large-amplitude burst spikes during movement and spontaneous neural spikes with lower amplitudes (Fig. ), indicating the adaptivity and flexibility of TRAIN hydrogel electrodes during in vivo dynamic environments. To verify the hydrogel microelectrodes recorded from the same neurons, we monitored the single-unit waveform characteristics in the same mouse at multiple time points-30 days, 35 days and 45 days post-implantation. The analysis revealed that the single-unit waveforms remained consistent over time (Supplementary Fig. ). Additionally, immunohistology staining of the spinal cord tissues around the implantation sites showed that glial fibrillary acidic protein (GFAP) expression decreased over time, while ionized calcium-binding adapter molecule 1 (IBA1) expression stayed consistent from 3 to 30 days post-implantation (Supplementary Fig. ). Beyond the traditional spinal cord surface epidural recording devices – , fiber-shaped or other penetrating microelectrodes demonstrate a capability to probe deep structures of the spinal cord with single-unit precision , however, the complex motion and the fragile spinal cord tissues require further soft neural-materials interface designs to minimize tissue damage from motion and the proper motion artifact management . Fatigue-resistant soft hydrogels offer motion-adaptive advantages by providing improved material-tissue mechanical matching and stretchability. In addition to the compliant interfaces, the reinforced electrical percolative networks support stable interface impedance and consistent conductive pathways to collect electrophysiological signals during dynamic conditions Moreover, such soft bioelectronics also allow minimal disruption to the natural behaviors of the experimental subjects. Using an integrated bioelectronic device to simultaneously record different sites of muscles and the nervous systems in the context of behavioral tests, this technology offers direct links between nerve and muscle circuit activities. 

In this study, we engineered a set of hydrogel microelectrodes with a bottom-up approach to reinforcing the percolative network of nanofillers and therefore providing adaptive tissue-material interfaces. Such hydrogel microelectrodes enable electrophysiological recording from mouse muscles and lumbar spinal cord ventral horn region under complex mechanical dynamics in vivo. We discovered that the CNTs-PVA hydrogel microelectrodes exhibited anisotropic electrochemical impedance and investigated the mechanism of stretch-induced reconstruction of conductive nanofillers in a hydrogel matrix. With the retained softness and stretchability, as well as the directional conductivity, when we applied these hydrogel microelectrodes in vivo, they robustly collected the electrical signals from multiple muscles simultaneously during mouse locomotion. Using an integrated device with hydrogel microelectrodes implanted in the mouse ventral horn of the spinal cord and muscle separately, we captured the light-evoked electrical signaling in the sciatic-spinal-motor reflex arc with transgenic mice. Due to the strong motion adaptation to the spinal cord tissues, we successfully recorded the electrophysiological signals from mouse ventral horn areas from various statuses, such as under anesthesia, awake, and naturally behaving. This soft nanomaterials-supported tissue-integrated bioelectronics offers a solution for collective recording from multiple sites, especially in those with severe mechanical dynamics, and a holistic understanding of neural circuits in the context of behaviors. 

Fabrications of conductive hydrogel fibers To prepare a 10 wt% polyvinyl alcohol (PVA) solution, 10 g of PVA (146,000 to 186,000 Da, 99 + % hydrolyzed, Sigma Aldrich 363065) was combined with 90 g of Milli-Q water (14 MΩ·cm at 25 °C). The mixture was heated to 100 °C under continuous stirring for 5 h, resulting in a clear and viscous solution. For the carbon nanotubes (CNTs) preparation, a stock solution of CNTs (OCSiAl, TUBALL BATT H2O 0.8% beta) was diluted with Milli-Q water in a weight ratio of 1:0.6. To prevent the aggregation of CNTs, a solution of Sodium Dodecylbenzene Sulfonate (SDBS, technical grade, Sigma Aldrich STBL3944) was prepared at a concentration of 5 wt%. To fabricate chemically cross-linked CNTs-PVA hydrogel fibers, 100 µL of Glutaraldehyde (GA, 25% in water, Sigma Aldrich G6257) was added into 10 g of 10 wt% PVA solution followed by mixing and degassing in a vacuum spinner (Musashi ARV-310). 150 µL of hydrochloric acid (HCl, 37%, Sigma-Aldrich 258148) was then added into another 10 g of 10 wt% PVA solution with mixing and degassing followed. Next, the diluted CNTs, PVA-GA, and PVA-HCl solutions were combined in a ratio of (0.6 ~ 1.4):1:1 with the same mixing and degassing procedure. The homogeneous solution was then infused into silicone molds (800 µm I.D., 51845K51 and 500 µm I.D., 51845K66, MacMaster-Carr) and allowed to cross-link at room temperature (RT) for 2 h. Dichloromethane (DCM, 99.8%, Sigma Aldrich 270997) was utilized to induce swelling in silicone molds, aiding the elution of CNTs-PVA hydrogel fibers. Post-elution, these fibers were rinsed with large amounts of Milli-Q water for 2 days to remove any residual unreacted chemicals. Following the washing step, the CNTs-PVA hydrogel fibers were immersed in HCl solution (12 mM) for 2 h (cite COMPACT), then pre-stretched to 200% strain and dried in the air for 12 h followed by annealing at 100 °C for 20 min. Finally, the fibers were reswelled in Milli-Q water for later use. Fabrications of conductive hydrogel films The CNTs stock solution was diluted with Milli-Q water (1:0.6 by weight) and then homogeneously dispersed with a 5 wt% SDBS solution (1:10 by weight). Subsequently, 100 µL of GA was incorporated into 10 g of a 10 wt% PVA solution. Additionally, 150 µL of HCl was added to another 10 g of 10 wt% PVA solution. Both mixtures were subjected to thorough mixing and degassing using a vacuum spinner. The diluted CNTs, PVA-GA, and PVA-HCl were then combined in a ratio of 1.4:1:1, employing identical mixing and degassing procedures. The resultant homogeneous mixture was poured into a customized mold and allowed to cross-link at room temperature for 2 h. The resultant CNTs-PVA hydrogel films were demolded and extensively rinsed with Milli-Q water to eliminate any unreacted chemicals. The films underwent a post-treatment with an HCl solution (12 mM) followed by pre-stretching the films to 10% strain and air drying for 12 h. The films were annealed at 100 °C for 20 min. Finally, these films were reswelled in Milli-Q water. TRAIN hydrogel materials To reorient CNTs in the PVA hydrogel matrix and fabricate TRAIN hydrogel fibers and films, we subjected them to cyclic stretching tests (strain-controlled mode: 5%, 10%, and 20% strains, and frequency of 0.5 Hz) for 5000–15000 cycles using a horizontal mechanical tester (Univert, Cell Scale) with a water bath. A 4.4 N load cell (Futek) was used. The conductive hydrogel materials were stretched with a constant strain amplitude, and the force variation was recorded over time. Electrochemical characterization of conductive hydrogel materials Impedance of conductive hydrogel fibers and thin films was systematically assessed using an electrochemical working station (Princeton Applied Research PARSTAT 2273). A 3-electrode electrochemical sink was used to characterize conductive TRAIN hydrogel fibers with a sinusoidal driving voltage spanning a frequency range from 10 Hz to 1 MHz and an amplitude of 10 mV. The conductive hydrogel films, after undergoing repeated training, were analyzed using a specialized device in three different orientations: along the stretching direction ( x -axis), across the stretching direction on the surface of the film ( y -axis), and through the thickness of the film, perpendicular to the stretching direction ( z -axis). For measurements along the x and y axes, impedance was determined using two platinum wires (diameter: 1.54 mm, length: 19.47 mm, and distance 15.44 mm). The length ( l ) used in calculations is the 15.44 mm distance between the wires, and the area ( A ) is the contact area where each wire touches the film. For the Z-axis measurements, impedance was recorded using two platinum sheets (length: 19.47 mm and width: 6.41 mm). Here, l is the thickness of the film, and A is the area where each sheet contacts the film. For hydrogel fibers, l is defined as the length of fiber immersed in a chemical solution, and A is the cross-sectional area of the immersed part of the fiber. The lengths of the hydrogel fibers and films were measured using a caliper, while their thickness was accurately gauged using a micrometer. The measured impedance was normalized using the specific formula: \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$R=\frac{l}{A}\rho$$\end{document} R = l A ρ , where R is the measured impedance, l is the length of the materials that were characterized, A is the area of the materials that were characterized, ρ is the specific impedance of the conductive hydrogel materials. Dimension measurements of hydrogel fibers Images of hydrogel fibers were captured using a microscope (AmScope) under a bright field while submerged in water. Each fiber was examined in three distinct areas, including both ends and the middle (three individual measurements in each section). Subsequently, the Image J software was used to measure the diameter of each fiber. In addition, the length (five individual measurements) of the fibers was measured using a caliper. SEM characterization of TRAIN hydrogel films To investigate the structure and morphology of hydrogel films, samples were first rapidly frozen using liquid nitrogen to preserve their internal structure. For TRAIN conductive hydrogel films, they were fractured along lines parallel to the training direction to expose the relevant structural facets. For pre PVA hydrogel films, they were fractured randomly. After fracturing, the hydrogel films were sputtered with platinum (Cressington, 208HR) to enhance conductivity and then examined using SEM (Hitachi Su5000) at an acceleration voltage of 4 kV. TEM imaging of CNTs TEM images were acquired using a transmission electron microscope (FEI Tecnai 12, 120 kV). CNTs were diluted in a range from 1:3.3 to 1:10 with Milli-Q water and subsequently deposited onto a copper grid (Sigma-Aldrich FCF200-Cu) for imaging purposes. Raman spectroscopy Raman spectra of TRAIN CNTs-PVA and PVA hydrogel films were acquired using a confocal Raman microscope (Renishaw InVia, 785-nm NIR laser, 20X objective lens). Prior to spectral collection, the films were mounted on glass slides enveloped in a reflective substrate. The acquisition resolution was 0.7 cm -1 and the integration time per acquisition was 10 sec. For the TRAIN CNTs-PVA hydrogel films, to prevent thermal degradation of the CNTs, the laser power was reduced to 0.1%, resulting in an effective power of approximately 0.57 mW at the focal point of the sample. In contrast, the PVA hydrogel samples were analyzed under 10% laser power, corresponding to an effective power of about 10 mW at the sample focus. All spectra were recorded and subsequently analyzed using Renishaw’s WiRE 4.1 software, ensuring precise and reproducible data for further interpretation. SRS microscopy To prepare samples for SRS imaging, TRAIN and untrained CNTs-PVA hydrogel films (0.16% and 0.24% CNTs) were embedded in O.C.T compounds (-80 o C for 2 h, Sakura Finetek 4583) then sliced with a 20 µm thickness using a cryo-slicing microtome (Leica CM1950). The sliced samples were then mounted onto glass slides for later imaging. A customized SRS setup was used to image for chemicals specific CNTs signals in the TRAIN and untrained CNTs-PVA hydrogel samples. Insight X3, (Spectra-Physics), a dual channel/wavelength, pulsed laser was used to generate the SRS signals. The modulated SRL signal (stimulated Raman loss) was captured with FDS1010 Si-photodiode (Thorlabs Inc.), which was then processed/demodulated by a HF2LI lock-in amplifier (Zurich Instruments). Scanning image software was used as an overall image-capturing system to generate the final digital SRS images with 1024×1024 pixel data density. Imaging was performed under a 25X water immersion objective with a 3X zoom, capturing an effective sample area of 233×233 µm 2 . The strokes and pump beams were set to an average power of 100 mW and 30 mW, respectively. The stroke beam is fixed at 1045 nm, and the tunable pump beam was set to 805, 809, 880, and 896 nm to obtain 4 sets of SRS images for each sample and location. SRS images were taken at 896 nm for the CNTs selective chemical imaging (based on Raman spectra) and 805 nm for the PVA hydrogel imaging. Images were also taken at 880 nm and 809 nm for off-peak (background) values, of CNTs and PVA hydrogel respectively. The collected images were processed, background subtracted, and overlaid with pseudo-colors for visualization, using Fiji ImageJ software. Tensile tests of hydrogel microelectrodes in water A tensile test machine (Univert, Cell Scale) was employed to stretch the hydrogel microelectrodes at a rate of 1 mm/s under water. The nominal stress was calculated using the formula σ = F∕A, where F denotes the recorded force, and A denotes the cross-sectional area of the fibers in the hydrated state. The strain was calculated using ϵ = ΔL∕L , where ΔL represents the displacement, and L represents the gauge length. The elastic moduli E were determined by calculating the average slope of the stress-strain relationship in the first 10% applied strain using linear regression. The maximum elongation (%) of the fibers was reported at the point of fracture in the stress-strain curve. X-ray scattering X-ray scattering experiments were conducted using the SAXSLAB GANESHA 300XL instrument, equipped with a Dectris Pilatus 300 K 2D CMOS photon counting detector (measuring 83.8 ×106.5 mm 2 ). Wide-angle X-ray (WAXS) measurements employed a 2 mm beamstop, and each sample was exposed for a duration of 300 s. Measurement of crystallinities The degree of crystallinity of hydrogel fibers and materials was assessed using a DSC instrument (2920 TA instrument). The PVA hydrogels were analyzed in the desiccated state. A small quantity of sample (1-15 mg) was loaded into a crucible (TA instrument T81006) and placed in a temperature-controlled DSC cell. A blank crucible served as a reference. The sample was heated from 30 °C to 300 °C in air, with a heating rate of 20 °C/min. The differential heat flow to the sample and reference was recorded by the instrument. To determine the melting fusion enthalpy of endothermic peaks, heat flow (mW) over sample weight (mg) was plotted against time (s). The areas of melting endothermic peaks were integrated using TA analyze software (TA Universal Analysis). The degree of crystallinity α was estimated using the equation: \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$\alpha=\frac{\Delta {H}_{f}}{\Delta {H}_{m}}\cdot 100\%$$\end{document} α = Δ H f Δ H m ⋅ 100 % , where was \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$\Delta {H}_{f}\,(J/g)$$\end{document} Δ H f ( J / g ) calculated from the integration of melting endothermic peaks and \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$\Delta {H}_{m}\,(150{J}/g)$$\end{document} Δ H m ( 150 J / g ) was the enthalpy of melting 100% of PVA crystallites – . Accelerated aging of hydrogel microelectrodes TRAIN hydrogel microelectrodes were subjected to accelerated aging in artificial cerebrospinal fluid (aCSF, Table ) to simulate in vivo physiological conditions. Aging experiments were conducted at 45 °C for five weeks, with aCSF adjusted to pH values of 4, 7, and 10. The diameter and impedance of the hydrogel microelectrodes were measured weekly to evaluate their stability and performance over time. Insulation of hydrogel microelectrodes To insulate the CNTs-PVA hydrogel electrodes, a dip-coating process was performed using a 20 wt% SEBS (Styrene-Ethylene-Butylene-Styrene) solution in toluene (Fisher Scientific, NC1024503). The SEBS solution was prepared by thoroughly dissolving SEBS in toluene with constant stirring to ensure a homogenous mixture. Prior to dip coating, the CNTs-PVA hydrogel electrodes were cleaned, straightened, and dried to eliminate any surface contaminants that might interfere with the coating process. The electrodes were then immersed into the SEBS solution at a controlled speed to ensure smooth application and prevent the formation of surface irregularities or trapped air bubbles. The depth of immersion was carefully controlled to ensure complete coverage of the electrode surface intended for insulation. After immersion, the electrodes were withdrawn with a speed of 11.8 mm/min from the solution to ensure an even coating layer. Following the dip-coating process, the electrodes were suspended vertically in a well-ventilated area to allow the toluene solvent to evaporate. Solvent evaporation was conducted under ambient conditions to promote uniform drying for 1 hour. After complete solvent evaporation, the electrodes were inspected for uniformity of the SEBS coating. If any irregularities in thickness or coverage were detected, additional dip-coating cycles were performed to ensure optimal insulation. Once the dip-coating and curing processes were complete, the electrodes were stored in a clean, dust-free environment to prevent contamination prior to their use in subsequent experiments. Assembling of conductive hydrogel bioelectronic device To fabricate TRAIN hydrogel electrodes, a hydrogel conductive fiber and a stainless-steel wire (30 g 316 L wire, Master Wire Supply) were dip-coated in CNTs (0.8 wt%) solution. The dip-coated hydrogel fiber and stainless-steel wire were inserted into an elastic tubing (100 µm) to create a hydrogel-steel junction. Another thin layer of silver paint (Ted Pella Inc) was applied at the junction to enhance conductivity. UV epoxy (Norland optical adhesive 87) was used to seal and reinforce the junction. To assemble the bioelectronic device for EMG recordings, 4 insulated TRAIN electrodes were soldered onto 4 pins from a 6-pin connector (952-3602-ND, DigiKey), respectively. 1 insulated stainless-steel wire (0.0045 inch in diameter, A-M systems) was soldered onto the last pin as the ground wire. To assemble the bioelectronic device for spinal cord recordings, 3 insulated TRAIN electrodes were soldered onto 3 pins from a 4-pin connector (SAM15343-ND, DigiKey), respectively. 1 insulated stainless-steel wire (50 µm) was soldered onto the last pin as the ground wire. The 3 working electrodes were twisted into a yarn and dipped coated in SEBS solution. Optical adhesive was applied to the soldering sides on the pin to provide insulation. Ethics Every experiment involving animals has been carried out following a protocol approved by an ethical commission: The Institutional Animal Care and Use Committee at Binghamton University (Protocol number: 897-23) and the University of Massachusetts Amherst (Protocol number: 2520). Experimental animals Wild-type (C57BL/6 J) and Thy1::ChR2-EYFP mice were purchased from the Jackson Laboratory. Mice were given ad libitum access to food and water and were housed at 24 °C ± 1 °C, with 50% relative humidity, and on a 12-h light/12-h dark cycle. All experiments were conducted during the light cycle. In vivo implantation in muscle for EMG recording in anesthetic mice Wild type (WT) and Thy1::ChR2-EYFP mice were anesthetized using isoflurane (1.5% induction, Fluriso, VET one) and continuously maintained at 1%. Supplemental heat was provided during the surgery. The fur was removed over the hindlimbs. To collect EMG signals from WT and Thy1-ChR2-EYFP mice under anesthesia, an insulated TRAIN hydrogel electrode was inserted into the medial tibialis anterior (TA) and gastrocnemius (GS) muscles of mice hindlimbs. A reference needle electrode was inserted in an electrical unrelated region. A ground needle electrode was subcutaneously inserted into the tail. In vivo implantation in muscle for freely moving EMG recording C67BL/6 J mice were anesthetized with 1.5% isoflurane continuously maintained at 1%, with supplemental heat provided throughout the surgical procedure. Fur was removed from the hindlimbs and head, and the exposed skin was sanitized using iodine followed by 75% ethanol. Incisions were then made at each site. A 6-pin device was carefully routed subcutaneously from the hindlimb to the skull. The pin connector was securely affixed to the skull using dental cement (Parkell C&B METABOND and Jet Set-4). In wild-type mice, two TRAIN hydrogel electrodes were employed—one as a working electrode and the other as a reference electrode. Both electrodes were inserted into the mid-belly of the tibialis anterior (TA) muscles on the left hindlimb using 30-gauge needles. Similarly, two additional TRAIN hydrogel electrodes were inserted into the gastrocnemius (GS) muscle on the left hindlimb of the same wild-type mice. A ground wire was positioned subcutaneously in the neck-shoulder area to complete the setup. The skin over the hindlimb muscles was then sutured closed using nylon sutures (Nylon 5-0). In vivo implantation in spinal cord Mice were anesthetized using 1% isoflurane. Once a stable plane of anesthesia was achieved, the area surrounding the dorsal hump was shaved and cleansed with alternating applications of iodine and 75% alcohol. For implantations at spinal segment L3, an incision was made slightly caudal to the peak of the dorsal hump, extending approximately 0.5 cm rostral and 0.5 cm caudal from the initial site. Larger incisions were made initially to provide greater access. An incision was created medial to the white tendons on either side of the vertebral column, spanning slightly more than one vertebral segment, from the outer edge of the caudal transverse process to the outer edge of the rostral transverse process. The tendon attached to the caudal transverse process was cut, and bleeding was controlled using absorbent spears. Tissue was cleared from the transverse processes while ensuring that nerves entering the spinal cord were not damaged. This process was repeated on both sides of the spinal column. The vertebrae of interest (T12 and T13) were identified, and a small incision was made between the tendons and the vertebral column on each side. All tissue was removed from the surface of the bone. The spine was then secured using customized spinal adaptor clamps. A small hole was created in the dura mater using a 30-gauge needle. The electrode bundle was trimmed to a length of less than 500 µm and mounted on an implantation bar attached to the stereotaxic frame. The device was positioned between vertebrae T12 and T13 and implanted to a depth of 300 µm into the spinal cord tissue. A small amount of sterile lubricant was applied around the electrode bundle and over the surface of the bone to minimize the risk of bleeding and to stabilize the electrode pin. The electrode pin was secured in place using dental cement. Once the cement dried, the surrounding skin was sutured. Mice were allowed to recover under a heat lamp before being returned to their home cages. Synchronized EMG recordings The potential differences between TA electrode and reference electrode, and GS electrode between reference electrode were separately collected from a differential amplifying module (DAM, 50, Supplementary Fig. ). The laser was pulsed at a frequency of 0.5 Hz with a pulse width of 50 ms during optical stimulation. Signals from TA and GS muscles were synchronized and digitized at 4 kHz (Powerlab 4/30, AD Instruments), and filtered between 300-3000 Hz. The signal-to-noise (SNR) ratio of optically evoked EMG was calculated using the formula: \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$${SNR}=20\times \log \left(\frac{{{RMS}}_{{signal}}}{{{RMS}}_{{noise}}}\right)({dB})\,,$$\end{document} S N R = 20 × log R M S s i g n a l R M S n o i s e ( d B ) , where RMS signa l is the root mean square of optically evoked EMG amplitude (µV), and where RMS nois e is the root mean square of baseline amplitude (µV). Running wheel behavioral assay for freely moving EMG recordings All the mice were acclimatized to a running wheel for 30 mins, 1 day prior to surgery. 3 days after the implantation of the TRAIN hydrogel electrodes, mice were acclimatized to the running wheel for 30 mins. The potential difference between the working electrode and reference in TA was individually collected through a DAM50 system, and the potential difference between the working electrode and reference in GS was individually collected through another DAM50 system. The EMG data was filtered (100-3000 Hz), synchronized, and collected through a recording system (PowerLab 4/20 T, ADInstruments). Concurrently, a camera was used to record videos for the analysis of the gait, using DeepLabCut (DLC), of the mice during locomotion. Critical anatomical landmarks on the mice, encompassing the electronic pin, neck, back, iliac crest, hip, knee, ankle, front toe, and rear toe, were meticulously tracked during the mice’s locomotion in the recorded videos. Using a custom-written MATLAB algorithm, we identified a single gait cycle in variable-width runway tasks (VWRTs), defined by the two local minima observed in the plot of the distance between the fore toe and hind toe over time. This gait cycle was further segmented into swing and stance phases. From these data, kinematic stick diagrams representing the hindlimb movement during a single gait cycle were generated, providing detailed insights into the locomotor dynamics of the subjects. Synchronized EMG and spinal cord electrophysiological recordings Thy1::ChR2-EYFP mice were anesthetized using isoflurane (1.5% induction and continuously maintained at 1%). A TRAIN hydrogel electrode (input M1) was inserted into the TA muscle in the hindlimb, a reference electrode (input M2) was inserted into the right body of the mice, and a ground electrode was inserted subcutaneously into the tail. A 4-pin bioelectronic device containing 2 electrodes (Working electrode: input S1. Reference electrode: input S2) was implanted in the L3 region of the spinal cord A 473 nm laser was used for transdermal optical stimulation over the hindlimb. The potential difference between input M1 and input M2 was collected through a DAM50 system, and the potential difference between input S1 and input S2 was collected through another DAM50 system. A synchronization data acquisition unit (PowerLab 4/20 T, AD Instrument, filtered 10-1000 Hz, sampling rate 40 kHz) was used to simultaneously collect spinal cord electrophysiology and EMG data triggered by optogenetic activation. Intraspinal electrophysiology recording The spinal cord-implanted mice were anesthetized using isoflurane (1.5% induction and continuously maintained at 0.5%). The 4-pin device was connected to a DAM50 system with one hydrogel microelectrode serving as the working electrode (input SC1), and one hydrogel microelectrode serving as the reference electrode (input SC2). The DAM50 system was used to amplify the difference between input 1 and 2 signals and reject any common noise present on both inputs. Spontaneous neural activities were collected through a recording system (PowerLab 4/20 T, AD Instruments, filtered 100-3000 Hz, sampling rate 40 kHz). Prior to recordings, all mice were acclimatized to an open field chamber for 30 min to minimize stress and adaptation effects. The same 4-pin device used in the anesthesia studies was connected to a DAM50 system for continuity in data collection. Spontaneous neural activities were filtered across a bandwidth of 100-3000 Hz and collected through the recording system (PowerLab 4/20 T, AD Instrument). Concurrently, mouse behaviors were monitored via a camera strategically positioned above the open field chamber, allowing for the correlation of neural activity with observable behaviors. Tissue collection Once mice were euthanized, their sciatic nerves and spinal cords were removed from the body, washed briefly in PBS (Sigma-Aldrich P3813), and fixed in 4% paraformaldehyde (PFA, Sigma-Aldrich 8187151000) for more than 48 h at 4 °C in the dark. Fixed tissues were then placed in 30% sucrose in PBS overnight at 4 °C in the dark. Next, the tissues were embedded in Tissue-Tek O.C.T compound (Sakura Finetek 4583) and cut into 20-μm transverse sections using a cryostat microtome (Leica CM1900), the cut tissues were attached on glass slides with positive charges. Tissues were left dry in the air overnight and baked at 60 °C for 2 h to remove OCT. For sciatic nerves and spinal cord tissues expressing Thy1::ChR2-EYFP , they were processed for confocal examination to confirm transgenic expression. For spinal cord tissues with foreign body response, they were processed with immunostaining. Immunohistology for foreign body response The sectioned spinal cord tissues were permeabilized with PBST (0.3% Triton-X-100 in PBS, Sigma-Aldrich 93443) for 3 times (each time 15 min) at room temperature and blocked with 1% bovine serum albumin in PBS (Sigma-Aldrich A9647) for 30 min prior to staining. Primary antibody solutions with specific diluted fractions (Table ) were applied to stain the tissues and incubated overnight at room temperature in a humid chamber. After washing the tissues with PBS three times (5 min each time), secondary antibody solutions (Table ) were applied and incubated at room temperature for 2 h in a humid chamber. The tissues were then washed with PBS three times (5 min each time), water three times (1 minute each time) and mounted on glass slides. DAPI mounting medium (Southernbiotech, Fluoromount-G, Cat. No. 0100-01) was used to mount the cover glass on top of the glass slide with the sections. The slides were left to dry in the air at room temperature overnight before images were acquired using an inverted fluorescence microscope (Nikon Eclipse Ti-S). The quantitative analysis (fluorescence intensity and percentages of fluorescence area) was performed with ImageJ. Area analysis of antibody labeled cells was performed by creating binary layers of the implantation sites using consistent threshold (triangle) and quantified using the measurement tool in Image J . Confocal microscopy on transgenic expression The tissue sections were permeabilized using PBST (0.3% Triton-X-100 in PBS, Sigma-Aldrich 93443) for 15 min at RT. This was followed by blocking with 1% bovine serum albumin (Sigma-Aldrich A9647) in PBS for 30 min to prevent nonspecific binding. Subsequently, the tissues were washed three times with PBS and allowed to air dry for 30 min. For visualization, the sections were mounted using DAPI-containing Fluoromount-G medium (Southernbiotech, 0100-01) under a cover glass placed on the glass slide. The slides were then left to dry overnight at room temperature. Imaging was performed using a confocal microscope (ZEISS LSM 880). Statistics and reproducibility Statistical analyses were performed in Excel (Microsoft Corporation, Inc., USA), MATLAB (MathWorks, Inc., USA), GraphPad Prism 10 (GraphPad by dotmatics), and DeepLabCut (Mackenzie Mathis). The data was tested with normality distribution before statistical analysis. Power analyses were not performed to determine sample sizes; instead, group sizes were chosen based on previous research. This enabled a direct comparison of our results with the earlier work. Statistical significance was determined by the analysis of One-way ANOVA, Two-way ANOVA, two-tailed unpaired Student’s t-tests, and two-tailed paired Student’s t-tests. For representative SEM images, each sample was repeated 10 times with similar results. For representative TEM images, each sample was repeated 6 times with similar results. For SRS analysis, the experiment was repeated from 6 individual samples with similar results. For representative confocal images of Thy1::ChR2-EYFP expression, 10 images were taken for each sample, consistently yielding similar results. Reporting summary Further information on research design is available in the linked to this article. 

To prepare a 10 wt% polyvinyl alcohol (PVA) solution, 10 g of PVA (146,000 to 186,000 Da, 99 + % hydrolyzed, Sigma Aldrich 363065) was combined with 90 g of Milli-Q water (14 MΩ·cm at 25 °C). The mixture was heated to 100 °C under continuous stirring for 5 h, resulting in a clear and viscous solution. For the carbon nanotubes (CNTs) preparation, a stock solution of CNTs (OCSiAl, TUBALL BATT H2O 0.8% beta) was diluted with Milli-Q water in a weight ratio of 1:0.6. To prevent the aggregation of CNTs, a solution of Sodium Dodecylbenzene Sulfonate (SDBS, technical grade, Sigma Aldrich STBL3944) was prepared at a concentration of 5 wt%. To fabricate chemically cross-linked CNTs-PVA hydrogel fibers, 100 µL of Glutaraldehyde (GA, 25% in water, Sigma Aldrich G6257) was added into 10 g of 10 wt% PVA solution followed by mixing and degassing in a vacuum spinner (Musashi ARV-310). 150 µL of hydrochloric acid (HCl, 37%, Sigma-Aldrich 258148) was then added into another 10 g of 10 wt% PVA solution with mixing and degassing followed. Next, the diluted CNTs, PVA-GA, and PVA-HCl solutions were combined in a ratio of (0.6 ~ 1.4):1:1 with the same mixing and degassing procedure. The homogeneous solution was then infused into silicone molds (800 µm I.D., 51845K51 and 500 µm I.D., 51845K66, MacMaster-Carr) and allowed to cross-link at room temperature (RT) for 2 h. Dichloromethane (DCM, 99.8%, Sigma Aldrich 270997) was utilized to induce swelling in silicone molds, aiding the elution of CNTs-PVA hydrogel fibers. Post-elution, these fibers were rinsed with large amounts of Milli-Q water for 2 days to remove any residual unreacted chemicals. Following the washing step, the CNTs-PVA hydrogel fibers were immersed in HCl solution (12 mM) for 2 h (cite COMPACT), then pre-stretched to 200% strain and dried in the air for 12 h followed by annealing at 100 °C for 20 min. Finally, the fibers were reswelled in Milli-Q water for later use. 

The CNTs stock solution was diluted with Milli-Q water (1:0.6 by weight) and then homogeneously dispersed with a 5 wt% SDBS solution (1:10 by weight). Subsequently, 100 µL of GA was incorporated into 10 g of a 10 wt% PVA solution. Additionally, 150 µL of HCl was added to another 10 g of 10 wt% PVA solution. Both mixtures were subjected to thorough mixing and degassing using a vacuum spinner. The diluted CNTs, PVA-GA, and PVA-HCl were then combined in a ratio of 1.4:1:1, employing identical mixing and degassing procedures. The resultant homogeneous mixture was poured into a customized mold and allowed to cross-link at room temperature for 2 h. The resultant CNTs-PVA hydrogel films were demolded and extensively rinsed with Milli-Q water to eliminate any unreacted chemicals. The films underwent a post-treatment with an HCl solution (12 mM) followed by pre-stretching the films to 10% strain and air drying for 12 h. The films were annealed at 100 °C for 20 min. Finally, these films were reswelled in Milli-Q water. 

To reorient CNTs in the PVA hydrogel matrix and fabricate TRAIN hydrogel fibers and films, we subjected them to cyclic stretching tests (strain-controlled mode: 5%, 10%, and 20% strains, and frequency of 0.5 Hz) for 5000–15000 cycles using a horizontal mechanical tester (Univert, Cell Scale) with a water bath. A 4.4 N load cell (Futek) was used. The conductive hydrogel materials were stretched with a constant strain amplitude, and the force variation was recorded over time. 

Impedance of conductive hydrogel fibers and thin films was systematically assessed using an electrochemical working station (Princeton Applied Research PARSTAT 2273). A 3-electrode electrochemical sink was used to characterize conductive TRAIN hydrogel fibers with a sinusoidal driving voltage spanning a frequency range from 10 Hz to 1 MHz and an amplitude of 10 mV. The conductive hydrogel films, after undergoing repeated training, were analyzed using a specialized device in three different orientations: along the stretching direction ( x -axis), across the stretching direction on the surface of the film ( y -axis), and through the thickness of the film, perpendicular to the stretching direction ( z -axis). For measurements along the x and y axes, impedance was determined using two platinum wires (diameter: 1.54 mm, length: 19.47 mm, and distance 15.44 mm). The length ( l ) used in calculations is the 15.44 mm distance between the wires, and the area ( A ) is the contact area where each wire touches the film. For the Z-axis measurements, impedance was recorded using two platinum sheets (length: 19.47 mm and width: 6.41 mm). Here, l is the thickness of the film, and A is the area where each sheet contacts the film. For hydrogel fibers, l is defined as the length of fiber immersed in a chemical solution, and A is the cross-sectional area of the immersed part of the fiber. The lengths of the hydrogel fibers and films were measured using a caliper, while their thickness was accurately gauged using a micrometer. The measured impedance was normalized using the specific formula: \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$R=\frac{l}{A}\rho$$\end{document} R = l A ρ , where R is the measured impedance, l is the length of the materials that were characterized, A is the area of the materials that were characterized, ρ is the specific impedance of the conductive hydrogel materials. 

Images of hydrogel fibers were captured using a microscope (AmScope) under a bright field while submerged in water. Each fiber was examined in three distinct areas, including both ends and the middle (three individual measurements in each section). Subsequently, the Image J software was used to measure the diameter of each fiber. In addition, the length (five individual measurements) of the fibers was measured using a caliper. 

To investigate the structure and morphology of hydrogel films, samples were first rapidly frozen using liquid nitrogen to preserve their internal structure. For TRAIN conductive hydrogel films, they were fractured along lines parallel to the training direction to expose the relevant structural facets. For pre PVA hydrogel films, they were fractured randomly. After fracturing, the hydrogel films were sputtered with platinum (Cressington, 208HR) to enhance conductivity and then examined using SEM (Hitachi Su5000) at an acceleration voltage of 4 kV. 

TEM images were acquired using a transmission electron microscope (FEI Tecnai 12, 120 kV). CNTs were diluted in a range from 1:3.3 to 1:10 with Milli-Q water and subsequently deposited onto a copper grid (Sigma-Aldrich FCF200-Cu) for imaging purposes. 

Raman spectra of TRAIN CNTs-PVA and PVA hydrogel films were acquired using a confocal Raman microscope (Renishaw InVia, 785-nm NIR laser, 20X objective lens). Prior to spectral collection, the films were mounted on glass slides enveloped in a reflective substrate. The acquisition resolution was 0.7 cm -1 and the integration time per acquisition was 10 sec. For the TRAIN CNTs-PVA hydrogel films, to prevent thermal degradation of the CNTs, the laser power was reduced to 0.1%, resulting in an effective power of approximately 0.57 mW at the focal point of the sample. In contrast, the PVA hydrogel samples were analyzed under 10% laser power, corresponding to an effective power of about 10 mW at the sample focus. All spectra were recorded and subsequently analyzed using Renishaw’s WiRE 4.1 software, ensuring precise and reproducible data for further interpretation. 

To prepare samples for SRS imaging, TRAIN and untrained CNTs-PVA hydrogel films (0.16% and 0.24% CNTs) were embedded in O.C.T compounds (-80 o C for 2 h, Sakura Finetek 4583) then sliced with a 20 µm thickness using a cryo-slicing microtome (Leica CM1950). The sliced samples were then mounted onto glass slides for later imaging. A customized SRS setup was used to image for chemicals specific CNTs signals in the TRAIN and untrained CNTs-PVA hydrogel samples. Insight X3, (Spectra-Physics), a dual channel/wavelength, pulsed laser was used to generate the SRS signals. The modulated SRL signal (stimulated Raman loss) was captured with FDS1010 Si-photodiode (Thorlabs Inc.), which was then processed/demodulated by a HF2LI lock-in amplifier (Zurich Instruments). Scanning image software was used as an overall image-capturing system to generate the final digital SRS images with 1024×1024 pixel data density. Imaging was performed under a 25X water immersion objective with a 3X zoom, capturing an effective sample area of 233×233 µm 2 . The strokes and pump beams were set to an average power of 100 mW and 30 mW, respectively. The stroke beam is fixed at 1045 nm, and the tunable pump beam was set to 805, 809, 880, and 896 nm to obtain 4 sets of SRS images for each sample and location. SRS images were taken at 896 nm for the CNTs selective chemical imaging (based on Raman spectra) and 805 nm for the PVA hydrogel imaging. Images were also taken at 880 nm and 809 nm for off-peak (background) values, of CNTs and PVA hydrogel respectively. The collected images were processed, background subtracted, and overlaid with pseudo-colors for visualization, using Fiji ImageJ software. 

A tensile test machine (Univert, Cell Scale) was employed to stretch the hydrogel microelectrodes at a rate of 1 mm/s under water. The nominal stress was calculated using the formula σ = F∕A, where F denotes the recorded force, and A denotes the cross-sectional area of the fibers in the hydrated state. The strain was calculated using ϵ = ΔL∕L , where ΔL represents the displacement, and L represents the gauge length. The elastic moduli E were determined by calculating the average slope of the stress-strain relationship in the first 10% applied strain using linear regression. The maximum elongation (%) of the fibers was reported at the point of fracture in the stress-strain curve. 

X-ray scattering experiments were conducted using the SAXSLAB GANESHA 300XL instrument, equipped with a Dectris Pilatus 300 K 2D CMOS photon counting detector (measuring 83.8 ×106.5 mm 2 ). Wide-angle X-ray (WAXS) measurements employed a 2 mm beamstop, and each sample was exposed for a duration of 300 s. 

The degree of crystallinity of hydrogel fibers and materials was assessed using a DSC instrument (2920 TA instrument). The PVA hydrogels were analyzed in the desiccated state. A small quantity of sample (1-15 mg) was loaded into a crucible (TA instrument T81006) and placed in a temperature-controlled DSC cell. A blank crucible served as a reference. The sample was heated from 30 °C to 300 °C in air, with a heating rate of 20 °C/min. The differential heat flow to the sample and reference was recorded by the instrument. To determine the melting fusion enthalpy of endothermic peaks, heat flow (mW) over sample weight (mg) was plotted against time (s). The areas of melting endothermic peaks were integrated using TA analyze software (TA Universal Analysis). The degree of crystallinity α was estimated using the equation: \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$\alpha=\frac{\Delta {H}_{f}}{\Delta {H}_{m}}\cdot 100\%$$\end{document} α = Δ H f Δ H m ⋅ 100 % , where was \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$\Delta {H}_{f}\,(J/g)$$\end{document} Δ H f ( J / g ) calculated from the integration of melting endothermic peaks and \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$$\Delta {H}_{m}\,(150{J}/g)$$\end{document} Δ H m ( 150 J / g ) was the enthalpy of melting 100% of PVA crystallites – . 

TRAIN hydrogel microelectrodes were subjected to accelerated aging in artificial cerebrospinal fluid (aCSF, Table ) to simulate in vivo physiological conditions. Aging experiments were conducted at 45 °C for five weeks, with aCSF adjusted to pH values of 4, 7, and 10. The diameter and impedance of the hydrogel microelectrodes were measured weekly to evaluate their stability and performance over time. 

To insulate the CNTs-PVA hydrogel electrodes, a dip-coating process was performed using a 20 wt% SEBS (Styrene-Ethylene-Butylene-Styrene) solution in toluene (Fisher Scientific, NC1024503). The SEBS solution was prepared by thoroughly dissolving SEBS in toluene with constant stirring to ensure a homogenous mixture. Prior to dip coating, the CNTs-PVA hydrogel electrodes were cleaned, straightened, and dried to eliminate any surface contaminants that might interfere with the coating process. The electrodes were then immersed into the SEBS solution at a controlled speed to ensure smooth application and prevent the formation of surface irregularities or trapped air bubbles. The depth of immersion was carefully controlled to ensure complete coverage of the electrode surface intended for insulation. After immersion, the electrodes were withdrawn with a speed of 11.8 mm/min from the solution to ensure an even coating layer. Following the dip-coating process, the electrodes were suspended vertically in a well-ventilated area to allow the toluene solvent to evaporate. Solvent evaporation was conducted under ambient conditions to promote uniform drying for 1 hour. After complete solvent evaporation, the electrodes were inspected for uniformity of the SEBS coating. If any irregularities in thickness or coverage were detected, additional dip-coating cycles were performed to ensure optimal insulation. Once the dip-coating and curing processes were complete, the electrodes were stored in a clean, dust-free environment to prevent contamination prior to their use in subsequent experiments. 

To fabricate TRAIN hydrogel electrodes, a hydrogel conductive fiber and a stainless-steel wire (30 g 316 L wire, Master Wire Supply) were dip-coated in CNTs (0.8 wt%) solution. The dip-coated hydrogel fiber and stainless-steel wire were inserted into an elastic tubing (100 µm) to create a hydrogel-steel junction. Another thin layer of silver paint (Ted Pella Inc) was applied at the junction to enhance conductivity. UV epoxy (Norland optical adhesive 87) was used to seal and reinforce the junction. To assemble the bioelectronic device for EMG recordings, 4 insulated TRAIN electrodes were soldered onto 4 pins from a 6-pin connector (952-3602-ND, DigiKey), respectively. 1 insulated stainless-steel wire (0.0045 inch in diameter, A-M systems) was soldered onto the last pin as the ground wire. To assemble the bioelectronic device for spinal cord recordings, 3 insulated TRAIN electrodes were soldered onto 3 pins from a 4-pin connector (SAM15343-ND, DigiKey), respectively. 1 insulated stainless-steel wire (50 µm) was soldered onto the last pin as the ground wire. The 3 working electrodes were twisted into a yarn and dipped coated in SEBS solution. Optical adhesive was applied to the soldering sides on the pin to provide insulation. 

Every experiment involving animals has been carried out following a protocol approved by an ethical commission: The Institutional Animal Care and Use Committee at Binghamton University (Protocol number: 897-23) and the University of Massachusetts Amherst (Protocol number: 2520). 

Wild-type (C57BL/6 J) and Thy1::ChR2-EYFP mice were purchased from the Jackson Laboratory. Mice were given ad libitum access to food and water and were housed at 24 °C ± 1 °C, with 50% relative humidity, and on a 12-h light/12-h dark cycle. All experiments were conducted during the light cycle. 

Wild type (WT) and Thy1::ChR2-EYFP mice were anesthetized using isoflurane (1.5% induction, Fluriso, VET one) and continuously maintained at 1%. Supplemental heat was provided during the surgery. The fur was removed over the hindlimbs. To collect EMG signals from WT and Thy1-ChR2-EYFP mice under anesthesia, an insulated TRAIN hydrogel electrode was inserted into the medial tibialis anterior (TA) and gastrocnemius (GS) muscles of mice hindlimbs. A reference needle electrode was inserted in an electrical unrelated region. A ground needle electrode was subcutaneously inserted into the tail. 

C67BL/6 J mice were anesthetized with 1.5% isoflurane continuously maintained at 1%, with supplemental heat provided throughout the surgical procedure. Fur was removed from the hindlimbs and head, and the exposed skin was sanitized using iodine followed by 75% ethanol. Incisions were then made at each site. A 6-pin device was carefully routed subcutaneously from the hindlimb to the skull. The pin connector was securely affixed to the skull using dental cement (Parkell C&B METABOND and Jet Set-4). In wild-type mice, two TRAIN hydrogel electrodes were employed—one as a working electrode and the other as a reference electrode. Both electrodes were inserted into the mid-belly of the tibialis anterior (TA) muscles on the left hindlimb using 30-gauge needles. Similarly, two additional TRAIN hydrogel electrodes were inserted into the gastrocnemius (GS) muscle on the left hindlimb of the same wild-type mice. A ground wire was positioned subcutaneously in the neck-shoulder area to complete the setup. The skin over the hindlimb muscles was then sutured closed using nylon sutures (Nylon 5-0). 

Mice were anesthetized using 1% isoflurane. Once a stable plane of anesthesia was achieved, the area surrounding the dorsal hump was shaved and cleansed with alternating applications of iodine and 75% alcohol. For implantations at spinal segment L3, an incision was made slightly caudal to the peak of the dorsal hump, extending approximately 0.5 cm rostral and 0.5 cm caudal from the initial site. Larger incisions were made initially to provide greater access. An incision was created medial to the white tendons on either side of the vertebral column, spanning slightly more than one vertebral segment, from the outer edge of the caudal transverse process to the outer edge of the rostral transverse process. The tendon attached to the caudal transverse process was cut, and bleeding was controlled using absorbent spears. Tissue was cleared from the transverse processes while ensuring that nerves entering the spinal cord were not damaged. This process was repeated on both sides of the spinal column. The vertebrae of interest (T12 and T13) were identified, and a small incision was made between the tendons and the vertebral column on each side. All tissue was removed from the surface of the bone. The spine was then secured using customized spinal adaptor clamps. A small hole was created in the dura mater using a 30-gauge needle. The electrode bundle was trimmed to a length of less than 500 µm and mounted on an implantation bar attached to the stereotaxic frame. The device was positioned between vertebrae T12 and T13 and implanted to a depth of 300 µm into the spinal cord tissue. A small amount of sterile lubricant was applied around the electrode bundle and over the surface of the bone to minimize the risk of bleeding and to stabilize the electrode pin. The electrode pin was secured in place using dental cement. Once the cement dried, the surrounding skin was sutured. Mice were allowed to recover under a heat lamp before being returned to their home cages. 

The potential differences between TA electrode and reference electrode, and GS electrode between reference electrode were separately collected from a differential amplifying module (DAM, 50, Supplementary Fig. ). The laser was pulsed at a frequency of 0.5 Hz with a pulse width of 50 ms during optical stimulation. Signals from TA and GS muscles were synchronized and digitized at 4 kHz (Powerlab 4/30, AD Instruments), and filtered between 300-3000 Hz. The signal-to-noise (SNR) ratio of optically evoked EMG was calculated using the formula: \documentclass[12pt]{minimal}
				\usepackage{amsmath}
				\usepackage{wasysym} 
				\usepackage{amsfonts} 
				\usepackage{amssymb} 
				\usepackage{amsbsy}
				\usepackage{mathrsfs}
				\usepackage{upgreek}
				\setlength{\oddsidemargin}{-69pt}
				\begin{document}$${SNR}=20\times \log \left(\frac{{{RMS}}_{{signal}}}{{{RMS}}_{{noise}}}\right)({dB})\,,$$\end{document} S N R = 20 × log R M S s i g n a l R M S n o i s e ( d B ) , where RMS signa l is the root mean square of optically evoked EMG amplitude (µV), and where RMS nois e is the root mean square of baseline amplitude (µV). 

All the mice were acclimatized to a running wheel for 30 mins, 1 day prior to surgery. 3 days after the implantation of the TRAIN hydrogel electrodes, mice were acclimatized to the running wheel for 30 mins. The potential difference between the working electrode and reference in TA was individually collected through a DAM50 system, and the potential difference between the working electrode and reference in GS was individually collected through another DAM50 system. The EMG data was filtered (100-3000 Hz), synchronized, and collected through a recording system (PowerLab 4/20 T, ADInstruments). Concurrently, a camera was used to record videos for the analysis of the gait, using DeepLabCut (DLC), of the mice during locomotion. Critical anatomical landmarks on the mice, encompassing the electronic pin, neck, back, iliac crest, hip, knee, ankle, front toe, and rear toe, were meticulously tracked during the mice’s locomotion in the recorded videos. Using a custom-written MATLAB algorithm, we identified a single gait cycle in variable-width runway tasks (VWRTs), defined by the two local minima observed in the plot of the distance between the fore toe and hind toe over time. This gait cycle was further segmented into swing and stance phases. From these data, kinematic stick diagrams representing the hindlimb movement during a single gait cycle were generated, providing detailed insights into the locomotor dynamics of the subjects. 

Thy1::ChR2-EYFP mice were anesthetized using isoflurane (1.5% induction and continuously maintained at 1%). A TRAIN hydrogel electrode (input M1) was inserted into the TA muscle in the hindlimb, a reference electrode (input M2) was inserted into the right body of the mice, and a ground electrode was inserted subcutaneously into the tail. A 4-pin bioelectronic device containing 2 electrodes (Working electrode: input S1. Reference electrode: input S2) was implanted in the L3 region of the spinal cord A 473 nm laser was used for transdermal optical stimulation over the hindlimb. The potential difference between input M1 and input M2 was collected through a DAM50 system, and the potential difference between input S1 and input S2 was collected through another DAM50 system. A synchronization data acquisition unit (PowerLab 4/20 T, AD Instrument, filtered 10-1000 Hz, sampling rate 40 kHz) was used to simultaneously collect spinal cord electrophysiology and EMG data triggered by optogenetic activation. 

The spinal cord-implanted mice were anesthetized using isoflurane (1.5% induction and continuously maintained at 0.5%). The 4-pin device was connected to a DAM50 system with one hydrogel microelectrode serving as the working electrode (input SC1), and one hydrogel microelectrode serving as the reference electrode (input SC2). The DAM50 system was used to amplify the difference between input 1 and 2 signals and reject any common noise present on both inputs. Spontaneous neural activities were collected through a recording system (PowerLab 4/20 T, AD Instruments, filtered 100-3000 Hz, sampling rate 40 kHz). Prior to recordings, all mice were acclimatized to an open field chamber for 30 min to minimize stress and adaptation effects. The same 4-pin device used in the anesthesia studies was connected to a DAM50 system for continuity in data collection. Spontaneous neural activities were filtered across a bandwidth of 100-3000 Hz and collected through the recording system (PowerLab 4/20 T, AD Instrument). Concurrently, mouse behaviors were monitored via a camera strategically positioned above the open field chamber, allowing for the correlation of neural activity with observable behaviors. 

Once mice were euthanized, their sciatic nerves and spinal cords were removed from the body, washed briefly in PBS (Sigma-Aldrich P3813), and fixed in 4% paraformaldehyde (PFA, Sigma-Aldrich 8187151000) for more than 48 h at 4 °C in the dark. Fixed tissues were then placed in 30% sucrose in PBS overnight at 4 °C in the dark. Next, the tissues were embedded in Tissue-Tek O.C.T compound (Sakura Finetek 4583) and cut into 20-μm transverse sections using a cryostat microtome (Leica CM1900), the cut tissues were attached on glass slides with positive charges. Tissues were left dry in the air overnight and baked at 60 °C for 2 h to remove OCT. For sciatic nerves and spinal cord tissues expressing Thy1::ChR2-EYFP , they were processed for confocal examination to confirm transgenic expression. For spinal cord tissues with foreign body response, they were processed with immunostaining. 

The sectioned spinal cord tissues were permeabilized with PBST (0.3% Triton-X-100 in PBS, Sigma-Aldrich 93443) for 3 times (each time 15 min) at room temperature and blocked with 1% bovine serum albumin in PBS (Sigma-Aldrich A9647) for 30 min prior to staining. Primary antibody solutions with specific diluted fractions (Table ) were applied to stain the tissues and incubated overnight at room temperature in a humid chamber. After washing the tissues with PBS three times (5 min each time), secondary antibody solutions (Table ) were applied and incubated at room temperature for 2 h in a humid chamber. The tissues were then washed with PBS three times (5 min each time), water three times (1 minute each time) and mounted on glass slides. DAPI mounting medium (Southernbiotech, Fluoromount-G, Cat. No. 0100-01) was used to mount the cover glass on top of the glass slide with the sections. The slides were left to dry in the air at room temperature overnight before images were acquired using an inverted fluorescence microscope (Nikon Eclipse Ti-S). The quantitative analysis (fluorescence intensity and percentages of fluorescence area) was performed with ImageJ. Area analysis of antibody labeled cells was performed by creating binary layers of the implantation sites using consistent threshold (triangle) and quantified using the measurement tool in Image J . 

The tissue sections were permeabilized using PBST (0.3% Triton-X-100 in PBS, Sigma-Aldrich 93443) for 15 min at RT. This was followed by blocking with 1% bovine serum albumin (Sigma-Aldrich A9647) in PBS for 30 min to prevent nonspecific binding. Subsequently, the tissues were washed three times with PBS and allowed to air dry for 30 min. For visualization, the sections were mounted using DAPI-containing Fluoromount-G medium (Southernbiotech, 0100-01) under a cover glass placed on the glass slide. The slides were then left to dry overnight at room temperature. Imaging was performed using a confocal microscope (ZEISS LSM 880). 

Statistical analyses were performed in Excel (Microsoft Corporation, Inc., USA), MATLAB (MathWorks, Inc., USA), GraphPad Prism 10 (GraphPad by dotmatics), and DeepLabCut (Mackenzie Mathis). The data was tested with normality distribution before statistical analysis. Power analyses were not performed to determine sample sizes; instead, group sizes were chosen based on previous research. This enabled a direct comparison of our results with the earlier work. Statistical significance was determined by the analysis of One-way ANOVA, Two-way ANOVA, two-tailed unpaired Student’s t-tests, and two-tailed paired Student’s t-tests. For representative SEM images, each sample was repeated 10 times with similar results. For representative TEM images, each sample was repeated 6 times with similar results. For SRS analysis, the experiment was repeated from 6 individual samples with similar results. For representative confocal images of Thy1::ChR2-EYFP expression, 10 images were taken for each sample, consistently yielding similar results. 

Further information on research design is available in the linked to this article. 

Supplementary Information Reporting summary Transparent Peer Review file 

Source data File 

