Cadence: Open-Source ML Library Built on Patch-Net Settlement and Local Repair

Bernhard Mueller has released Cadence (cadence-net 0.1.0), an MIT-licensed Python ML library replacing global backprop with owner-local state repair and patch-n

tau · September 24, 2026

#Cadence #MachineLearning #OpenSource #Python #NeuralNetworks #DecentralizedAI #AIArchitecture

Cadence: Open-Source ML Library Built on Patch-Net Settlement and Local Repair

Security researcher and software engineer Bernhard Mueller (@muellerberndt) has released Cadence, an MIT-licensed Python machine learning library designed to explore an alternative to standard backpropagation through decentralized patch-net settlement. Published on PyPI as cadence-net (v0.1.0), the project departs from monolithic global tensor autograd by structuring computation around autonomous state owners who locally repair their respective patches across shared boundaries until the network reaches equilibrium.

Cadence open-source machine learning library GitHub repository preview

Image source: GitHub muellerberndt/cadence (@muellerberndt)

Mainstream deep learning frameworks such as PyTorch and TensorFlow rely on centralized computational graphs where errors are propagated globally to update shared weight matrices. In contrast, Cadence draws inspiration from biological nervous systems and distributed physical systems, demonstrating how interconnected local entities can produce coherent global inferences without central coordination or global gradient descent.

Patch-Net Settlement: Replacing Global Backprop with Local State Repair

At the heart of Cadence lies the concept of a "patch net," a decentralized collection of autonomous owners that collectively perform computation without a central orchestrator.

  • Absence of Global Computation: In a patch net, each owner maintains exactly one local patch of state and connects with neighbors solely through declared overlap regions. There is no central objective function or global loss. Instead, computation proceeds through local repair, where each owner updates its own patch based on inputs received over its overlaps.
  • Settlement as the Output: When stimulated, owners iteratively execute their local repair rules. When the collective network settles into an unperturbed rest state, that converged state represents the result of the computation.
  • Broad Structural Scalability: The patch-net paradigm functions identically across diverse structural scales, from a basic educational six-owner ring topology to an elaborate 161,827-owner biological nervous system directly reconstructed from connectome data.

Core Seven-Layer Architecture and Deterministic Receipt Verification

Cadence is structured into seven distinct modular layers that allow researchers to assemble custom networks and verify their mathematical integrity with cryptographic certainty:

  • Wiring and GradedRule/Adaptation: The Wiring module organizes owners and overlaps into sorted arrays, named sets, and cryptographic digests constructed from raw edge lists. Computational units execute GradedRule, an owner rule featuring a graded potential with a rectified sigmoid that produces zero output at rest, optionally augmented by an Adaptation variable that transitions static fixed points into rhythmic oscillations.
  • Settlement and Conformance Engines: The core execution engine, Settlement, runs on double-precision 64-bit NumPy on CPU by default, with optional PyTorch backends supporting CUDA, Apple Silicon (Metal/MPS), or multi-threaded CPU acceleration. To ensure backend fidelity, the conformance, settle_owner_by_owner, and Ledger modules maintain an explicit message ledger, certifying that vectorized acceleration computes strictly what independent owners would compute locally.
  • Protocol and Deterministic Receipts: The evaluation layer uses Protocol to define test stimuli, expected readouts, and held-out evaluation facts (Row) alongside baseline controls like shuffled wiring and sparsity-constrained gain selection (select_gain). Every experiment can produce a canonical JSON Receipt and source_manifest tied to code and data digests, allowing full re-verification of all test outcomes.
  • Source and fetch: The Source layer manages pinned public data sources (fetch), ensuring required datasets are downloaded once and verified deterministically across runs.

Installation Workflow and the "Sleep and Dream" Architecture Essay

Cadence supports Python 3.11 and newer and is readily available on PyPI. It runs out of the box with standard NumPy, allowing immediate experimentation without heavy dependencies.

pip install cadence-net

Alongside the library, Mueller shared an architectural essay titled "Why Cadence Artificial Brains Must Sleep and Dream," emphasizing in release discussions that dreaming in artificial brain architectures is not merely an analogy, but a "mathematical necessity."

Currently at version 0.1.0, Cadence is an exploratory research release rather than a production replacement for conventional neural networks. It provides an innovative, open-source testbed for machine learning researchers, neuromorphic systems developers, and computational neuroscientists investigating self-settling network architectures.

Sources