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

@diegopetrucci/pi-minimal-footer

v0.1.5

Published

A minimal custom footer for pi.

Downloads

448

Readme

minimal-footer

A minimal custom footer for pi.

minimal-footer preview

It replaces pi's built-in footer with a cleaner two-line layout that focuses on the information I care about most:

  • current git branch
  • current repo name
  • current context percentage
  • red DUMB ZONE indicator when context usage is above 200k tokens
  • current model and thinking level
  • OpenAI Codex 5-hour and 7-day usage when available

Layout

On wide terminals it renders two lines:

<git-branch>                                         <repo-name>
<context-%>                                     <model> <thinking>

Example:

fix/remove-detached-image-tasks                     SendItToMy
44.1%                                              gpt-5.4 high

When context usage is above 200k tokens, the bottom-left line includes a red warning:

44.1% · DUMB ZONE

When using openai-codex, the bottom-left line also includes subscription usage:

44.1% · 5h 12% · 7d 38%

On narrow terminals it falls back to one item per line.

Install

Standalone npm package

pi install npm:@diegopetrucci/pi-minimal-footer

Collection package

pi install npm:@diegopetrucci/pi-extensions

GitHub package

pi install git:github.com/diegopetrucci/pi-extensions

Then reload pi:

/reload

Configuration

Config files are merged, with project config overriding global config:

  • ~/.pi/agent/extensions/minimal-footer.json
  • <project>/.pi/minimal-footer.json

A ready-to-copy sample file is included at minimal-footer.example.json.

Example:

{
  "context": {
    "showPercent": true,
    "dumbZone": {
      "enabled": true,
      "thresholdTokens": 200000,
      "label": "DUMB ZONE",
      "color": "error"
    }
  },
  "codexUsage": {
    "enabled": true,
    "cacheTtlMs": 300000,
    "requestTimeoutMs": 10000,
    "windows": {
      "primary": {
        "enabled": true,
        "label": "5h"
      },
      "secondary": {
        "enabled": true,
        "label": "7d"
      }
    }
  }
}

Disable DUMB ZONE:

{
  "context": {
    "dumbZone": {
      "enabled": false
    }
  }
}

Disable OpenAI Codex session-limit usage entirely:

{
  "codexUsage": {
    "enabled": false
  }
}

Disable one session-limit window:

{
  "codexUsage": {
    "windows": {
      "secondary": {
        "enabled": false
      }
    }
  }
}

Config fields

  • context.showPercent: show the context percentage
  • context.dumbZone.enabled: show DUMB ZONE when context tokens exceed the threshold
  • context.dumbZone.thresholdTokens: token threshold for DUMB ZONE
  • context.dumbZone.label: warning text
  • context.dumbZone.color: theme color for the warning (error, warning, accent, text, or dim)
  • codexUsage.enabled: show OpenAI Codex session-limit usage when using openai-codex
  • codexUsage.cacheTtlMs: in-memory usage cache duration
  • codexUsage.requestTimeoutMs: usage request timeout
  • codexUsage.windows.primary.enabled: show the primary usage window
  • codexUsage.windows.primary.label: label for the primary usage window
  • codexUsage.windows.secondary.enabled: show the secondary usage window
  • codexUsage.windows.secondary.label: label for the secondary usage window

What it shows

  • Top left: current git branch
  • Top right: current repo directory name
  • Bottom left: current context usage percentage, plus red DUMB ZONE above 200k context tokens
  • Bottom left on openai-codex: current context usage percentage plus 5-hour and 7-day Codex usage
  • Bottom right: model id and thinking level

Publishing notes

This extension also lives inside the broader pi-extensions collection, but it is set up to be publishable as its own npm package too.

Notes

  • Replaces pi's built-in footer entirely.
  • Uses pi footer data for git branch updates.
  • Shows only context percentage, not context window size.
  • Shows DUMB ZONE only while context usage is above 200k tokens.
  • Shows the model id rather than a provider-specific display label.
  • For openai-codex, reads pi's stored OAuth login and fetches usage from ChatGPT's backend usage endpoint.
  • Usage is cached briefly in memory and refreshed after turns.