Free SKILL.md scraped from GitHub. Clone the repo or copy the file directly into your Claude Code skills directory.
npx versuz@latest install hiyenwong-ai-collection-collection-skills-ember-snn-llm-cognitive-architecturegit clone https://github.com/hiyenwong/ai_collection.gitcp ai_collection/SKILL.MD ~/.claude/skills/hiyenwong-ai-collection-collection-skills-ember-snn-llm-cognitive-architecture/SKILL.md---
name: ember-snn-llm-cognitive-architecture
description: >
Hybrid LLM-SNN cognitive architecture that reorganizes the LLM-memory relationship
by placing the LLM as a replaceable reasoning engine within a persistent,
biologically-grounded SNN associative substrate. Features experience-modulated
dynamics and emergent autonomous reasoning capabilities.
Activation: EMBER architecture, hybrid LLM SNN, experience-modulated reasoning,
associative memory substrate, cognitive architecture, spiking neural network memory,
autonomous cognitive behaviour, emergent reasoning, LLM-SNN integration,
经验调制推理, 联想记忆基质, 混合认知架构, 脉冲神经网络记忆
version: 1.0.0
metadata:
hermes:
source_paper: "EMBER: Autonomous Cognitive Behaviour from Learned Spiking Neural Network Dynamics in a Hybrid LLM Architecture"
arxiv_id: "2604.12167v1"
author: "William Savage"
published: "2026-04-14"
tags: [hybrid-architecture, LLM-SNN, cognitive-architecture, associative-memory, emergent-reasoning, spiking-neural-networks]
---
# EMBER: Hybrid LLM-SNN Cognitive Architecture
## Overview
EMBER (Experience-Modulated Biologically-inspired Emergent Reasoning) is a hybrid cognitive architecture that fundamentally reorganizes the relationship between large language models and memory. Rather than the conventional RAG paradigm of augmenting an LLM with retrieval tools, EMBER places the LLM as a **replaceable reasoning engine** embedded within a **persistent, biologically-grounded associative substrate** built from Spiking Neural Networks (SNNs).
This inversion produces autonomous cognitive behaviour through learned SNN dynamics, experience-modulated synaptic plasticity, and emergent multi-step reasoning — all without explicit retrieval pipelines or prompt engineering for memory access.
## Key Insights
### 1. LLM-Memory Relationship Reorganization
**Conventional Paradigm (RAG-style):**
```
LLM (central) → calls → Retrieval tools → searches → External memory
```
- LLM is the fixed cognitive core
- Memory is an external service the LLM queries
- Retrieval is an explicit, discrete operation
**EMBER Paradigm (Substrate-centered):**
```
SNN Associative Substrate (persistent memory & dynamics)
↑↓ bidirectional activation
LLM (replaceable reasoning engine)
```
- The SNN substrate is the persistent cognitive foundation
- The LLM operates as a transient reasoning module activated by substrate dynamics
- Memory access is implicit through associative recall in the SNN
- The LLM is **swappable** — architecture is not tied to a specific model
**Key Implications:**
- Memory is not "retrieved" but **reactivated** through neural dynamics
- Cognitive behaviour emerges from substrate-LLM interaction loops
- System exhibits persistence of internal state across interactions
- LLM upgrades don't require architectural changes
### 2. SNN Associative Memory Structure
The associative substrate is implemented as a learned Spiking Neural Network with:
**Architecture:**
- **Recurrent connectivity** enabling self-sustaining activation patterns
- **Attractor dynamics** where stored experiences form stable energy minima
- **Distributed representation** — memories are patterns across neuron populations
- **Temporal coding** — information encoded in spike timing, not just rates
**Learning Mechanism:**
- Synaptic weights learned through exposure to experience sequences
- Hebbian plasticity reinforced by experience modulation signals
- Pattern completion from partial cues (associative recall)
- Forgetting as natural decay of weak activation pathways
**Properties:**
- Content-addressable memory (recall by semantic similarity)
- Graceful degradation (partial recall from incomplete cues)
- Interference-based generalization (similar memories influence each other)
- Continuous learning without catastrophic forgetting (through experience modulation)
### 3. Experience Modulation Mechanism
Experience modulation is the core learning signal that shapes the SNN substrate:
**Components:**
1. **Experience encoding** — inputs are mapped to SNN activation patterns
2. **Modulation signals** — global signals that adjust plasticity based on experience significance
3. **Synaptic updating** — weights change according to modulated Hebbian rules
4. **Consolidation** — important patterns are strengthened through replay
**Modulation Process:**
```
Input → SNN activation → Modulation signal → Synaptic change → Consolidated memory
```
- **Salience detection**: Novel or significant experiences receive stronger modulation
- **Temporal credit assignment**: Recent activations receive higher modulation
- **Interference resolution**: Conflicting patterns are resolved through competitive dynamics
- **Experience-dependent plasticity**: The substrate continuously adapts to the agent's experience history
### 4. Emergent Reasoning Capabilities
Reasoning in EMBER is not programmed — it **emerges** from the interaction between:
- **SNN substrate dynamics**: Associative recall chains that connect related concepts
- **LLM reasoning**: Structured inference applied to activated memory patterns
- **Feedback loops**: LLM outputs re-enter the substrate, creating recursive reasoning chains
**Emergent behaviours include:**
- **Multi-hop reasoning**: Sequential activation of related memory traces
- **Analogy formation**: Similar patterns activated across different contexts
- **Counterfactual thinking**: Substrate explores alternative activation patterns
- **Self-correction**: Conflicting activations lead to revised conclusions
- **Autonomous exploration**: Substrate generates novel activation patterns that prompt LLM reasoning
## Implementation Pattern
```python
import numpy as np
from typing import Optional, List, Tuple
class EMBERArchitecture:
"""
EMBER: Experience-Modulated Biologically-inspired Emergent Reasoning
A hybrid cognitive architecture with an SNN associative substrate
and a replaceable LLM reasoning engine.
"""
def __init__(
self,
substrate_size: int = 1024,
recurrent_connectivity: float = 0.3,
modulation_rate: float = 0.01,
llm_engine=None
):
# SNN Associative Substrate
self.substrate_size = substrate_size
self.W = self._initialize_connectivity(substrate_size, recurrent_connectivity)
self.membrane_potentials = np.zeros(substrate_size)
self.spike_history = []
# Experience modulation
self.modulation_rate = modulation_rate
self.salience_tracker = np.ones(substrate_size)
# Replaceable LLM reasoning engine
self.llm = llm_engine
def _initialize_connectivity(self, size: int, density: float) -> np.ndarray:
"""Initialize recurrent connectivity with sparse random weights."""
mask = np.random.random((size, size)) < density
W = np.random.randn(size, size) * mask * 0.1
np.fill_diagonal(W, 0) # No self-connections
return W
def encode_input(self, input_text: str) -> np.ndarray:
"""Encode input into SNN activation pattern."""
# Map input to initial activation pattern
# In practice, this uses the LLM's embedding space
pattern = np.random.random(self.substrate_size) * 0.1
return pattern
def substrate_dynamics(
self,
input_pattern: np.ndarray,
timesteps: int = 50
) -> List[np.ndarray]:
"""
Run SNN substrate dynamics to perform associative recall.
This is the core of EMBER's memory mechanism — rather than
retrieving stored items, the substrate evolves to settle into
an attractor state that represents the recalled memory.
"""
self.membrane_potentials = input_pattern.copy()
activation_history = []
for t in range(timesteps):
# LIF neuron dynamics
membrane_current = self.membrane_potentials
recurrent_input = self.W @ membrane_current
# Update membrane potential (leaky integration)
tau = 0.9
self.membrane_potentials = (
tau * self.membrane_potentials +
(1 - tau) * recurrent_input
)
# Spike generation (threshold)
threshold = 0.5
spikes = (self.membrane_potentials > threshold).astype(float)
# Reset after spike
self.membrane_potentials *= (1 - spikes * 0.8)
# Track spikes
self.spike_history.append(spikes)
activation_history.append(self.membrane_potentials.copy())
# Convergence check
if len(activation_history) > 5:
recent = activation_history[-5:]
if np.std([np.mean(a) for a in recent]) < 1e-4:
break
return activation_history
def experience_modulation(self, activation: np.ndarray, salience: float = 1.0):
"""
Apply experience-dependent plasticity to consolidate memories.
Modulates synaptic weights based on current activation pattern
and the salience/significance of the experience.
"""
# Hebbian plasticity with experience modulation
delta_W = self.modulation_rate * salience * np.outer(activation, activation)
# Apply modulation with decay
self.W += delta_W - 0.001 * self.W # Weight decay
# Update salience tracker
self.salience_tracker *= 0.99
self.salience_tracker += salience * activation * 0.01
def reasoning_loop(
self,
input_text: str,
max_iterations: int = 5
) -> dict:
"""
Full EMBER cognitive cycle:
1. Encode input → substrate activation
2. Substrate dynamics → associative recall
3. LLM reasoning on activated patterns
4. Output re-enters substrate (feedback)
5. Experience modulation consolidates learning
"""
# Step 1: Encode input
input_pattern = self.encode_input(input_text)
results = {
'input': input_text,
'activation_chain': [],
'reasoning_steps': [],
'final_output': None
}
for iteration in range(max_iterations):
# Step 2: Substrate dynamics (associative recall)
activations = self.substrate_dynamics(input_pattern, timesteps=50)
recalled_pattern = activations[-1] if activations else input_pattern
results['activation_chain'].append(recalled_pattern.tolist())
# Step 3: LLM reasoning on activated memory
if self.llm is not None:
context = self._pattern_to_context(recalled_pattern)
reasoning_output = self.llm.generate(
input_text, context=context
)
results['reasoning_steps'].append(reasoning_output)
# Step 4: Feedback — LLM output re-enters substrate
input_pattern = self.encode_input(reasoning_output)
else:
break
# Step 5: Experience modulation consolidates the interaction
final_activation = results['activation_chain'][-1] if results['activation_chain'] else input_pattern
salience = self._compute_salience(results)
self.experience_modulation(np.array(final_activation), salience)
results['final_output'] = results['reasoning_steps'][-1] if results['reasoning_steps'] else None
return results
def _pattern_to_context(self, pattern: np.ndarray) -> str:
"""Convert SNN activation pattern to LLM-readable context."""
# Map active neurons to concepts/memories
active_indices = np.argsort(pattern)[-10:] # Top 10 activations
return f"Activated memory nodes: {active_indices.tolist()}"
def _compute_salience(self, results: dict) -> float:
"""Compute experience salience for modulation."""
# Salience based on novelty and reasoning depth
novelty = 1.0
depth = len(results['reasoning_steps'])
return min(1.0, novelty * (0.5 + 0.1 * depth))
# --- Usage Example ---
class SimpleLLMEngine:
"""Placeholder for the replaceable LLM reasoning engine."""
def generate(self, input_text: str, context: str = "") -> str:
# In practice, this is any LLM API call
return f"[Reasoning] Based on {context}, processing: {input_text[:50]}..."
# Initialize EMBER architecture
ember = EMBERArchitecture(
substrate_size=1024,
recurrent_connectivity=0.3,
llm_engine=SimpleLLMEngine()
)
# Run cognitive cycle
result = ember.reasoning_loop(
input_text="What is the relationship between neural dynamics and memory?",
max_iterations=3
)
```
## Activation Keywords
### English
- EMBER architecture, hybrid LLM SNN, experience-modulated reasoning
- associative memory substrate, cognitive architecture, spiking neural network memory
- autonomous cognitive behaviour, emergent reasoning, LLM-SNN integration
- biologically-inspired AI, attractor dynamics memory, Hebbian plasticity
- replaceable reasoning engine, substrate-centered memory, experience-dependent learning
- RAG alternative, neural cognitive architecture, multi-hop reasoning emergence
### Chinese
- EMBER架构, 混合LLM脉冲神经网络, 经验调制推理
- 联想记忆基质, 认知架构, 脉冲神经网络记忆
- 自主认知行为, 涌现推理, LLM-SNN集成
- 生物启发AI, 吸引子动力学记忆, 赫布可塑性
- 可替换推理引擎, 基质中心记忆, 经验依赖学习
- RAG替代方案, 神经认知架构, 多跳推理涌现
## Applications
| Domain | Application | Value Proposition |
|--------|------------|-------------------|
| **Conversational AI** | Persistent memory agents | Continuous learning across sessions without explicit memory databases |
| **Robotics** | Embodied cognitive systems | Real-time experience accumulation with biologically-plausible memory |
| **Education** | Adaptive tutoring systems | Experience-modulated personalization that evolves with learner history |
| **Healthcare** | Clinical decision support | Emergent reasoning from accumulated patient experience patterns |
| **Creative AI** | Associative ideation tools | Non-linear concept association through substrate dynamics |
| **Autonomous Systems** | Self-improving agents | Continuous adaptation without catastrophic forgetting |
## Related Skills
- `snn-performance-analysis` — SNN training methods and performance metrics
- `eeg-hopfield-emotion-energy` — Attractor dynamics and energy landscapes
- `brain-inspired-intelligence-paradigm` — Broader brain-inspired computing concepts
- `quantum-neuromorphic-computing` — Neuromorphic computing foundations
- `sparse-gradient-plasticity` — Plasticity mechanisms and gradient-based learning
- `gtas-generative-spike-train-model` — Spike train modeling techniques
## References
**Primary Source:**
- **Title:** EMBER: Autonomous Cognitive Behaviour from Learned Spiking Neural Network Dynamics in a Hybrid LLM Architecture
- **Author:** William Savage
- **arXiv:** [2604.12167v1](https://arxiv.org/abs/2604.12167)
- **Published:** April 14, 2026
- **Categories:** cs.AI, cs.NE
**Key Contribution:** Introduces a paradigm shift in LLM-memory integration — replacing the dominant RAG pattern with a substrate-centered architecture where the LLM is a replaceable reasoning engine within a persistent SNN associative memory. Demonstrates that autonomous cognitive behaviour and emergent reasoning arise naturally from learned SNN dynamics combined with experience-modulated plasticity.