OpenSource-Hub
P

pi

SHA-256
54.2k stars·Developer Tools·SHA-256 checksum verified

pi is an open-source AI agent toolkit offering a unified multi-provider LLM API (OpenAI, Anthropic, Google, etc.), an interactive self-extensible coding agent CLI, a TUI library with differential rendering, Slack bot, and vLLM pods. Compared to proprietary tools like Cursor or Claude Code, pi provides full transparency, multi-backend flexibility, and supply-chain hardened dependency management.

Smart Download

Download Download Version

v0.75.5 · 45.5 MB

An open-source AI agent toolkit with unified multi-provider LLM API, self-extensible coding agent CLI, TUI libraries, and Slack bot.

Core Features

  • Unified multi-provider LLM API (OpenAI, Anthropic, Google, etc.) — switch models without code changes
  • Interactive coding agent CLI with tool calling and state management, self-extensible
  • Terminal UI (TUI) library with differential rendering for building rich CLI interfaces
  • Slack/chat automation via pi-chat companion project
  • Supply-chain hardening: exact dependency pinning, lockfile verification, release smoke tests

What It Can't Do

  • New contributor Issues and PRs are auto-closed by default; maintainers review them daily. Please read CONTRIBUTING.md before contributing.
  • Dependency management is strict: use npm install --ignore-scripts to avoid lockfile issues. Set PI_ALLOW_LOCKFILE_CHANGE=1 if you need to modify the lockfile.
  • Only supported in Node.js environment; not for Python or other languages.
  • Ensure you have an LLM API key (OpenAI, Anthropic, etc.) before using the coding agent.

Use Cases

  • Developers using an AI coding agent in the terminal for code writing, refactoring, and debugging
  • Teams wanting to quickly test different LLM backends via a unified API
  • Automating workflows with a Slack bot integrated with AI

Detailed Introduction

pi is a comprehensive AI agent harness monorepo developed by earendil-works. It provides a unified multi-provider LLM API that supports OpenAI, Anthropic, Google, and more, allowing developers to switch AI backends seamlessly. The core includes an interactive coding agent CLI that can self-extend by calling tools and managing state. Additionally, it offers a Terminal UI (TUI) library with differential rendering for building rich terminal interfaces. pi also integrates with Slack and chat automation via its companion project pi-chat. Compared to other coding agents like Claude Code or Copilot, pi stands out for its open-source nature, multi-provider LLM support, and rigorous supply-chain hardening practices (exact dependency pinning, lockfile verification, release smoke tests). The project encourages sharing coding agent sessions to improve real-world performance.

Tags

AI agentcoding agentLLM APICLIopen sourceSlack botTUI

Getting Started

1

Download installer

Click the button above to download the installer for your system

2

Install the software

Double-click the downloaded installer and follow the prompts

3

Install globally: npm install -g @earendil-works/pi-coding-agent

4

Run npx pi in your project directory, then configure your LLM API key when prompted

5

Start giving instructions in natural language to the agent for coding tasks

Install Guide
  1. Install globally: npm install -g @earendil-works/pi-coding-agent
  2. Run npx pi in your project directory, then configure your LLM API key when prompted
  3. Start giving instructions in natural language to the agent for coding tasks

Latest Release Notes

### New Features

- **Cleaner read tool output** - Collapsed `read` tool cards now show only the read line by default, while `Ctrl+O` still expands the full file content.

- **Faster file tools on Windows** - Built-in file tools now use async filesystem operations during streaming, and image resizes run off the main TUI thread in a worker.

- **More reliable package updates** - `pi update` and git package installs now reconcile pinned git refs and keep package settings intact. See [Packages](docs/packages.md).

- **Custom Anthropic-compatible adaptive thinking** - Custom provider model configs can opt into adaptive-thinking Claude behavior with `compat.forceAdaptiveThinking`. See [Custom providers](docs/custom-provider.md) and [Models](docs/models.md).

### Added

