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.
npx skills add twaldin/flt --skill pi-autoresearch-loopgit clone --depth 1 https://github.com/twaldin/fltWrote 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.
[](https://agentmods.dev/skills/twaldin/flt/pi-autoresearch-loop)<a href="https://agentmods.dev/skills/twaldin/flt/pi-autoresearch-loop"><img src="https://agentmods.dev/badge/skills/twaldin/flt/pi-autoresearch-loop.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.02628 |
| Opus 5 | $0.00000 | $0.01314 |
| Sonnet 5 | $0.00000 | $0.00526 |
| Haiku 4.5 | $0.00000 | $0.00263 |
Grade A, and why
pi-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 7d 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.
How it starts
The opening of the file, as written. The whole thing — 398 lines — stays where its author put it; the contents beside it link to each section on GitHub.
---
name: pi-autoresearch-loop
cli-support: [all]
description: Autonomous experiment loop for pi that continuously tries optimizations, measures results, and keeps what works
triggers:
- autoresearch
- autonomous experiment loop
- optimize automatically
- run experiment loop
- continuous optimization
- benchmark and improve
- start autoresearch session
- keep what works discard what doesnt
---
# pi-autoresearch — Autonomous Experiment Loop
> Skill by [ara.so](https://ara.so) — Daily 2026 Skills collection
Autonomous experiment loop extension for [pi](https://github.com/antiwork/pi). Continuously proposes changes, benchmarks them, commits wins, reverts losses, and repeats — forever. Works for any measurable target: test speed, bundle size, build time, LLM training loss, Lighthouse scores.
---
## Installation
```bash
pi install https://github.com/davebcn87/pi-autoresearch
Manual install:
cp -r extensions/pi-autoresearch ~/.pi/agent/extensions/
cp -r skills/autoresearch-create ~/.pi/agent/skills/
Then /reload in pi.
Quick Start
/skill:autoresearch-create
The agent will:
- Ask about your goal, command, metric, and files in scope (or infer from context)
- Create a branch
- Write
autoresearch.mdandautoresearch.sh - Run the baseline
- Start looping immediately — no further input needed
Core Concepts
Two-file persistence model
Every session is fully recoverable from two files:
| File | Purpose |
|---|---|
autoresearch.jsonl |
Append-only log — one JSON line per run (metric, status, commit, description) |
autoresearch.md |
Living document — objective, what's been tried, dead ends, key wins |
A fresh agent with zero memory can read these two files and continue exactly where the previous session left off.
Session files written by the skill
| File | Purpose |
|---|---|
autoresearch.md |
Session document — objective, metrics, files in scope, experiment history |
autoresearch.sh |
Benchmark script — pre-checks, runs the workload, outputs METRIC name=number lines |
autoresearch.checks.sh |
(optional) Backpressure checks — tests, types, lint. Failures block keep |
Extension Tools
init_experiment
One-time session configuration. Call once at session start.
await init_experiment({
name: "vitest-speed",
metric: "seconds",
unit: "s",
direction: "lower", // "lower" | "higher"
});
run_experiment
Runs any shell command, times wall-clock duration, captures stdout/stderr.
const result = await run_experiment({
command: "pnpm test --run",
timeout_seconds: 120, // optional, default 300
checks_timeout_seconds: 300, // optional, for checks script
});
// result: { exit_code, duration_seconds, stdout, stderr }
log_experiment
Records result, auto-commits on keep, updates the status widget and dashboard.
await log_experiment({
metric_value: 42.3,
status: "keep", // "keep" | "discard" | "crash" | "checks_failed"
description: "Enable parallel test workers in vitest config",
commit_message: "perf: parallel vitest workers → 42.3s (-18%)",
});
The Autonomous Loop
Once started, the agent runs this cycle indefinitely:
propose change → edit files → run_experiment → measure metric
↓
metric improved?
YES → log_experiment(keep) → auto-commit → update autoresearch.md
NO → log_experiment(discard) → git revert → try next idea
↓
repeat forever (until interrupted)
Interrupt anytime with Escape, then ask for a summary of what was tried.
Benchmark Script Format
autoresearch.sh must output at least one METRIC line:
#!/bin/bash
set -euo pipefail
# Pre-checks
[ -f package.json ] || { echo "No package.json"; exit 1; }
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.
- 7d ago First seen · 398 lines · 0 tokens per session scan A 9adcd8680c4b
pi-autoresearch-loop is a skill published in the GitHub repository twaldin/flt (5 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,628 tokens. 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-31.
Other skills, from other repositories
Science
The scientific method as a universal problem-solving algorithm — goal-first, plural falsifiable hypotheses, designed experiments, and honest measurement, scaling from TDD to feature validation to MVP launch. USE WHEN think about, figure out, experiment, iterate, optimize, hypothesis, science, full cycle, quick…
ArXiv
Search and retrieve arXiv academic papers by topic, category, or paper ID — with AlphaXiv-enriched AI-generated overviews. Uses arXiv Atom API across cs.AI/cs.LG/cs.CL/cs.CR/cs.MA/cs.SE/cs.IR. Three workflows: Latest, Search, Paper. USE WHEN arxiv, papers, latest papers, research papers, recent ML papers, paper…
adaptyv
Cloud laboratory platform for automated protein testing and validation. Use when designing proteins and needing experimental validation including binding assays, expression testing, thermostability measurements, enzyme activity assays, or protein sequence optimization. Also use for submitting experiments via API…
harness-init-runner
Initialize a lightweight repo-local Node.js harness (harness/ + .harness/) WITHOUT AIOS dependency. Use ONLY when you need a standalone, portable harness. If AIOS is installed, use aios-long-running-harness instead — it has rex Command hosting, ContextDB integration, and checkpoint recovery.
claude-ally-health
A health assistant skill for medical information analysis, symptom tracking, and wellness guidance.
openevidence
Query OpenEvidence (clinical evidence assistant) without an MCP server. Closely mirrors the openevidence-mcp tool surface - check auth, list question history, fetch an article, or ask a new question (with optional follow-up thread). Use when the user asks medical / evidence-based clinical questions, references…