Pi-Bolt Docs

Reference

Benchmarks

Pi-Bolt 1.0.0 against Pi 1.4.0 as released, run by stock Bun 1.4.4, Node 22 and Node 24, on GitHub's Linux x86-64, Linux ARM64 and Windows runners and an Apple M5 Mac. Lower is better in every row.

How it is measured#

  • The same work for every build. Each build runs the same prompts against a local server that replays the same model responses, so there is no network or provider variance.
  • Pi as released. "Pi on Bun" and "Pi on Node" are Pi 1.4.0 from its npm package (@earendil-works/pi-coding-agent), not Pi-Bolt's tree. Pi-Bolt is the release's code built on its runtimes. Every downloaded build is checked against its checksums.
  • Interleaved. Builds take turns, so a change in the machine's state affects all of them alike. Times to start and sessions are medians of 21 runs.
  • CPU time is user plus system time of the process. Memory is the process's resident memory (on Windows, the working set).

The benchmark scripts, the method in full and the raw data are in the repository: BENCHMARKS.md and bench/results.

Against Pi on Bun and Node#

GitHub's ubuntu-24.04 runner, Intel Xeon Platinum 8573C, every build pinned to one CPU.

BenchmarkPi-Bolt 1.0.0Pi on Bun 1.4.4Pi on Node 22Pi on Node 24
Writing a 400 KB file through a tool call1.2 s194.8 s189.6 s143.7 s
CPU, streaming a 60,000-character answer2.34 s21.92 s22.17 s18.62 s
CPU, a 20,000-character answer in tmux0.75 s8.53 s7.79 s7.19 s
Bytes sent to the terminal for it528 KB3,563 KB3,570 KB3,562 KB
CPU per prompt, prompts 21 to 40 of a session46 ms328 ms381 ms352 ms
Memory after 40 prompts117 MB309 MB506 MB521 MB
CPU, interactive session167 ms1,087 ms1,248 ms1,180 ms
Ready to type41 ms366 ms396 ms423 ms

GitHub's ubuntu-24.04-arm runner, Neoverse-N2, every build pinned to one CPU.

BenchmarkPi-Bolt 1.0.0Pi on Bun 1.4.4Pi on Node 22Pi on Node 24
Writing a 400 KB file through a tool call1.3 s164.1 s177.1 s134.5 s
CPU, streaming a 60,000-character answer2.32 s18.82 s21.10 s18.19 s
CPU, a 20,000-character answer in tmux0.90 s8.51 s7.89 s7.02 s
Bytes sent to the terminal for it528 KB3,564 KB3,570 KB3,571 KB
CPU per prompt, prompts 21 to 40 of a session42 ms280 ms326 ms299 ms
Memory after 40 prompts120 MB299 MB533 MB640 MB
CPU, interactive session156 ms1,021 ms1,140 ms1,099 ms
Ready to type37 ms334 ms348 ms390 ms

An Apple M5 Mac, not pinned.

BenchmarkPi-Bolt 1.0.0Pi on Bun 1.4.4Pi on Node 22Pi on Node 24
Writing a 400 KB file through a tool call0.6 s76.2 s143.8 s96.7 s
CPU, streaming a 60,000-character answer1.35 s7.10 s8.01 s6.47 s
CPU, a 20,000-character answer in tmux0.60 s4.22 s4.47 s3.93 s
Bytes sent to the terminal for it571 KB3,738 KB3,738 KB3,740 KB
CPU per prompt, prompts 21 to 40 of a session17 ms111 ms209 ms149 ms
Memory after 40 prompts89 MB746 MB1,031 MB1,363 MB
CPU, interactive session80 ms485 ms580 ms523 ms
Ready to type24 ms120 ms155 ms151 ms

GitHub's windows-2025 runner, AMD EPYC 9V74, 2 cores. Memory is the working set. There is no tmux test on Windows.

BenchmarkPi-Bolt 1.0.0Pi on Bun 1.4.4Pi on Node 22Pi on Node 24
Writing a 400 KB file through a tool call1.8 s131.0 s172.9 s110.1 s
CPU, streaming a 60,000-character answer2.69 s44.86 s42.17 s39.01 s
CPU per prompt, prompts 21 to 40 of a session53 ms278 ms446 ms379 ms
Memory after 40 prompts79 MB286 MB352 MB378 MB
CPU, interactive session213 ms1,266 ms1,490 ms1,286 ms
Ready to type78 ms300 ms425 ms363 ms

Against Pi on Node 24, Pi-Bolt writes the large file 61 to 161 times faster, uses 4.8 to 15 times less CPU while a long answer streams, 6.0 to 8.8 times less per prompt and per session, 4.5 to 15 times less memory, and is ready to type 4.7 to 11 times sooner.

Against PiG#

Pi-Bolt 1.0.0 against PiG 0.5.1, a port of Pi 1.3.0 to Go, and Pi-Bolt 0.9.9, doing the same work.

GitHub's ubuntu-24.04 runner, AMD EPYC 7763, every build pinned to one CPU.

