Skip to content

v20261128

Latest

Choose a tag to compare

@github-actions github-actions released this 28 Nov 12:45
· 165 commits to main since this release

New Features

  • Compaction recall & retention: summaries now cite session entries ([rN]), include ## Key Facts (cNrN) and ## Replaced Context (E<n>) sections restored on demand via recall_context, enforce long-session retention rules, and add opt-in compaction.growthGateTokens (see Compaction Reference and Compaction settings) (#767, #794)
  • Externalized truncated tool outputs: truncated read, grep, find, and ls results are saved under the agent directory and paged back in 50KB chunks via recall_tool_result (#767)
  • Autonomous image generation (generate_image): generates or edits images (supporting aspectRatio and size) using the session provider's image model when available, gated by the permission prompt in non-yolo sessions (see Use image models) (#757, #893)
  • Built-in git, /token-usage, batch (execute_many), and subagents.preferredCli: unified git (status|diff|log|branch, including reading diffs) and /token-usage join the built-in modules, hidden execute_many batches multiple tool calls into one round trip, and subagents can run via claude, codex, or agy (see Slash commands) (#803, #824)
  • Read-only subagent viewer & status UI: pressing Down in an empty editor opens a read-only subagent list and job report overlay; the working indicator aligns at column 0 with a breathing dot, and retry/compaction rows shimmer at 30fps (#877, #906)
  • o200k_base token estimation, Usage.pricing snapshots, and fail-closed sandbox: context estimation uses gpt-tokenizer o200k_base instead of character division, costed responses freeze rate snapshots on usage.pricing, and unattended sessions fail closed when a configured sandbox launcher is missing (see Security) (#763, #803)
  • Embedded sidecars in full: full bundles embed TUI native prebuilds and photon wasm again, removing on-demand downloads so image and clipboard features work offline (#840)

Added

  • Ported four pi-extensions picks as built-in modules: pi-deepwiki (repo-grounded Q&A), pi-git-tools (read-only git, no gh), pi-meat (faithful reading diff via subagent), and /token-usage over the existing usage ledger. subagents-mini gains subagents.preferredCli so a spawn can run claude, codex, or agy with the harness default model (issue #824)

  • Read-only subagent viewer: pressing Down on an empty editor when subagent jobs exist opens a job list overlay (Up/Down selects, Enter opens the selected job report, Esc exits) without altering the transcript or the live widget under the editor

  • Added the hidden built-in batch module (execute_many tool, module/batch build component) to run multiple callable tools sequentially or in parallel within one model round trip (issue #803)

  • Costed responses now freeze an auditable Usage.pricing snapshot (provider, model, revision, rates) via calculateCost() and preserve it in combineUsage(), keeping historical spend explainable across catalog edits (issue #803)

  • A compaction summary cites the session entries behind its facts as [rN], and recall_context reads one back. Every message handed to the summarizer carries its entry id, the summary prompt asks for a trailing <refs> block that defines each tag, and the tool resolves the tags against that block and appends a context_recall entry, so the recalled history returns as history instead of a tool result the next compaction eats. An undefined tag, a summary without a <refs> block (any session compacted before this change), an entry still inside the kept region, and a block over a quarter of the context window are all refused with a reason (#767)

  • Compaction summaries now follow explicit long-session retention rules: exact paths, signatures, errors, decisions, constraints, and unfinished work are kept; consumed logs, repeated reads, and settled discussions are dropped. The rules live in the summarization system prompt and do not change the summary format (issue #767)

  • The summarization system prompt now keeps every open, unsuperseded user objective as its own line even when the summarized range made no progress on it, and requires user requests, decisions, and constraints to be quoted verbatim or explicitly marked as a paraphrase. Both the default and the Codex compaction paths share this prompt, so the rules apply to each (#794)

  • Compaction summaries gain a ## Key Facts block with stable refs (c0r2) to the session entries they compress; the recall_context tool restores those original messages on demand when a summary is too compressed to continue safely (issue #767)

  • A compaction summary now lists the history it replaced, and recall_context pulls one region back. The summary ends with a ## Replaced Context (recallable) section, one line per replaced turn with a ref, a one-line preview, an entry count, and a token size; recall_context({ ref }) answers with the original messages of that region, capped at 8000 tokens so a recall cannot refill the window the summary just freed. A ref is an ordinal over the branch (E3 = the third model-visible entry), recomputed from the branch and the newest cut point, so it survives a reload and a fork with no schema change. session_before_compact can now post-process a summary it did not write: the event is dispatched a second time with replacedSummary when no handler built one, which is what lets the appendix land on the Codex-style summary (#767)

  • Added opt-in compaction.growthGateTokens. Automatic threshold compaction now waits for enough estimated context growth since the last compaction, so a threshold that is barely exceeded cannot produce a second summary right after one finished. The default 0 keeps the existing threshold-only behavior (issue #767)

  • The pi-image module registers generate_image, the first caller of modelRegistry.generateImages(). It picks an image model for the session's own provider when there is one (a ChatGPT OAuth session draws with its own subscription, otherwise the first available image model), returns the image as a tool result, and writes it to the path the model asked for, taking the extension from the returned format. Its guideline lets the model draw on its own when the task's output includes an image file, not only when the user asks for one (#757)

  • generate_image accepts optional aspectRatio (e.g. "16:9") and size (e.g. "2K") arguments and forwards them to image providers. Values are passed through unchanged, so an unsupported value is reported by the provider (issue #893)

Changed

  • todo tool result cards for add, done, undone, and clear no longer echo the full step list beneath the count summary; list still renders all steps (issue #908)

  • Unattended sessions (print, json, rpc) now fail closed on shell calls when a configured sandbox launcher is missing, instead of running commands unsandboxed; interactive sessions keep the warning (issue #803)

  • Context token estimation (estimateTokens, message codecs, estimateContextTokens) now uses o200k_base (gpt-tokenizer) instead of chars / 4 or chars / 3.5 and excludes opaque thinkingSignature payloads, preventing severe underestimates on code, JSON, and CJK text (issue #763)

  • mcp subagent calls now run with only the single mcp__<server>__<tool> tool and --mcp-only-prompt --no-context-files instead of inheriting read, the coding-assistant system prompt, and AGENTS.md (issue #800)

  • Cloudflare Workers AI and Cloudflare AI Gateway default models now target @cf/zai-org/glm-5.3 (issue #822)

  • Qwen Token Plan Individual now lists qwen4-max instead of the retired qwen4-max-preview (upstream 22f5f2995)

  • Together drops reasoning-effort overrides for deprecated models; every listed Together reasoning model takes the Together thinking toggle (upstream e459be65a)

  • GitHub Copilot Claude and GPT-6 models preserve the prompt cache across thinking-level and tool changes: Claude uses mid-conversation effort and tool changes, GPT-6 uses configuration_update items, and Claude models declare 5-minute and 1-hour cache lifetimes for warming (upstream d5b453814)

  • meat is folded into the git tool as git action=diff with mode=raw|reading. The pi-meat module and build component are removed; the compiler and chunker now live under pi-git-tools/src/vendor/. mode=reading still requires pi-subagent-mini (issue #870)

  • The git tools are now one git tool with action=status|diff|log|branch, and web_search, read_page, and the DeepWiki tools are now one web tool with action=search|fetch|wiki_structure|ask_repo. The pi-deepwiki module is merged into websearch; /deepwiki now prefills a web call (issue #852)

  • The codex-compaction module is renamed to compaction and moved from src/modules/codex-compaction/ into src/core/compaction/. The session machinery it replaced lives there as *-core.ts files; the module registry, buildconfig component, and test imports use the new name (issue #842)

  • full embeds the TUI native prebuilds and photon wasm again; the on-demand sidecar download, its release tarball, the GitHub/AtomGit mirror URLs, the NANOPI_OFFLINE host probe, and --sidecars-out are removed. First image read and first clipboard use need no network (issue #840)

  • The machine hostname is now shown on its own line under the welcome box directory and as a Hostname: row in /status. The standalone pi-hostname module is removed (issue #835)

Fixed

  • The /plan exit prompt now reaches nanopi webui sessions through the structured-input card, so approving submits the plan for execution instead of requiring a manual mode switch (issue #903)

  • Fixed OpenRouter image models billing image tokens at the text rate or not at all, ignoring choice errors and non-stop finish_reason, and missing provider-reported usage.cost (upstream ccda1f74b, 596540d43)

  • Fixed GitHub Copilot models on openai-completions losing their reasoning state between turns by preserving reasoning_opaque on thinking blocks and replaying it with reasoning_text (upstream ede8bdca0)

  • Antigravity /login now matches the official agy client's authorization flow (PKCE S256, state validation, cloud-platform / userinfo.email / aicode scopes) and sends matching client headers on loadCodeAssist / onboardUser (issue #825)

  • Error codes like my_plugin_request_too_large_flag no longer trigger context-overflow compaction; only standalone request_too_large and HTTP 413 do (upstream 32c7f6d7b)

  • Completed retry backoffs remove their abort listeners, and createProvider merges fetched model catalogs once per publish instead of per getModel()/getModels() call (upstream 51ba3ab5b, 073b0bae8)

  • Provider errors reporting "Connection closed.", bare Node socket codes (ECONNRESET, EPIPE, ETIMEDOUT, ...), "connection reset by peer", and five additional transport failure patterns now enter the retry classifier (upstream 9b88b94e2, 4699b5b26, issue #743)

  • openai-completions sends reasoning-model system messages with the developer role only on api.openai.com (and system on Groq and other compatible hosts), non-type schema nodes fall back to non-strict for OpenAI, and non-strict Anthropic tool schemas keep root additionalProperties (upstream b82477b7b, 406e719a6, aa47cedce)

  • CRLF SSE frames split across chunks no longer drop event: fields, and failed OAuth token exchanges name missing/invalid fields without echoing raw token responses

  • Google discrete thinking selects from the model's thinkingLevelMap (supporting gemini-4-hydrogen xhigh, gemini-4-argon, and gemini-4-carbon) and maps @google/genai 3.3.0 FinishReason values (MISSING_THOUGHT_SIGNATURE, ESCALATION, PUP_LIMITED_DISABLED, MODEL_ARMOR) to "error" (issue #723, issue #731)

  • Azure catalog clones preserve 272k+ long-context pricing tiers and give GPT-6 models (gpt-6-astra, gpt-6-sol, gpt-6-luna, gpt-6.1-sol) their 1.05M contextWindow; Kimi K3 cacheWrite bills at $3/MTok (issue #743, issue #750)

  • Endpoint provider detection and attribution match exact hostnames via matchesHostname instead of baseUrl.includes(...), Anthropic OAuth adds prompt=login and appends deepestCause(error) on connection errors, and mergeStreamingArgumentObject guards __proto__/constructor/prototype keys (issue #743, issue #796)

  • SettingsList (/settings) uses the configured tui.select.confirm and tui.select.cancel keys in its hint (upstream b882d08f3), and interactive selectors (/model, /login, /scoped-models, /resume, /effort, /settings) keep selection when non-editing keys leave the search unchanged (issue #783)

  • Right-click paste no longer inserts the clipboard twice in Tabby on Windows (upstream 165c70df9)

  • Repeated prompts in Up-arrow history move to the front instead of duplicating, and pressing Enter on an absolute-path autocomplete menu completes the path instead of submitting (upstream 06a20368a, 9a7cfba47)

  • Markdown after an unclosed $ before a number (such as +$50) no longer renders the rest of the paragraph raw, hyperlink() caps OSC 8 URLs at 8192 characters, bracketed-paste end markers and LaTeX normalizeScriptValue() scan linearly, and parseDiffLine() scans linearly without regex backtracking (upstream 362bf6f1b, 6ca01d1e9, da7e26cc8, issue #796)

  • Kitty image IDs stay within the signed 32-bit range for Konsole, and appending in-viewport Kitty images skips full-screen redraws (upstream ed0f27d62, fd68df1cf)

  • An aborted agent run ends at the turn boundary even when finishTurn returns continue

  • Session discovery and writes surface read/write failures instead of returning an empty list or advancing in-memory state past a failed write; read with limit stops streaming once the page is full; /tree empty search displays the query and clear search hint

  • grep waits to stop ripgrep until a match past the trailing-context window proves results were cut off, preventing intermittent missing Search stopped early notices (issue #747)

  • ModelRuntime.getProviderAuthStatus() marks unresolved stored !command credentials as unresolved instead of configured (issue #816)

  • Restored tool-result-store in buildconfig.json moduleBundles so single-file and flavored builds bundle recall_tool_result (issue #775)

  • ask_user_question now decodes double-encoded tool arguments before schema validation. A resumed session whose questions array or its elements were serialized as JSON strings opens the dialog instead of failing validation (upstream #244, issue #885)

  • Fixed HTML export inserting viewer scripts and CSS with String.replace string replacements, which expanded $$ and $& in template.js and highlight.js and showed the cost without its dollar sign (upstream 41da1a524)

  • Fixed WSL detection in terminals that start the shell without WSL environment variables: keybindings, footer branch polling and clipboard now share one check that falls back to /proc/version (upstream e4ed3d610)

  • Fixed app.message.followUp (Alt+Enter) ignoring an open autocomplete menu and queuing the half-typed text; it now applies the selected suggestion like Enter (upstream 27157503e)

  • Fixed key hints that named hardcoded keys: the extension editor and session rename name tui.input.submit, /hotkeys names tui.select.cancel for autocomplete, and session and submenu selectors follow remapped keys (upstream b882d08f3)

  • Retry and compaction status rows shimmer again like the working row: a module can register a status renderer for those kinds, the host keeps the countdown text, and each row advances its own band at 30fps. The renderer receives kind in its state; existing working-only registrations keep their behavior (issue #877)

  • The working row shows a breathing dot before its shimmer text, growing from a point into a blue-to-purple star on a 2.4s cycle. It now starts at column 0, aligned with the dots on tool rows such as • Running (issue #906)

  • Sign in with ChatGPT accepts the single .onboarding_entrypoint=life_sciences suffix OpenAI appends to the OAuth callback state for some accounts. Other suffixes and repeated suffixes still fail with OAuth state mismatch, and the authorization request is unchanged (issue #854)

  • pi-fake-opencode follows opencode2api's latest free-tier shaping rules: client tools now travel under the plain mcp_<digest> namespace instead of clint_, which the tier learned to refuse with 429, and top-level client tool descriptions use NBSP instead of ASCII spaces, which the tier also rejects. Parameter descriptions and official tool definitions stay verbatim (#841)

  • recall_context loads without startup errors again. The three recall strategies now live inside one codex-compaction module, whose single recall_context tool dispatches by ref shape: [rN] citations, Key Facts cNrN refs, and replaced-region E<n> refs all work from one tool call (issue #832)

  • In-context compaction now replays the captured next-turn request, including tool declarations, request metadata, and the resolved API key. A provider that keys its cache on any of those fields no longer drops the cached prefix and falls back to a paid standalone summary (issue #830)

  • The bash tool on Windows now finds Git for Windows installed outside Program Files: it asks the git.exe on PATH for its installation (git var GIT_SHELL_PATH, Git 2.47+) and uses that Git Bash before the WSL launcher System32\bash.exe (upstream e8ee38887)

  • Copies on Wayland pass an explicit text/plain MIME type to wl-copy, so clipboard managers such as Klipper no longer discard text whose inferred type was e.g. application/x-ruby (upstream 2d8133085)

  • Sessions with more entries after the last compaction than fit in a function call's arguments now build their context instead of throwing RangeError: Maximum call stack size exceeded (upstream cb1205e46)

  • Invalid models.json is reported as a warning in services diagnostics, so print, JSON, and RPC modes name the cause instead of failing with "Model not found" (upstream eee9f85fc)

  • The ! command cancel hint names the configured interrupt key instead of tui.select.cancel or a hardcoded Esc (upstream 745338811)

  • The RPC JSONL reader and session file loader scan only newly read text, so a line larger than the read chunk is not rescanned on every chunk (upstream da7e26cc8)

  • Terminal restore sequences are flushed before CLI exit: interactive shutdown, --resume cancellation, and startup selectors now wait for queued stdout/stderr writes (at most one second), so the cursor, bracketed paste, and Kitty keyboard state are not left behind when the process exits (upstream 7c05885bc)

  • Unscoped syntax-highlighted text uses the theme foreground again, so tool previews stay readable when the terminal and nanopi use contrasting color themes (upstream 562da75f9)

  • An external SIGTSTP (kill -TSTP) now follows the same suspend path as Ctrl+Z, restoring the terminal and redrawing on fg; the listener is tied to terminal ownership so a child that owns the terminal afterwards is suspended normally (upstream e4f50d76d, 3107a58d2)

  • read keeps the non-vision image warning in the tool details renderer instead of the tool result text: switching to a vision model no longer sends an image with a stale note saying the model cannot see it (upstream 4be4cb4f5)

  • Truncated read, grep, find and ls results are saved under the agent dir instead of being lost: the tool result carries a recall_tool_result ref and a path, and the new module reads the stored text back in 50KB pages so one oversized log can no longer spend the whole context on the way back (issue #767)

  • /retry works on the failure auto-retry gave up on: every attempt that loop made is omitted from the model projection, so the branch held no replayable response and the command answered "No failed response to retry" right after a visible failure. The turn is repeated with a fresh retry budget now, and the failure returns to the transcript so a second /retry still has something to replay

  • A grep match inside a file with NUL bytes is reported as a binary match: a minified bundle, a git show dump, or a UTF-16 document printed as ordinary source rows, so the answer looked like source code the model could quote. The rows are still returned, and a notice says how many of them are inside binary content (#763)

  • A bash or tool-output temp file is closed once, on every exit path, and its write completion is awaited: a failed write used to surface as an unhandled error event (or not at all) while the caller got a truncated log path back

  • The grep tool aborts during tool lookup and path probing, not only once ripgrep is running: an interrupt that landed before the child existed left the search to finish on its own, and a child killed by the abort was no longer reported as a ripgrep exit failure

  • Project trust stops its ancestor walk at the user's home directory: a stray .agents/skills above it (/home, /) is user territory, and treating it as project context put every checkout underneath behind a trust prompt

  • RpcClient.promptAndWait returns as soon as a prompt the session handled itself reports handled, instead of waiting out the event timeout for an agent_settled that will never arrive

  • pi-fake-opencode replays each lane's own identity instead of one shape for both: the 2.x lanes (/inference, /zen/go) send the conversation affinity in x-opencode-session, x-session-affinity and X-Session-Id with the client's own session in x-opencode-session-id, and stop sending x-opencode-request, which the v2 gate answers with 403 FreeTierError; a forked session keeps its child id while affinity stays on the parent. The 1.x /zen lane gains the AI SDK's Accept: */* and a provider-utils version that depends on the wire protocol (4.0.23 chat, 4.0.40 responses, 4.0.46 anthropic) instead of a fixed one. The 1.x prompt and tool set are now their own captures rather than the 2.x pair with names substituted: eleven tools (bash, task, todowrite where the 2.x CLI has shell, subagent, question), a different description and schema behind every shared name, no strict field on any of them (issue #725)

Removed

  • DeepWiki research is removed from the web tool: action=wiki_structure, action=ask_repo, the /deepwiki command and the DEEPWIKI_MCP_URL override no longer exist. Search and fetch are unchanged (issue #861)

  • Removed the pi-output-compact module, its /output-compaction command, and its build component. Tool output is no longer rewritten before entering the model context (issue #886)

  • Removed Qoder entirely: the startup//qoder-checkin daily check-in, the module/qoder-checkin build component, Qoder provider docs and the NANOPI_QODER_CHECKIN switch. The browser sign-in was already removed; now /qoder-checkin does not exist and no Qoder credential is read (issue #855)

  • Removed the install-telemetry and analytics shell: core/telemetry.ts, the first-time setup dialog, enableInstallTelemetry, enableAnalytics, and trackingId are gone. Provider attribution headers were never telemetry and stay, behind enableProviderAttribution (default true) and NANOPI_PROVIDER_ATTRIBUTION, which replaces NANOPI_TELEMETRY (issue #896)