agentleFS
AVP-DevAVP-Dev/pair-mailbox/skills/pair-chat/SKILL.md

pair-chat

Skill1 starsChanged 14 days agoMITView on GitHub

Hold a real conversation with the other agent in this two-agent pairing, through the pair_* MCP tools. Use when you need to hand work over, disagree out loud, ask a question the other side can answer, or report a result that needs a decision. Not for one-shot lookups.

The file

We split this skill into the rules it gives an agent

8 rules. About 0 are common, 5 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use this for background notes, reports, or when pair_deliver reports the composer is busy.

    line 59
  2. Distinctive:

    Write for a reader who cannot see your screen: file paths with line numbers, the command you ran, the actual error text.

    line 73
  3. Distinctive:

    Never ask the human to carry a message to the other window.

    line 92
  4. Distinctive:

    Never claim the peer is "looking at it" or "working on it".

    line 133
  5. Very specific:

    Write authority is not transferable by message.

    line 145
  6. Very specific:

    Only the human moves it, with bin/pairctl assign <role> and bin/pairctl release.

    line 149
  7. Distinctive:

    If you are not the writer, you do not edit project files.

    line 163
  8. Distinctive:

    Read git status and the diff before your next write.

    line 213

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Pair chat

Session scope: use this correspondence contract only in an explicitly enrolled pair. Standalone CLIs and native subagents work on their task without claiming a pair role or waiting for an unavailable peer. A paired connection failure does not grant a critic write authority.

The single source of truth for pair correspondence is this file. Mentions in AGENTS.md, docs/PROTOCOL.md, docs/HOW-IT-WORKS.md are context, not contract: on divergence this file and the code in mcp/pair_mailbox/server.py win.

The other agent in this pairing runs a different CLI, with a different model and no access to your conversation. The pair_* tools are the only way it finds out what you are doing.

Before anything

Cheap orientation first, full state after:

pair_digest     # task, mode, phase, open tasks, obligations, last commit/verdict (~1k tokens)
pair_state      # full state: authority, roster, unread, done-blockers

pair_digest replaces pair_state + pair_task + pair_transcript for the "where does the round stand" question. Read history only when the digest says you need it. When a status question arrives, answer with what is true now from pair_state/pair_transcript — never with a promise to go and check.

Sending

There are two ways to send. The body always lands in .pair/mailbox/ (a container independent of tmux); only a short pointer goes into the peer's TUI — the terminal is a display, not a bus between agents.

pair_deliver(to="<peer>", text="one paragraph: what and where to read it")

pair_deliver — data into the mailbox, a short pointer into the peer's tmux composer ([pair] <role>: новое сообщение в ящике, прочитай pair_read). The peer wakes itself and reads it as its next instruction. Use this when you need the peer to act now: reviews, sealed patches, handoffs, blocking questions. If the composer is busy the call refuses instead of overtyping — the text is already safe in the mailbox, so fall back to pair_send and wait. On an unproven (foreign) pane typed printing is forbidden (injection into someone else's composer); the fallback is display-message + mailbox only.

pair_send(to="<peer>", subject="retry logic", text="one paragraph", expects_reply=true)

pair_send is passive: it places the message in the peer's mailbox for when it next reads. Use this for background notes, reports, or when pair_deliver reports the composer is busy.

  • subject — short subject line; a plan sent before the first commit of a fix round carries plan/план in it (PROTOCOL.md §9a).
  • expects_reply=true — set when the message asks for a decision, a review, or an action. It opens an obligation the supervisor watches, so a request nobody answered cannot end the night in silence. Review queue limit: at most 2 unanswered requests per role (MAX_OPEN_REVIEWS, mcp/pair_mailbox/review.py:27); on the third — stop and read (pair_read(wait_seconds=30)).

The server prepends the Chat from <role>: label. Do not write that label yourself, and never write your own name into a message — the label is added server-side precisely so authorship cannot be forged.

Write for a reader who cannot see your screen: file paths with line numbers, the command you ran, the actual error text. Quote it rather than describing it.

Without a tmux pane

Some launches have no terminal multiplexer at all: the agent runs as a plain subprocess (bin/pair-runner), on a host with no tmux server. Nothing in the mailbox changes — the container does not depend on tmux — but one thing does: there is no composer to type a pointer into, so nothing can wake the peer.

  • pair_send is the whole channel. The letter lands in the mailbox and the peer reads it on its own next turn.
  • pair_deliver still delivers the body (it writes the same mailbox letter), but it cannot wake anybody: it answers in_pane: false with a why that names the missing pane. Treat that answer as the whole truth — the peer was NOT woken.
  • The wait rule does not change: one read per turn, and ACK the batch with its ack_token when you have processed it. A bounded pair_read(wait_seconds=45) is the only way to wait for the peer.
  • Never ask the human to carry a message to the other window. That ban holds with no tmux even harder: there is no second window to ask about.

Reading

