Program-as-Weights: A Programming Paradigm for Fuzzy Functions
Wentao Zhang, Liliana Hotsko, Woojeong Kim, Pengyu Nie, Stuart Shieber, Yuntian Deng
arXiv:2607.02512 · 106▲ · cs.LG, cs.AI, cs.CL
View on arXiv →Premium readers get an interactive explainer for this paper — a figure you can poke at, not just read.
What it is
The paper introduces Program-as-Weights (PAW), a system that compiles a natural-language description of a fuzzy task (things like log alerting, JSON repair, or intent classification that resist clean rule-based code) into a small neural artifact. A 4B compiler reads the spec plus an auto-generated pseudo-program of paraphrase-and-examples, then emits a per-function LoRA adapter that gets hot-attached to a frozen 0.6B interpreter model, which runs the task locally.
Why it matters
Instead of calling a remote LLM API on every input (with the recurring cost, latency, and silent model-drift that brings), you compile the function once in the cloud and then run it offline on a small device-resident model. The compiled program is a single ~23MB file you can version-control, ship in a package, and call with a two-line API, with no network in the request path after the first download.
Practical takeaway
Watch for tooling that lets you replace scattered gpt() calls in a codebase with compiled, versioned local functions. The authors released code, a 10M-example dataset (FuzzyBench), and a demo; quantized, the interpreter runs at ~30 tokens/s on a MacBook M3 from a ~430MB shared base plus a 23MB per-function adapter, and a GPT-2 path runs client-side in the browser.
Key result
On FuzzyBench (exact-match on a verified test set of held-out fuzzy-task specs), a 0.6B interpreter running PAW programs scored 73.78% versus 68.70% for directly prompting Qwen3-32B, at roughly 50x less inference memory (~1.2GB vs ~60GB). Caveats: both training and test data are synthetic (generated by gpt-5.2, which itself ceilings at 96%), all tasks are single-step, and on some non-benchmark datasets in the same table (SMS, IMDB) PAW trails the larger prompted baselines.
Subscribe
Get the next issue.
Free. One email a week. Unsubscribe any time: no account, no dark patterns.