Pi 0.68.0
New version of pi. Download from npm or view release on GitHub.
New Features
- Configurable streaming working indicator for extensions via
ctx.ui.setWorkingIndicator(), including animated, static, and hidden indicators. See docs/tui.md#working-indicator, docs/extensions.md, and examples/extensions/working-indicator.ts. before_agent_startnow exposessystemPromptOptions(BuildSystemPromptOptions) so extensions can inspect the structured system-prompt inputs without re-discovering resources. See docs/extensions.md#before_agent_start and examples/extensions/prompt-customizer.ts.- Configurable keybindings for scoped model selector actions and session-tree filter actions. See docs/keybindings.md.
/cloneduplicates the current active branch into a new session, while extensions can choose whether to forkbeforeoratan entry viactx.fork(..., { position }). See README.md, docs/extensions.md, and docs/session.md.
Breaking Changes
- Changed SDK and CLI tool selection from cwd-bound built-in tool instances to tool-name allowlists.
createAgentSession({ tools })now expectsstring[]names such as"read"and"bash"instead ofTool[],--toolsnow allowlists built-in, extension, and custom tools by name, and--no-toolsnow disables all tools by default rather than only built-ins. Migrate SDK code fromtools: [readTool, bashTool]totools: ["read", "bash"](#2835, #3452) - Removed prebuilt cwd-bound tool and tool-definition exports from
@mariozechner/pi-coding-agent, includingreadTool,bashTool,editTool,writeTool,grepTool,findTool,lsTool,readOnlyTools,codingTools, and the corresponding*ToolDefinitionvalues. Use the explicit factory exports instead, for examplecreateReadTool(cwd),createBashTool(cwd),createCodingTools(cwd), andcreateReadToolDefinition(cwd)(#3452) - Removed ambient
process.cwd()/ default agent-dir fallback behavior from public resource helpers.DefaultResourceLoader,loadProjectContextFiles(), andloadSkills()now require explicit cwd/agent-dir style inputs, and exported system-prompt option types now require an explicitcwd. Pass the session or project cwd explicitly instead of relying on process-global defaults (#3452)
Added
- Added extension support for customizing the interactive streaming working indicator via
ctx.ui.setWorkingIndicator(), including custom animated frames, static indicators, hidden indicators, a newworking-indicator.tsexample extension, and updated extension/TUI/RPC docs (#3413) - Added
systemPromptOptions(BuildSystemPromptOptions) tobefore_agent_startextension events, so extensions can inspect the structured inputs used to build the current system prompt (#3473 by @dljsjr) - Added
/cloneto duplicate the current active branch into a new session, while keeping/forkfocused on forking from a previous user message (#2962) - Added
ctx.fork()support forposition: "before" | "at"so extensions and integrations can branch before a user message or duplicate the current point in the conversation; the interactive clone/fork UX builds on that runtime support (#3431 by @mitsuhiko) - Added configurable keybinding ids for scoped model selector actions and tree filter actions, so those interactive shortcuts can be remapped in
keybindings.json(#3343 by @mpazik) - Added
PI_OAUTH_CALLBACK_HOSTsupport for built-in OAuth login flows, allowing local callback servers used bypi authto bind to a custom interface instead of hardcoded127.0.0.1(#3409 by @Michaelliv) - Added
reasonandtargetSessionFilemetadata tosession_shutdownextension events, so extensions can distinguish quit, reload, new-session, resume, and fork teardown paths (#2863)
Changed
- Changed
pi updateto batch npm package updates per scope and run git package updates with bounded parallelism, reducing multi-package update time while preserving skip behavior for pinned and already-current packages (#2980) - Changed Bedrock session requests to omit
maxTokenswhen model token limits are unknown and to omittemperaturewhen unset, letting Bedrock use provider defaults and avoid unnecessary TPM quota reservation (#3400 by @wirjo)