pi-system-prompt-switcher

Switch active Pi system prompt from ~/.pi/agent/systems and reload on swap

Packages

Package details

extension

Install pi-system-prompt-switcher from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:pi-system-prompt-switcher
Package
pi-system-prompt-switcher
Version
0.1.1
Published
Jun 3, 2026
Downloads
not available
Author
drsh4dow
License
unknown
Types
extension
Size
9.7 KB
Dependencies
0 dependencies · 3 peers
Pi manifest JSON
{
  "extensions": [
    "./extensions/system-prompt-switcher.ts"
  ]
}

Security note

Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.

README

pi-system-prompt-switcher

npm version

Switch Pi's active system prompt from files in ~/.pi/agent/systems/.

This package does one thing: /system-prompt picks a prompt file, persists that choice, then reloads Pi so the next turn uses it. There is no file watcher. Editing a prompt file takes effect after a reload or after selecting it again.

Install

pi install npm:pi-system-prompt-switcher

Prompt files

Put prompt files directly in:

~/.pi/agent/systems/

Example:

~/.pi/agent/systems/default.md
~/.pi/agent/systems/reviewer.md
~/.pi/agent/systems/prototype.md

Hidden files and subdirectories are ignored. Symlinks are ignored so selections cannot escape the systems directory.

Usage

Interactive picker:

/system-prompt

Direct switch:

/system-prompt reviewer.md

Selection is stored in:

~/.pi/agent/system-prompt-switcher.json

On interactive startup, Pi lists the active prompt filename in a [System Prompt] section.

After a successful switch, the extension calls Pi's reload flow. The selected prompt is appended to Pi's effective system prompt under an Active system prompt heading, preserving Pi's generated tool guidance, skills, project context, date, and cwd.

Development

bun install
bun test
bun run typecheck
bun run check
bun pm pack --dry-run
PI_OFFLINE=1 bunx --bun pi --no-extensions -e . --list-models >/tmp/pi-system-prompt-switcher-pi-load.out