A shared runtime for networked machine learning

Machine learning that runs outside the data center.

Bytes and Brains is a Rust framework for machine learning that runs across many small machines instead of one big cluster: phones, sensors, robots, lab fleets, peer-to-peer overlays.

You write the whole distributed computation once, as a composition of Modules. A compiler partitions it into per-node programs that run wherever the nodes are. It is early, open source, and being built in public.

What you can build on it

// a thought experiment: a nervous system for machines

A fun example of a workload Bytes and Brains was envisioned around.

concept · not built cloud · system 3 fleet mind · unifies all bots · 0.1 Hz lan hub gossips shared action latents ↔ peers peer robots robot vlm · system 2 sees and reads · 10 Hz camera mic action model · system 1 shared action latents · 120 Hz imu joints latent gossip controller reflex arc · 1 kHz actuators

// in this example: system 1 acts at 120 Hz, system 2 reasons at 10 Hz, system 3 unifies the fleet from the cloud, and action latents gossip over the lan. every arrow is bytes the framework moves for you.

What it is

// the moving parts

The Module

The unit of work. Modules compose into the whole distributed computation, recorded once, instead of hand-writing each node's half of every conversation.

The compiler

Lowers a Module to its own IR, serializable to ONNX, then partitions it into per-node programs: each node gets exactly the piece of the computation it is responsible for.

The engine

A sans-IO engine runs each node's program. It never owns your network or your hardware: you feed it bytes and events, and it tells you what to send.

Roadmap

// what is next
ONNX Runtime backendnear-term
Benchmark harnessnear-term
In-memory simulatornear-term
Kademlia overlaynear-term
Raftnear-term
Gossip learningnear-term
libp2p + HTTP adaptersvision
Python + JS DSL surfacesvision
Privacy primitivesvision

Two tracks: extensions to the framework itself, and protocols built on its primitives. The list keeps growing as the core stabilizes.

v0.3.8

First public release: framework + sans-IO Engine + Wire + role traits + CpuBackend reference.

read the release notes →

From the blog

// latest post

AI, Velocity, and Trust

On AI velocity, losing the plot, and the trust levels I am using to earn back my own codebase.

read the post →

browse all posts →

Building in public.

The library is on crates.io and the design lives in the whitepaper. It is early: 0.3 works, and 0.4 is a rework of the core. If you work on federated learning, gossip protocols, or peer-to-peer systems, reach out.

[email protected]