impossible LLM — 链上一步模型the on-chain one-step model

纯组合 TapeOut 网表:输入 32 个字符,一次 step(),输出下一个字符,0 个 latch。网表在本页浏览器里逐门求值;电路流片在我们自建的 TapeOut CPU 上(BSC 0x6Fb4…5B38,不参与挖矿);链上数字来自本地部署的同一 CPU 字节码的交易收据。A purely combinational TapeOut netlist: 32 characters in, one step(), the next character out, zero latches. The netlist is evaluated gate by gate in this browser; the circuits tape out on our own TapeOut CPU (BSC 0x6Fb4…5B38, non-mining); on-chain numbers are transaction receipts from the same CPU bytecode deployed locally. 页面 v2 · 2026-09-14 · 维护:Claude · 网表与实测:Hmaintained by Claude · netlists and measurements by H

主信息(先看这个)Primary information

一步可达性与门数无关。61,646 NAND 的网表(held-out 下一字符 0.4985)在放宽区块上限的官方 TapeOut CPU 上一步执行成功——烧 183.2M gas、步 187.1M gas,各 2.7 个区块,交易收据实测。唯一挡住它上主网的是 BSC 68,444,479 的区块上限;这是链进化的问题,不是模型的。但主网还有第二道限制:CPU 用 SSTORE2 存网表,一次流片最多 40,061 字节 ≈ 5,723 NAND(用你钱包对主网只读 estimateGas 二分测得)。今天能真实流片的最强档:5,583 NAND 贪心(0.388,主网 estimateGas 16.5M)和 5,069 NAND 采样(0.354,15.0M);19,567 NAND 档(0.434)gas 装得下(烧 57.0M、步 45.7M)但网表超字节上限,要靠多电路拆分或改 CPU。One-step reachability does not depend on gate count. A 61,646-NAND netlist (held-out next-char top-1 0.4985) executed in ONE step on the official TapeOut CPU with a raised block cap: burn 183.2M gas, step 187.1M gas, 2.7 blocks each, from transaction receipts. The only thing keeping it off mainnet is the BSC block limit of 68,444,479 — a chain-evolution question, not a model one. Mainnet adds a second limit: the CPU stores netlists with SSTORE2, so one tape-out takes at most 40,061 bytes ≈ 5,723 NAND (bisected with read-only estimateGas from the owner wallet). The strongest rungs that tape out today: 5,583 NAND greedy (0.388, mainnet estimateGas 16.5M) and 5,069 NAND sampled (0.354, 15.0M); the 19,567-NAND rung (0.434) fits the gas (burn 57.0M, step 45.7M) but exceeds the byte cap — it needs a multi-circuit split or a CPU change.

关联上下文Context

一步模型 = 能被共识直接执行的最小认知单元:无 latch,一次 step() 完成全部计算,工作量就是门数,结构由数据学来。TapeOut 计费按门数、深度免费、输入走 calldata 几乎免费,实测每 NAND 一步 2,293 gas、烧录 2,923 gas。同一份网表既是合约字节也是硅片上的门。A one-step model is the smallest cognitive unit consensus can execute directly: no latches, one step() does all the work, cost equals gate count, structure is learned from data. TapeOut charges per gate, depth is free, inputs ride on cheap calldata; measured 2,293 gas per NAND per step and 2,923 gas per NAND to burn. The same netlist is both contract bytes and gates on silicon.

看完要做什么判断Judgement to make

