Skip to content

construct-worlds/construct

Repository files navigation

construct

A terminal-native agentic development environment.

construct lineage and program run

Quick start

curl -fsSL https://raw.githubusercontent.com/construct-worlds/construct/main/install.sh | sh

More screenshots and demos: gallery.

Why construct?

  • tmux for agent fleets — manage Codex, Claude Code, OpenCode, Antigravity, Grok, and smith sessions from your terminal — or let an agent coordinate them. CLI-only; no desktop app to install.

  • Fork / merge — fork a session when you need a parallel attempt (new idea, side quest, or a long shot). Supports cross-harness forks and merging results back.

    construct fork and merge demo
  • Program — collaborative, executable Markdown (docs/program.md): co-develop workflows, tasks, and ideas with the agent, then run them from the same document.

    construct program demo
  • Agent-to-agent orchestration — MCP tools let an agent list sessions, read output, spawn helpers, send input, inspect diffs, and drive Chrome.

  • ACP (Agent Client Protocol) server — point Agent Client Protocol clients at construct acp to create, load, resume, prompt, cancel, and close construct daemon sessions through the same installed binary.

  • Generative widgets — construct generates and updates widgets for your task, so you can track progress, review outputs, and take action without leaving the TUI or web client.

    construct generative widgets demo
  • Remote control when you step away/remote-control opens a browser-accessible web client with a QR code. Connect from your phone, no service signup, no setup required.

    construct remote control demo     →     construct web client on a phone

  • Extensible harness protocol — adapters are separate processes speaking JSON-RPC over stdio, so new tools can plug in without changing the daemon.

Getting started

1. Requirements

Bring the agents you want to run. construct wraps the CLIs already on your machine, so install whichever harnesses you use, keep them on PATH, and log in first:

  • Codex — install the codex CLI and complete its OAuth login.
  • Claude Code — install the claude CLI and complete its OAuth login.
  • OpenCode — install the opencode CLI and authenticate the providers you plan to use.
  • Antigravity — install the agy CLI and complete its OAuth login.
  • Grok — install the grok CLI and complete its OAuth login.
  • smith — built in to construct. Talks to OpenAI, Anthropic, Google Gemini, or xAI Grok via API key, a local Ollama, a ChatGPT subscription via Codex OAuth, a Claude subscription via the authenticated Claude Code CLI, or a Grok subscription via the authenticated Grok CLI.

Once those CLIs are available and authenticated, construct can create and resume their sessions from the fleet TUI.

2. Install

The installer downloads the right prebuilt binary for your platform, verifies its SHA-256 checksum, and drops every binary into one directory on your PATH:

curl -fsSL https://raw.githubusercontent.com/construct-worlds/construct/main/install.sh | sh

Pin a version or change the directory with CONSTRUCT_VERSION=v0.2.0 / CONSTRUCT_BIN_DIR=/usr/local/bin.

3. Open the construct Terminal UI

construct

If no daemon is running yet, construct auto-starts one in the background and attaches — there's no separate daemon step. (Opt out with CONSTRUCT_NO_AUTOSTART=1, e.g. in scripts that manage the daemon themselves.)

Use ? for help and M-x for the command palette. From the TUI you can create sessions, switch between agents, send input, inspect diffs, and interrupt or stop work without leaving the flow.

To run the daemon explicitly instead (e.g. on a server, or under a process supervisor):

construct daemon run

It owns sessions, persists state, and exposes the local IPC socket used by clients. Lifecycle helpers are also available for background daemons:

construct daemon start
construct daemon stop             # stops adapters; sessions resume on next start
construct daemon stop --sessions  # explicit spelling of the same session-safe stop
construct daemon restart
construct daemon restart --sessions

4. Start building

Happy hacking. Chase the idea from your terminal: ask Codex, Claude Code, OpenCode, Antigravity, Grok, and smith to dive into the hard parts, then keep steering from your phone when you're in motion.

Upgrading

construct upgrade            # install the latest release (atomic in-place replace)
construct upgrade --check    # just compare your version against the latest
construct upgrade --restart  # upgrade, then restart a running daemon to apply

construct upgrade re-runs the installer for you (pin a release with --version vX.Y.Z); re-running the install one-liner does the same thing. A running daemon keeps the old code until it restarts — pass --restart, or run /construct restart in the TUI, to pick up the upgrade without losing sessions. Interactive client commands also ask whether to upgrade when a newer release is available; saying yes upgrades in place, restarts a running daemon, and resumes the original command under the new binary. The TUI still surfaces a one-line notice from the cached check. Disable both with CONSTRUCT_NO_UPDATE_CHECK=1.

ACP (Agent Client Protocol) server

construct acp runs an Agent Client Protocol stdio server. Configure ACP clients to launch this command:

construct acp

It auto-starts the daemon if needed, then maps ACP session lifecycle calls onto construct daemon sessions. Use --harness, --model, or --cwd to set defaults for session/new requests that omit those fields.

Building from source

git clone https://github.com/construct-worlds/construct.git
cd construct
cargo build --workspace

Debug binaries land in target/debug/:

  • target/debug/construct — TUI, control CLI, the daemon (construct daemon run), ACP stdio server (construct acp), MCP bridge (construct __mcp, internal), and all harness adapters (construct __adapter <name>, internal)

For an optimized build, use cargo build --workspace --release and replace target/debug with target/release.

Documentation

  • Gallery — screenshots and demo clips of the TUI and web client.
  • Architecture — daemon/client split, crates, and the Agent Harness Protocol (AHP).
  • Harnesses and session modes — supported adapters, interactive vs. headless modes, worktree isolation, and resume behavior.
  • Program — the per-session Markdown document you and the agent co-edit and run: smart clips, run shimmer, templates, and live collaboration.
  • Program selection verbs — typed refinement actions on a Program selection (challenge assumptions, simplify, crystallize, interview), the pinned inline terminal for interactive verbs, and authoring your own.
  • smith built-in agent — providers, model selection, tools, approvals, automode, and hooks.
  • Unified tool layer — MCP servers and shared tools for fleet control, browser automation, and agent coordination.
  • Generative widgets — agent-generated Markdown UI for compact session-scoped task state, timelines, and action links.
  • Memory — durable Markdown context for project workflows, decisions, preferences, and pitfalls.
  • Configuration — XDG paths, CONSTRUCT_* overrides, and TUI theme customization.
  • Remote control — phone/browser access, QR setup, credentials, and local debug mode.

License

MIT — see LICENSE.

About

A terminal-native ADE (agentic development environment).

Topics

Resources

License

Stars

3 stars

Watchers

0 watching

Forks

Packages

 
 
 

Contributors

Languages