From awesome-cognitive-and-neuroscience-skills
Guides building biologically realistic spiking neural network simulations: neuron models, E/I balance, connectivity, synaptic dynamics, plasticity rules.
npx claudepluginhub neuroaihub/awesome_cognitive_and_neuroscience_skills --plugin awesome-cognitive-and-neuroscience-skillsThis skill uses the workspace's default tool permissions.
This skill encodes expert methodological knowledge for constructing biologically realistic spiking neural network simulations. A competent programmer without computational neuroscience training will get this wrong because:
Supports neuroscience research workflows using ToolUniverse tools for computational modeling (rate models, integrate-and-fire), neuroanatomy, neurophysiology, synaptic plasticity, neural circuits, neurodegeneration, and clinical neurology.
Guides ACT-R cognitive model construction: chunk types, production rules, subsymbolic parameters, fitting to behavioral data, and validation. For pyactr (Python) or ACT-R 7.x (Lisp) implementations.
Analyzes Neuropixels 1.0/2.0 neural recordings from SpikeGLX/OpenEphys data: loads, preprocesses with motion correction, runs Kilosort4 spike sorting, computes quality metrics, curates units via Allen/IBL methods.
Share bugs, ideas, or general feedback.
This skill encodes expert methodological knowledge for constructing biologically realistic spiking neural network simulations. A competent programmer without computational neuroscience training will get this wrong because:
Do NOT use this skill for:
neural-population-analysis-guide)Before executing the domain-specific steps below, you MUST:
For detailed methodology guidance, see the research-literacy skill.
This skill was generated by AI from academic literature. All parameters, thresholds, and citations require independent verification before use in research. If you find errors, please open an issue.
What firing properties does your model need?
|
+-- "Just spikes, basic rate coding, large networks"
| --> Leaky Integrate-and-Fire (LIF)
| Simplest; fastest simulation; no adaptation or bursting
|
+-- "Spike initiation sharpness matters"
| --> Exponential IF (EIF)
| Adds realistic spike onset; still single-variable
|
+-- "Spike-frequency adaptation or bursting"
| --> Adaptive Exponential IF (AdEx)
| Two variables; can produce regular spiking, bursting,
| intrinsic oscillations, adaptation
|
+-- "Diverse firing patterns with minimal complexity"
| --> Izhikevich model
| Four parameters; 20+ firing patterns; fast to simulate
|
+-- "Biophysically detailed ion channel dynamics"
--> Hodgkin-Huxley (HH)
Four variables; channel-level accuracy; slow to simulate
Use only when ion channel pharmacology is relevant
| Parameter | Symbol | Value | Source |
|---|---|---|---|
| Resting potential | V_rest | -65 mV | Dayan & Abbott, 2001 |
| Threshold | V_thresh | -50 mV | Dayan & Abbott, 2001 |
| Reset potential | V_reset | -65 mV | Dayan & Abbott, 2001 |
| Membrane time constant | tau_m | 20 ms | Dayan & Abbott, 2001 |
| Membrane resistance | R_m | 100 MOhm (typical cortical) | Dayan & Abbott, 2001 |
| Refractory period | t_ref | 2 ms (absolute) | Dayan & Abbott, 2001 |
| Parameter | Symbol | Value | Source |
|---|---|---|---|
| All LIF parameters | -- | Same as above | Dayan & Abbott, 2001 |
| Sharpness of spike initiation | Delta_T | 2 mV | Fourcaud-Trocme et al., 2003 |
| Spike detection threshold | V_peak | 0 mV or 20 mV | Fourcaud-Trocme et al., 2003 |
| Parameter | Symbol | Value | Source |
|---|---|---|---|
| Subthreshold adaptation | a | 4 nS | Brette & Gerstner, 2005 |
| Spike-triggered adaptation | b | 0.08 nA (80 pA) | Brette & Gerstner, 2005 |
| Adaptation time constant | tau_w | 100--300 ms | Brette & Gerstner, 2005 |
| Spike initiation sharpness | Delta_T | 2 mV | Brette & Gerstner, 2005 |
| All EIF parameters | -- | Same as EIF above | Brette & Gerstner, 2005 |
AdEx firing patterns by parameter regime (Brette & Gerstner, 2005; Naud et al., 2008):
| Pattern | a (nS) | b (nA) | tau_w (ms) | Typical neuron type |
|---|---|---|---|---|
| Regular spiking | 4 | 0.08 | 150 | Cortical pyramidal |
| Bursting | 4 | 0.5 | 100 | Intrinsically bursting |
| Fast spiking | 0 | 0 | -- | PV+ interneuron (no adaptation) |
| Adapting | 4 | 0.08 | 300 | Slow-adapting pyramidal |
The model uses two variables (v, u) with four parameters (a, b, c, d) (Izhikevich, 2003):
| Pattern | a | b | c (mV) | d | Source |
|---|---|---|---|---|---|
| Regular spiking | 0.02 | 0.2 | -65 | 8 | Izhikevich, 2003 |
| Intrinsically bursting | 0.02 | 0.2 | -55 | 4 | Izhikevich, 2003 |
| Chattering | 0.02 | 0.2 | -50 | 2 | Izhikevich, 2003 |
| Fast spiking | 0.1 | 0.2 | -65 | 2 | Izhikevich, 2003 |
| Low-threshold spiking | 0.02 | 0.25 | -65 | 2 | Izhikevich, 2003 |
Use only when biophysical detail is required. See references/hh-parameters.md for the full parameter set. Key values (Hodgkin & Huxley, 1952):
| Receptor | tau_rise | tau_decay | Net tau_syn | Source |
|---|---|---|---|---|
| AMPA | ~0.5 ms | ~5 ms | 5 ms (single exponential) | Dayan & Abbott, 2001 |
| NMDA | ~2 ms | ~100 ms | 100 ms (single exponential) | Dayan & Abbott, 2001 |
| GABA_A | ~0.5 ms | ~10 ms | 10 ms (single exponential) | Dayan & Abbott, 2001 |
| GABA_B | ~50 ms | ~200 ms | 200 ms (single exponential) | Dayan & Abbott, 2001 |
| Type | Equation | When to Use | Source |
|---|---|---|---|
| Current-based | I_syn = w * g(t) | Large networks; faster simulation; when voltage-dependent effects are unimportant | Brunel, 2000 |
| Conductance-based | I_syn = g(t) * (V - E_rev) | When synaptic interactions depend on membrane potential (e.g., NMDA voltage dependence, shunting inhibition) | Dayan & Abbott, 2001 |
Domain judgment: Current-based synapses are appropriate for most network-level studies. Switch to conductance-based when the research question involves voltage-dependent effects (NMDA Mg2+ block, shunting inhibition) or when accurate I-V relationships matter (Brunel, 2000; Dayan & Abbott, 2001).
The Tsodyks-Markram (TM) model captures short-term facilitation and depression (Tsodyks & Markram, 1997):
| Parameter | Facilitating synapse | Depressing synapse | Source |
|---|---|---|---|
| U (initial release prob.) | 0.1 | 0.5 | Tsodyks & Markram, 1997 |
| tau_rec (recovery time) | 800 ms | 800 ms | Tsodyks & Markram, 1997 |
| tau_fac (facilitation time) | 1000 ms | 0 ms (no facilitation) | Tsodyks & Markram, 1997 |
| Parameter | Value | Source |
|---|---|---|
| Excitatory fraction | 80% of neurons | Braitenberg & Schutz, 1998 |
| Inhibitory fraction | 20% of neurons | Braitenberg & Schutz, 1998 |
| E-to-E connection probability | 10--20% (random) | Brunel, 2000 |
| E-to-I connection probability | 10--20% | Brunel, 2000 |
| I-to-E connection probability | 10--20% | Brunel, 2000 |
| I-to-I connection probability | 10--20% | Brunel, 2000 |
For a balanced network to produce biologically realistic asynchronous irregular (AI) firing (Brunel, 2000):
Domain judgment: The ratio g = J_I/J_E (relative inhibitory strength) determines the network regime. g < 4 produces synchronous regular firing; g = 4--8 produces the biologically realistic asynchronous irregular (AI) state; g >> 8 produces very low firing rates or silence (Brunel, 2000).
| Scale | Neurons | Typical Use | Source |
|---|---|---|---|
| Minimal | 100--500 | Quick tests; parameter exploration | Expert consensus |
| Cortical column | 1,000--10,000 | Standard for cortical circuit models | Brunel, 2000 |
| Large-scale | 10,000--100,000 | Multi-area models; detailed column | Potjans & Diesmann, 2014 |
Standard pair-based STDP parameters (Bi & Poo, 1998; Song et al., 2000):
| Parameter | Symbol | Value | Source |
|---|---|---|---|
| Potentiation time constant | tau_+ | 20 ms | Bi & Poo, 1998 |
| Depression time constant | tau_- | 20 ms | Bi & Poo, 1998 |
| Potentiation amplitude | A_+ | 0.01 (relative) | Song et al., 2000 |
| Depression amplitude | A_- | -0.012 ( | A_- |
| Maximum weight | w_max | Set to prevent runaway | Song et al., 2000 |
Domain judgment: The asymmetry |A_-| > A_+ is critical. Without it, STDP drives all weights to their maximum value (runaway potentiation). The slight depression bias ensures stable weight distributions (Song et al., 2000). Additional stabilization mechanisms (weight dependence, homeostatic plasticity) are often needed in practice.
The Bienenstock-Cooper-Munro (BCM) rule provides a stable, rate-based plasticity rule (Bienenstock et al., 1982):
For long simulations with STDP, add homeostatic mechanisms to prevent runaway dynamics:
| Neuron Model | Recommended dt | Maximum dt | Rationale | Source |
|---|---|---|---|---|
| LIF | 0.1 ms | 0.5 ms | Exact integration possible; larger steps miss coincident spikes | Rotter & Diesmann, 1999 |
| EIF / AdEx | 0.1 ms | 0.1 ms | Exponential term requires small steps near threshold | Brette & Gerstner, 2005 |
| Izhikevich | 0.1 ms | 0.5 ms (with Euler) | Use 0.5 ms with two half-steps per Izhikevich (2003) | Izhikevich, 2003 |
| Hodgkin-Huxley | 0.01--0.05 ms | 0.05 ms | Gating variable dynamics require fine resolution | Rotter & Diesmann, 1999 |
| Phenomenon | Minimum Duration | Rationale | Source |
|---|---|---|---|
| Network stabilization (transient) | 500 ms discard | Allow initial transient to decay | Expert consensus |
| Asynchronous irregular state | 1--5 s after transient | Sufficient for firing rate and CV statistics | Brunel, 2000 |
| STDP weight development | 10--100 s | Weights evolve slowly | Song et al., 2000 |
| Oscillation analysis | 2--10 s | Need multiple cycles for spectral analysis | Expert consensus |
| Metric | Target Value | What It Indicates | Source |
|---|---|---|---|
| Mean firing rate (excitatory) | 1--10 Hz | Realistic cortical activity | Brunel, 2000 |
| Mean firing rate (inhibitory) | 5--30 Hz | Fast-spiking interneurons fire faster | Brunel, 2000 |
| CV of ISI | ~1.0 (0.8--1.2) | Irregular firing (Poisson-like) | Brunel, 2000; Softky & Koch, 1993 |
| Fano factor (spike count) | ~1.0 | Poisson-like variability | Softky & Koch, 1993 |
| Population synchrony (chi) | < 0.2 for AI state | Asynchronous activity | Brunel, 2000 |
| Pairwise correlation | 0.01--0.1 | Weak correlations as in cortex | Cohen & Kohn, 2011 |
Domain judgment: A network with mean firing rate in range but CV << 1 (regular firing) is NOT in a biologically realistic regime. Cortical neurons fire irregularly (CV ~ 1) even when the network is in a stationary state. If your CV is much less than 1, inhibition is likely too weak or connectivity too structured (Brunel, 2000).
| Simulator | Language | Best For | Limitations | Source |
|---|---|---|---|---|
| NEST | Python/C++ | Large-scale LIF/IF networks; exact integration | Less flexible for custom models | Gewaltig & Diesmann, 2007 |
| Brian2 | Python | Rapid prototyping; custom equations; education | Slower than NEST for very large networks | Stimberg et al., 2019 |
| NEURON | Python/HOC | Compartmental models; biophysical detail | Overkill for point-neuron networks | Hines & Carnevale, 1997 |
| GeNN | C++/Python | GPU-accelerated; very large networks | Requires NVIDIA GPU; steeper learning curve | Yavuz et al., 2016 |
Recommendation: Start with Brian2 for prototyping and model development. Use NEST for production runs of large-scale networks. Use NEURON only when compartmental morphology is needed. Use GeNN when GPU acceleration is required for network size (Stimberg et al., 2019).
Networks without proper E/I ratio (80/20) and weight scaling produce unrealistic dynamics: runaway excitation, epileptiform synchrony, or silence. Always verify the network operates in the AI regime (Brunel, 2000).
The first 200--500 ms of simulation reflect initial conditions, not the network's steady state. Always discard this transient period before computing statistics (expert consensus).
Using dt = 1 ms for HH models causes numerical instability. Using dt = 0.01 ms for LIF networks wastes computation. Match dt to the model (Rotter & Diesmann, 1999).
Pair-based STDP alone drives weights to bimodal (all 0 or all w_max) distributions. Add weight dependence, homeostatic scaling, or use triplet STDP rules for stable learning (Song et al., 2000; Turrigiano et al., 1998).
Changing network size N without rescaling weights (1/sqrt(N)) changes firing rates and dynamics. Always verify that results are robust to network size or explicitly rescale (Brunel, 2000).
Conductance-based synapses are slower to simulate and add complexity. Unless voltage-dependent effects (NMDA, shunting inhibition) are central to the question, current-based synapses are appropriate and much faster (Brunel, 2000).
Based on Nordlie et al. (2009) model description standards and Brunel (2000):
See references/hh-parameters.md for full Hodgkin-Huxley parameter tables.
See references/network-regimes.md for Brunel network regime diagrams and extended parameter sweeps.