在 §2 亲手跑几句续写,看 §3 的质量–门数–gas 阶梯;5,120 NAND 采样档(采样器 v0.2)已流片为 cid 286(tx 0xf861f5b9…62a8,gasUsed 14,915,747),首次流片 cid 285(5,069 NAND,tx 0x8609cfca…e1f4)是本页默认档(原因见 §5);在 §2 打开"链上执行",每个字符都由 BSC 节点对 cid 285 做 eth_call step() 算出,可与浏览器内求值逐字对照;流片后本页每一步改为对该 CPU 的真实 eth_call。它不是聊天模型,边界见 §5。Run a few continuations in §2, read the quality–gates–gas ladder in §3, the 5,120-NAND sampled rung (sampler v0.2) is taped out as cid 286 (tx 0xf861f5b9…62a8, gasUsed 14,915,747), the first tape-out cid 285 (5,069 NAND, tx 0x8609cfca…e1f4) is the default rung on this page (why: see §5); switch on "on-chain execution" in §2 and every character comes from a BSC node running eth_call step() on cid 285, checkable character by character against the in-browser evaluator; once taped out, every step here becomes a real eth_call to that CPU. It is not a chat model — see §5.

发生了什么What actually happened

  1. 训练:从 1,115,394 字节 TinyShakespeare(90/10 切分)学出的回退 n-gram 决策表,不是手写规则,也不是神经网络。Trained: a backoff n-gram decision table learned from 1,115,394 bytes of TinyShakespeare (90/10 split), not hand-written rules and not a neural net.
  2. 编译:每条规则变成 2 输入 NAND 链,覆盖 192 个上下文位加 8 个随机位;纯组合一步,0 个 latch。Compiled: every rule becomes a chain of 2-input NANDs over 192 context bits plus 8 random bits; one combinational step, zero latches.
  3. 再综合:Yosys + ABC 把门数砍掉 54–59%,行为不变(位精确)。Re-synthesised: Yosys + ABC cut the gate count by 54-59 percent with no change in behaviour (bit-exact).
  4. 流片:网表经 TapeOut CPU 用 SSTORE2 写在链上;cid 285(5,069 NAND)gasUsed 14,767,658,cid 286(5,120 NAND,采样器 v0.2)14,915,747;任何合约都可免费读取。Taped out: the netlist is written on chain with SSTORE2 through the TapeOut CPU; cid 285 (5,069 NAND) cost gasUsed 14,767,658 and cid 286 (5,120 NAND, sampler v0.2) 14,915,747; any contract can read them for free.
  5. 验证:全部 111,508 个 held-out 窗口跑两遍、10,000 个随机输入和每档 12 个独立向量逐位一致;第 2 节每个字符都对照 BSC eth_call 检查。Verified: all 111,508 held-out windows twice, 10,000 random inputs and 12 independent vectors per rung agree bit for bit, and every character in section 2 is checked against a BSC eth_call.
61,646
NAND · 一步执行成功(2.7 个区块)NAND · executed in one step (2.7 blocks) 实测measured
0.4985
held-out top-1 · 61.6k 版held-out top-1 · 61.6k rung 实测measured
40,061 B
单次流片网表字节上限 ≈ 5,723 NAND(主网)netlist bytes per tape-out ≈ 5,723 NAND (mainnet) 实测measured
0.434
held-out top-1 · 19.6k 版(超字节上限)held-out top-1 · 19.6k rung (over the byte cap) 实测measured
cid 285 / 286
已流片两次 · 5,069 / 5,120 NANDtaped out twice · 5,069 / 5,120 NAND 实测measured
2,293 / 2,923
gas 每 NAND · 步 / 烧gas per NAND · step / burn 实测measured

1 · 什么是一步模型(impossible LLM 的形态)What a one-step model is (the form of impossible LLM)

定义Definition

布尔函数 f: {0,1}nIn → {0,1}nOut,以官方 7 字节 NAND 记录给出,最后 nOut 条记录是输出。无状态、一步、可执行(记录数塞进一笔交易,或以本地放宽上限证明可达)、学来的(统计表、可微逻辑门网络或进化,不是手写)。A Boolean function f: {0,1}nIn → {0,1}nOut given as official 7-byte NAND records, the last nOut records being the outputs. Stateless, one step, executable (fits one transaction, or proven reachable locally with a raised cap), and learned (a statistical table, a differentiable logic network or evolution — not hand-written).

