Skip to content

pi-python v1.1.0

Choose a tag to compare

@github-actions github-actions released this 24 Nov 16:58
· 16 commits to main since this release

This is a minor release. It introduces code mode (pi-codemode-py) with deferred tool_search, shared sandbox v2, and runtime Auto gating, adds the built-in skill-creator skill, adds a live thinking_level session option saved and restored on load, makes zypi consume ACP usage_update, and fixes bash late output-limit detection, cross-chunk <thought> leading whitespace, and edit diff persistence. All eight Python packages and the TUI move to 1.1.0.

Added

  • Code mode (pi-codemode-py), deferred tool_search, shared sandbox v2, and runtime Auto gating (pi-agent-core, pi-agent-harness, pi-agent-cli, pi-codemode, pi-mcp): new pi-codemode-py extension exposing codemode (async Python orchestration in the promoted pi_agent_core.sandbox protocol v2 child process), tool_search, and /codemode [status|on|hybrid|only|off]; deferred tool loading (activate_tools / deactivate_tools, deferred_tool_names) and gated AgentHarness.invoke_tool (origin={"kind": "codemode", ...}); home [codemode] configuration table in agent.toml (enabled, mode, defer_mcp, require_approval = true by default so outer calls still prompt in ask/auto while inner tools.* calls go individually through permission and Auto gating); deferred MCP tool exposure in pi-mcp-py (PI_MCP_EXPOSURE); bundled into zycode-agent and covered by packaging/agent/smoke.py (#147).
  • Built-in skill-creator skill (pi-agent-cli): bundled skill-creator (builtin_skills/skill-creator/SKILL.md with references/installing-skills.md and references/authoring-guide.md) guiding agents through installing, auditing, creating, validating, and configuring Agent Skills. Enabled by default via [skills] include_builtin = true at lowest precedence (configured [skills].paths override by name, later wins; does not require project trust) and verified in packaging/agent/smoke.py.
  • A live thinking_level option, saved in the chat and restored on load (pi-agent-cli): session/new, session/load and session/resume return a thinking_level select (category thought_level; the levels max, xhigh, high, medium, low, minimal, off) unless agent.toml says reasoning = false. session/set_config_option changes the level of the open session with no restart: an unknown level, and any level but off when reasoning = false, are invalid_params. When reasoning is not set, Model.reasoning follows the level, also after a change of model. The harness saves each change in the chat file as a thinking_level_change entry. session/load and session/resume start the chat at the latest saved level, as they start it with the saved model, and write nothing to the chat file. The saved level is used only when reasoning is not false and the option offers it. A new chat, and a chat with no saved level, start at thinking_level of agent.toml. Agents up to 1.0.1 have none of this: the level lives in agent.toml only (#144, #146).
  • zypi consumes ACP usage_update (TUI): zypi now reads incoming usage_update notifications (used, size, and USD cost when sent) and updates its context bar and status line (#144, #146).

Changed

  • New version numbers (all eight Python packages, TUI): pi-agent-core-lc, pi-agent-harness-lc, pi-agent-cli-lc, pi-web-access-py, pi-goal-x-py, pi-dynamic-workflows-py, pi-mcp-py, and new pi-codemode-py (first PyPI release at 1.1.0), plus the TUI crates (pi-pager-bin, pi-version, and tui/Cargo.lock), move to 1.1.0. pi-agent-core-lc, pi-agent-harness-lc and pi-agent-cli-lc pin each other with ==1.1.0, and all five extension packages raise their workspace floors to >=1.1.0.

Fixed

  • The output limit of bash could miss a command that ended first (pi-agent-core): a bash call that has an output limit (Auto sets one) and prints more than the limit could pass when the command ended before the tool counted its output, which happens on a loaded machine. The tool now counts the output after the command ended too, and fails the call with the same message. When the command had already ended, the message adds that fact and its exit code (or the signal that killed it). In one run on one machine, with 12 busy processes on 4 cores, 145 of 300 calls passed the limit before and 0 of 300 after; the share changes from run to run (#146).
  • Cross-chunk <thought> leading whitespace & workflow subagent thinking_format (pi-agent-core, pi-dynamic-workflows): bounded leading-whitespace buffering in ThoughtTagSplitter preserves <thought> tags split across streamed chunks, and workflow sub-agents preserve thinking_format (#144).
  • edit tool keeps oldText/newText out of persisted session details (pi-agent-core, pi-agent-cli): full before/after texts travel only on live AgentToolResult.event_details (not persisted details), and replayed edits emit plain text without a diff block (#144).

Known issues

  • The count in usage_update is partly an estimate (pi-agent-cli): the tool results of a turn, and the whole count after a compaction, are estimates (4 characters for 1 token, which is too low for CJK text). The next model call gives an exact number. A window that is too small can show more than 100 %. A change to a model with no window leaves the old numbers on the client, because ACP cannot clear them.
  • Gemini thinking_format and <thought> streaming were not verified against live Google Gemini or Vertex AI APIs (pi-agent-core, pi-agent-cli): verified with local HTTP/mock-transport tests only (#138).
  • max was not sent to a real provider (pi-agent-core): verified with scripted models and a fake OpenAI-format server only; Anthropic adaptive thinking with effort is not built.
  • Nobody ran zypi for Linux aarch64 or macOS arm64 by hand: CI builds them; the macOS binary is not signed or notarized, and the Linux zypi binary requires glibc 2.39 or newer.
  • macOS weaker sandbox limits (pi-dynamic-workflows, pi-codemode): on macOS the script child process has no kernel limit on memory (RLIMIT_AS) or process count (RLIMIT_NPROC), relying on the audit hook as a speed bump; keep ask (or auto, which also prompts before outer workflow / codemode calls) and run inside a container or VM for untrusted code.