agentwire-dev CLAUDE.md

Project instructions for AgentWire, a voice interface that lets people talk to AI coding agents running in terminal sessions.

In plain words
What is it for?
They help develop and operate the AgentWire portal, rebuild its components, restart development services, and verify repository and safety settings.
Why use it?
They document the rebuild and restart steps needed for code and structural changes to actually reach the running application.

Instructions file

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/dotdevdotdev/agentwire-dev/claude-md
Clone the repo
git clone --depth 1 https://github.com/dotdevdotdev/agentwire-dev
Per session 10,527 This file is loaded in full into every session.
When invoked 10,527 The same file — it is already loaded in full.
Security scan D 3 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.10527 $0.10527
Opus 5 $0.05264 $0.05264
Sonnet 5 $0.02105 $0.02105
Haiku 4.5 $0.01053 $0.01053

Measured yesterday against content hash 6ba0bccff50c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade D, and why

agentwire-dev CLAUDE.md scanned grade D with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

| `.env` | **All API keys/secrets** — the one blessed spot, loaded on every entry point. `chmod 600`. See [`docs/wiki/security/secrets.md`](docs/wiki/security/secrets.md) |

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

- **Unattended guardrail** — scheduler dispatches are marked `AGENTWIRE_UNATTENDED=1`; the hook resolves `ask`-tier commands by failing closed (block + email owner) unless the matched rule carries an `unattended_allow` g

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

- **Damage-control hooks** block dangerous ops (`rm -rf`, `git push --force`, etc.)
CLAUDE.md · 212 lines

How it starts

The opening of the file, as written. The whole thing — 212 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AgentWire

Voice interface for AI coding agents. Push-to-talk from any device to tmux sessions running Claude Code.

No Backwards Compatibility - Pre-launch, no customers. Change things completely, no legacy fallbacks.

Dev Workflow

uv tool install caches builds and ignores source changes.

# Step 0 — after a remote merge, pull first. rebuild reinstalls whatever is
# checked out, so a never-pulled main silently ships stale code.
git pull --ff-only

# During development (picks up changes instantly)
agentwire portal start --dev

# After structural changes (pyproject.toml, new files)
agentwire rebuild

# After code changes: ALWAYS do both
git pull --ff-only && agentwire rebuild && agentwire portal restart --dev

Rebuild alone = stale static files. Restart alone = stale Python. The MCP server runs as a separate process started by Claude Code — session restart required after rebuild to pick up MCP changes. rebuild now refuses (warn + --force to override) when the checkout is behind origin/main, and agentwire doctor flags a behind-main checkout, a disabled kill switch (enabled: false in ~/.agentwire/damagecontrol.yml), damage-control rule/hook/matcher drift, and any of ~/.agentwire/ · .env · portal.token · machines.json readable beyond its owner (doctor --yes tightens them; #887).

CLI is the Single Source of Truth

All session/machine logic lives in CLI commands (agentwire/__main__.py). The portal (agentwire/server.py) is a thin wrapper that:

  1. Calls CLI via run_agentwire_cmd(["command", "args"])
  2. Parses JSON output (--json flag)
  3. Adds WebSocket/real-time features

When adding new functionality:

  1. Implement in CLI first with --json output
  2. Portal calls CLI, doesn't duplicate logic
  3. Never bypass CLI with direct tmux/subprocess calls

CLI layout (#495): the old __main__.py monolith is split per-domain. Shared helpers (machine config, SSH _run_remote, JSON output, session resolution, etc.) live in agentwire/core.py; each command group lives in its own agentwire/<domain>_cli.py module exposing a register_<domain>_parser(subparsers) registrar. build_parser() imports them and runs the _REGISTRARS loop — adding a command means writing a new *_cli.py + appending its registrar, not editing a god-file. Example: the portal git endpoints (api_check_path / api_check_branches) shell out to agentwire repo-info and agentwire branches (in repo_cli.py) rather than embedding their own git/SSH logic.

Read the full file on GitHub · 212 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 212 lines · 10,527 tokens per session scan D 6ba0bccff50c

Subscribe to this mod's changes

agentwire-dev CLAUDE.md is an instructions file published in the GitHub repository dotdevdotdev/agentwire-dev (21 stars, last pushed 17d ago), licensed Apache-2.0. It adds 10,527 tokens to every session, about $0.0526 per session on Opus 5. A static security scan graded it D with 3 findings (asks for root, reads agent configuration directories, recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.