delegating-to-agents

Orchestrates prompt delegation and polling across Pi, Codex, Claude Code, and Hermes agents.

60|11|Updated Jun 15, 2026
One-click install
npx skills add https://github.com/matyasstoch/david-skills --skill delegating-to-agents-matyasstoch
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: delegating-to-agents
Source: https://github.com/matyasstoch/david-skills/tree/main/skills/delegating-to-agents
Command: npx skills add https://github.com/matyasstoch/david-skills --skill delegating-to-agents-matyasstoch

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Coordinating multiple AI coding agents in cmux or tmux sessions often fails due to fragmented multi-line prompts, wrong agent selection, and inefficient polling, causing broken or stalled delegated work. ## Core Features & Use Cases - Agent Selection Guidance: Recommends which agent to use per task type — Codex CLI for complex coding, Pi Agent with Opus 4.8 Fast for frontend and design work. - Single-Line Prompt Rule: Enforces sending prompts as one line via cmux send or tmux send-keys, since newlines act as Enter and fragment TUI agent input. - Short Polling Cadence: Prescribes 3-5 second sleep intervals when waiting on fast agents like Pi and Hermes instead of long blocking sleeps. - Use Case: You orchestrate a long-running refactor by having Pi Agent delegate execution to Codex CLI in another cmux pane, writing multi-step instructions to a file and polling every few seconds until completion. ## Quick Start Read this skill before sending any prompt to another AI agent, then delegate your coding task to Codex CLI in a cmux pane using a single-line cmux send command.

Frequently Asked Questions about delegating-to-agents

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

FAQPage Schema
How do I send a prompt to a Codex or Pi agent in tmux?▼

Send the prompt as a single line using cmux send or tmux send-keys, followed by one explicit send-key enter. Newlines act as Enter in these TUIs, so multi-line strings get submitted prematurely and fragmented.

Which AI coding agent should I use for complex tasks?▼

Codex CLI is recommended for complex, long-running software engineering tasks, while Pi Agent with Opus 4.8 Fast is better for frontend and design work. A common setup uses Pi Agent as orchestrator delegating execution to Codex CLI.

How do I send long multi-step instructions to a TUI agent?▼

Write the instructions to a file and tell the agent to read it, for example sending 'read /tmp/task.md and follow it' as a single-line prompt. This avoids newline fragmentation while preserving full detail.

Why does my prompt get cut off when sent to a Claude Code agent?▼

TUI agents treat newlines as Enter, so a multi-line message submits after the first line and the rest arrive as separate mid-turn messages. Reformat the prompt as one line using separators like semicolons.

How long should I wait when polling another AI agent?▼

Use short sleep intervals of 3-5 seconds and re-check rather than long sleeps like 30 seconds. Pi and Hermes run on fast opus-4.8-fast models and typically respond within a few seconds.

Can an agent manage a remote VPS over SSH?▼

Yes, but SSH into the VPS first and launch the agent on the remote machine itself, such as codex --yolo, then drive that on-box agent. This avoids fragile per-command SSH round-trips from a local agent.