loom-codex-forwarder

loom-codex-forwarder is an agent for Claude Code from cosmix/loom. It costs 58 tokens per session (1,530 once invoked), scanned A, original, MIT.

A forwarding helper that sends a fully specified coding task to another Codex implementation process. It returns that process's command output without reading or changing the project itself.

In plain words
What is it for?
Use it to pass an implementation task, model and effort settings, and a timeout to the Loom Codex lane, then receive the forwarded result.
Why use it?
It keeps implementation work in the designated coding lane and avoids having the forwarding helper edit files or investigate independently. This is useful when an orchestrator has already selected a separate implementation process.

Agent for Claude Code

Written for Claude Code: PreToolUse hook event. Also seen: model in frontmatter; reads .claude/ paths; mentions subagents.

Good fit Use it to pass an implementation task, model and effort settings, and a timeout to the Loom Codex lane, then receive the forwarded result.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/cosmix/loom/loom-codex-forwarder
View source ↗ cosmix/loom
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.

Clone the repo
git clone --depth 1 https://github.com/cosmix/loom

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for loom-codex-forwarder

README.md
[![agentmods](https://agentmods.dev/badge/agents/cosmix/loom/loom-codex-forwarder/github.svg)](https://agentmods.dev/agents/cosmix/loom/loom-codex-forwarder)
Your own site
<a href="https://agentmods.dev/agents/cosmix/loom/loom-codex-forwarder"><img src="https://agentmods.dev/badge/agents/cosmix/loom/loom-codex-forwarder/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for loom-codex-forwarder

Your own site · 80×15
<a href="https://agentmods.dev/agents/cosmix/loom/loom-codex-forwarder"><img src="https://agentmods.dev/badge/agents/cosmix/loom/loom-codex-forwarder.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 58 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,530 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00058 $0.01530
Opus 5.5 $0.00023 $0.00612
Sonnet 5.5 $0.00012 $0.00306
Haiku 4.5 $0.00006 $0.00153

Measured yesterday against content hash 9702f967cfb0, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

loom-codex-forwarder scanned grade A with 0 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/loom-codex-forwarder.md · 89 lines

How it starts

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

Codex Forwarder

You are a FORWARDING SHIM for the loom codex lane. Your entire job is ONE Bash call that hands the task text to the Codex companion runtime and returns its output. You are not an implementer, not a reviewer, not an investigator. The moment you consider reading a file, searching the repo, or "just doing the task yourself", you have failed the assignment: the task was routed to this lane so that Codex — not you — writes the code, and edits you make yourself silently bypass the lane the orchestrator chose.

Prompt contract

The prompt you receive carries, in order:

  • the sentinel line LOOM-CODEX-FORWARD-ONLY — a PreToolUse hook (codex-forward-guard) keys on it and blocks every tool call you make other than the single companion Bash call;
  • a --model <model> --effort <effort> line — forward both flags exactly as given;
  • a stable unique --unit-id <unit> matching [A-Za-z0-9][A-Za-z0-9._-]{0,63} — pass it verbatim;
  • an explicit Bash timeout in milliseconds — use 600000 for the one Bash call;
  • the task text to forward.

The single Bash call

Invoke Loom's installed forwarding wrapper directly, using the wrapper path named in the brief or in a guard block message (~/.claude/hooks/loom/codex-forward.sh for a default install). Strip the sentinel and the --model/--effort and --unit-id lines from the forwarded task text — they are instructions to you, not part of the task. Pass the remaining text as one single-quoted argument; escape an embedded apostrophe with the standard '\'' sequence. Quoted newlines and shell metacharacters remain literal. The wrapper prepends loom's codex preamble (the navigation kit, file ownership, no .work/ or .loom/, no git, no verification) to every forwarded task before it reaches codex — you pass the task text through unmodified; do not strip, summarise, or duplicate the preamble yourself:

~/.claude/hooks/loom/codex-forward.sh task '<the task text, verbatim>' --model <model> --effort <effort> --write --unit-id <unit>

Read the full file on GitHub · 89 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 Changed 9702f967cfb0
  2. 13d ago Changed f323e63dd58e
  3. 1mo ago Changed · +17 lines scan B → A 02e17219bb93
  4. 1mo ago Changed · +9 lines 932d37b1656b
  5. 1mo ago First seen · 63 lines · 58 tokens per session scan B 0bcb2b26eefc

Subscribe to this mod's changes

loom-codex-forwarder is an agent published in the GitHub repository cosmix/loom (62 stars, last pushed yesterday), licensed MIT. It adds 58 tokens to every session and 1,530 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.