Changelog

Release notes and changes from the Pi changelog.

Release notes

Pi 0.29.1

New version of pi. Download from npm or view release on GitHub.

Added

  • Automatic custom system prompt loading: Pi now auto-loads SYSTEM.md files to replace the default system prompt. Project-local .pi/SYSTEM.md takes precedence over global ~/.pi/agent/SYSTEM.md. CLI --system-prompt flag overrides both. (#309)
  • Unified /settings command: New settings menu consolidating thinking level, theme, queue mode, auto-compact, show images, hide thinking, and collapse changelog. Replaces individual /thinking, /queue, /theme, /autocompact, and /show-images commands. (#310)

Read more

Release notes

Pi 0.29.0

New version of pi. Download from npm or view release on GitHub.

Breaking Changes

  • Renamed /clear to /new: The command to start a fresh session is now /new. Hook event reasons before_clear/clear are now before_new/new. Merry Christmas @mitsuhiko! (#305)

Added

  • Auto-space before pasted file paths: When pasting a file path (starting with /, ~, or .) after a word character, a space is automatically prepended. (#307 by @mitsuhiko)
  • Word navigation in input fields: Added Ctrl+Left/Right and Alt+Left/Right for word-by-word cursor movement. (#306 by @kim0)
  • Full Unicode input: Input fields now accept Unicode characters beyond ASCII. (#306 by @kim0)

Read more

Release notes

Pi 0.28.0

New version of pi. Download from npm or view release on GitHub.

Changed

  • Credential storage refactored: API keys and OAuth tokens are now stored in ~/.pi/agent/auth.json instead of oauth.json and settings.json. Existing credentials are automatically migrated on first run. (#296)

  • SDK API changes (#296):

    • Added AuthStorage class for credential management (API keys and OAuth tokens)
    • Added ModelRegistry class for model discovery and API key resolution
    • Added discoverAuthStorage() and discoverModels() discovery functions
    • createAgentSession() now accepts authStorage and modelRegistry options
    • Removed configureOAuthStorage(), defaultGetApiKey(), findModel(), discoverAvailableModels()
    • Removed getApiKey callback option (use AuthStorage.setRuntimeApiKey() for runtime overrides)
    • Use getModel() from @mariozechner/pi-ai for built-in models, modelRegistry.find() for custom models + built-in models
    • See updated SDK documentation and README
  • Settings changes: Removed apiKeys from settings.json. Use auth.json instead. (#296)

Read more

Release notes

Pi 0.27.9

New version of pi. Download from npm or view release on GitHub.

Fixed

  • Model selector and --list-models with settings.json API keys: Models with API keys configured in settings.json (but not in environment variables) now properly appear in the /model selector and --list-models output. (#295)

Read more

Release notes

Pi 0.27.8

New version of pi. Download from npm or view release on GitHub.

Fixed

  • API key priority: OAuth tokens now take priority over settings.json API keys. Previously, an API key in settings.json would trump OAuth, causing users logged in with a plan (unlimited tokens) to be billed via PAYG instead.

Read more

Release notes

Pi 0.27.7

New version of pi. Download from npm or view release on GitHub.

Fixed

  • Thinking tag leakage: Fixed Claude mimicking literal </thinking> tags in responses. Unsigned thinking blocks (from aborted streams) are now converted to plain text without <thinking> tags. The TUI still displays them as thinking blocks. (#302 by @nicobailon)

Read more

Release notes

Pi 0.27.6

New version of pi. Download from npm or view release on GitHub.

Added

  • Compaction hook improvements: The before_compact session event now includes:

    • previousSummary: Summary from the last compaction (if any), so hooks can preserve accumulated context
    • messagesToKeep: Messages that will be kept after the summary (recent turns), in addition to messagesToSummarize
    • resolveApiKey: Function to resolve API keys for any model (checks settings, OAuth, env vars)
    • Removed apiKey string in favor of resolveApiKey for more flexibility
  • SessionManager API cleanup:

    • Renamed loadSessionFromEntries() to buildSessionContext() (builds LLM context from entries, handling compaction)
    • Renamed loadEntries() to getEntries() (returns defensive copy of all session entries)
    • Added buildSessionContext() method to SessionManager

Read more

Release notes

Pi 0.27.5

New version of pi. Download from npm or view release on GitHub.

Added

  • HTML export syntax highlighting: Code blocks in markdown and tool outputs (read, write) now have syntax highlighting using highlight.js with theme-aware colors matching the TUI.
  • HTML export improvements: Render markdown server-side using marked (tables, headings, code blocks, etc.), honor user's chosen theme (light/dark), add image rendering for user messages, and style code blocks with TUI-like language markers. (@scutifer)

Read more

Release notes

Pi 0.27.4

New version of pi. Download from npm or view release on GitHub.

Fixed

  • Symlinked skill directories: Skills in symlinked directories (e.g., ~/.pi/agent/skills/my-skills -> /path/to/skills) are now correctly discovered and loaded.

Read more

Release notes

Pi 0.27.3

New version of pi. Download from npm or view release on GitHub.

Added

  • API keys in settings.json: Store API keys in ~/.pi/agent/settings.json under the apiKeys field (e.g., { "apiKeys": { "anthropic": "sk-..." } }). Settings keys take priority over environment variables. (#295)

Read more

Release notes

Pi 0.27.2

New version of pi. Download from npm or view release on GitHub.

Added

  • Skip conversation restore on branch: Hooks can return { skipConversationRestore: true } from before_branch to create the branched session file without restoring conversation messages. Useful for checkpoint hooks that restore files separately. (#286 by @nicobarray)

Read more

Release notes

Pi 0.27.0

New version of pi. Download from npm or view release on GitHub.

Breaking

  • Session hooks API redesign: Merged branch event into session event. BranchEvent, BranchEventResult types and pi.on("branch", ...) removed. Use pi.on("session", ...) with reason: "before_branch" | "branch" instead. AgentSession.branch() returns { cancelled } instead of { skipped }. AgentSession.reset() and switchSession() now return boolean (false if cancelled by hook). RPC commands reset, switch_session, and branch now include cancelled in response data. (#278)

Added

  • Session lifecycle hooks: Added before_* variants (before_switch, before_clear, before_branch) that fire before actions and can be cancelled with { cancel: true }. Added shutdown reason for graceful exit handling. (#278)

Read more

Release notes

Pi 0.26.1

New version of pi. Download from npm or view release on GitHub.

Fixed

  • SDK tools respect cwd: Core tools (bash, read, edit, write, grep, find, ls) now properly use the cwd option from createAgentSession(). Added tool factory functions (createBashTool, createReadTool, etc.) for SDK users who specify custom cwd with explicit tools. (#279)

Read more

Release notes

Pi 0.26.0

New version of pi. Download from npm or view release on GitHub.

Added

  • SDK for programmatic usage: New createAgentSession() factory with full control over model, tools, hooks, skills, session persistence, and settings. Philosophy: "omit to discover, provide to override". Includes 12 examples and comprehensive documentation. (#272)

  • Project-specific settings: Settings now load from both ~/.pi/agent/settings.json (global) and <cwd>/.pi/settings.json (project). Project settings override global with deep merge for nested objects. Project settings are read-only (for version control). (#276)

  • SettingsManager static factories: SettingsManager.create(cwd?, agentDir?) for file-based settings, SettingsManager.inMemory(settings?) for testing. Added applyOverrides() for programmatic overrides.

  • SessionManager static factories: SessionManager.create(), SessionManager.open(), SessionManager.continueRecent(), SessionManager.inMemory(), SessionManager.list() for flexible session management.

Read more

Release notes

Pi 0.25.4

New version of pi. Download from npm or view release on GitHub.

Fixed

  • Syntax highlighting stderr spam: Fixed cli-highlight logging errors to stderr when markdown contains malformed code fences (e.g., missing newlines around closing backticks). Now validates language identifiers before highlighting and falls back silently to plain text. (#274)

Read more

Release notes

Pi 0.25.3

New version of pi. Download from npm or view release on GitHub.

Added

  • Gemini 3 preview models: Added gemini-3-pro-preview and gemini-3-flash-preview to the google-gemini-cli provider. (#264 by @LukeFost)

  • External editor support: Press Ctrl+G to edit your message in an external editor. Uses $VISUAL or $EDITOR environment variable. On successful save, the message is replaced; on cancel, the original is kept. (#266 by @aliou)

  • Process suspension: Press Ctrl+Z to suspend pi and return to the shell. Resume with fg as usual. (#267 by @aliou)

  • Configurable skills directories: Added granular control over skill sources with enableCodexUser, enableClaudeUser, enableClaudeProject, enablePiUser, enablePiProject toggles, plus customDirectories and ignoredSkills settings. (#269 by @nicobailon)

  • Skills CLI filtering: Added --skills <patterns> flag for filtering skills with glob patterns. Also added includeSkills setting and glob pattern support for ignoredSkills. (#268)

Read more

Release notes

Pi 0.25.2

New version of pi. Download from npm or view release on GitHub.

Fixed

  • Image shifting in tool output: Fixed an issue where images in tool output would shift down (due to accumulating spacers) each time the tool output was expanded or collapsed via Ctrl+O.

Read more

Release notes

Pi 0.25.1

New version of pi. Download from npm or view release on GitHub.

Fixed

  • Gemini image reading broken: Fixed the read tool returning images causing flaky/broken responses with Gemini models. Images in tool results are now properly formatted per the Gemini API spec.

  • Tab completion for absolute paths: Fixed tab completion producing //tmp instead of /tmp/. Also fixed symlinks to directories (like /tmp) not getting a trailing slash, which prevented continuing to tab through subdirectories.

Read more

Release notes

Pi 0.25.0

New version of pi. Download from npm or view release on GitHub.

Added

  • Interruptible tool execution: Queuing a message while tools are executing now interrupts the current tool batch. Remaining tools are skipped with an error result, and your queued message is processed immediately. Useful for redirecting the agent mid-task. (#259 by @steipete)

  • Google Gemini CLI OAuth provider: Access Gemini 2.0/2.5 models for free via Google Cloud Code Assist. Login with /login and select "Google Gemini CLI". Uses your Google account with rate limits.

  • Google Antigravity OAuth provider: Access Gemini 3, Claude (sonnet/opus thinking models), and GPT-OSS models for free via Google's Antigravity sandbox. Login with /login and select "Antigravity". Uses your Google account with rate limits.

Changed

  • Model selector respects --models scope: The /model command now only shows models specified via --models flag when that flag is used, instead of showing all available models. This prevents accidentally selecting models from unintended providers. (#255)

Read more