autoresearch-hooks

autoresearch-hooks is a skill for Claude Code, Codex from ethanolivertroy/my-agent-stuff. It costs 54 tokens per session (1,568 once invoked), scanned A, original, MIT.

A way to add scripts that run before and after each iteration of an autoresearch session. An iteration is one repeated experiment in which a change is tested and recorded.

In plain words
What is it for?
It is for adding research fetching, Slack or webhook notifications, persistent learnings, automatic tags, anti-thrashing behavior, or idea rotation around recorded experiments.
Why use it?
It lets the research loop trigger side effects such as fetching information, sending notifications, saving learnings, or steering future experiments without changing the loop itself.

Skill for Claude CodeCodex

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

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is ' | ./autoresearch.hooks/before.sh.

Good fit It is for adding research fetching, Slack or webhook notifications, persistent learnings, automatic tags, anti-thrashing behavior, or idea rotation around recorded experiments.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/ethanolivertroy/my-agent-stuff
agentmods
npx agentmods add skills/ethanolivertroy/my-agent-stuff/autoresearch-hooks

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-hooks

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/ethanolivertroy/my-agent-stuff/autoresearch-hooks"><img src="https://agentmods.dev/badge/skills/ethanolivertroy/my-agent-stuff/autoresearch-hooks.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 54 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,568 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.00054 $0.01568
Opus 5 $0.00027 $0.00784
Sonnet 5 $0.00011 $0.00314
Haiku 4.5 $0.00005 $0.00157

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

Security

Grade A, and why

autoresearch-hooks 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 10d ago.

The scan reads SKILL.md. This mod also ships 9 executable files (examples/after/auto-tag-winners.sh, examples/after/learnings-journal.sh, examples/after/macos-notify.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.

skills/autoresearch-hooks/SKILL.md · 174 lines

How it starts

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

autoresearch-hooks

Optional scripts that run at iteration boundaries in an autoresearch session. Two hooks, both transparent to the loop-running agent — their effect is a file on disk or a steer message.

autoresearch.hooks/
  before.sh    # fires before each iteration (prospective)
  after.sh     # fires after each log_experiment (retrospective)

Both files are optional. Files without the executable bit are silently ignored.


Contract

Stdin — before.sh

One JSON line. Parse with jq. Realistic example:

{
  "event": "before",
  "cwd": "/path/to/workdir",
  "next_run": 6,
  "last_run": {
    "run": 5,
    "status": "discard",
    "metric": 42.1,
    "description": "Simplified to sorted(arr) — copy cost dominates",
    "asi": {
      "hypothesis": "Built-in sort avoids Python overhead",
      "next_focus": "list copy avoidance"
    }
  },
  "session": {
    "metric_name": "total_ms",
    "metric_unit": "ms",
    "direction": "lower",
    "baseline_metric": 40.7,
    "best_metric": 33.5,
    "run_count": 5,
    "goal": "optimize sort speed"
  }
}
Field Notes
last_run The most recent run entry. null on a fresh session.
session.direction "lower" or "higher" — which end of the scale wins.
session.baseline_metric First run of the current segment. null until one run exists.
session.best_metric Optimal metric across kept runs only. null until one is kept.
session.goal The session name set by init_experiment.
session.run_count Total runs logged so far (any status).

Stdin — after.sh

{
  "event": "after",
  "cwd": "/path/to/workdir",
  "run_entry": {
    "run": 6,
    "status": "discard",
    "metric": 38.9,
    "description": "Timsort hybrid slower on random",
    "asi": {
      "hypothesis": "Partial-sort heuristic on input distribution",
      "learned": "Overhead dominates on random arrays"
    }
  },
  "session": {
    "metric_name": "total_ms",
    "metric_unit": "ms",
    "direction": "lower",
    "baseline_metric": 40.7,
    "best_metric": 33.5,
    "run_count": 6,
    "goal": "optimize sort speed"
  }
}

Read the full file on GitHub · 174 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. 10d ago First seen · 174 lines · 54 tokens per session scan A 061bcc8bea7b

Subscribe to this mod's changes

autoresearch-hooks is a skill published in the GitHub repository ethanolivertroy/my-agent-stuff (11 stars, last pushed 2mo ago), licensed MIT. It adds 54 tokens to every session and 1,568 once invoked, about $0.0003 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

duckduckgo-search

Free keyless web, news, and image search via ddgs.

NousResearch/hermes-agent · 19 tokens

mcporter

List, auth, and call MCP servers/tools from the terminal.

NousResearch/hermes-agent · 16 tokens

mem0-oss-to-platform

Plan and then execute a migration of a project from the mem0 open-source / self-hosted SDK (the local Memory class) to the mem0 Platform / hosted / managed SDK (the MemoryClient class). Use this whenever a developer wants to move, switch, or migrate their mem0 usage off OSS/self-hosted to the hosted API — e.g.…

mem0ai/mem0 · 273 tokens

deploy-docker-compose

Run the Omnigent server as a Docker compose stack (server + Postgres) on any Docker host — your laptop, a VPS, EC2 by hand, or as the base layer of any container-platform deploy. Invoke when the user wants to build the image, bring up the compose stack, debug the stack on a host they already have, or extend the stack…

omnigent-ai/omnigent · 84 tokens

mapping-to-snomed

Maps clinical concept spans extracted by OpenMed to SNOMED CT concepts through a USER-SUPPLIED terminology server (the user's own Ontoserver, Snowstorm, or UMLS/UTS), never a bundled vocabulary. Use when the user wants to code findings, disorders, procedures, body structures, or substances to SNOMED CT, run an ECL…

maziyarpanahi/openmed · 205 tokens

auditing-subgroup-fairness

Audit an OpenMed NER or de-identification model for performance disparities across demographic subgroups (sex, age band, race/ethnicity when available) using openmed.eval.fairnessreport. Use when the user wants per-subgroup recall and leakage, wants to check whether de-identification under-protects a group, wants to…

maziyarpanahi/openmed · 148 tokens