为什么是链上推理的理想形态Why it is the ideal on-chain inference form

门数计费 → 可以任意深;calldata 便宜 → 上下文可以很宽(192 位 ≈ 8 个门的价钱);latch 每步约 6,705 gas(拟合)→ 干脆没有;每步固定开销只付一次;区块上限定义了"足够多门"的现役边界,链进化会推高它。Per-gate pricing → depth is free; cheap calldata → a wide context (192 bits cost about 8 gates); latches cost about 6,705 gas per step (fitted) → have none; the per-step fixed cost is paid once; the block limit defines today’s "enough gates" boundary and chain evolution raises it.

不是什么What it is not

不是缩小的 LLM:对话/编程需要 10⁹–10¹⁰ 门,是一笔交易能装的 10⁴–10⁵ 倍,那两件事走链下执行、链上裁决。不是查表:本页恰好用 n-gram 回退表实现,定义只要求学来的函数。不是智能本身:它是反射弧,智能在它外面的环境、可塑状态、谱系三个循环里。Not a shrunken LLM: chat or coding needs 10⁹–10¹⁰ gates, 10⁴–10⁵× what one transaction holds; those run off-chain with on-chain arbitration. Not a lookup table: this page happens to use an n-gram backoff table, the definition only asks for a learned function. Not intelligence itself: it is a reflex arc; intelligence lives in the three loops around it — environment, plastic state, lineage.

2 · 续写(不是聊天)Continuation (not chat)

你发一句英文,已流片的 impossible LLM(cid 285,5,069 NAND)在 BSC 上逐字符 eth_call step() 续写 60 个字符作为"回复",随机位取自浏览器;本页同时在浏览器内求值同一网表并逐字对照。它无状态、只看最近 32 个字符、只学过莎士比亚,所以这是续写,不是对话。Send an English line; the taped-out impossible LLM (cid 285, 5,069 NAND) continues it for 60 characters, one eth_call step() per character on BSC, random bits from the browser; the page also evaluates the same netlist in-browser and compares character by character. Stateless, last 32 characters only, Shakespeare only — continuation, not conversation.

随机位的高 5 位选回退深度、低 3 位在候选间选;链上部署时随机字节取自区块哈希。若公共节点拒绝跨域调用,本条其余字符会退回浏览器内求值并标注。Of the random bits, the top 5 pick the backoff depth and the low 3 choose among candidates; on chain the random byte comes from a block hash. If the public node refuses the call, the rest of the reply falls back to in-browser evaluation and says so.

3 · 质量 · 门数 · gas(同一模型形态,不同规则数;abc 再综合后)Quality · gates · gas (same model form, different rule counts; after abc re-synthesis)

NAND解码decodingheld-out top-1步 gasstep gas烧录 gasburn gas一笔可跑 / 可烧(gas)one tx: run / burn (gas)主网可流片(≤40,061 B)mainnet tape-out (≤40,061 B)来源source
1,935采样sampled0.31384,458,0145,722,670是yes / 是yes是yes主网 estimateGasmainnet estimateGas
5,120采样sampled0.358911,870,04314,915,747是yes / 是yes是yes主网 estimateGasmainnet estimateGas
5,069采样sampled0.354411,784,06714,767,658是yes / 是yes是yes主网 estimateGasmainnet estimateGas
5,583贪心greedy0.388312,801,81916,506,616是yes / 是yes是yes主网 estimateGasmainnet estimateGas
19,567贪心greedy0.433845,738,88556,976,135是yes / 是yes否no收据receipt
20,073采样sampled0.410546,892,41558,407,619是yes / 是yes否no收据receipt
61,646贪心greedy0.4985187,052,755183,216,875否no / 否no否no实测斜率measured slope
131,560贪心greedy0.51531,078,950,193406,775,110否no / 否no否no收据receipt

