npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

useful-pi-extensions

v1.11.3

Published

A small collection of pi extensions, installed with one command — a labelled status line with context pressure, cache, cost, effort, TTFT and tokens/sec, plus an opt-in context breakdown panel.

Readme

useful-pi-extensions

English | 中文

A small collection of pi extensions, installed with one command. Every extension in it is also published on its own, so you can take the collection or just the piece you want.

pi install npm:useful-pi-extensions

What is in here

| Extension | What it does | | ------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | @reedchan/statusline | Replaces pi's footer with a labelled two-row one: context pressure as a fixed-size meter, the session's input/output tokens, cache hit rate and cost (in whatever currency you configure), the model and effort level, and the latest turn's TTFT and decode throughput in tokens/second. ctrl+e opens an opt-in context-breakdown panel — what occupies the window, bucket by bucket, with the arithmetic closed |

Only one extension owns the footer, so statusline is a complete replacement rather than an addition. If you want pi's stock footer back, remove this package and /reload.

Screenshots

statusline

Install

# the collection: every extension in this repository
pi install npm:useful-pi-extensions

# one extension on its own
pi install npm:@reedchan/statusline

# from the repository, pinned to a tag
pi install git:github.com/reedchan7/[email protected]

# from a local checkout (development)
pi install /absolute/path/to/useful-pi-extensions

Then reload pi in the running session with /reload, or start a new one.

Install one surface, not both. The collection and the individual package ship the same extension file, so installing useful-pi-extensions and @reedchan/statusline loads it twice. Nothing breaks, but there is nothing to gain either.

Removing a loose copy first. If you were running the extension as a single file in ~/.pi/agent/extensions/, delete that file before installing this package. Both would load, and two footers race for the same slot — the later one wins, which decides nothing useful.

Requirements

  • pi 0.85 or newer (pi --version)
  • No runtime dependencies. @earendil-works/pi-coding-agent and @earendil-works/pi-tui are peer dependencies supplied by pi itself.

Layout

Two things are published from this repository: the collection, which is the repository root, and each extension under packages/, on its own.

package.json                     # the collection package, published as useful-pi-extensions
packages/
  statusline/                    # published as @reedchan/statusline
    package.json
    extensions/statusline/
      index.ts                   # pi entry point: events and footer wiring
      render.ts                  # pure helpers: number formatting, the meter, row layout
      render.test.ts             # unit tests for render.ts
tools/                           # repository tooling: docs pairing, commit lint, publishing

The collection declares "pi": { "extensions": ["packages/*/extensions"] } and the individual package declares "./extensions". pi resolves the glob, finds every extensions/<name>/index.ts and loads it — no build step, no bundling. Adding an extension is therefore adding a directory under packages/: no manifest needs editing, because the collection's glob picks the new package up on its own, and make publish discovers it the same way.

Development

make install      # bun install
make check        # every gate: format, lint, types, docs pairing, tests
make hooks        # install the git hooks (run once, needs a git checkout)
make help         # list every target

make check runs the same gates as CI:

| Gate | Command | What it enforces | | ------ | -------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | Format | bun run fmt:check | oxfmt: 100 columns, single quotes, no semicolons | | Lint | bun run lint | oxlint in type-aware mode with --deny-warnings, so a warning fails the run | | Types | bun run typecheck | --strict plus noUncheckedIndexedAccess, exactOptionalPropertyTypes and verbatimModuleSyntax, which is what keeps every file loadable by pi without a transform | | Docs | bun run docs:check | every README.md has a README_CN.md with the same heading sequence and a working language switcher | | Tests | bun test | the unit tests under packages/*/ |

Commits follow Conventional Commits: the commit-msg hook rejects a subject that is not type(scope): summary, and the pre-commit hook formats and lints only the staged files. The toolchain is pinned to exact versions in package.json (bunfig.toml sets install.exact = true). The @earendil-works/* packages are deliberately left at *: they are the host API pi supplies, and tracking it is what surfaces an upstream break early.

License

MIT. See LICENSE.