← Catalog

@zigai/pi-status-bar

Pi package that provides a programmable active and idle status bar with timing stats.

Extension

Install

Install with PiG

pig install npm:@zigai/pi-status-bar

Install with Pi

pi install npm:@zigai/pi-status-bar
Review before installing

Packages run code with your permissions and influence agent behavior. Catalog inclusion is not a security audit. Review the source before installing a third-party package.

Pi manifest JSON

The pi field of package.json.

{
  "extensions": [
    "./src/index.ts"
  ]
}

README

Written by the package's publisher, shown as published in version 0.9.0 (README.md). PiG does not review it.

Pi Status Bar

npm version npm downloads license

Adds a coherent programmable status bar to Pi:

  • active working-line status with spinner, text, elapsed time, and optional right-side messages
  • idle post-run status with tool-time-excluding model throughput, such as Worked for 1m 12s. [45.0 tok/s]
  • an extension API for changing active text, spinner frames, timer state, idle text, and custom status segments

This package intentionally stays single-line and status-focused. For richer UI above the editor, use Pi's built-in API's.

Install

pi install npm:@zigai/pi-status-bar

Configuration

Global settings are stored in ~/.pi/agent/extension-settings/pi-status-bar.json.

OptionTypeDefaultDescription
statusBar.active.textstring—Custom active status text.
statusBar.active.spinner.framesstring[]—Spinner frames displayed while Pi is active.
statusBar.active.timer.visiblebooleantrueShow the active-run timer.
statusBar.active.timer.pausedbooleanfalseDisplay the active-run timer as paused.
statusBar.idle.textstring—Custom idle status text.
statusBar.idle.visiblebooleantrueShow the status bar while Pi is idle.
statusBar.idle.showLastRunSummarybooleantrueShow the previous run summary while idle.
statusBar.idle.showTokensPerSecondbooleantrueShow model token throughput in the previous run summary.
rightMessages.enabledbooleanfalseEnable rotating messages on the right side.
rightMessages.intervalMsinteger10000Delay between rotating messages in milliseconds.
rightMessages.minGapinteger4Minimum spaces between repeated scrolling messages.
rightMessages.minScrollCyclesinteger1Minimum completed scroll cycles before advancing.
rightMessages.scrollColumnIntervalMsinteger120Delay between horizontal scroll columns in milliseconds.
rightMessages.dimmedbooleantrueRender rotating messages with dim styling.
rightMessages.italicbooleantrueRender rotating messages with italic styling.
rightMessages.messagesstring[][]Inline rotating status messages.
rightMessages.messagesFilestring—Path to a newline-delimited messages file.
{
  "$schema": "./schemas/pi-status-bar.schema.json",
  "statusBar": {
    "active": {
      "timer": {
        "visible": true,
        "paused": false
      }
    },
    "idle": {
      "visible": true,
      "showLastRunSummary": true,
      "showTokensPerSecond": true
    }
  },
  "rightMessages": {
    "enabled": false,
    "intervalMs": 10000,
    "minGap": 4,
    "minScrollCycles": 1,
    "scrollColumnIntervalMs": 120,
    "dimmed": true,
    "italic": true,
    "messages": []
  }
}

Extension API

Other extensions can program the active and idle status bar through @zigai/pi-status-bar/api.

import { configureStatusBar, registerStatusBarSegment } from "@zigai/pi-status-bar/api";

const statusBar = configureStatusBar({
  active: {
    text: "Searching docs",
    spinner: { frames: ["◐", "◓", "◑", "◒"] },
  },
  idle: {
    text: "Ready",
    showLastRunSummary: true,
  },
});

statusBar.pauseTimer();
statusBar.resumeTimer();
statusBar.resetTimer();
statusBar.setActiveText("Running tests");
statusBar.setIdleText("Last run finished");
statusBar.dispose();

Custom segments can appear in the active line, idle line, or both.

const segment = registerStatusBarSegment({
  id: "my-extension.status",
  states: ["active", "idle"],
  side: "right",
  text: "review",
  priority: 50,
});

segment.setText("typechecking");
segment.clear();
segment.dispose();

License

MIT