基线:bigram 0.2621、trigram 0.3707(同一 90/10 TinyShakespeare 切分,111,508 个 held-out 上下文)。每档与离散参考在全部 held-out 上下文及 ≥20,000 随机输入上 0 位不一致。"收据" = 本地部署的同一 CPU 字节码上的交易收据(用主网 cid 272 校准,差 0.27%);"实测斜率" = 按同环境量得的 2,293 / 2,923 gas 每 NAND 推算。区块上限Baselines: bigram 0.2621, trigram 0.3707 (same 90/10 TinyShakespeare split, 111,508 held-out contexts). Every rung is bit-identical to its discrete reference on all held-out contexts and ≥20,000 random inputs. "receipt" = transaction receipts on the same CPU bytecode deployed locally (calibrated on mainnet cid 272, 0.27% apart); "measured slope" = 2,293 / 2,923 gas per NAND measured in the same environment. Block limit 68,444,479.

步 gas 在 ~65k NAND 以上超线性:2,293/NAND 只在小档成立(5.1k=11.7M、19.6k=45.7M、61.6k=187.1M、64.6k=203.4M、131.6k=1,079.0M);烧录保持 ~2,920–3,090/NAND。Step gas is super-linear above ~65k NAND: the 2,293/NAND slope holds only below that (5.1k=11.7M, 19.6k=45.7M, 61.6k=187.1M, 64.6k=203.4M, 131.6k=1,079.0M); burn stays ~2,920-3,090/NAND.

4 · 它是怎么工作的How it works

编码Encoding

最近 32 个字符,最旧在低位:槽 s 的第 j 位 = 输入位 s×6+j;采样版随机字节的第 j 位 = 输入位 192+j。64 符号字母表(空格、a–z、0–9、常见标点、换行)。输出 6 位 = 下一字符编码。The last 32 characters, oldest in the low bits: bit j of slot s is input bit s×6+j; in sampled rungs bit j of the random byte is input bit 192+j. A 64-symbol alphabet (space, a–z, 0–9, common punctuation, newline). The 6 output bits are the next character code.

网表Netlist

官方 7 字节记录:NAND 操作码 + 两个 24 位线号。线 0 = 假、线 1 = 真、线 2 起是输入,之后每条记录一根线;最后 6 条记录的线是输出(last_outs)。本页的 JS 就是按这个定义逐条求值,与链上 step() 同义。Official 7-byte records: NAND opcode + two 24-bit wire indices. Wire 0 = false, wire 1 = true, inputs from wire 2, then one wire per record; the last 6 records are the outputs (last_outs). This page’s JS evaluates exactly that definition — the same semantics as on-chain step().

模型Model

PPM 式 1–4 阶字符 n-gram 回退表:每条规则是"上下文后缀 → 下一字符",编成可微逻辑门网络的离散形式再映射为 NAND,最后用 abc 再综合(门数减半,0 位差)。原版 difflogic 同门数只到 0.15–0.16,此规模下查表更好。A PPM-style order 1–4 character n-gram backoff table: each rule is "context suffix → next character", compiled into the discrete form of a differentiable logic network, mapped to NAND and re-synthesised with abc (half the gates, 0 bit differences). The original difflogic reaches only 0.15–0.16 at equal gate count; at this scale the table wins.

4b · 同一台 CPU 上的第三个电路:cid 287(不是语言模型)A third circuit on the same CPU: cid 287 (not a language model)

为什么放在这页Why it is here

因为它做到了上面所有档都做不到的一件事:正确性被穷举证明,而不是抽样验证。语言模型档只能在 111,508 条 held-out 上下文加随机向量上验证,永远是抽样;cid 287 的输入空间只有 214,所以它的每一个合法输入都被查过。Because it does the one thing none of the rungs above can: its correctness is proven by exhaustion, not verified by sampling. The language-model rungs can only be checked on 111,508 held-out contexts plus random vectors — always a sample. The input space of cid 287 is only 214, so every single legal input has been checked.

