Headless OpenCode CLI delegate skill by Artem Letyushev.
This repository packages a cross-platform agent skill that lets a controlling agent run opencode run once, non-interactively, capture the result, and verify the work outside the delegated agent.
- Runs
opencode runthroughscripts/delegate_opencode.py - Captures stdout, stderr, exit code, output files, and the final response
- Supports macOS, Linux, WSL, and Windows
- Uses
OPENCODE_BINwhen the executable is not onPATH - Supports optional OpenCode JSON event capture
- Keeps delegated output untrusted until the controlling agent checks diffs and tests
With npx skills:
npx skills add letya999/opencode-delegateOr copy this repository into an agent skill directory such as .agents/skills/, .claude/skills/, or ~/.codex/skills/.
python3 scripts/delegate_opencode.py \
--cwd "$PWD" \
--task "Review this repository and report the highest-risk issue." \
--timeout 45mWindows users can run the same wrapper with py -3. See QUICKSTART.md and references/runtime-setup.md for the full cross-platform pre-flight.
- SKILL.md is the skill instruction file.
- .well-known/agent-skills/index.json is the discovery index.
- dist/opencode-delegate.zip is the archive artifact referenced by the index.
MIT License. See LICENSE.