anomalyco/opencode

The open source coding agent.

OpenCode – an open‑source AI coding assistant

What it is – OpenCode is a self‑hosted, command‑line (and optional desktop) AI agent that helps you write, understand, and plan code. It ships with two built‑in agents:

  • build – a full‑access agent that can edit files and run commands.
  • plan – a read‑only, analysis‑focused agent that asks before executing anything. A special @general sub‑agent handles complex, multi‑step queries.

How you get it – A one‑liner installer (curl … | bash) or any of the usual package managers (npm, Homebrew, Scoop, Pacman, Nix, etc.) will drop a opencode binary on your system. A desktop GUI (beta) is also available for macOS, Windows and Linux.

Key features

  • Terminal UI – an interactive console where you type natural‑language prompts and the agent replies, edits files, or runs shell commands.
  • Agent switching – hit Tab to toggle between the build and plan agents.
  • Safety controls – the plan agent never writes files unless you approve, and it asks before running any bash command.
  • Extensible – the docs mention a “general” sub‑agent for advanced searches and multi‑step tasks; the project is open source, so you can add your own agents or plug‑ins.
  • Cross‑platform – installers for macOS (Intel & Apple‑silicon), Windows, Linux (deb, rpm, AppImage) and a Homebrew Cask for the desktop app.

Typical workflow

  1. Install the CLI (npm i -g @opencode/cli or any of the other methods).
  2. Run opencode in a terminal inside a codebase.
  3. Ask the agent to, for example, “Add a unit test for function X” or “Explain how this module works”.
  4. The build agent will edit files directly; the plan agent will show you a plan and request confirmation before any change.

Who it’s for – Developers who want an AI‑powered pair programmer that runs locally and can be constrained for safety. The project is community‑driven, with a Discord server for support and a public roadmap.

Where to learn more – Full documentation at https://opencode.ai/docs, plus contribution guidelines in the repo.

Related

  • Project
  • Project
  • Project
  • Project
  • Project