ALPHA — UNDER ACTIVE DEVELOPMENT

Neuromorphic AI built on Hebbian learning.

A Python library for biologically plausible AI systems. No backpropagation. No gradients. No loss functions. Every weight update is local: dw = f(pre, post). Learns continuously without forgetting. Runs on anything.

import mnemos

brain = mnemos.Brain(n_filters=400)
brain.learn_features(images)
brain.learn_concepts(features, labels)
brain.teach("fire", "produces", "heat")

result = brain.see(image)
# → perception → recognition → reasoning
97.4% Continual learning
0 Backprop operations
5 Hebbian layers
137 Counterfactual cascade

01 — Results

Beats EWC without a single gradient.

Split-MNIST continual learning. 5 tasks, 2 digits each, trained sequentially. No replay. No pretraining. No excess capacity. Purely local Hebbian updates.

Model Accuracy Backprop? Forgetting
Mnemos (ours) 97.4% No ~0 WINNER
Mnemos SMoHE 98.4% No ~0 easy variant
MLP + SGD 67.0% Yes Severe −30.4%
EWC (DeepMind) 65.5% Yes Severe −31.9%

Hebbian Knowledge Recall

Structured knowledge stored in weight matrices through outer-product Hebbian learning. Recall through matrix-vector multiplication.

20/20 top-1 recall accuracy

MNIST Recognition

Real handwritten digits perceived through Hebbian convolutional filters. Multi-prototype recognition bridge with specificity penalty.

73.7% with 200 filters (no backprop)

Emergent Connections

Spreading activation finds connections nobody taught. "Think 2 + 7" → prime emerges as bridge. "Think 0 + 9" → round emerges.

prime, round, digit discovered autonomously

Counterfactual Cascades

"What if the sun disappeared?" Traces cascading consequences through Hebbian weight matrices across 4 levels of depth.

137 consequences from one removal

02 — Architecture

Five layers. All Hebbian.

A closed loop: perception feeds recognition feeds reasoning feeds self-model feeds attention feeds back to perception. Every connection learned through local Hebbian rules.

01
Perception
400 competitive Hebbian convolutional filters with specificity penalty. Same mechanism that achieves 97.4% on Split-MNIST.
HebbianFilters
02
Recognition Bridge
Multi-prototype competitive matching. Each concept stores 3 prototypes to capture variation. Specificity penalty prevents collapse.
PrototypeBridge
03
Reasoning
256-dim sparse Hebbian weight matrices. One matrix per relation type. Outer-product learning, matrix-vector recall, chain reasoning.
HebbianMemory
04
Self-Model
Tracks its own perceptions, confidence, surprises, and knowledge gaps. Reports actual internal state — not generated text.
metacognition
05
Attention
Reasoning feeds back to perception. Thinking about "fire" boosts fire-related filters. The brain sees what it's thinking about.
top-down feedback

03 — Core Mechanism

The specificity penalty.

Three lines of code that solve winner-take-all collapse. The core mechanism of the entire system — it appears in perception, recognition, and every layer that uses competitive matching.

The Problem

In competitive Hebbian learning, filters converge to the global mean of the data. Every filter responds to everything. Nothing specialises. The network collapses.

The Fix

effective_sim = raw_sim − mean_sim − threshold

Subtract the mean similarity across all filters. Filters that respond to everything get penalised. Only filters that respond specifically to certain patterns win. Homeostatic thresholds balance usage across all filters.

Where It Appears

Perception: prevents filter collapse (97.4% accuracy).
Recognition: prevents concept collapse (5/5 correct).
Every competitive layer: same fix, same 3 lines, every time.

One mechanism. Three applications. Biologically plausible — real neurons use homeostatic plasticity for the same purpose.

04 — Capabilities

What the brain can do.

See → Recognise → Reason

A raw 28×28 pixel image enters. Hebbian filters extract features. Prototype bridge recognises the digit. Reasoning fires automatically: "3 is odd, prime, round, looks like 8."

Spreading Activation

Activate two concepts simultaneously and watch what emerges. "Think fire + ice" → heat emerges as the bridge concept after 6 steps of matrix propagation.

Counterfactual Reasoning

"What if the sun disappeared?" The brain traces consequences through its weight matrices: energy stops → heat stops → plants die → oxygen drops → life collapses.

Background Thought

The brain thinks autonomously between interactions. Explores counterfactuals, finds paths between random concepts, discovers which concepts are most critical to the knowledge network.

Goal-Directed Reasoning

"How does the sun lead to food?" Searches through sequences of matrix multiplications to find causal chains. sun → light → plants → food.

Attention Feedback

Thinking about "fire" biases perception toward fire-related patterns. Ambiguous input (50% fire + 50% water) → recognised as fire when primed, water when not.

05 — Get Started

Install in 10 seconds.

Mnemos is a Python package. Only dependency is NumPy. Works on any machine — no GPU required.

$ pip install mnemos

Or from source:

$ git clone https://github.com/theGcmd/mnemos.git
$ cd mnemos
$ pip install -e .
GitHub → Examples

License

Free for research, education, and personal projects.
Commercial use requires a license. Contact for details.

06 — About

My name is Gustav Gausepohl. I'm 14 years old and an independent AI researcher. I built Mnemos from scratch — every mechanism, every experiment, every design decision.

The code was written with Claude (Anthropic) as my programming partner. I focused on the science and architecture; Claude helped implement my ideas in Python. Every result is real. Every idea is mine.

Mnemos is under active development. The core algorithms work. The architecture is proven. But this is alpha software — there are known limitations, the API will change, and there's a lot more to build. I'm building in public because I believe the best way to make something great is to let people use it, break it, and help improve it.

Contact
gustavgausepohl@gmail.com
github.com/theGcmd

Status
◉ Alpha — APIs may change
◉ Core algorithms validated
◉ Open to collaborations
◉ Looking for: hardware partners,
   neuromorphic chip access,
   research collaborators

Built with
◉ Python + NumPy
◉ No frameworks. No pretrained models.
◉ Every mechanism from first principles.