Pi is an AI agent toolkit that provides a unified LLM API, agent runtime, and interactive coding agent CLI built on TypeScript.
The project addresses the need for a flexible framework to build and run AI agents with tool-calling capabilities. It offers a modular architecture with separate packages for different concerns: a unified multi-provider LLM API that abstracts over OpenAI, Anthropic, Google, and other providers; an agent core runtime handling tool calling and state management; an interactive coding agent CLI for direct user interaction; and a terminal UI library with differential rendering. The toolkit is designed to be self-extensible, allowing developers to build custom agents on top of the core harness.
Developers should adopt this toolkit if they need to build agents that work across multiple LLM providers without vendor lock-in, or if they want a ready-made interactive coding agent. The project is suitable for applications requiring tool calling, state management, and terminal-based interaction. The toolkit does not include built-in permission controls for filesystem, process, network, or credential access; users running untrusted agents should containerize or sandbox the process, with the documentation providing three specific patterns for isolation: Gondolin extension for routing tools into a micro-VM, plain Docker for simple process isolation, or OpenShell for policy-controlled sandboxing.
The project maintains a substantial base of adopters who report issues from real-world use rather than the core team driving the issue tracker. Maintainers respond to new issues and pull requests within a day. Work in the issue tracker is dominated by bug reports and items marked with no-action or possibly-openclaw-clanker labels.