autoresearch
Use when running autonomous iterative experiments to optimize a measurable metric on an existing codebase — not for writing tests or diagnosing a specific…
Skill by matt-riley
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/matt-riley-autoresearch
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: writing
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/autoresearch
What's inside
- Skill name
autoresearch- Description
- Use when running autonomous iterative experiments to optimize a measurable metric on an existing codebase — not for writing tests or diagnosing a specific failure.
- License
- GPL-3.0
- Metadata
- kind: task · version: 2.0.1 · audience: general-coding-agent · category: workflow · maturity: draft
- Instructions
- 152 lines in SKILL.md · view on GitHub
Files (6)
- SKILL.md
- openai.yaml · agents/
- setup-template.md · assets/
- evals.json · evals/
- trigger-queries.json · evals/
- experiment-guide.md · references/
SKILL.md (first lines)
# Autoresearch Use this skill when the goal is to improve a specific, measurable outcome through repeated automated experiments — write a change, measure it, keep it or revert it, repeat. You define the metric; the agent runs the loop autonomously until interrupted or the budget is exhausted. This is distinct from test-driven development (writing tests for behavior) and systematic debugging (diagnosing a known failure). Use this skill when optimization through iteration is the work. ## Use this skill when - You want to iteratively improve a measurable outcome: execution time, bundle size, test pass rate, build time, latency, coverage, complexity, or a custom benchmark score. - You have a metric command that produces a numeric result and you want the agent to run experiments autonomously until interrupted or a budget is reached. - The right solution is not obvious upfront and you want to explore the space empirically. - You want to hill-climb: keep changes that help, discard changes that do not, and log everything. ## Do not use this skill when - The task is writing tests for a new feature or behavior (use `test-driven-development`). - The goal is diagnosing why something is broken (use `systematic-debugging`). - There is no measurable metric — the outcome is purely qualitative or subjective. - The codebase does not have a git repository or the user has not confirmed a dedicated experiment branch is acceptable. ## Routing boundary | Situation | Use this skill? | Route instead | | --- | --- | --- | | Writing failing tests before implementing a feature | No | `test-driven-development` | | Diagnosing why a test or build is failing | No | `systematic-debugging` | | Iteratively optimizing a benchmark or metric | Yes | — | | Improving code quality with no numeric signal | No | `systematic-debugging` or `verification-before-completion` | | Running a single targeted experiment to validate a hypothesis | No | Implement directly; this skill is for multi-experiment autonomous loops | ## Inputs to gather **Required before editing** - **Goal**: what you are trying to improve (e.g., execution time, pass rate, bundle size). - **Metric command**: the exact shell command that produces the metric (e.g., `npm run benchmark`, `go test -bench=. ./...`, `hyperfine './build.sh'`). - **Metric extraction**: how to pull the numeric value from the output (regex, JSON field, specific line). - **Direction**: `lower_is_better` or `higher_is_better`. - **In-scope files/directories**: what the agent is allowed to edit. - **Out-of-scope files/directories**: what must not be touched. **Helpful if present** - **Max experiments**: a count or `unlimited` (default: unlimited, stop only on interrupt). - **Constraints**: time budget per run, dependency policy, test-passing requirement, API compatibility, memory limits. - **Simplicity policy**: default is "simpler is better — weigh complexity cost against improvement magnitude." **Only investigate if encountered** - Existing benchmark history or prior result logs. - CI-enforced test gates that must stay green throughout the loop. ## First move 1. Confirm all required inputs are known. If the metric command or extraction method is unclear, ask before creating the branch. 2. Create a dedicated experiment branch: `git checkout -b autoresearch/<tag>` (use today's date as the tag, e.g., `autoresearch/2025-07-09`). 3. Run the metric command on the unmodified code and record the baseline value before any experiments begin. ## Workflow ### Phase 1: Setup confirmation Summarize all parameters in a table before proceeding: | Parameter | Value | | --- | --- | | Goal | … | | Metric command | … | | Metric extraction | … | | Direction | lower is better / higher is better | | In-scope files | … | | Out-of-scope files | … | | Constraints | … | | Max experiments | … | | Simplicity policy | … | Do not start the loop until confirmed. ### Phase 2: Branch and baseline 1. Create branch: `git checkout -b autoresearch/<tag>`. 2. Read all in-scope files to build full context of the current state. 3. Initialize `results.tsv` in the repo root with the header row (see `references/experiment-guide.md` for the TSV format). Add `results.tsv` and `run.log` to `.git/info/exclude` so they stay untracked without modifying any tracked file. 4. Run the metric command on unmodified code. Record as experiment `0` with status `baseline`. 5. Report baseline to the user before starting the loop. ### Phase 3: Experiment loop Run until `MAX_EXPERIMENTS` is reached or the user interrupts. Do not stop to ask permission between iterations. For each experiment: 1. **Think** — analyze previous results and current code. Generate a hypothesis. Consult `references/experiment-guide.md` for strategy ordering (low-hanging fruit first, diversify after plateaus, combine winners, etc.). 2. **Edit** — modify only in-scope files. Keep changes focused and minimal per experiment. 3. **Commit** — `git add <changed files> && git commit -m "experiment: <short description>"`. 4. **Run** — execute the metric command. Redirect to `run.log` (`<command> > run.log 2>&1`). 5. **Measure** — extract the metric from `run.log`. If extraction fails, read the last 50 lines for the error. 6. **Decide**: - **Improved**: keep the commit. Update the running best. - **Same or worse**: revert with a revert commit — `git revert HEAD --no-edit`. Log status `discard`. - **Crash/error**: if a quick single-line fix is obvious, apply it in a new commit and re-run once. If still broken after one fix attempt, revert with `git revert HEAD --no-edit` (or revert both commits if two were made) and log status `crash`. Do not use `--amend` or `reset --hard`. 7. **Log** — append one row to `results.tsv`: `experiment_number commit_hash metric_value status description`. 8. **Continue** — go to step 1. ### Phase 4: Report When the loop ends: 1. Print the full `results.tsv` as a formatted table. 2. Summarize: total experiments, kept / discarded / crashed counts, baseline vs. final metric, improvement percentage, top 3 most impactful changes. 3. Show the kept-commit log: `git log --oneline <start_commit>..HEAD`. 4. Recommend next steps: ideas that were too risky or complex for the automated loop. ## Outputs - `autoresearch/<tag>` branch containing only kept (improving) experiment commits. - `results.tsv` (untracked) — full experiment journal. - `run.log` (untracked) — output from the most recent metric run. - A written Phase 4 summary report in the chat.
From matt-riley/agent-skills, GPL-3.0.
More from matt-riley/agent-skills
- 0.614score
agent-governance
matt-riley
Use this skill when building AI agents that call external tools, implementing policy-based access controls, adding semantic intent classification, creating…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-instructions
matt-riley
Use when creating or updating agent instruction files (AGENTS.md for Pi, copilot-instructions.md for Copilot, per-path guides, or AGENTS.md router) —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-supply-chain
matt-riley
Use this skill when generating SHA-256 integrity manifests for agent plugins, verifying that installed plugins match their manifests, detecting tampered…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agentic-eval
matt-riley
Use when designing or implementing an evaluation loop for AI agent outputs — reflection loops, evaluator-optimizer pipelines, LLM-as-judge scoring, or…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
api-smoke-validation
matt-riley
Use when running quick, repeatable API smoke tests after changes with hurl, including auth, status-code, response-shape, endpoint sanity, and pre-integration…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
aws-sdk-v2-to-v3-migration
matt-riley
Use when the codebase still imports from 'aws-sdk' v2, uses new AWS.*() constructors, .promise() calls, AWS.config.update(), DocumentClient, or s3.upload() —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
circleci-to-github-actions-migration
matt-riley
Use when a repository still depends on .circleci/config.yml jobs, workflows, or artifacts that need to be replaced or phased out with GitHub Actions —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
mocha-to-jest-migration
matt-riley
Use when a JavaScript or TypeScript suite still depends on Mocha, Chai, or Sinon and needs an incremental Jest migration.
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
project-references-migration
matt-riley
Use when a layered TypeScript workspace needs an incremental project-references migration without breaking package boundaries or editor resolution.
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
ast-grep
matt-riley
Use when you need ast-grep structural search, linting, or safe codemod rewrites, especially for requests that mention ast-grep, sg, codemod, rule files, or…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
code-generation
matt-riley
Run and troubleshoot repository code generation after detecting the generator contract.
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
code-intelligence
matt-riley
Use when navigating or refactoring code — choosing between LSP, rg, or semantic search tools; an LSP call returns empty and you need to know if it failed; or…
SkillAFreshness: A★ 4Claude Code +9
Signals
- Stars
- 4
- Forks
- 0
- Open issues
- 1
- Last commit (this folder)
- Sep 24, 2026 (1 month ago)
- Last release
- Oct 23, 2026 (6 days ago)
From GitHub (fetched Oct 24, 2026).
Details
- Version
- 2.0.1
- License
- GPL-3.0
- Repository
- github.com/matt-riley/agent-skills
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from matt-riley
- 0.614score
agent-instructions
matt-riley
Use when creating or updating agent instruction files (AGENTS.md for Pi, copilot-instructions.md for Copilot, per-path guides, or AGENTS.md router) —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-supply-chain
matt-riley
Use this skill when generating SHA-256 integrity manifests for agent plugins, verifying that installed plugins match their manifests, detecting tampered…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agentic-eval
matt-riley
Use when designing or implementing an evaluation loop for AI agent outputs — reflection loops, evaluator-optimizer pipelines, LLM-as-judge scoring, or…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
api-smoke-validation
matt-riley
Use when running quick, repeatable API smoke tests after changes with hurl, including auth, status-code, response-shape, endpoint sanity, and pre-integration…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
aws-sdk-v2-to-v3-migration
matt-riley
Use when the codebase still imports from 'aws-sdk' v2, uses new AWS.*() constructors, .promise() calls, AWS.config.update(), DocumentClient, or s3.upload() —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-governance
matt-riley
Use this skill when building AI agents that call external tools, implementing policy-based access controls, adding semantic intent classification, creating…
SkillAFreshness: A★ 4Claude Code +9
Cite this page
autoresearch skill. Agent Mart. https://agentmart.dev/skills/matt-riley-autoresearch (last updated 2026-10-24)