loop-orchestration

loop-orchestration is a skill for Claude Code, Codex from runxhq/runx. It costs 32 tokens per session (770 once invoked), scanned A, original, Apache-2.0.

An example application that runs several controlled agent turns in sequence; each turn is one bounded piece of work with its own record and limits.

In plain words
What is it for?
Use it to build or study an outer workflow that continues, stops, or pauses based on receipts, budgets, allowed tools, and stop rules.
Why use it?
It demonstrates how long-running work can continue safely without giving the agent unlimited authority or context.

Skill for Claude CodeCodex

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 skills/runxhq/runx/loop-orchestration
Any agent
npx skills add runxhq/runx --skill loop-orchestration
Clone the repo
git clone --depth 1 https://github.com/runxhq/runx

Made for: Claude Code, Codex.

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 loop-orchestration

README.md
[![agentmods](https://agentmods.dev/badge/skills/runxhq/runx/loop-orchestration.svg)](https://agentmods.dev/skills/runxhq/runx/loop-orchestration)
Your own site
<a href="https://agentmods.dev/skills/runxhq/runx/loop-orchestration"><img src="https://agentmods.dev/badge/skills/runxhq/runx/loop-orchestration.svg" alt="Measured on agentmods" height="20"></a>
Per session 32 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 770 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 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.00032 $0.00770
Opus 5 $0.00016 $0.00385
Sonnet 5 $0.00006 $0.00154
Haiku 4.5 $0.00003 $0.00077

Measured 4d ago against content hash 12e858b1a9b1, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

loop-orchestration 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 4d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (loop/loop-host.mjs, loop/turn.mjs, run.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

examples/loop-orchestration/SKILL.md · 94 lines

How it starts

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

Loop Orchestration

This example shows the runx pattern for long-running agent work:

  1. An outer loop host decides whether work should continue.
  2. Each iteration submits one normal governed runx turn.
  3. Each turn seals a receipt before the loop can advance.
  4. The next turn consumes only explicit inputs, projection state, and receipt summaries.

Nothing in this example adds a loop engine to runx-core. The loop host is just an application script. In production it could be a hosted service, Temporal workflow, LangGraph app, n8n workflow, or another orchestrator.

Run It

sh examples/loop-orchestration/run.sh

The script runs three demonstrations:

  • success: two governed turns complete a tiny build-review loop;
  • refusal: a requested tool is outside the loop policy, so the loop stops before another turn is submitted;
  • context gate: an agent-task turn pauses with digest-bound skill context and explicit allowed_tools, showing what a host or managed provider would receive without requiring a model key.

The output prints each run id, receipt id, decision, and next-turn reason.

Check The Harness

For the repeatable inline harness, use a fresh receipt store and the demo signing identity. A clean store avoids mixing receipts signed by different local test issuers.

tmpdir="$(mktemp -d)"
RUNX_RECEIPT_SIGN_KID=runx-demo-key \
RUNX_RECEIPT_SIGN_ED25519_SEED_BASE64=QkJCQkJCQkJCQkJCQkJCQkJCQkJCQkJCQkJCQkJCQkI= \
RUNX_RECEIPT_SIGN_ISSUER_TYPE=hosted \
"${RUNX_BIN:-crates/target/debug/runx}" harness examples/loop-orchestration \
  --receipt-dir "$tmpdir" \
  --json

What This Proves

The important boundary is not the Node script. It is the contract:

  • A loop owns scheduling, durable loop state, projection, and stop policy.
  • A turn is one runx skill/graph run with explicit authority and one sealed receipt.
  • A handoff is an artifact/result the loop host can inspect; it is not hidden prompt continuation.
  • A projection is derived from receipts and admitted signals, not from ambient memory.

Read the full file on GitHub · 94 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 4d ago First seen · 94 lines · 32 tokens per session scan A 12e858b1a9b1

Subscribe to this mod's changes

loop-orchestration is a skill published in the GitHub repository runxhq/runx (84 stars, last pushed today), licensed Apache-2.0. It adds 32 tokens to every session and 770 once invoked, about $0.0002 per session on Opus 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.

Related

Other skills, from other repositories

aml-sim-console

How to operate the AML investigation console tools (mcp:aml-sim/) to triage a financial-crime referral and resolve a case. Use when working an anti-money-laundering alert, investigating suspicious transactions, or deciding whether to file a SAR.

comisai/comis · 59 tokens

mm-sim-desk

How to operate the algorithmic market-making desk tools (mcp:mm-sim/) to run a trading book through an episode and settle it for a graded result. Use when making markets, quoting two-sided prices, managing trading inventory, or running a market-making session.

comisai/comis · 61 tokens

officecli-financial-model

Use this skill when the user wants to build a financial model, 3-statement model, DCF valuation, cap table, scenario analysis, or financial projections in Excel. Trigger on: 'financial model', '3-statement model', 'DCF', 'cap table', 'pro forma', 'projections', 'sensitivity analysis', 'waterfall', 'debt schedule'…

CES-Ltd/TitanX · 136 tokens

aidlc-portfolio

Coordinate multiple AI-DLC workflows across repositories and Git worktrees using an evidence-backed portfolio catalog and deterministic workspace tooling. Use when initializing an AI-DLC portfolio workspace, discovering organization or business context, registering projects and dependencies, creating child intents and…

awslabs/cli-agent-orchestrator · 74 tokens

install-openclaw

Install and configure OpenClaw non-interactively with Alibaba Cloud Model Studio. Use when the user asks to install OpenClaw, configure Aliyun Bailian/Model Studio/DashScope credentials, choose pay-as-you-go, Coding Plan, or Token Plan billing, set Base URL/model config, optionally configure DingTalk, start the local…

alibaba/anolisa · 85 tokens

daemon

Continuous autonomous operation mode. Keeps campaigns running 24/7 by chaining Claude Code sessions via RemoteTrigger. Each session picks up from the campaign's continuation state, works until context runs low or the phase completes, then schedules the next session. Auto-stops on campaign completion or budget…

SethGammon/Citadel · 69 tokens