Skip to content

Pi-Bolt 0.8.5

Latest

Choose a tag to compare

@Kushalkhemka Kushalkhemka released this 12 Oct 07:11
· 98 commits to pi-bolt since this release
b93895d

Pi-Bolt 0.8.5 is faster and lighter where you spend your time: typing and answers in long conversations, streamed replies,
large edits and long tool output. Everything else is 0.8.4.

Faster in use

Against 0.8.0 (0.8.4 measures the same as 0.8.0), on an Apple M5 and on Linux (an AMD EPYC 7B13 VM, pinned to 4 cores):

macOS 0.8.0 macOS 0.8.5 Linux 0.8.0 Linux 0.8.5
Interactive session (5 prompts, 25 model turns): CPU 171 ms 136 ms (−21%) 253 ms 199 ms (−21%)
Interactive session: time per turn 196 ms 179 ms (−9%) 269 ms 210 ms (−22%)
One prompt with pi -p: CPU 58 ms 54 ms (−7%) 74 ms 63 ms (−14%)
pi --version: peak memory 27 MB 25 MB (−7%) 63 MB 59 MB (−6%)
Long conversation (~4.2M tokens): CPU per prompt 133 ms 108 ms (−19%) 256 ms 177 ms (−31%)
Long conversation: memory 533 MB 462 MB (−13%) 289 MB 244 MB (−16%)
Long conversation, a pause after each answer: memory 458 MB 311 MB (−32%) 182 MB 170 MB (−7%)
  • The screen redraws only what changed. Messages, tool rows and the editor keep the lines they drew; the spinner and each
    key press no longer redraw the whole conversation. Late in a long conversation that is up to 17× less work per frame in the
    default (non-fullscreen) mode, and 5× less in fullscreen. Key bindings are matched once per key press.

  • Streamed replies are read faster. OpenAI-style streams are parsed with a faster reader, and tool-call arguments are
    parsed as they arrive instead of again from the start: a 400 KB file write streams in about 50 ms instead of 765 ms.

  • Memory is given back when Pi is idle. After an answer, once Pi has been idle for a moment, it collects garbage if memory
    grew; long conversations hold much less.

  • Edits and long output are cheaper. The edit tool's preview and patch only compare the changed lines (an edit in a 230 KB
    file: 23 ms → 1 ms), long tool output is cut in one step, and truncated output is kept once.

  • Startup does less. Grammars, the image decoder, compression and network modules load when first needed; in tmux the
    hyperlink check runs in the background; on Kitty-type terminals such as Ghostty Pi is ready about 30% sooner.

  • Extensions are not called for events they do not listen to, and the session's size and name are not recomputed every
    frame.

  • Extensions load faster when stock Bun is installed too. Pi-Bolt keeps its compiled-extension cache in a folder of its own
    (@t@pi-bolt, beside Bun's @t@). Sharing one, each runtime took the other's entries for stale and compiled them again:
    with three extensions, a start after Pi on stock Bun had run took about 200 ms longer on Linux and macOS, and pi-subagents
    took 4 s instead of 0.5 s on Windows.

  • @ file completion runs its two searches at the same time.

Windows

  • The bash tool starts Git's bash.exe itself, without Git's launcher in front (the -jit build keeps the launcher, which
    its job object needs): 10 bash calls 1.6 s → 1.45 s.
  • A program started by name is looked up on PATH once.
  • An idle Pi-Bolt no longer wakes every 4 seconds once it has made a request.
  • Against 0.8.4 on an Intel Core i5-1335U laptop: interactive CPU 301 → 260 ms, CPU per prompt in a long conversation
    177 → 160 ms, its peak private memory 332 → 254 MB.

For extension authors

  • pi-tui has markStableRender() and Container.renderShared() for components whose lines do not change between frames.
    Components that do not opt in are compared with what was drawn before, so existing extensions draw as they did.
  • In session files and extension events, details.truncation.content of the read, grep, find, ls and bash tools is now empty;
    the counts are unchanged.

Fixes

  • Installing from npm handles a download base address with many trailing slashes quickly.
  • The Windows install script's tests run on any machine.

From Pi

Fixes from Pi's main branch since 1.1.0:

  • A terminal's late replies (colour or cursor queries) no longer end up as typed input.
  • Images show in Kitty-protocol terminals inside Herdr.
  • Compaction summaries leave out thinking.
  • AGENTS.md that is a symlink is found in nested git worktrees.
  • MCP OAuth refuses an issuer when no authorization server metadata was found.
  • Codex request bodies and Mistral timeouts (the timeout covers the response headers only).
  • Extensions can override the colours of the compaction status indicator.
  • Packaging works with npm 12.

Engine

Both engines change, so all three runtimes are new.

  • Faster request bodies. Text is converted to UTF-8 in one pass into a buffer of the right size, instead of growing and
    copying it: a large part of the savings in long conversations.
  • From upstream WebKit: faster replace() with an empty string, string search, parseInt and number conversion of
    strings that are not numbers, and microtasks queued without copies.
  • From upstream Bun: sliceAnsi/stripANSI of huge input; fixes to FileSink, PipeReader, child processes' standard
    output and spawnSync; the idle collection also gives back the allocator's free memory.
  • x86-64 (Linux, Windows): property lookups by a name held in a variable, and dispatch-table slots, in ahead-of-time
    compiled code (thanks to @carsteneu, #18).
  • Map and Set with long string keys compare them many characters at a time (a lookup with 64 KB keys: 7× faster).
  • macOS: what the image builder takes for an address in the code is narrower, so large numbers are not mistaken for one.
  • Windows: the sockets' sweep timer stops with the last socket (oven-sh/bun#37096), and a task left queued after a tick wakes
    the event loop (oven-sh/bun#42968).

Install

curl -fsSL https://pi-bolt.opensec.in/install.sh | sh
irm https://pi-bolt.opensec.in/install.ps1 | iex
powershell -c "irm https://pi-bolt.opensec.in/install.ps1 | iex"

or pi-bolt update, or npm install -g --allow-scripts=pi-bolt pi-bolt, or bun add -g --trust pi-bolt.

Asset For
pi-bolt-linux-x64.tar.xz / .tar.gz Recommended on Linux. CPUs with AVX2 (Intel Haswell 2013+, AMD Zen+).
pi-bolt-linux-x64-baseline.tar.xz / .tar.gz Any x86-64 CPU with SSE4.2.
pi-bolt-linux-x64-jit.tar.xz / .tar.gz JIT also on, for plugins loaded at run time.
pi-bolt-darwin-arm64.tar.xz / .tar.gz macOS. Macs with Apple silicon, macOS 13 or later.
pi-bolt-darwin-arm64-jit.tar.xz / .tar.gz macOS, JIT also on.
pi-bolt-win32-x64.zip Windows. Windows 10 (1809) or 11 on x64; compiled code on AVX2 CPUs, bytecode on others.
pi-bolt-win32-x64-jit.zip Windows, JIT also on.
pi-bolt-runtime-linux-x64.tar.gz, pi-bolt-runtime-darwin-arm64.tar.gz, pi-bolt-runtime-win32-x64.zip The Pi-Bolt Bun runtime, for compiling plugins in.

Linux x86-64 with glibc 2.17 or later; macOS 13 or later on Apple silicon; Windows 10 1809 or later, or Windows 11, on x64.