- Added `compat.forceAdaptiveThinking` support to custom Anthropic-compatible model configuration docs and validation ([#4797](https://github.com/earendil-works/pi-mono/pull/4797) by [@mbazso](https://github.com/mbazso)).

- Added a standard unified patch to edit tool result details for SDK consumers ([#4821](https://github.com/earendil-works/pi/issues/4821)).

### Changed

- Changed collapsed read tool cards to show only the read line until expanded ([#4916](https://github.com/earendil-works/pi/issues/4916)).

- Replaced the inherited optional `koffi` dependency for Windows VT input with a tiny vendored native helper, reducing install size while preserving Shift+Tab handling ([#4480](https://github.com/earendil-works/pi/issues/4480)).

- Changed the root development install documentation to use `npm install --ignore-scripts` ([#4868](https://github.com/earendil-works/pi/issues/4868)).

### Fixed

- Fixed `pi update` to reconcile git-pinned packages to their configured ref ([#4869](https://github.com/earendil-works/pi/issues/4869)).

- Fixed package/resource path handling for Windows and glob/pattern resolution ([#4873](https://github.com/earendil-works/pi-mono/pull/4873) by [@mitsuhiko](https://github.com/mitsuhiko)).

- Fixed config pattern matching to resolve patterns from the correct base directory ([#4898](https://github.com/earendil-works/pi-mono/pull/4898) by [@haoqixu](https://github.com/haoqixu)).

- Fixed theme pickers to list themes by their content name instead of file stem ([#4830](https://github.com/earendil-works/pi-mono/pull/4830) by [@Perlence](https://github.com/Perlence)).

- Fixed OpenCode Zen/Go requests to send per-session OpenCode routing headers ([#4847](https://github.com/earendil-works/pi/issues/4847)).

- Fixed Amazon Bedrock provider loading under strict package managers by inheriting the declared `@smithy/node-http-handler` dependency from `@earendil-works/pi-ai` ([#4842](https://github.com/earendil-works/pi/issues/4842)).

- Fixed inherited Amazon Bedrock Claude requests to send the model output token cap by default, avoiding Bedrock's 4096-token default truncation ([#4848](https://github.com/earendil-works/pi/issues/4848)).

- Fixed exported session HTML to escape quote characters in attribute values ([#4832](https://github.com/earendil-works/pi/issues/4832)).

- Fixed GitHub Copilot device-code login to keep opening the verification URL in browser-capable environments while ignoring browser launch failures for headless use ([#4788](https://github.com/earendil-works/pi-mono/pull/4788) by [@vegarsti](https://github.com/vegarsti)).

- Fixed git package installs to reconcile existing checkouts to the requested ref and update package settings without losing filters ([#4870](https://github.com/earendil-works/pi/issues/4870)).

- Published a 0.74.2 rescue release that tells Node 20 users to upgrade Node before updating to newer Pi versions ([#4876](https://github.com/earendil-works/pi/issues/4876)).

- Fixed final bash tool cards to avoid rendering duplicate full-output truncation paths ([#4819](https://github.com/earendil-works/pi/issues/4819)).

- Fixed bash tool truncation line counts to ignore the trailing newline as an extra output line ([#4818](https://github.com/earendil-works/pi/issues/4818)).

- Fixed footer home-directory abbreviation to avoid shortening sibling paths that only share the same prefix ([#4878](https://github.com/earendil-works/pi/issues/4878)).

- Fixed macOS Bun release binaries to resolve the native clipboard sidecar so Ctrl+V image paste can load `@mariozechner/clipboard` ([#4307](https://github.com/earendil-works/pi/issues/4307)).

- Fixed coding-agent tools to avoid synchronous filesystem operations during streaming and moved image resizing off the main TUI thread ([#4756](https://github.com/earendil-works/pi-mono/pull/4756) by [@mitsuhiko](https://github.com/mitsuhiko)).

File Integrity

SHA-256 checksum verified

Checksum extracted from GitHub official Release page

SHA256 Checksum

775bec6cf05ed13cfb866cf13280c7878d018ccf9db11b44902c80589166cbb5

This checksum is extracted from the GitHub Release page. Verify file integrity after download.

All SHA-256 checksums on this platform are extracted from the project's official GitHub Release page, without any modification. You can independently verify them on the GitHub Releases page.

Open Source Transparency

View GitHub Source
Environment Guide

Uninstall Info

Uninstall pi: npm uninstall -g @earendil-works/pi-coding-agent. Also remove pi-chat if installed separately. This removes all globally installed packages.

No Extra Dependencies

Ready to use after download. No additional runtime required.

Project Info
LicenseMIT
Last Updated2026-05-25T06:45:32Z
GitHub RepositoryOfficial Website

Similar Projects