# Pier

> A terminal-native agentic coding CLI that reads your repository, plans across files, runs commands, and ships code — powered by multiple AI models at low cost.

Pier is a terminal coding agent built by Alphabench LLP, an India-based software company. It lives in your terminal, reads your entire repository, plans changes across files, runs shell commands, and ships code — all through a keyboard-first interactive REPL. The project is source-available on GitHub under the Business Source License 1.1, with a change date of 2030-07-09 when it converts to Apache 2.0.

## What It Is

Pier is a CLI-based agentic coding tool written in TypeScript and compiled to a single self-contained binary using Bun. It sits in the category of autonomous coding agents — tools that don't just suggest code but plan, edit, run tests, and iterate across a full codebase session. Unlike IDE-embedded assistants, Pier runs entirely in the terminal and is designed for long autonomous sessions spanning many files and commands.

## How the Agent Loop Works

Pier's architecture separates the model (the "engine") from the harness (everything else). The harness handles the tool loop, system prompts, permission gates, and the logic that feeds each step into the next. Key capabilities include:

- **Plan mode**: Pier investigates and presents a plan before touching any file — read-only research first, then execution with user approval.
- **Subagents**: Delegates scoped research and work to specialized sub-sessions, acting as an orchestrator rather than a single prompt loop.
- **Project memory**: Reads `CLAUDE.md` and `AGENTS.md` files from the repo root and follows project conventions, build commands, and house rules.
- **Permission modes**: `default`, `plan`, `acceptEdits`, `auto`, and `bypassPermissions`, cycled with Shift-Tab.
- **OS-level sandboxing**: Bash runs inside a real OS sandbox (seatbelt on macOS, bubblewrap on Linux).
- **MCP support**: Built-in MCP client supporting stdio and streamable-http transports.
- **Thread persistence**: Every conversation is saved locally and resumable with `pier resume`, with optional cross-device sync.

## Model Access and the Pier Hybrid Router

Pier supports a wide range of models including Sarvam 105B, DeepSeek-V4 Flash, DeepSeek-V4 Pro, GLM 5.2, Kimi K2.7, Qwen, Codestral, and more — each billed at the provider's API cost from the user's credits. The Pier Hybrid router classifies each request by type and complexity and routes it to the best-fit model automatically, keeping everyday work on cost-effective models and only reaching for heavier models when needed. Users can also bring their own Sarvam AI or OpenRouter API key and use Pier with a free account, bypassing the subscription entirely.

## Setup Path

Pier installs with a single curl command on macOS and Linux, or can be built from source using Bun. The CLI speaks the OpenAI Responses API; a Go bridge translates to the underlying Chat Completions provider. Config lives in `~/.pier` by default, and the production API endpoint is `https://api.piercode.com/v1`. Key commands include `pier login` for device pairing, `pier exec "…"` for headless task execution, and `pier resume` for continuing saved sessions.

## Update: v1.5.0

The latest release is **pier v1.5.0**, published on 2026-07-14. The repository was created in July 2026 and has been actively updated, with the last push on 2026-07-17. The about page describes Pier as "a rapidly maturing" product that improves recursively — the team builds Pier with Pier itself, so each agent improvement compounds into the next release. A public changelog is maintained at piercode.com/changelog.

## Features
- Interactive terminal REPL with readline composer and vim keymap
- Plan mode: read-only research before any file edits
- Subagents for delegating scoped research and work
- Project memory via CLAUDE.md and AGENTS.md files
- Multi-repo and monorepo context support
- OS-level sandboxing (seatbelt on macOS, bubblewrap on Linux)
- MCP client (stdio + streamable-http)
- Pier Hybrid router for automatic model selection
- Bring Your Own Key (BYOK) support for Sarvam AI and OpenRouter
- Permission modes: default, plan, acceptEdits, auto, bypassPermissions
- Thread persistence with cross-device sync via pier resume
- Headless task execution with pier exec
- Custom instructions via CLAUDE.md, AGENTS.md, or config.json
- Slash commands and custom command loading
- Client-side context compaction and auto-compaction
- Markdown rendering with syntax highlighting and structured diffs
- WebSearch and WebFetch native tools
- Skills and hard rules enforcement across all file edits

## Integrations
Sarvam AI, DeepSeek, GLM, Kimi, Qwen, Codestral, OpenRouter, Fireworks AI, MCP (Model Context Protocol), Bun runtime, Git

## Platforms
WINDOWS, MACOS, LINUX, WEB, API, CLI

## Pricing
Freemium — Free tier available with paid upgrades

## Version
v1.5.0

## Links
- Website: https://www.piercode.com
- Documentation: https://github.com/alphabench/pier
- Repository: https://github.com/alphabench/pier
- EveryDev.ai: https://www.everydev.ai/tools/pier
