Repository navigation
Releases
Zpi v0.3.5
Zpi v0.3.5
Zpi v0.3.5 publishes the native executable worker plugin runtime, SHA-256-verified platform binary downloads, zpi plugin init --zig, zpi plugin update, and built-in zpi update [--plugins] (carrying forward v0.3.4 plus CI cache and macOS x64 fullscreen PTY test stability fixes).
Highlights
- Native executable worker plugins (
runtime: "executable").zpi-plugin.jsonsupports"runtime": "executable"with"entry"or a per-platform"entries"map (darwin-arm64,darwin-x64,linux-x64,linux-arm64).- Runs executable workers directly as
<binary> --worker <id>inside Zpi's strict sandbox with full v1 NDJSON protocol parity (tools,commands,context_snippet,tool_result.appendNote, lazy catalog caching) and zero Node.js requirement when all installed plugins are native executables.
- SHA-256-verified platform binary downloads (
downloadsinzpi-plugin.json).zpi plugin installautomatically downloads only the current platform's binary for pure-source executable plugin repositories (such assyuchua/zpi-plugins), verifies its SHA-256 checksum, sets+x, and registers it.
- LSP-ready hook timeout (
src/plugins.zig).- Raised
tool_resulthook timeout from 2s to 5s to accommodate cold language-server startup on first edit.
- Raised
- Zig plugin scaffold & plugin updater (
zpi plugin init --zig,zpi plugin update [id]).zpi plugin init <dir> --zigscaffolds a compilable Zig 0.17.0 executable worker (build.zig,src/main.zig,zpi-plugin.json).zpi plugin installpersists.zpi-source.jsonsozpi plugin update [id]refreshes installed plugins in place.
- Built-in self-updater (
zpi update&zpi update --plugins).zpi update [--check] [--version vX.Y.Z]downloads and SHA-256-verifies the platform release archive and atomically swaps~/.local/bin/zpi.zpi update --pluginsupdates both Zpi and all managed plugins;zpi update --only-pluginsupdates only managed plugins.
Installation
curl -fsSL https://raw.githubusercontent.com/syuchua/zpi/v0.3.5/install.sh | shOr install the official pure-Zig plugins:
zpi plugin install syuchua/zpi-plugins/plugins/lsp
zpi plugin install syuchua/zpi-plugins/plugins/memoryBuilding from source requires Zig 0.17.0.
Zpi v0.3.3
Zpi v0.3.3
Zpi v0.3.3 is the first published GitHub Release since v0.3.0. It fixes a Linux --output-schema / long literal system-prompt failure on Zig 0.17.0, significantly accelerates multi-platform CI builds, and ships all v0.3.1 and v0.3.2 harness, plugin, and ergonomics upgrades.
Highlights
v0.3.3 Fixes & CI Improvements
- Linux
ENAMETOOLONGfix insystem_prompt.resolve(src/cli/system_prompt.zig).- Multiline prompts (
\r/\n) and inputs whose resolved path exceeds POSIXPATH_MAXorNAME_MAX(255 bytes per segment) now return literal text directly without callingstatFile, avoiding Zig 0.17.0's LinuxdirStatFileLinuxENAMETOOLONG -> error.Unexpectedfailure when using--output-schemaor long--system-prompt/--append-system-promptstrings.
- Multiline prompts (
- Faster multi-platform CI (
build.zig,.github/workflows/ci.yml,scripts/run-e2e-suites.py).- Runs the 369 Zig unit tests in Debug mode alongside a ReleaseSafe
zpi+native-fixturesbuild with Zig build caching, skips slow macOS loopbacksocket.getfqdn()reverse-DNS timeouts in Python E2E servers, and executes offline E2E suites in parallel — cutting cold CI time from 20–30 minutes down to 6–11 minutes.
- Runs the 369 Zig unit tests in Debug mode alongside a ReleaseSafe
Harness & Plugin Capabilities (from v0.3.2)
- Core modular refactoring (~1,486 lines extracted).
- Split
src/main.zig,src/harness.zig, andsrc/tui.ziginto cohesive modules (sessions_cli,tool_summary,herdr_integration,harness_tree,harness_child,fullscreen_render,pickers).
- Split
- Passive plugin context injection & post-tool notes.
- Plugins can subscribe to
context_snippet(startup,compaction,new,resume) to return bounded<plugin-context>blocks (4 KiB per plugin, 8 KiB total), andtool_resulthooks now receive optionalpathand can return boundedappendNoteannotations (2 KiB per plugin, 4 KiB total).
- Plugins can subscribe to
- Non-destructive Observation Masking (
src/observation_mask.zig).- Automatically folds bulky older
tool_resultoutputs in outbound provider requests (configurable viasettings.json"observationMasking") while preserving persisted JSONL transcripts intact.
- Automatically folds bulky older
- Structured JSON output (
--output-schema PATH).- Validates the JSON Schema up front, enforces schema-conforming output with up to 2 automatic self-repair retries, and emits clean validated JSON in
-pmode (orstructured_outputevents in--mode json).
- Validates the JSON Schema up front, enforces schema-conforming output with up to 2 automatic self-repair retries, and emits clean validated JSON in
- Explicit plugin installer (
zpi plugin install <github-url-or-local>).- Installs validated plugins from local directories, GitHub shorthand (
owner/repo[/subdir][#ref]), GitHub tree URLs, orfile://repos into~/.zpi/agent/plugins/<id>, pluszpi plugin remove <id> --purge.
- Installs validated plugins from local directories, GitHub shorthand (
Startup & Ergonomics Polish (from v0.3.1)
- Lazy plugin workers + manifest cache (
plugin-cache.json) +--no-plugins. - Local
--model/ credential preflight checks before entering slow setup or network paths. - Canonical path persistence in
zpi plugin addand fast-fail extension preflight. - Real subcommand help for
zpi sessions --help,zpi sessions list|export --help, andzpi doctor --help.
Installation
curl -fsSL https://raw.githubusercontent.com/syuchua/zpi/v0.3.3/install.sh | shBuilding from source requires Zig 0.17.0.
Validation
Verified on linux-x64, linux-arm64, macos-x64, and macos-arm64 with zig fmt --check, zig build test -Ddebug, zig build install native-fixtures, reproducible release archive packaging (scripts/test-package-release.py, scripts/test-install.py), and all 17 offline E2E suites.
Zpi v0.3.0
Zpi v0.3.0
Zpi v0.3.0 matures the first-party plugin and SDK ecosystem, strengthens day-to-day coding and long-session reliability, aligns RPC and ACP controls, and adds shell completion and offline session management commands.
Highlights
- First-party plugin CLI, v1.0 contract, and lighter runtime requirements. Manage local JS/TS plugins with
zpi plugin init|add|list|remove(stored in user~/.zpi/agent/settings.json; never auto-loaded from project directories). Plain.mjsplugins now run on Node 20+, while native.mtsTypeScript plugins require Node 22.18+ / 24+. Addsturn_endandtool_resultread-only lifecycle hooks alongsidesession_openandsession_close, publishesdocs/spec/zpi-plugin-manifest.schema.json, and ships a first-party cross-session workspace memory plugin undershare/zpi/examples/zpi-memory-plugin(zpi_memory__remember,zpi_memory__recall,zpi_memory__forget,/plugin:memory:list,/plugin:memory:clear). - Zero-dependency SDKs and standalone native plugin examples. Ships three lightweight zero-dependency SDK packages under
packages/(also bundled in release archives undershare/zpi/packages/):@zpi/plugin-sdk(packages/zpi-plugin-sdk): TypeScript declarations anddefinePlugin/defineTool/defineCommandhelpers (zpi plugin init --tsnow scaffolds strongly-typedplugin.mts+zpi-plugin.d.ts).@zpi/rpc-sdk(packages/zpi-rpc-sdk): typed TypeScript/JavaScript client forzpi --mode rpc, withonApprovalandpromptAndWaithelpers.zpi-rpc-sdkfor Python (packages/zpi-rpc-sdk-py): stdlib-only Python 3.10+ client with context-manager lifecycle,on_approval, andprompt_and_wait.- Adds standalone C and Zig minimal native plugin examples under
examples/zpi-native-plugin/that compile cleanly outside the Zpi source tree.
- Coding workflow and long-session reliability.
editnow falls back to a fail-closed unique trailing-whitespace / CRLF-normalized line match when exact byte matching finds zero hits (still rejecting ambiguous matches), reducing model edit retries.readsupports streaming line-skipping reads for text files larger than 8 MiB when explicitoffsetorlimitis passed.- Mid-stream SSE truncation (
TruncatedStream,IncompleteStream,ResponseReadFailed,TlsConnectionTruncated) automatically recovers once via seamless continuation without duplicating already-emitted text. @git:diffand@git:stagedexpand directly in CLI, TUI, RPC, and ACP prompts (bounded to 64 KiB and authorized in--security secure), paired withfd-powered.gitignore-aware fuzzy@pathcompletion in the TUI.- Long-session compaction automatically tracks
<touched-files>(Modified/Read) for the summarizer and aggregates compaction token usage into/cost.
- RPC v1.1+ & ACP parity and bug fix.
- RPC adds
set_plan_mode,get_todos,rewind,export_session, andlist_subagents, plusplanModeandtodoCountinget_state(backed by updatedrpc-v1.schema.json). - ACP advertises and executes
/plan,/todo,/diff,/history, and/rewind, and fixes a bug where locally handled ACP slash commands previously fell through to the model provider.
- RPC adds
- Out-of-box CLI ergonomics & modular core.
- Adds
zpi completion bash|zsh|fishfor shell tab completion andzpi sessions list|exportfor offline workspace session inspection and Markdown export. - Enhances
zpi doctorto report configured user plugins, shell hooks, and Node.mjs/.mtsversion tiers, and updates static error hints inerror_hint.zig. - Extracts cohesive modules from
harness.zigandtui.zig(harness_security.zig,harness_hooks.zig,tui/approval.zig,tui/commands.zig).
- Adds
Installation and compatibility
Download a platform archive and verify its accompanying SHA-256 file. Archives are built by the release workflow for macOS arm64/x64 and Linux arm64/x64 with glibc or musl.
curl -fsSL https://raw.githubusercontent.com/syuchua/zpi/v0.3.0/install.sh | shBuilding from source requires Zig 0.17.0.
Validation
Verified on native builds (zig build -Dtui=none, zig build install test), reproducible archive packaging (scripts/test-package-release.py, scripts/test-install.py), and all 16 E2E suites including scripts/test-opt4.py and scripts/test-sdk-and-examples.py. Check the tagged CI workflow for full macOS and Linux matrix results.
Zpi v0.2.5
Zpi v0.2.5
This release adds a first-party JavaScript/TypeScript plugin API alongside the existing experimental pi extension host and native plugin interfaces. It also expands native subagent workflows, interactive session/task tools, provider protocol handling, and plugin lifecycle and security verification.
Highlights
- First-party JS/TS plugins. Explicitly load local plugins with repeatable
--plugin PATHor thepluginsarray in user~/.zpi/agent/settings.json. Plugins can register schema-validated model tools, local TUI commands (/plugin:<id>:<command>), and session lifecycle observers. They run in separate Node workers over a versioned JSONL protocol; no pi SDK, npm install, or TypeBox is needed for the shipped examples. The.mjsand erasable.mtsexamples and TypeScript declarations are installed undershare/zpi/examples/zpi-plugin. The core CLI remains usable without Node when no plugin is selected; explicitly selected plugins require Node 24.22.1+ in the 24.x line. Plugin code is local executable code, not an untrusted-code sandbox. See the plugin author contract and worker protocol. - Safer plugin dispatch and lifecycle. Plugin tool declarations follow tool selection, including
--no-tools, explicit--toolsre-enable, and exclusions. The host validates tool batches before dispatch, preserves paired results for failed calls, removes crashed workers' tools from later provider turns, drains or quarantines late responses, and closes responsive workers in a deterministic order. Secure mode requires launch authorization, strict child environment isolation, and the configured OS sandbox; project trust never implicitly discovers executable plugins. - Richer native agent workflows. Adds Plan Mode, structured
/todo, filesystem checkpoints and/rewind,/diff, and autonomous/goalloops with optional verification. Native subagents support concurrent and background tasks, progress, bounded results, optional worktree isolation, and usage aggregation in/cost. - Provider, context, and transport improvements. Adds native Gemini streaming and thinking-signature replay, OpenAI Responses reasoning-item replay, Anthropic prompt caching and signed-thinking replay, per-request context-budget clamping, concurrent contiguous read-only tools, and shared keep-alive HTTP transport with cancellation and retry handling.
- Interactive and RPC improvements. Improves regular/fullscreen TUI session commands, queueing and cancellation, Markdown table and code rendering, and tool output previews. JSONL RPC v1.1 adds capability negotiation, model/session/tree controls, images, steering, approvals, compaction, and structured asynchronous events while retaining v1.0 compatibility when initialization is skipped.
- Reliability fixes. Corrects Linux non-TTY terminal attribute handling in first-run onboarding, keeps Anthropic context-budget fixtures aligned with cached system blocks, and rejects stale or duplicate worker frames rather than allowing them to affect a later operation.
Installation and compatibility
Download a platform archive and verify its accompanying SHA-256 file. Archives are built by the release workflow for macOS arm64/x64 and Linux arm64/x64 with glibc or musl. The installer remains available:
curl -fsSL https://raw.githubusercontent.com/syuchua/zpi/v0.2.5/install.sh | shBuilding from source requires Zig 0.17.0. Existing pi SDK extensions and experimental native plugins remain separate interfaces; this release does not claim full pi compatibility, a stable native ABI, or containment of untrusted plugin code.
Validation
The release workflow runs the Zig, CLI, RPC, ACP, trusted-execution, pi SDK, native C/Zig plugin, provider fixture, and plugin protocol/PTY suites on native macOS arm64/x64 and Linux arm64/x64 runners. Each release archive is stripped, smoke-tested in its target runtime, checksummed, and tested against the unpacked .mjs and .mts examples. Check the tagged CI workflow for final platform results and archive artifacts.
Zpi v0.2.4
Zpi v0.2.4
This release improves the interactive terminal workflow with clipboard image attachments and responsive Markdown rendering, while tightening local diagnostics, extension-host compatibility checks, and unattended startup validation.
Highlights
- Interactive clipboard image attachments. Press
Ctrl+Vin the TUI to paste a PNG, JPEG, WebP, or GIF from the system clipboard. macOS reads the native pasteboard; Linux useswl-pasteon Wayland orxclipon X11. Clipboard helpers run with a restricted environment and bounded output; image reads are audited under the clipboard-read capability.imagePasteMaxBytesin user settings can lower the default 2 MiB limit. Pasted images are attached to the draft and sent with its text; startup--imageremains available for print-mode requests. - Responsive Markdown in the TUI. Pipe tables render with terminal-width columns, alignment, and wrapping, including CJK text; tables that cannot fit fall back to source text. Long fenced-code lines wrap while preserving indentation and highlighting. Session replay renders blocks at the current width. Print output and
/copyretain the original Markdown. - More useful doctor reports.
zpi doctor --trust-projectreports counts for project skills, prompt templates, and MCP entries, plus how many context files can be loaded. Doctor does not run MCP commands, project instructions, or user code. Project-context settings and explicit trust flags are documented more clearly. - Local provider preflight and clearer CLI guidance. In the default compatibility mode, startup prompts check provider/model configuration and credential availability before starting MCP or extension resources, without network access or OAuth refresh. The preflight does not reject a model merely because it is not in the local catalog. Custom endpoints can remain anonymous, and known authentication headers are recognized. Fork-session errors now state that
--fork-sessioncannot be combined with-p. - Capability-based pi SDK checks. The experimental TypeScript host and fixtures probe the SDK APIs they use instead of maintaining a coding-agent SDK version allowlist. The separate
pi-aiversion match and protocol checks remain in place; passing the probe is not a claim of full pi or extension compatibility. - Configuration and terminal integration. Settings can control the image-paste size limit and initial thinking/tool-output display. Interactive TUI lifecycle updates use OSC 7501, and startup validation preserves the explicit security requirements for unattended execution.
Validation
The Zig 0.17.0 build and Zig test suite passed locally. The local macOS arm64 release archive passed its smoke test and checksum verification. The full CLI integration and TypeScript-host fixtures also passed locally with pi SDK 1.7.0. The release workflow builds stripped binaries and publishes macOS arm64/x64 and Linux arm64/x64 glibc/musl archives with SHA-256 checksums. Platform release artifacts are produced by the tagged GitHub Actions workflow.
Zpi v0.2.3
Zpi v0.2.3
This release combines a more adaptable terminal workflow and safer session recovery with improvements to ACP integrations, tool-call validation, and interactive control. It also makes provider and tool failures clearer without claiming broader protocol or compatibility parity.
Highlights
-
Narrow-screen status bar. At phone-sized terminal widths the footer prioritizes the provider/model and context-window usage, hiding lower-priority workspace, token, and activity fields.
-
Folded multiline paste previews. Bracketed multiline pastes remain intact in the prompt buffer and are sent to the model in full, while the editor shows a compact line-count preview. Editing or moving within the pasted text reveals the full content. Slash-command completion remains available during active turns, and failed tool output can be folded without hiding its exit status.
-
Markdown in user messages. User-entered Markdown now receives the same lightweight terminal styling as assistant content, including inline code and fenced code blocks such as
context. -
Resume and fork sessions more reliably. Resuming restores the saved model and thinking level. When another Zpi process holds a session's exclusive writer lock, create an independent snapshot and continue in it:
zpi --fork-session /path/to/session.jsonl --session /path/to/company-session.jsonl zpi --session /path/to/company-session.jsonl
A fork contains the complete committed transcript and saved model/thinking selection as of the snapshot read. The source process remains untouched and can continue writing its own session. The two resulting sessions are independent; later changes do not synchronize between them.
-
ACP controls and slash commands. ACP clients receive model and reasoning-effort selectors, and available skill/prompt commands are advertised and handled through the session interface. Model/thinking selection remains effective across prompts in the same ACP process; settings cannot be changed during an active prompt.
-
Safer tool dispatch. Tool arguments are checked against a bounded JSON Schema subset before dispatch, across built-in, MCP, and native/plugin tools. If a provider returns an invalid call in a batch, the batch is rejected before any tool runs and each call receives a paired error result. This is not full JSON Schema support.
-
Improved TUI controls and feedback. Fullscreen conversations can preview edit diffs with clear added/removed line styling and expand the preview when needed. Existing queued follow-ups and Ctrl+S steering remain available while a turn is running.
-
Clearer diagnostics. Busy sessions now explain the fork workflow.
HttpConnectionClosing(peer/proxy closed before response headers) andRequestTimeout(Zpi's end-to-end request deadline expired) have distinct hints; the former alone does not establish that the configured timeout was too short.
Validation
Validated locally with Zig 0.17.0: unit tests, build, formatting, package fixture, and the offline CLI integration suite passed. The tagged release workflow built and published stripped archives for macOS arm64/x64 and Linux arm64/x64 (glibc and musl), each with a SHA-256 checksum. ACP and tool-schema coverage includes fixture tests; provider-backed behavior still depends on the configured service.
Zpi v0.2.2
Zpi v0.2.2
This release adds an ACP v1 frontend for editor integrations, improves persistent session recovery and TUI steering/diff presentation, and raises provider request timeouts for longer model responses.
Highlights
- ACP v1 frontend for Zed and other editors. Implements initialization and capability negotiation, session creation/loading, prompt streaming, cancellation, tool-call updates, and secure-mode permission requests. Persistent ACP session IDs are stable session-file paths;
session/loadrestores the active history after an agent process restart. Session loading is not advertised when persistence is disabled. Zpi retains filesystem and tool ownership; client filesystem/terminal capabilities, images, and MCP server overrides are not advertised. - TUI steering feedback. Ctrl+S confirms accepted steering in the busy editor, and the footer shows the pending steer count. Queue failures leave the draft available for editing. Enter continues to queue follow-up prompts.
- Edit diff rendering and replay. Fullscreen tool cards retain edit diffs in session history and render added, removed, and hunk lines with distinct colors. Compact/fullscreen and regular TUI previews retain their existing expansion behavior.
- Longer provider request window. OpenAI Chat Completions, OpenAI Responses, Anthropic, and Gemini clients now default to 120-second request timeouts instead of 60 seconds.
- Zed configuration and Herdr integration. Documents the Zed custom ACP server setup and reports the interactive Zpi pane to Herdr when launched inside a Herdr-managed terminal.
ACP clients such as Zed render composer controls for model, mode, and effort when an agent advertises session configuration options. Zpi v0.2.2 advertises a model select (category model) built from the configured Model Catalog and handles session/set_config_option, so Zed can switch the provider/model from its native selector. The agent still owns provider auth and configuration files; no Zed-side plugin is required.
See README.md, ACP implementation notes, and docs/security.md for usage and security boundaries.
Zpi v0.2.1
Zpi v0.2.1
This release completes the MCP client protocol surface, polishes the native TUI, hardens MCP OAuth security, and fixes several real-world usability and provider compatibility issues.
Highlights
- Complete MCP protocol support (
pagination,resources,prompts,progress). Follows boundednextCursorpagination with cycle detection (tools/list,resources/list,resources/templates/list,prompts/list); registers capability-gatedmcp__<server>__list_resourcesandmcp__<server>__read_resourcetools; exposes server prompts as/mcp:<server>:<prompt>slash commands (with TUI/autocomplete andkey=value/positional arguments); streams livenotifications/progressupdates across stdio, Streamable HTTP SSE, and Legacy SSE into--mode jsonand the TUI progress bar; and serializes empty MCP parameter/capability objects strictly as{}. - Full-path SSRF protection for MCP OAuth 2.1. Enforces
validateUrlSsrf+ connected-peer IP verification (blocking loopback, private, link-local, and cloud metadata addresses, and re-validating redirects) across RFC 9728 PRM discovery, RFC 8414/OIDC metadata, authorization, DCR, token exchange, and automaticmcp:*token refresh (--allow-loopback-web-fetchopt-in for local testing). - TUI visual and ergonomics polish. Adds framed Markdown code blocks with zero-dependency syntax highlighting (Zig, Rust, C-like, JS/TS, Python, Shell, JSON, Diff), inline italic/link/ordered-list/table styling, determinate percentage progress rules, tool execution duration badges, and
secure/<N> mcpfooter indicators. Resumed sessions no longer reprint the startup logo/hints, and the sticky pinned user prompt header only appears once the active prompt scrolls above the visible viewport. - Provider compatibility and daily-use CLI fixes. Fixes OpenAI Chat Completions decoding for sparse / 1-based
delta.tool_calls[].indexemitted by Responses-to-Chat proxies (eliminating falseIncompleteToolCallfailures); adds--max-turns N(1..10000, default 32); prints actionable one-line error hints by default (with--verbosestill adding build metadata); and fixes--help/-hhandling across allzpi mcp,zpi auth, andzpi modelssubcommands.
See README.md and docs/security.md for usage and security boundaries.
Zpi v0.2.0
Zpi v0.2.0
This release introduces a major connectivity and extensibility upgrade while keeping Zpi small, fast, and zero-dependency: a three-layer Model Catalog with online sync, a unified pure-Zig OAuth engine with interactive TUI /login//logout//auth, OpenAI Codex Responses backend compatibility, complete MCP Streamable HTTP + Legacy SSE + OAuth 2.1 support, and declarative Skill tool registration.
Highlights
- Three-layer Model Catalog (
zpi models sync/list). Ships with a curated compiled-in catalog acrossopenai,openai-codex,anthropic,gemini,github-copilot,openrouter,opencode-go, anddeepseek.zpi models syncqueries native provider/modelsendpoints first and enriches metadata (context windows, output limits, capabilities, and pricing) frommodels.dev/api.jsoninto atomic0600~/.zpi/agent/models-cache.json, while preserving backward-compatiblemodels.jsonoverrides. - Unified pure-Zig OAuth &
auth.jsonengine + TUI/login,/logout,/auth. Stores credentials atomically in0600~/.zpi/agent/auth.jsonwith transparent token refresh and zero secret echoing:openai-codex(PKCE +localhost:1455callback + JWTchatgpt_account_id),github-copilot(RFC 8628 Device Flow + Copilot session token exchange),anthropic/claude(PKCE + Bearer refresh +anthropic-beta: oauth-2025-04-20),gemini(Google Cloud OAuth PKCE + Bearer refresh ongenerativelanguage.googleapis.com),openrouter(official PKCE code-to-key exchange), andopencode-go(--stdin/interactive token). Interactive TUI adds/login,/logout, and/authwith provider selection, slash autocomplete,/hotkeysdocumentation, and live auth reload. - OpenAI Codex Responses backend compatibility. Automatically detects
openai-codex//codex/responsesendpoints, lifts system messages to top-levelinstructions, omitsmax_output_tokens, keepsstore: falseandstream: true, and setstool_choice: "auto",parallel_tool_calls: true, andinclude: ["reasoning.encrypted_content"]. - Complete MCP Streamable HTTP, Legacy SSE, and MCP OAuth 2.1. Extends the MCP client alongside
stdiowith Streamable HTTP (http: JSON + SSE responses,Mcp-Session-Id,DELETEcleanup) and Legacy HTTP+SSE (sse: background SSE reader thread andevent: endpointcorrelation). Enforcesweb_fetchSSRF validation andmcp.start+network.connectpolicy/audit checks, adds--mcp-http,--mcp-sse, andzpi mcp add --url, and supportszpi mcp login <name>(RFC 9728 PRM, RFC 8414 AS Metadata, DCR, PKCE S256, and RFC 8707resource). - Declarative Skill tool registration (
tools.json). Skills can register bounded custom tools (skill__<skill>__<tool>) via a declarativetools.jsonbesideSKILL.mdwith typed argument templates, zero shell interpolation, rejection of model-controlledargv[0]and..traversal,Source.skill+Capability.process_execauthorization/audit + OS sandbox confinement, and--trust-project-skillsgating for project-scoped skills.
See README.md and docs/security.md for usage and security boundaries.
Zpi v0.1.5
Zpi v0.1.5
This release focuses on out-of-the-box daily usability while keeping Zpi small, fast, and dependency-light: native web_search with zero-config Exa, a native Google Gemini API provider, /cost and /context inspection commands, zpi auth/models/mcp management subcommands, and persistent mcp.json configuration.
Highlights
- Pure-Zig native
web_searchtool. Automatically selects Brave (BRAVE_API_KEY), Tavily (TAVILY_API_KEY), or SearXNG (SEARXNG_URL/ZPI_SEARCH_URL) when configured, and defaults to zero-config Exa (https://mcp.exa.ai/mcp, Streamable HTTP JSON-RPCweb_search_exa) with no API key required (ZPI_SEARCH_BACKEND=duckduckgois also supported). Reusesweb_fetchSSRF validation andnetwork.connectpolicy/audit enforcement. - Native Google Gemini API client. Built-in
geminiprovider (gemini-generate-contentviastreamGenerateContent?alt=sse, defaultgemini-2.5-flash,GEMINI_API_KEY/GOOGLE_API_KEY) authenticates viax-goog-api-keyheader (never URL query strings) and supports streaming text/thoughts,systemInstruction, multi-turncontents,inlineDataimages, sanitizedfunctionDeclarations,functionCall/functionResponseround-trips,thinkingConfig, andusageMetadata(includingcachedContentTokenCount). /costand/contextinteractive commands. Tracks per-session request counts, input/output tokens, and cache read/write tokens across OpenAI, Anthropic, and Gemini, estimates USD when pi-compatiblemodels.jsoncostpricing is configured, and breaks down active context window usage by category.- Out-of-box
zpi auth,zpi models, andzpi mcpCLI subcommands.zpi auth status|set|removemanages provider credentials via--api-key-envor--stdinwith atomic0600writes and zero secret echoing;zpi models list|set-default <provider>/<model>manages defaults insettings.json;zpi mcp list|add|removemanages~/.zpi/agent/mcp.json. - Restrained
mcp.jsonconfiguration with project trust gating. Loads user-level~/.zpi/agent/mcp.jsonby default (--no-mcp-configdisables it) while keeping project.zpi/mcp.json/.mcp.jsonopt-in behind--trust-project-mcp. Configured MCP servers pass through the samemcp.start+process.execcapability checks, audit logging, and OS sandbox confinement as--mcp-stdio.
See README.md and docs/security.md for usage and security boundaries.