BenchmarkPi-Bolt 1.0.0PiG 0.5.1Pi-Bolt 0.9.9
Ready to type43 ms16 ms48 ms
CPU, one prompt (-p)58 ms24 ms63 ms
CPU, interactive session176 ms165 ms187 ms
CPU, streaming a 60,000-character answer2.31 s1.33 s2.61 s
CPU per prompt, 40 prompts into a session46.9 ms49.5 ms69.5 ms
Own memory after 40 prompts39 MB42 MB70 MB
Peak own memory, interactive session33 MB20 MB42 MB
CPU, an answer streaming into a 4,000-entry session0.48 s0.54 s4.46 s
CPU, writing files in a terminal (tmux)0.99 s3.22 s1.08 s
Idle CPU, two minutes after an answer0.017 ms/s0.003 ms/s0.043 ms/s

GitHub's ubuntu-24.04-arm runner, Neoverse-N2, every build pinned to one CPU.

BenchmarkPi-Bolt 1.0.0PiG 0.5.1Pi-Bolt 0.9.9
Ready to type39 ms15 ms43 ms
CPU, one prompt (-p)55 ms26 ms60 ms
CPU, interactive session171 ms160 ms199 ms
CPU, streaming a 60,000-character answer2.40 s0.96 s2.49 s
CPU per prompt, 40 prompts into a session41.3 ms43.3 ms57.3 ms
Own memory after 40 prompts44 MB39 MB114 MB
Peak own memory, interactive session38 MB18 MB48 MB
CPU, an answer streaming into a 4,000-entry session0.32 s0.45 s3.77 s
Idle CPU, two minutes after an answer0.046 ms/s0.004 ms/s0.065 ms/s

An Apple M5 Mac, not pinned. Own memory is the footprint; CPU per prompt and memory after 40 prompts are the range of two runs.

BenchmarkPi-Bolt 1.0.0PiG 0.5.1Pi-Bolt 0.9.9
Ready to type25 ms17 ms26 ms
CPU, one prompt (-p)34 ms24 ms37 ms
CPU, interactive session78 ms118 ms80 ms
CPU, streaming a 60,000-character answer1.58 s1.11 s1.91 s
CPU per prompt, 40 prompts into a session19-26 ms31-53 ms21-51 ms
Own memory after 40 prompts40-44 MB48-49 MB35-69 MB
Peak own memory, interactive session31 MB26 MB40 MB
CPU, an answer streaming into a 4,000-entry session0.21 s0.23 s1.36 s
CPU, writing files in a terminal (tmux)0.61 s2.13 s1.16 s
Idle CPU, two minutes after an answer0.18 ms/s0.006 ms/s0.17 ms/s

GitHub's windows-2025 runner, AMD EPYC 7763, 2 cores. Own memory is the private bytes (the memory the process has committed). There is no tmux test on Windows.

BenchmarkPi-Bolt 1.0.0PiG 0.5.1Pi-Bolt 0.9.9
Ready to type93 ms106 ms107 ms
CPU, one prompt (-p)97 ms93 ms106 ms
CPU, interactive session274 ms378 ms285 ms
CPU, streaming a 60,000-character answer3.25 s3.08 s3.87 s
CPU per prompt, 40 prompts into a session61.0 ms69.2 ms70.2 ms
Own memory after 40 prompts100 MB88 MB132 MB
Peak own memory, interactive session90 MB67 MB101 MB
CPU, an answer streaming into a 4,000-entry session0.50 s0.61 s4.34 s
Idle CPU, two minutes after an answer0.20 ms/s1.64 ms/s0.41 ms/s

The lowest of each row is in bold. On Linux, own memory is the process's anonymous resident memory.

PiG starts sooner, streams with less CPU and is a third of the size: it is a native Go program. Pi-Bolt runs Pi's own code, so every Pi extension works unchanged, and over a long session it uses less CPU than PiG. Against Pi-Bolt 0.9.9, CPU per prompt 40 prompts in falls by a third on Linux x86-64 and own memory by 44%, and an answer streaming into a 4,000-entry session takes a tenth of the CPU.

Why a large file write takes so long on stock Pi#

Those two to three minutes are not the disk. A model writes a file by streaming the write tool call's arguments, the whole file, a few characters at a time, so a 400 KB file arrives in thousands of chunks. For every chunk, stock Pi parses the whole tool call again, redraws the screen even when nothing shown has changed, and highlights every line of the file. Each chunk costs more than the last, and the total grows with the square of the file's size. Pi-Bolt parses again only once the arguments have grown by an eighth, draws a frame only when what is shown changes, and highlights only the lines it shows.

In the benchmark the model streams as fast as it can, so the cost shows as wall time. With a real model, which streams more slowly, it shows as CPU.

Why streaming and long sessions cost less#

Streaming. Stock Pi redraws the message every time a few words arrive, and each redraw re-lexes the whole Markdown, re-wraps every block and re-highlights every code block. Pi-Bolt keeps what it has rendered and redoes only the last block or two, with highlighted code cached. The screen shows the same output, line for line.

Long sessions. Every request sends the whole conversation to the model again, and stock Pi serializes all of it from scratch each time, so each prompt costs more than the last. Pi-Bolt builds each request from the previous one's bytes plus what is new. The bytes sent are identical.

Measurements, not guarantees Each table comes from one machine. On other hardware the times differ; what carries over is the comparison.