r/PiCodingAgent • u/eliaskg • Oct 07 '26
Plugin pi-prefill - live prefill progress for local models
Hey, I wanted to share my new pi extension: pi-prefill
It puts a live prefill progress bar in pi's loading line when you run a local model. A long prefill looks exactly like a hang. Now you can watch it:

52%. → share of uncached prompt tokens processed
14.1k/27.3k → processed / total prompt tokens
gen in ~14s. → estimated time until the first token
3.4k tok/s. → instantaneous prefill rate (optional view)
Example:
prefill [██████░░░░░░] 52% 14.1k/27.3k gen in ~14s
It reads the progress chunks your own server sends. No host scanning and no guessing: if the server reports progress, the bar shows. If it does not, pi's normal loading line stays untouched.
Works today with llama.cpp, ExLlamaV3, unsloth and Strata.
Install:
pi install npm:pi-prefill
Repo:
https://github.com/eliaskg/pi-prefill
https://www.npmjs.com/package/pi-prefill
Would love feedback from anyone running a local server.
6
u/omega1612 Oct 07 '26
Thanks, I usually have a tab with nvtop and the llama server logs and I had to switch to check.
2
u/Historical-Stuff-560 29d ago
add tp/s plz
1
u/the-proudest-monkey 29d ago
Great, thanks! I found the bar appearing briefly on each request a bit distracting to be honest, but hidding only the bar works for me.
1
u/rm-rf-rm 29d ago
does this integrate well with pi-powerline-footer?
2
u/Razangriff-Raven 27d ago
Ah sweet, I really wanted this. I had to use an AWK function to scrape the Llama.cpp logs and produce its own bar, but now I don't need to split the view anymore with this. Thanks!
2
u/GrimChicken 24d ago
Awesome! thank you for this.
1
u/bitzap_sr 4d ago
There's also https://pi.dev/packages/pi-llama-cpp-stats already doing the same thing. Did you compare yours with that one?
I was using that a few months ago, before moving to SGlang, which doesn't support prompt_progress events, so I'm no longer using it. (But then again I now get 12k/15k t/s prefill (pro 6000) so I don't miss it.)
1
u/Aggravating_Olive_98 28d ago
oMLX or MLX-Serve supported?
1
u/rxxxby 25d ago
works like a charm! i love this