loop-operator

An operating guide for autonomous coding-agent loops: repeated runs where an agent works, checks progress, and continues. It defines checkpoints, stop conditions, recovery steps, and escalation rules.

In plain words
What is it for?
Use it to start, monitor, pause, retry, or safely resume long-running agent tasks.
Why use it?
It helps prevent stalled loops, repeated failures, uncontrolled retries, and work that exceeds its budget. It also requires safeguards such as tests, rollback, and isolated branches or worktrees.

Agent

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 agents/fmarzochi/egc/loop-operator
Clone the repo
git clone --depth 1 https://github.com/Fmarzochi/EGC
Per session 19 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 179 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 100% copy Near-identical to another mod 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.00019 $0.00179
Opus 5 $0.00010 $0.00089
Sonnet 5 $0.00004 $0.00036
Haiku 4.5 $0.00002 $0.00018

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

Security

Grade A, and why

loop-operator 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 2d ago.

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.

Origin

This is a copy

100% identical to loop-operator — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.kiro/agents/loop-operator.md · 37 lines

What it actually says

You are the loop operator.

Mission

Run autonomous loops safely with clear stop conditions, observability, and recovery actions.

Workflow

  1. Start loop from explicit pattern and mode.
  2. Track progress checkpoints.
  3. Detect stalls and retry storms.
  4. Pause and reduce scope when failure repeats.
  5. Resume only after verification passes.

Required Checks

  • quality gates are active
  • eval baseline exists
  • rollback path exists
  • branch/worktree isolation is configured

Escalation

Escalate when any condition is true:

  • no progress across two consecutive checkpoints
  • repeated failures with identical stack traces
  • cost drift outside budget window
  • merge conflicts blocking queue advancement
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. 2d ago First seen · 37 lines · 19 tokens per session scan A 37df24bfa25b

Subscribe to this mod's changes

loop-operator is an agent published in the GitHub repository Fmarzochi/EGC (46 stars, last pushed 6d ago), licensed Apache-2.0. It adds 19 tokens to every session and 179 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. It is 100% identical to loop-operator, differing in 0 lines, and is treated as a copy.

Related

Other agents, from other repositories

test-hunter

Generates adversarial tests for a module or feature. Does NOT write happy-path tests — that is the author's job. Finds inputs that break contracts, bypass permissions, trigger race conditions, or violate invariants. Invoke when a module has a base suite and needs adversarial hardening, before merging a sensitive…

jghiringhelli/forgecraft-mcp · 83 tokens

change-reviewer

Reviews structural changes (new modules, refactors, schema changes) for architecture conformance, naming conventions, layer violations, and missing ADRs. Invoke when a PR touches architecture, data model, or adds a new domain module.

jghiringhelli/forgecraft-mcp · 50 tokens

security-reviewer

Reviews code changes for security issues: credential leaks, auth bypass, missing input validation, unsafe operations, and violations of operation-classification.md. Invoke before merging PRs that touch auth, API routes, or credential handling.

jghiringhelli/forgecraft-mcp · 48 tokens

spec-guardian

Verifies the codebase is in sync with the spec (PRD.md, use-cases.md, ADRs, data-model.md). Detects derivation gaps — code that contradicts the spec, spec that has no implementation, and structural decisions without an ADR. Invoke before cutting a release or when drift is suspected.

jghiringhelli/forgecraft-mcp · 69 tokens

gem-mobile-tester

Mobile E2E testing: Detox, Maestro, iOS/Android simulators.

mubaidr/gem-team · 22 tokens

ijfw-assumptions-analyzer

Use when surfacing hidden assumptions in a brief or plan before execution begins -- what does the plan assume that the spec doesn't guarantee?

FerroxLabs/ijfw · 34 tokens