opencode

Delegate coding tasks to the OpenCode CLI agent via terminal and process tools.

1|Updated Jul 22, 2026
One-click install
npx skills add https://github.com/IceHeartGitH/Hermes-Agent-Android-Termux --skill opencode-iceheartgith
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: opencode
Source: https://github.com/IceHeartGitH/Hermes-Agent-Android-Termux/tree/main/custom-skills/autonomous-ai-agents/opencode
Command: npx skills add https://github.com/IceHeartGitH/Hermes-Agent-Android-Termux --skill opencode-iceheartgith

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires opencode-ai.

What problem does it solve? Offloading implementation, refactoring, and PR review work to an autonomous coding agent requires knowing the right CLI flags, session modes, and process controls; this Skill provides the exact commands and workflows to orchestrate OpenCode reliably from Hermes. ## Core Features & Use Cases - One-Shot Task Execution: Run bounded coding tasks with opencode run, attaching context files and forcing specific models. - Interactive TUI Sessions: Launch background interactive sessions with pty, submit prompts, poll progress, and exit cleanly with Ctrl+C. - PR Review & Parallel Work: Review pull requests with opencode pr and run parallel tasks in isolated workdirs or worktrees. - Use Case: Ask the agent to implement an OAuth refresh flow with tests in your repository, monitor its progress in the background, then receive a summary of changed files and test results. ## Quick Start Use the opencode skill to run a one-shot task that adds retry logic to the API calls in my project and updates the tests.

Frequently Asked Questions about opencode

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run a one-shot coding task with OpenCode CLI?▼

Use `opencode run 'your prompt'` in the target repository workdir for bounded, non-interactive tasks. Attach context files with `-f`, force a model with `--model provider/model`, and show reasoning with `--thinking`.

How do I review a pull request with OpenCode?▼

Run `opencode pr 42` in the repository to use the built-in PR command. For isolation, clone the repo into a temporary directory and run a review prompt with the changed files attached via `-f`.

Does OpenCode interactive mode require a pty terminal?▼

Yes, interactive TUI sessions require `pty=true` when launched in the background. The `opencode run` one-shot command does not need a pty and works as a plain terminal command.

Why does OpenCode behave differently in my terminal versus the agent?▼

PATH mismatches can resolve different OpenCode binaries or model configs. Check with `which -a opencode` and `opencode --version`, and pin an explicit binary path such as `$HOME/.opencode/bin/opencode` if needed.

How do I exit an OpenCode TUI session cleanly?▼

Send Ctrl+C (`\x03`) via the process write action or kill the process directly. Do not use `/exit`, which is not a valid OpenCode command and opens an agent selector dialog instead.

Can I run multiple OpenCode sessions in parallel?▼

Yes, launch separate background sessions scoped to distinct workdirs or Git worktrees to avoid collisions. Track all sessions with the process list action and monitor each with poll or log.