← All projectsGitHub
LLM chip design loops

How few bits can a MAC lane use to classify real handwritten digits before accuracy falls off a cliff?

research/chip-digits

Weight and activation bit-width sweep of a 64-16-10 quantised MLP on the scikit-learn digits data (5 splits), with the MAC lane's gate count from Yosys and its RTL checked against NumPy: 4-bit weights and activations lose about 2 points of accuracy, 5 and 5 about 0.5, below 3 bits it collapses.

6 tests

What it found

A 64-16-10 ReLU MLP trained on the real scikit-learn digits images (1797 8×8 scans, 70/30 splits, 5 seeds; float test accuracy 96.8%), quantised after training to W-bit signed weights and A-bit unsigned activations (W, A = 2–8, 49 configurations). One multiply-accumulate lane is written in Verilog, simulated in Icarus Verilog and matched to NumPy on 64 real layer-1 dot products per configuration (all 49 agree), and scored with Yosys and ABC in generic gates. Accuracy holds to 96.3% at W5A5 (268 cells, −0.5 points), 94.8% at W4A4 (189 cells, −2.0 points) and collapses at 3 bits or fewer (7978–82% at W3, 31–34% at W2ndash;82% at W3 with 3-bit or wider activations, 3178–82% at W3, 31–34% at W2ndash;34% at W2) or at 2-bit activations; widening beyond 6 bits buys nothing. Lane cells are not monotonic in width (ABC noise). Limitations: one small network and dataset, symmetric max-scaled quantisation with no quantisation-aware training (so the 2–3 bit collapse is a property of that scheme), generic-gate counts not square microns, one lane rather than a full accelerator, no clock, power or layout.

A figure from its own output

Figure produced by research/chip-digits: accuracy_vs_cells
chip-digits/experiments/accuracy_vs_cells.svg, written by the project's own experiment code.

Paper, code and results

More in LLM chip design loops

All 40 LLM chip design loops projects →

Other research topics

Proper scoring & elicitation28Effort & peer prediction9Verification games & slashing19Detection & tolerances14Markets as routers13Prediction-market design9Paying contributors8Decentralised training systems23Digital twins & sim-to-real164LLM chip design loops40Robot manufacturing loops53Ambient AI assistant46Self-replicating manufacturing34Simulation-first design64Engineered clothing45Task-specific AI accelerators40Algorithmic chip-design loops42Open-source purpose-built robots44The software-engineering loop43Adversarial human imitation41Open-source residential construction41Autonomous multi-angle capture34Sensing, imaging and 3D31Energy supply and dense energy storage39Robot societies among people31Agentic co-design of low-cost robots27Laundry-hanging robots25Machine learning on qualitative data23Robots on the building site27Civilizations & group psychology1History & human sciences1

Produced with AI assistance (Claude). Results are from the code in this repository and are simulated or stylised unless the abstract says otherwise; nothing here implies affiliation with or endorsement by any lab, researcher or company cited. MIT licensed.