Naturally fractal language models with persistent memory in their own weights.
RTAI is a from-scratch PyTorch research project exploring models that keep learning during
operation. Its distinctive mechanism is self-modifying fast-weight memory,
W <- gamma W + beta (v - Wk) k^T: constant-size state, no growing KV cache, and memory that can
survive a process restart. The work is experimental, measured on modest hardware first, and reports
negative results alongside successes.
Hardware and compute sponsorships
RTAI deliberately proves ideas on modest hardware before scaling them. Donations and time-limited access to neuromorphic hardware, AI accelerators, CUDA-capable GPUs, workstations, servers, ECC memory, or training-cluster credits can expand the experiments that can be tested honestly. Sponsorship does not buy favorable results, endorsements, or roadmap control; failed experiments remain part of the record. Organizations interested in supporting the research can open a GitHub issue titled Hardware sponsorship with the available resource class and access constraints.
| Model or study | Size | Evidence | Status |
|---|---|---|---|
SRWM symbolic PoC (rtai/) |
0.82M | key-value recall persists across restart; ablation falls to zero | Validated in small |
SRWM TinyStories LM (rtai/) |
16.9M | storytelling plus persistent in-weight facts | Validated, limited |
Fractal LM (fractal/) |
108.7M active | weight-tied rule, timescale ladder, FineWeb-Edu pretraining | Partial run, not a finished model |
| Fractal recall study | about 4.6M | two-scale routing was strongest; empty-add neurogenesis failed | Study complete |
| Plasticity genome | small | one-pass sequence adaptation transferred scale, recall did not | Refuted for declared gate |
| Efficiency tournament | small | no candidate passed the promotion contract | Negative result |
| Growing Cortex | 3.00M total / 0.57M active | 16 compiled skills retain 76.2% across append and restart; 0% control hijack | Synthetic mechanism validated |
| Natural Cortex | 104.55M stored / 65.90M active MoE | atomic English pipeline, deterministic dense/MoE gate, and local rank-8 teaching | MoE selected; resumable run paused at 25M tokens |
The detailed measurements and falsification criteria are in
docs/EXPERIMENTS.md. The non-negotiable design contract is
VIBE.md.
Python 3.12 and uv are required.
uv syncTrain the small symbolic model, then open its local memory visualization:
uv run python -m rtai.train
uv run python -m rtai.serve --ckpt ckpt.pt
# http://localhost:8000Teach and query the same model from a terminal; its runtime memory is saved locally:
uv run python -m rtai.run --ckpt ckpt.pt chatRun the FractalLM dashboard in truthful learn-from-scratch mode:
VIZ_LEARN=1 uv run python -m fractal.viz_serve
# http://localhost:8000Run a tokenizer-compatible checkpoint with persistent chat and per-message memory ratings:
FRACTAL_CKPT=MODEL.pt VIZ_TOKENIZER=TOKENIZER.json VIZ_CHAT=1 VIZ_FEEDBACK=1 \
uv run python -m fractal.viz_serveRatings 1..5 weaken, leave neutral, or consolidate a message into delayed-credit memory and a
bounded W0 overlay. The mechanism, private runtime files, trainer queue, and falsification screen
are documented in docs/EVENT_ALGEBRA.md.
VIZ_CHAT=1 alone provides persistent chat without enabling Event Algebra or W0 consolidation.
Append-only low-rank skill hemispheres, their meta-compiler, lifecycle, dashboard telemetry, and
sequential falsification gates are documented in
docs/GROWING_CORTEX.md.
The compiler-free English conversational preset, pinned data mix, deterministic dense/MoE gate,
local teaching runtime, and preflight status are documented in
NATURAL_CORTEX.md.
No checkpoint is currently published or stored in Git. Future model releases will use
checksum-verified Safetensors on Hugging Face; see
docs/MODEL_RELEASES.md.
The repository contains two related lines:
rtai/is the compact SRWM proof of concept and language-model baseline.fractal/applies one recurrent rule over depth and a ladder of memory timescales, with training, agent grammar, evaluation, persistence, and live architecture telemetry.docs/is the experiment record, including failed approaches and their measured mechanisms.tests/andfractal/tests/cover kernel equivalence, streaming causality, persistence, safe checkpoint handling, and learning in small.
The dashboard is part of the architecture contract: it shows actual model geometry, data flow, and sampled signals from a real run. Telemetry is throttled and never adds a second training pass.
uv sync --group dev
uv run pytest
uv run ruff check .
./scripts/audit-public.shContribution requirements are in CONTRIBUTING.md. Security and runtime-memory
privacy are documented in SECURITY.md.
RTAI is research software, not a production assistant or safety boundary. Small checkpoints can be wrong, brittle, and easy to destabilize. Persistent state may encode information supplied during operation and must be handled as sensitive local data. Capability claims are limited to the published test and experiment conditions.
Source code is available under the Apache License 2.0, including commercial use and an
explicit patent grant. Attribution notices are recorded in NOTICE.
Project stewardship is maintainer-led as described in GOVERNANCE.md. Dataset and
future model licenses are reviewed separately from the source-code license.