Does clipping, per-channel scaling or quantisation-aware training move the 3-bit cliff of an MLP lane on real digits?
research/chip-digits-qat
MSE-optimal weight clipping lifts the 3-bit-weight digits MLP from 81% to 91% test accuracy at the same MAC-lane hardware and integer-exact; per-channel scales and QAT help at 4 bits (95.7% at W4A4, within 1.1 points of float) but QAT fails at 2 bits.
What it found
Follow-up to chip-digits, whose max-scaled post-training quantisation collapsed at 3-bit weights (81% at W3A4 against 96.8% float). On the same 64-16-10 MLP and five scikit-learn digits splits, four quantisers are compared for W = 2–4, A = 3–5: the baseline max scale; a per-tensor scale chosen to minimise weight MSE (clipping); per-output-channel max scales; and quantisation-aware training (300 full-batch epochs, straight-through estimator). The two per-tensor methods are integer-exact in the same lane specification, so the lane gate counts of chip-digits apply unchanged. At W3A4 the accuracy is 80.7% (baseline), 90.8% (clip), 91.5% (per-channel, float rescale, not an integer lane) and 90.9% (QAT); at W4A4 94.8%, 94.4%, 95.7% and 95.7%; at W2 only clipping gets above 60% and QAT fine-tuning is worse than the baseline at A=3 (28.5% against 32.8%). Limitations: one small network and dataset, five splits (minimum accuracies are in results.txt, spreads of several points at W≤3), QAT hyperparameters untuned, per-channel rescale hardware not built or costed, generic gates not area. All inputs are measured on the dataset; none is assumed.
A figure from its own output
Paper, code and results
More in LLM chip design loops
- What does an all-open RTL flow report for small designs, and can it prove them equivalent?Reproducible open RTL flow (Yosys, Icarus, Verilator): gate count and depth for adders, a multiplier and a FIFO, SAT equivalence of two adders plus a broken-adder control. Gate counts, not silicon.
- Which check catches an RTL bug: lint, random simulation or a formal equivalence proof?What lint, random simulation and a Yosys equivalence proof each catch, on 12 small RTL tasks (companion to
chip-rtl-loop); mutation probe shows 30 of 389 rejected bugs are caught only by the formal proof. Session-written attempts, not an LLM benchmark. - How much does simulation and formal feedback help a proposer repair small Verilog designs?Lint, simulation and formal-equivalence feedback for Verilog repair on nine small tasks; 6/9 pass at round 0 and 9/9 after one round, with the session as proposer (anecdotal, not an LLM benchmark).
- What does a no-model baseline repair when a scripted RTL checker is the only feedback?No-model mutation-repair baseline for a scripted Verilog checker (compile, lint, simulation, SAT miter) on ten small tasks: 9/20 one-fault cases repaired in 60 evaluations; the session agent passed all ten first try, so the feedback loop is unmeasured. Preliminary.
- Does a rewrite proposer beat a parameter sweep on area and depth when every rewrite must be proved equivalent?Equivalence-gated area/depth rewrites of a 16-bit adder and 6x6 multiplier against a no-model parameter sweep; best adder 0.85x the reference cells×depth, tied by the sweep, no multiplier gain (stylised, gate counts).
- How does generic-gate area grow with bit width for adders, shifters, popcount and multipliers?How generic-gate cells and depth scale with bit width for seven arithmetic blocks: adder, comparator and mux are near-linear, the multiplier quadratic (exponent 2.19), and adder depth grows ~2×W (stylised, generic gates).
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.