autoresearch-loop

autoresearch-loop is a skill for Claude Code, Codex from jdrhyne/agent-skills. It costs 120 tokens per session (1,857 once invoked), scanned A, original, MIT.

A repeatable experiment loop that improves a project against a measurable objective. It proposes a change, tests it, keeps improvements, reverts regressions, and records the results.

In plain words
What is it for?
Choosing a metric, running trials, comparing results, keeping successful changes, reverting failed ones, and maintaining an experiment history.
Why use it?
It provides a structured way to compare changes instead of keeping edits based only on guesswork.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Choosing a metric, running trials, comparing results, keeping successful changes, reverting failed ones, and maintaining an experiment history.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/jdrhyne/agent-skills/autoresearch-loop
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.

Any agent
npx skills add jdrhyne/agent-skills --skill autoresearch-loop
Clone the repo
git clone --depth 1 https://github.com/jdrhyne/agent-skills

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/jdrhyne/agent-skills/autoresearch-loop/github.svg)](https://agentmods.dev/skills/jdrhyne/agent-skills/autoresearch-loop)
Your own site
<a href="https://agentmods.dev/skills/jdrhyne/agent-skills/autoresearch-loop"><img src="https://agentmods.dev/badge/skills/jdrhyne/agent-skills/autoresearch-loop/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 autoresearch-loop

Your own site · 80×15
<a href="https://agentmods.dev/skills/jdrhyne/agent-skills/autoresearch-loop"><img src="https://agentmods.dev/badge/skills/jdrhyne/agent-skills/autoresearch-loop.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 120 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,857 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00120 $0.01857
Opus 5 $0.00060 $0.00928
Sonnet 5 $0.00024 $0.00371
Haiku 4.5 $0.00012 $0.00186

Measured 9d ago against content hash 721e9fd122f6, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

autoresearch-loop 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 9d ago.

The scan reads SKILL.md. This mod also ships 7 executable files (examples/code-perf-demo/.auto/checks.sh, examples/code-perf-demo/.auto/measure.sh, examples/code-perf-demo/bench.js, …), 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.

skills/autoresearch-loop/SKILL.md · 61 lines

How it starts

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

autoresearch-loop

Generalize Karpathy's autoresearch into a domain-adaptive improvement loop. The agent discovers what to measure, then runs a disciplined propose → trial → keep-or-revert loop, maintaining an explicit ledger of what was tried, kept, discarded, and implemented.

Read DESIGN.md once at the start of a run for the full architecture and the domain-specific tensions (metric latency/noise/cost, Goodhart gaming, cost-per-trial, reversibility). The phases below are the operating procedure.

Runtime: the loop's mechanics (run a trial, parse the metric, score confidence, keep/commit or discard/revert) are handled by the arl CLI over a .auto/ session folder — a Claude-native port of pi-autoresearch's tools. Read references/runtime-contract.md for the .auto/ layout, the METRIC name=value contract, MAD confidence scoring, and the arl init|run|log|status commands. Invoke it as node scripts/arl.mjs <cmd> (or arl if on PATH).

When NOT to run

  • There is no metric that can be measured repeatably and cheaply enough within a trial budget. A loop with no trustworthy metric chases noise — stop and say so.
  • The change surface is irreversible or unsafe to mutate experimentally (production data, customer-facing irreversible actions) without an explicit revert procedure in the adapter.

Phase 0 — FRAME (metric discovery)

Given {project, goal, context} — follow the procedure in references/metric-discovery.md (restate the goal as an outcome → enumerate candidates on the proxy→outcome spectrum → score on six axes → choose primary + guardrails + strategy → red-team for gaming). In brief:

  1. Identify or select a domain adapter (adapters/*.md). If none fits, draft an inline adapter following references/domain-adapter-contract.md.
  2. Propose candidate metrics (the adapter's menu is a prior, not the answer — reason from the goal). Score each on measurability, latency, noise, alignment, gameability, and cost. Prefer alignment over convenience for the primary.
  3. Pick ONE primary objective, a set of guardrail metrics that must not regress, a trial budget (wall-clock and/or cost per trial), and a stop condition (budget exhausted, plateau over K trials, or target hit).
  4. Choose the accept/reject strategy for this domain: deterministic-delta (fast, low-noise), significance-test, or bandit (noisy/delayed/expensive — e.g. ads).
  5. Name the Goodhart guards (guardrail metrics, holdout, periodic critic).
  6. Write runs/<id>/CHARTER.md. Confirm it with the user before spending real budget if trials cost money or touch production.

Read the full file on GitHub · 61 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. 9d ago First seen · 61 lines · 120 tokens per session scan A 721e9fd122f6

Subscribe to this mod's changes

autoresearch-loop is a skill published in the GitHub repository jdrhyne/agent-skills (241 stars, last pushed 10d ago), licensed MIT. It adds 120 tokens to every session and 1,857 once invoked, about $0.0006 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.