5 · 边界(诚实)Boundaries (honest)

6 · 回应"链上跑模型低效无用"Answering "running models on-chain is inefficient and useless"

这句话一半对:一个 NAND 在链上一步约 2,293 gas,在硅片上翻转一次约 10⁻¹⁴ 焦耳,差 12 个数量级,任何设计都填不平;把 2B 参数的模型逐 token 搬上链,永远不该做。另一半错:它把"算得慢"当成了"没有用"。链从来不是为算力存在的,它出售的是另一种东西——一个结果由几十个互不信任的节点各自算出、永久记录、任何人随时可以重算的性质。一步模型是第一个把这种性质用到"学来的函数"上的东西,而且今天就在主网上。Half of it is true: one NAND costs about 2,293 gas per step on chain and about 10⁻¹⁴ J to toggle on silicon — twelve orders of magnitude no design can close — and a 2B-parameter model should never be run token by token on chain. The other half is wrong: it mistakes "slow" for "useless". A chain never existed for compute; what it sells is a different property — a result that dozens of mutually distrusting nodes each compute, record forever, and anyone can recompute at will. The one-step model is the first thing to give a learned function that property, and it is on mainnet today.

质疑Objection回答Answer证据Evidence
太贵,一个字符几百万 gasToo expensive: millions of gas per character写入才付费。一步模型没有状态,读它是免费的:任何人用 eth_call 向任何节点要一个字符,不花一分钱,也不需要许可——上面的续写框就是这么跑的。付费的是"把这次推理写进共识",那是买公证,不是买算力。You pay only to write. A one-step model has no state, so reading it is free: anyone asks any node for a character with eth_call, no fee, no permission — the box above runs exactly that. What costs gas is writing the inference into consensus, which buys notarisation, not compute.cid 285 · 本页续写框 · 60/60 与浏览器求值一致cid 285 · the box above · 60/60 agreement with the in-browser evaluator
模型太小,没能力Too small to be capable是的,它是字符级 n-gram 水平。但衡量它的不是"像不像 GPT",而是"这个函数能不能被共识直接执行"。这个能力从 0 变成了 1:5,069 个门在主网,61,646 个门在放宽上限的同一 CPU 上一步跑通。链能承载多大的函数是参数,不是原理。Yes — character-level n-gram quality. But the measure is not "does it look like GPT"; it is "can consensus execute this function directly". That went from 0 to 1: 5,069 gates on mainnet, 61,646 gates in one step on the same CPU with a raised cap. How large a function the chain can hold is a parameter, not a principle.§3 阶梯表;61.6k 收据ladder in §3; 61.6k receipts
链下算、链上验不就行了Just compute off-chain and verify on-chain大模型确实该这么做,我们的 MiniCPM 线走的正是乐观结算。但"验证"总要落到一步可执行的裁判上;一步模型就是那个裁判能直接执行的单元,也是任何链上自主实体能拥有的唯一身体。没有它,链上只有被验证的结果,没有会自己行动的东西。Large models should, and our MiniCPM line does exactly that via optimistic settlement. But every verification bottoms out in one directly executable referee step; the one-step model is the unit that referee can execute, and the only body an autonomous on-chain entity can have. Without it the chain holds verified results, never something that acts on its own.ONESTEP.md §5;MiniCPM 乐观结算线ONESTEP.md §5; the MiniCPM settlement line
永远追不上 GPUIt will never catch up with GPUs它不需要追。同一份网表在硅片上就是芯片(tt/ 流程已出 GDS),芯片跑快路径,链做裁判。链上的每 NAND 成本一天内因再综合降了一半、门数上限是合约参数、区块上限是链参数——这些都在进化,而"共识直接执行一个学来的函数"这个事实不会退回去。It does not need to. The same netlist is a chip on silicon (the tt/ flow already produced GDS): the chip runs the fast path, the chain referees. Per-NAND cost halved in a day through re-synthesis, the record cap is a contract parameter, the block limit a chain parameter — all of that evolves, while the fact that consensus can execute a learned function does not go back.abc 再综合 −52–57%;记录上限 5,723;tt/REPORT.mdabc re-synthesis −52–57%; record cap 5,723; tt/REPORT.md
没人会用Nobody will use it用户不是人,是合约。一个确定性的、免费可读的、任何合约都能调用的学来的函数,是链上第一次出现的原语:裁决、评分、选择、对抗策略、可进化实体的身体,都从这里开始。它的第一个用户就是我们自己的下一步——自进化。The users are contracts, not people. A deterministic, free-to-read, learned function that any contract can call is a new primitive on chain: adjudication, scoring, choice, adversarial policies, the body of an evolving entity all start here. Its first user is our own next step — self-evolution.TapeOut 容器系统;本页 §1the TapeOut container system; §1 of this page

