pi-profile-switch

Named profiles for Pi: reference skills, extensions, MCP servers, and tools per workflow, switched without restarting.

Packages

Package details

extension

Install pi-profile-switch from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:pi-profile-switch
Package
pi-profile-switch
Version
0.4.5
Published
Sep 19, 2026
Downloads
1,033/mo · 1,033/wk
Author
vincentff
License
MIT
Types
extension
Size
170.7 KB
Dependencies
2 dependencies · 1 peer
Pi manifest JSON
{
  "extensions": [
    "./extensions"
  ]
}

Security note

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

README

pi-profile-switch

English | 中文

Named profiles for Pi. A profile references a set of existing skills, extensions, MCP servers, and tools — switch between them in the same Pi process, without restarting.

Use a lean read-only profile for code review, a full-powered one for implementation, a minimal one for a quick question — all against the same installed resources.

Install

npm install -g pi-profile-switch

Requires Pi (installed automatically as a peer dependency).

Quick start

# Launch with the built-in default profile (all resources, plain Pi behavior)
pi-profile

# Launch with a named profile
pi-profile review

# Anything after -- is passed to pi verbatim
pi-profile review -- --model openai/gpt-5.4

Define profiles in ~/.pi-profile-switch/profiles.json (global, fallback to ~/.pi/agent/profiles.json for migration; custom root via PI_PROFILE_SWITCH_DIR) or <project>/.pi/profiles.json (project, trusted projects only):

{
  "schemaVersion": 1,
  "profiles": {
    "review": {
      "label": "Code review",
      "skills": ["code-review"],
      "mcp": ["github"],
      "tools": ["read", "grep", "find", "bash"],
      "instructions": "Review only; do not modify files."
    }
  }
}

Profiles reference resources by name — they never copy them. Installed packages and files in standard locations are discovered automatically; no registration needed. Full schema with more examples: examples/profiles.json.

On install, pi-profile-switch seeds ~/.pi-profile-switch/profiles.json with a starter ask profile — read-only Q&A and code exploration (read/grep/find/ls, no skills, extensions, or MCP). It assumes nothing about your setup; edit or delete it freely.

Commands

In the TUI, the /profile command family manages everything in-session:

Command What it does
/profile Interactive profile picker
/profile list / /profile status Show profiles / active profile details
/profile use <name> / /profile reload Switch / reload without restarting (rollback on failure)
/profile create|edit|delete|duplicate Guided profile CRUD (TUI only)
/profile customize / /profile reset Narrow the active profile for this session only

All commands work in non-interactive modes (--mode rpc|print|json); CRUD wizards are TUI-only.

Guarantees

  • Reference, never copy — profiles point at resources you already own and maintain.
  • Pi-native — anything a profile doesn't explicitly control keeps plain Pi behavior.
  • Fail safe — untrusted project directories are never read; a failed switch rolls back to the last working configuration.

Docs

License

MIT