build(deps-dev): bump @earendil-works/pi-ai from 1.4.0 to 1.5.0
Bumps @earendil-works/pi-ai from 1.4.0 to 1.5.0.
Release notes
Sourced from @earendil-works/pi-ai's releases.
v1.5.0
New Features
- Extension update changelogs: see what changed in installed extension packages on the next fresh launch after an update. Package authors can choose the changelog path, and
collapseChangelogcondenses the notices. See Show a changelog.- Faster streaming: large tool calls are parsed incrementally, and code-heavy answers and tool rows reuse highlighting and rendered Markdown instead of repeating the work on every update. See Keep rendering responsive.
- Custom self-update commands: use
PI_SELF_UPDATE_COMMANDorselfUpdateCommandto update pi through a wrapper or another package manager. See Custom update command.- GPT-6.1 Terra: available through OpenAI, Azure OpenAI Responses, and OpenAI Codex, with tool search, mid-conversation thinking-level changes, and thinking
off. Codex offers a 500K context window. See Models.Breaking Changes
- Tool argument validation runs on
@earendil-works/pi-schema. TypeBox features outside JSON Schema (Type.Refine(),Type.BigInt(),Type.Undefined(), codecs,Format.Set()formats) no longer apply to tool arguments; see Tool parameter schemas and TypeBox. Plain JSON Schema tools, including MCP tools, now get the same coercion as TypeBox tools, such as converting numeric strings and wrapping a single value into an array. Validation failures the model sees list pi-schema's messages (- path: missing,- limit: expected number, got string) instead of TypeBox's (must have required properties path,must be number).Added
- Extension packages can now show their changelog after an update. Pi reads
pi.changelogPathfrom the package'spackage.json, orCHANGELOG.mdin the package root, and on the next fresh launch shows entries newer than the last seen version under "Extension Updates". ThecollapseChangelogsetting condenses this to one line per package (#5958, #8790)pi.exec()accepts amaxBufferoption that limits stdout and stderr combined, and its result has atruncatedfield that is true when output exceeded the limit (#11360)- Device-code login (for example GitHub Copilot) now opens the verification page and copies the code when you press Enter. Providers can turn either action off with
openBrowserOnConfirm: falseorcopyCodeOnConfirm: false(#9282, #9301)pi updatecan update Pi through a wrapper or another package manager. SetPI_SELF_UPDATE_COMMAND(for examplemise use -g npm:{packageName}@{version}) or the globalselfUpdateCommandsetting;pi updateruns it when pi.dev reports a newer release and fills{packageName},{version}, and{installSpec}from that release. See Custom update command (#7756, #5607)- Extensions can format the user's configured keybindings with
keyText()andkeyHint()from the tool render context and the message and entry renderer options. Importing these functions from@earendil-works/pi-coding-agentcan resolve the extension's own copy of the package, which does not see pi's keybindings, so hints such askeyHint("app.tools.expand", "to expand")rendered without the key. The docs now recommend the injected functions (#4748)- Added persisted session-entry
messageIdand ISOtimestamptoMarkdownTransformContext. They are available when rendering saved entries and undefined for live rendering (#7952 by@vipentti)- Added a
blockedoption to inlinectx.ui.custom()components so approval prompts and other custom dialogs can report that pi is waiting for user input. Overlays ignore the option. See Custom screens and overlays (#11428)- Added
Usage.cost.totalFromProviderto distinguish billed totals from catalog estimates in SDK and extension usage data; combined usage is marked provider-reported only when every part is (#11178)- Added concrete
responseModelmetadata to messages from pi-messages providers such as Radius, including when a virtual model is requested. See AssistantMessage (#11265)- Added GPT-6.1 Terra for OpenAI, Azure OpenAI Responses, and OpenAI Codex, with tool search and mid-conversation thinking-level changes. It supports thinking
off; Codex offers a 500K context windowChanged
- Extensions keep importing
Type,StaticandTSchemafrom@earendil-works/pi-ai: Pi maps that import to pi-ai's compat entry plus the TypeBox it bundles, now that pi-ai itself no longer re-exports TypeBox, and itsStringEnumthere stays a TypeBoxTUnsafe<T>. The built-in tool factories (createReadTool()and the others) returnTypeBoxAgentTool<typeof schema>, which keepsparamstyped for TypeBox.- Tightened system prompt
pi updatefor installs from the pi.dev installer no longer passes--min-release-age=0tonpm ci. The release lockfile pins every package, so the flag had no effect, and security scanners that block it stopped the update (#11262)/modeland/scoped-modelsnow show a model's name next to its ID when the name adds words the ID lacks, such as a renamedmodels.jsonoverride (#5916, #11347)- MCP OAuth sign-in now uses pi's Client ID Metadata Document by default when the authorization server supports it for public clients, and registers a client dynamically otherwise, like Codex, Claude Code, and opencode. Clients registered before stay in use while their redirect URI matches. The new default
oauth.clientRegistration: "auto"registers whenclientNameor a non-defaultcallbackUrlis set;"dcr"always registers.pi mcp add --oauth-client-registrationsets the mode (#11426)- Changed the default OpenAI model from
gpt-5.5togpt-6.1-sol, including after ChatGPT sign-in when no model is selected (#11442)- Updated the built-in model catalog to models.dev v2. Realtime and image-only models are no longer offered as chat models; newer OpenAI and Google chat models are included
Fixed
- Updated glob matching to prevent denial of service from amplified glob patterns.
- Fixed a saved "Do not trust" decision being ignored for projects without trust-requiring resources, for example a folder with only
AGENTS.md. pi auto-trusted such projects, soctx.isProjectTrusted()returned true and package commands treated them as trusted. A saved decision intrust.jsonnow takes precedence; auto-trust applies only when no decision is saved (#10947)- Fixed
Shift+Enterqueueing a follow-up instead of inserting a newline in Apple Terminal setups that sendESC+ Return. pi now checks the local Shift key state for that sequence, as it already did for plain Return;Alt+Enterwithout Shift still queues a follow-up (#11559)- Fixed the working status (OSC 7501) disappearing in Rex and iTerm2 during runs in regular TUI mode. Rendered messages wrote OSC 133 prompt markers to the terminal, which the terminal treats as a new shell prompt; regular mode no longer writes them (#11519)
- Fixed compaction, branch summaries, and bug-report summaries in SDK sessions passing the stored OAuth token back to the model runtime as an explicit API key. Provider auth that treats explicit keys differently from stored OAuth now sees the OAuth login, as normal prompts do (#11520)
- Fixed a redundant system prompt update (tools, rules) when an extension set the same active tools in a different order, for example a reversed
pi.setActiveTools()list. Tools that stay active now keep their order and newly activated tools are appended (#11495)- Fixed
pi.exec()crashing pi withRangeError: Invalid string lengthwhen a command printed more output than fits in a string. The default output cap is the smaller of 256 MiB and the runtime string limit; past the cap, the command is terminated and the result hastruncated: trueand a nonzero exit code (#11360)- Fixed
pi.exec()never returning when a command ignored SIGTERM after a timeout or abort. pi now sends SIGKILL 5 seconds later, as intended- Fixed
pi installandpi removeadding ever deeper nested entries to the npmpackage-lock.jsonwhen the agent directory is reached through a symlink, such as~/.pilinked into a dotfiles repo. pi now passes the resolved real path to npm (#11358)- MCP sign-in now rejects authorization endpoints and other OAuth metadata URLs that are not
http:orhttps:. Before, a malicious MCP server could supply afile:or custom protocol URL, which pi passed to the platform URL handler.- Automatic
fdandrgdownloads no longer fetch x86-64 binaries on ARM32 and other architectures without a prebuilt release. pi now warns and recommends installing the tool with the system package manager (#11209)- Fixed
/modelsearch ranking letters scattered over an earlier part of an entry above a real match, for exampleopuslistinggpt-oss-120bandclaude-sonnet-4.5beforeclaude-opus-4.1(#11220, #11296)- Fixed
/resumesearch matching scattered letters anywhere in session messages and IDs, for example1024matching inside a session UUID. Session names and working directories still match fuzzily; IDs and message text now match only as exact substrings (#11220, #11024, #11296)
... (truncated)
Changelog
Sourced from @earendil-works/pi-ai's changelog.
[1.5.0] - 2026-11-02
Breaking Changes
The main entry no longer re-exports TypeBox (
Type,Static,TSchema), andtypeboxis no longer a dependency.Tool.parametersis any JSON Schema object (Tool<TParameters extends object>):@earendil-works/pi-schema's builders, which also type the arguments through pi-schema'sStatic, TypeBox schemas, or plain objects.validateToolCall()/validateToolArguments()validate with pi-schema (compile(schema, { coerce: true }).parse()): every schema gets the same coercion, the superset of TypeBox'sValue.Convertrules (which only applied to TypeBox-built schemas) and pi-ai's own, so plain JSON Schema tools (MCP tools) now also get, for example,nullto"null"for a required string,"3.5"to 3 for an integer and a single value wrapped into an array. The error text lists pi-schema's messages (- edits.0.oldText: missing,- limit: expected number, got string) instead of TypeBox's.StringEnum()returns a pi-schemaSchema<T>with the same JSON ({ type: "string", enum }). The model and compat schemas (providers/model-schema,providers/compat-schema) are built with pi-schema, with the same JSON Schema, and their types come from pi-schema'sStatic;ProviderCompatis exported. Migration:// Before import { Type, type Static, StringEnum } from "@earendil-works/pi-ai"; const params = Type.Object({ path: Type.String(), mode: StringEnum(["a", "b"]) }); type Params = Static<typeof params>;// After: pi-schema builders (closed objects; pass { open: true } to allow other properties) import { StringEnum } from "
@earendil-works/pi-ai"; import { obj, type Static, str } from "@earendil-works/pi-schema"; const params = obj({ path: str(), mode: StringEnum(["a", "b"]) }); type Params = Static<typeof params>;
// Or keep TypeBox, imported from typebox itself (its schemas are JSON Schema) import { Type, type Static } from "typebox";Tool arguments are validated as JSON Schema only; nothing runs through TypeBox's own validator any more, so TypeBox features outside JSON Schema no longer apply to tool arguments:
Type.Refine()refinements are not run: arguments they would reject are accepted.Type.BigInt(),Type.Undefined()andType.Void()reject every JSON argument (TypeBox converted to them).- Codecs (
Type.Codec()) do not decode: the tool receives the encoded JSON value.- Formats registered with TypeBox's
Format.Set()are not checked; the standard formats plusurlandjson-pointer-uri-fragmentare.- Property names are names, not regular expressions:
"a.b"no longer also converts the argumentaxb.additionalPropertiesconverts only undeclared properties; TypeBox also converted declared ones with it when an object had more than one property.A
$refthat names nothing (a missing definition, an external document) rejects only arguments at its place (- t: unresolved reference #/definitions/Missing) instead of failing every call of the tool, as TypeBox's rejection did before.
appendGrammarToolInputJsonDelta()(api/constrained-sampling) takes the input delta instead of the whole input so far and no longer closes the input; close it with the newcloseGrammarToolInputJson()(#9265)Added
- Added optional
openBrowserOnConfirmandcopyCodeOnConfirmtodevice_codeauth events andOAuthDeviceCodeInfo. Both default totrue; set them tofalseto stop clients from offering to open the verification page or copy the code (#9282, #9301)- Added
StreamingJsonParser, an incremental, tolerant parser for JSON text that arrives in pieces (each piece is read once; snapshots of the partial value never change once returned), andToolCallArgumentsStream, which every provider now uses for streamed tool-call arguments; itsappend()also returns the changes each piece made (JsonChange: a value set at a path, or text appended to a string), for writers that keep their own copy (#9265)- Added GPT-6.1 Terra to the OpenAI, Azure OpenAI Responses, and OpenAI Codex providers with official pricing ($1 input, $0.05 cached input, $1.25 cache writes, $5 output, long-context tier above 272k), tool search, and mid-conversation effort changes. Unlike GPT-6.1 Sol it supports
off(reasoning effortnone); Codex serves it with a 500K context window- Added
Usage.cost.totalFromProviderto distinguish provider-reported billed totals from catalog estimates. Missing orfalsemeans an estimate; combined usage is marked provider-reported only when every part is (#11178)- Added
responseModelto pi-messages terminal events, preserving the concrete model reported by providers such as Radius when a virtual model is requested (#11265)Changed
- The faux provider streams partial tool-call arguments, so
toolcall_deltapartials show growing arguments as real providers do (#9265)- The built-in model catalog is generated from models.dev's v2 catalog, and its per-provider rules moved from
scripts/generate-models.tsinto one TypeScript definition per provider undercatalog/. Models that models.dev types as realtime or image models (gpt-realtime-2.1,gemini-3.1-flash-live-preview,gemini-3.1-flash-lite-image) are no longer offered as chat models, and models.dev's newer OpenAI and Google chat models (chat-latest,gpt-5.6-cyber,gemini-robotics-er-2-preview) are now includedFixed
- Fixed Claude models that accept mid-conversation system messages rejecting a session with a 400 (
role 'system' must precede an 'assistant' message) when a system update was followed by an assistant reply with nothing to send to Anthropic, such as an empty reply or another model's reasoning-only reply (#11091)- Fixed Claude models with mid-conversation effort failing with
Invalid effort levelon accounts whose organization caps effort belowhigh, even atlowormediumthinking, by sending a fixedlowtop-level effort (#10063)- Fixed streamed tool-call arguments being re-parsed in full on every delta, which made CPU time and memory grow quadratically with the size of a tool call (a 90 KB
writeon Anthropic peaked at about 140 MB of heap; a 500 KB one took minutes). Every provider and the pi-messages client now read each delta once, and keep the raw argument text and their other stream state (partialJson,partialArgs,index,customInput,streamIndex, Bedrock's encrypted reasoning bytes) off the content blocks, so it no longer reaches partial messages or transcripts of failed streams (#9265)- Fixed grammar (custom) tool input streaming copying the whole input so far on every delta (#9265)
... (truncated)
Commits
f9a2636Release v1.5.0ddbe02cdocs: audit changelogs and add release highlights6536f80feat(ai,agent,coding-agent): validate tool arguments with pi-schema, drop Typ...b4c2e92fix: remove vulnerable dependency chainsc719d5bfix(ai): do not retry Zhipu usage limit errors (code 1308) (#11572)2e0f175feat(ai): refactor provider definitions (#11368)068e972fix(ai): remove adaptive thinking metadata test that duplicated generator logic44f6851fix(ai): use Anthropic Messages for OpenRouter ~anthropic latest aliasesd3398f8fix(ai): detect LiteLLM ContextWindowExceededError as context overflow (#11494)842c731fix(ai): fall back on Bedrock strict tool limits- Additional commits viewable in compare view
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
@dependabot rebasewill rebase this PR@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency@dependabot ignore this major versionwill close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this minor versionwill close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this dependencywill close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Summary by cubic
Bumps the @earendil-works/pi-ai dev dependency from 1.4.0 to 1.5.0. Note that the transitive @earendil-works/pi-telemetry is also updated to 1.5.0, while @earendil-works/pi-agent-core and @earendil-works/pi-coding-agent still pin pi-ai 1.4.0, so both versions now coexist in the lockfile.
Breaking Changes
- The main entry no longer re-exports TypeBox (
Type,Static,TSchema) andtypeboxis no longer a dependency; import them fromtypeboxdirectly or use@earendil-works/pi-schemabuilders. - Tool argument validation now runs through
@earendil-works/pi-schemaas JSON Schema only, so TypeBox features outside JSON Schema (Type.Refine(),Type.BigInt(), codecs,Format.Set()formats) no longer apply to tool arguments.