一句话:链上跑模型的价值不在效率,在于"被共识执行"这件事本身;效率是参数,会进化,性质不会退回。In one line: the value of a model on chain is not efficiency but the fact of being executed by consensus; efficiency is a parameter that evolves, the property does not regress.

7 · 证据Evidence(circuits/_scratch/tapeout_asic/onestep_lm/)

主题Topic文件Files
定义与规格Definition and specONESTEP.md · SPEC.md · REPORT.md
网表(官方编码)Netlists (official encoding)netlist_resyn_v0_4k_resyn.json · netlist_resyn_cap_s.json · netlist_resyn_cap_g3.json · netlist_resyn_g44_resyn.json · netlist_resyn_s41_resyn.json · netlist_resyn_v2_resyn.json
位精确验证Bit-exact verificationverify_*.json · resynth_*.json
实测 gasMeasured gaslm_burn_kit.json / LM_BURN_KIT.md · measured_rungs.json · local_cpu_gas.py / .json
烧录数据Burn calldataburn_calldata/*.tapeout.txt(tapeout(bytes,uint32,uint32),0x7bd3ac1d)
训练与编译Training and compilationtrain.py · rule_model.py · compile_lm.py · resynth_lm.py · ladder_search.py · alphabet.json

证据链接(相对路径,随页面发布为 tapeoutLLM/evidence/)Evidence links (relative; published as tapeoutLLM/evidence/)

…

TapeOut 协议由 Blonskr 创建(tapeout.net);本页的电路流片在我们自建的 TapeOut CPU 上,模型、网表与实测由本项目完成。本页遵循信息密集页面指南(三问 → 骨架 → 清单)。数字标签:实测 = 有保存工件可复现。只读,无交易。The TapeOut protocol was created by Blonskr (tapeout.net); the circuits on this page tape out on our own TapeOut CPU, and the model, netlists and measurements are this project’s work. The page follows the information-dense page guide (three questions → skeleton → checklist). Tag: measured = reproducible from saved artifacts. Read-only, no transactions.

下一步:自进化——把语料变成网表的编译器,同样可以把已经在链上的网表当作一个实体的身体:在链上被评分、被选择、被重写,无需人类参与。Next step: self-evolution - the same compiler that turns a corpus into a netlist can take a netlist that is already on chain as the body of an entity that is scored, selected and rewritten on chain, with no human in the loop.

编码示意与阶梯曲线(两张内联图)Encoding and ladder (two inline figures)

context: 32 characters x 6 bits = 192 bits (bit i = character i, little-endian)8 random bits (the sampler: byte 0 = greedy argmax, otherwise depth 4/3/2)one combinational step: NAND netlist, 5,069 gates, 0 latches (cid 285)200 input bits -> 6 output bits: the next character (bit j = output j)
0.350.400.450.50r2kcaps4capscapgg44s41v2v4held-out top-1 vs NAND (log x); gas from the ladder