explaingit

badlogic/pi-mono

🔥 Hot51,189TypeScriptAudience · developerComplexity · 4/5ActiveLicenseSetup · moderate

TLDR

A monorepo toolkit for building AI agents, featuring a command-line coding assistant that uses AI to write and run code, plus reusable packages for creating custom AI-powered tools.

Mindmap

mindmap
  root((repo))
    What it does
      CLI coding agent
      AI tool calling
      Code generation
    Key packages
      pi-ai layer
      pi-agent-core
      pi-tui terminal UI
      pi-web-ui components
    Use cases
      Custom coding agents
      Automation tools
      Chat interfaces
    Tech stack
      TypeScript
      Node.js
      npm packages
    Audience
      AI developers
      Tool builders

Things people build with this

USE CASE 1

Build a specialized coding agent tailored to your codebase's conventions and patterns.

USE CASE 2

Create a chat-based automation tool that connects AI to your internal systems and APIs.

USE CASE 3

Use the ready-to-go CLI coding agent to handle general coding tasks from the terminal.

USE CASE 4

Develop a custom AI assistant with a web or terminal interface for your specific domain.

Tech stack

TypeScriptNode.jsOpenAIAnthropicGoogle AI

Getting it running

Difficulty · moderate Time to first run · 30min

Requires API keys for OpenAI, Anthropic, or Google AI to run the CLI assistant.

Use freely for any purpose including commercial, as long as you keep the copyright notice.

In plain English

Pi Mono is a monorepo (a single repository containing multiple related packages) that provides a toolkit for building AI agents. Its primary offering is a command-line coding agent, a tool that uses AI to write, edit, and run code on your behalf interactively from the terminal, but the repository also contains reusable building blocks that developers can use to create their own AI-powered tools. The coding agent package is the flagship product. It runs from the command line and acts like a developer assistant that you can give coding tasks to. Under the hood, it calls AI language models to generate and apply code changes, using a concept called "tool calling", the AI can request to perform actions like reading files, writing code, or running commands, and the agent runtime executes those actions and feeds the results back to the AI. The remaining packages provide the infrastructure behind this and similar agents. The pi-ai package is a unified API layer that normalizes calls to different AI providers (OpenAI, Anthropic, Google, and others) into one consistent interface. The pi-agent-core package is the runtime that manages agent state and tool execution. The pi-tui package is a terminal user interface library for building interactive chat-like interfaces in the terminal. The pi-web-ui package provides web components for building AI chat interfaces in browsers. A developer would use Pi Mono when building a custom AI agent or coding assistant, for example, a specialized coding agent tailored to a particular codebase's conventions, or a chat-based automation tool that connects AI to internal systems. The coding agent itself is ready to use out of the box for general coding tasks. The tech stack is TypeScript and Node.js throughout, distributed as npm packages.

Copy-paste prompts

Prompt 1
How do I set up the pi-mono coding agent to help me write code from the command line?
Prompt 2
Show me how to use the pi-ai package to call different AI providers (OpenAI, Anthropic, Google) with the same code.
Prompt 3
How can I build a custom AI agent using pi-agent-core and pi-tui for a terminal chat interface?
Prompt 4
What's the difference between using the standalone coding agent versus building my own agent with these packages?
Prompt 5
How do I add tool calling to my AI agent so it can read files, write code, and run commands?
Open on GitHub → Explain another repo

Generated 2026-05-18 · Model: sonnet-4-6 · Verify against the repo before relying on details.