Skip to main content

Cadence: a mesh of stateful neural patches, feedback loops and synaptic signals

Cadence

Website · Cadence page · PyPI · Documentation

An experimental neural library for learning through local overlap repair and equilibrium detuning.

Cadence explores an animal-inspired hypothesis: the same network that interprets an observation should carry context, change its learned relationships through experience, and explore possible continuations. It does not claim to reproduce an animal or human brain.

Under active development. Pin a release or exact commit for reproducible work. The revised PatchNet interface is included in version 0.9.0; earlier applications use other library compositions and their results do not validate it automatically.

Start with PatchNet

PatchNet is the common starting point for new experiments. It uses the existing nonlinear neural dynamics and local free/nudged learning rule, with a fully reciprocal graph by default. Its observer-like patches have bounded activity, declared ports, local readback and feedback/repair; experiments expose their observations, residuals and learned changes through reproducible evidence.

  • Current context lives in neural activity. Activity continues between observations. Optional temporal overlap holds each solve against the previous free activity. Whether a particular graph retains a cue through a delay must be measured; a converged network can also forget its previous input.
  • Acquired relationships live in continuous synapses and biases. Resetting activity leaves learned parameters intact. No external fact store or replay buffer is required by this interface. Interference during further learning remains a separate test.
  • Real observations detune the network. Continuous targets nudge only declared observed ports. Each synapse changes from its endpoints' free/nudged activity contrast. The implementation does not construct a backward graph.
  • Convergence is checked. Every required phase must satisfy the neural equations within the declared residual tolerance before learning commits. A capped solve is reported as unfinished. A small residual does not establish a unique, stable or correct answer.
  • Imagined continuations are isolated. Branches use the same learned net without changing live activity, parameters or evidence bookkeeping. Branch isolation is implemented; useful planning and musical improvisation need empirical validation.
  • A complete checkpoint resumes the learner. It includes parameters, optimizer state, current activity and the optional bounded source-ID window. Repeated IDs are suppressed within that window; IDs do not prove that two environmental reports are independent.

Follow the PatchNet guide for the running example, memory semantics, continuous targets and rehearsal. The earlier Brain, Learner, GenericBrain, Records and circuit APIs remain available for existing applications. Their separate associative memories are optional compositions, not required components of PatchNet.

The research target is fewer local mechanisms supporting acquisition, selective forgetting, retention and correction together. Learned importance, robust lifelong memory, autonomous specialization and animal-level capability remain open. In particular, the revised core does not freeze each weight into a binary state: that candidate prevented compatible learning through shared connections.

Install

Python 3.11+, with NumPy as the only required dependency:

python -m venv .venv
source .venv/bin/activate
python -m pip install cadence-net==0.9.0

For development from this checkout, use python -m pip install -e .. On Windows activate with .venv\Scripts\Activate.ps1. Optional backends support Numba, PyTorch and MLX.

Reference

Experience · Quickstart · Continuous interaction · Records · Write a cortex · Compose a brain · Evolve a brain · Local learning · Reward · API · All docs · Lean proofs

Check equation residuals before claiming equilibrium. Measure task quality and learning cost; local updates alone guarantee neither capability nor speed. Concepts and limits. MIT licensed.

Release files for cadence-net 0.9.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cadence-net 0.9.0
File Size Uploaded
cadence_net-0.9.0.tar.gz 1.5 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for cadence-net 0.9.0
File Interpreter ABI Platform
cadence_net-0.9.0-py3-none-any.whl Python 3 none any Details

Total release size: 1.7 MB

Release files / cadence_net-0.9.0.tar.gz

Download URL cadence_net-0.9.0.tar.gz
Size 1.5 MB
Tags Source
SHA-256 checksum
How to use checksums
dbc57535f3079a5ef84625656e31cc3e658a4ee5afc6b838d438858dedfd43bd
BLAKE2b-256 checksum
How to use checksums
bf5aec85c4ffbed85a03f7ba5409740d3d9c39268f773f4dd70ff09c0b4fbbd9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.0

Release files / cadence_net-0.9.0-py3-none-any.whl

Download URL cadence_net-0.9.0-py3-none-any.whl
Size 159.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fd41844286dfd0faa3c975829695844751f961c0a980dba892cd61d5907bbb47
BLAKE2b-256 checksum
How to use checksums
94ddc052a0222ce9489edb304a9ba93f698073fde16dce578b16091dafe2f96f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.0

Release history Release notifications | RSS feed

0.15.0

2 release files

0.14.0

2 release files

0.13.0

2 release files

0.12.0

2 release files

0.11.0

2 release files

0.10.0

2 release files

This release

0.9.0 This release

2 release files

0.8.1

2 release files

0.8.0

2 release files

0.7.1

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page