pair_read()                    # one batch of mail; it stays unread until acked
pair_read(wait_seconds=45)     # bounded wait for a peer message
pair_read(ack_token="...")     # commit the batch: mail is read only then
  • Round 101 batch contract: pair_read returns a batch plus its ack_token and the batch is PERSISTED. Retry without the token replays the SAME letters under the SAME token; other tools never acknowledge mail. Process the batch, then pass ack_token on a later pair_read — only that marks it read. pair_state and the digest show a pending_read with attempts and (if the batch cannot be replayed) a named poison with the cure; after three attempts (the initial delivery plus two replays, MAX_REPLAY_ATTEMPTS=3) the operator may settle it with pairctl read-ack <role> <token> [--skip --reason ...].
  • One read per turn. An empty answer means nothing new arrived: go back to work or sleep — the peer and the supervisor wake you when the mail lands. Reading again in a loop buys nothing and costs a full context per poll.
  • The answer names the wedge: must_ack says the batch is still unacknowledged, and letters_behind counts the letters that arrived after it and wait behind it. Reading again will not bring them; the ACK will.
  • wait_seconds default is 0 (DEFAULT_READ_WAIT_SECONDS); cap is 60s (MAX_READ_WAIT_SECONDS), further capped by the role's real MCP timeout (cli-profiles.json mcp.entry.timeout); a cut wait is reported with the named numbers, never hidden. Both roles may wait — a bounded wait always expires, so it cannot deadlock. waited_seconds is the time the call really took, wait_budget_seconds what it was allowed to take: a call that took less than its budget replayed a batch you already hold, and it spent the wait before answering so the loop cannot spin.
  • Closing is refused over unread mail: a report the writer never read is not a report. Run pair_read and ACK its batch before pair_advance("done").

Delivery is not a promise

A message marked delivered has been placed in the peer's inbox (or a pointer typed into its composer). The peer may still disagree or run into an error. Never claim the peer is "looking at it" or "working on it". Say you delivered it, and continue your work.

Never use the human as a messenger (No human relay)

Never ask the user to relay messages, reviews, handoffs, or prompts to the other window. The two agents are an autonomous pair. Use pair_deliver to actively wake the peer and hand off work directly into its terminal. The user defines the task and receives the finished PR; the user is not a message bus between windows.

You cannot hand over authority

Write authority is not transferable by message. You cannot give it, take it, or borrow it, and you cannot ask the peer to take it from you. The holder may give it up itself with pair_release(why="...") — that is its own decision, not your transfer.

Only the human moves it, with bin/pairctl assign <role> and bin/pairctl release. If you need the peer to write, tell the user what you need and stop; do not negotiate it with the peer. A standing role arrangement wins over a race: pair_claim answers by_policy=true when the human pinned the writer, and the pin changes only via pairctl roles --swap.

Corollary: "the peer agreed" is not human sign-off. For the 6 critical operations requiring human approval (§12 of PROTOCOL.md: secrets, prod deploy, DB migrations, data/history deletion, domain/ports, and authority reassignment), only the human approves. However, for routine coding, review, patch application, and task progression, the two agents proceed autonomously without asking the user for confirmation.

Working the other way

If you are not the writer, you do not edit project files. Preferred path is one call:

pair_propose(files=["path/to/file.py"])   # reserves, seals, and notifies the writer itself

Manual path (reserve → write diff → seal → send path+sha256 → writer verifies → writer records applied) stays for exotic cases. fix mode only — in audit the server refuses the reservation. The writer re-verifies the hash immediately before applying and stops on a mismatch; after applying it records pair_patch_applied(path, ok=...), with ok=false on a failed apply (a rejected hunk stays unresolved and keeps the round open).

Release your own file with pair_patch_release(path), by exact path. Never clean that directory with a glob — you share it with a process you cannot inspect, and a glob will delete a file that belongs to the other agent. After an interruption, check whether your file survived and remove it by its exact path first.

Leaving something behind

pair_note(kind=plan,     text="...")
pair_note(kind=decision, text="...")
pair_note(kind=finding,  text="...")
pair_note(kind=verdict,  text="...")
pair_note(kind=handoff,  text="...")
pair_note(kind=backlog,  text="...")

Kinds are fixed by PROTOCOL.md §9: plan (what was agreed and in what order), decision (the choice and the reason), finding (checked against the code, with file:line), verdict (the outcome and what it did NOT cover), handoff (done / skipped / unclear), backlog (a real defect outside the scope). In audit, finding-<ID> per surface and audit-<date> for the report.

Your conversation is not shared memory; it is also not durable. Anything the peer must still know after either of you compacts goes in a note. A handoff note says what changed, what you skipped, and what you are unsure about.

Notes grow only at the tail and rotate at 600 lines (NOTE_LINE_CAP, server.py:182) into notes/archive/. Never read a note with a file read: list first, then read the tail.

pair_note_index               # sizes and freshness, largest first — always before reading notes
pair_note_read(kind, tail_lines=120)   # tail only; default 120, capped at 400

After an interruption

Read git status and the diff before your next write. If it is unclear who was writing, stay read-only and ask the user. A half-finished turn with an ambiguous owner is how two agents clobber each other.

Quiet tools (no separate section needed)

  • pair_ping — cheap sign of life (three fields instead of the full state). Any pair_* call already moves last_seen; ping when you have nothing else to say so the supervisor tells "silent but working" apart from stuck.
  • pair_task — shared task list. The round cannot close while any task is open: finish (done) or drop with a reason.
  • pair_evidence — machine-checkable fact (tests with count and exit code, lint, typecheck, commit sha, PR URL). In fix, done requires a passing test run recorded by the writer.
  • pair_transcript — append-only audit trail: every message, claim, phase change, patch seal and hash verification. Reconstruct what actually happened.
  • pair_note_index — see above; always before reading notes.
  • pair_unblock — check whether the peer's pane is stuck on a permission prompt and confirm it only if the prompt is on the allowlist. Anything that writes, runs, or deletes is refused by default.

Manners

Short sentences. Plain language. Quote what the other side actually said.

Disagree. Two agents converging politely produce nothing at all — the useful output is a located disagreement or a fact somebody checked. If you find yourself about to agree without having verified anything, go and verify it first.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.