github badlogic/pi-mono v0.55.4

5 hours ago

New Features

  • Runtime tool registration now applies immediately in active sessions. Tools registered via pi.registerTool() after startup are available to pi.getAllTools() and the LLM without /reload (docs/extensions.md, examples/extensions/dynamic-tools.ts, #1720).
  • Tool definitions can customize the default system prompt with promptSnippet (Available tools) and promptGuidelines (Guidelines) while the tool is active (docs/extensions.md, #1720).
  • Custom tool renderers can suppress transcript output without leaving extra spacing or empty transcript footprint in interactive rendering (docs/extensions.md, #1719).

Added

  • Added optional promptSnippet to ToolDefinition for one-line entries in the default system prompt's Available tools section. Active extension tools appear there when registered and active (#1237 by @semtexzv).
  • Added optional promptGuidelines to ToolDefinition so active tools can append tool-specific bullets to the default system prompt Guidelines section (#1720).

Fixed

  • Fixed pi.registerTool() dynamic registration after session initialization. Tools registered in session_start and later handlers now refresh immediately, become active, and are visible to the LLM without /reload (#1720)
  • Fixed session message persistence ordering by serializing AgentSession event processing, preventing toolResult entries from being written before their corresponding assistant tool-call messages when extension handlers are asynchronous (#1717)
  • Fixed spacing artifacts when custom tool renderers intentionally suppress per-call transcript output, including extra blank rows in interactive streaming and non-zero transcript footprint for empty custom renders (#1719 by @alasano)
  • Fixed session.prompt() returning before retry completion by creating the retry promise synchronously at agent_end dispatch, which closes a race when earlier queued event handlers are async (#1726 by @pasky)

Don't miss a new pi-mono release

NewReleases is sending notifications on new releases.