> ## Documentation Index
> Fetch the complete documentation index at: https://docs.guild.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# opencode driver

> How the Guild runtime executes the opencode coding engine to drive agent turns.

Guild's runtime can drive agent turns with the opencode coding engine. The opencode driver runs alongside the Claude, Codex, and Antigravity drivers, so the runtime can execute any of these engines in the same environment.

This page describes how the runtime installs and executes opencode. You do not set these values yourself — the runtime manages them for every turn.

## Execution environment

The runtime container installs the `opencode-ai` command-line interface (CLI), which provides the `opencode` command that the driver runs.

## Running a turn

The driver runs `opencode` as a subprocess to execute a single tool-less turn. The turn runs without tools, so the engine produces its result from the prompt alone.

## Event-stream translation

The driver runs opencode with `--format json` and reads the resulting event stream. It translates each event into the same task notifications any other agent emits:

| Notification | Emitted from                                                 |
| ------------ | ------------------------------------------------------------ |
| `progress`   | Each event that renders a readable line while the turn runs. |
| `done`       | The end of the turn, carrying the final result.              |
