rharness
An opinionated research harness for ML and NLP work done with coding agents. One command, a disciplined workspace.
curl -fsSL https://raw.githubusercontent.com/Vein05/rharness/main/install.sh | shWhy
- Research moves faster than it ever has. Coding agents write the code, run the experiments, and draft the text.
- Speed does not change the obligation. Every number in a paper must trace back to the run and the code that produced it, and the record must survive a hostile reread.
- Working on several projects at once multiplies the risk. When five ideas are in flight, memory is not a system. Verification has to be built into the workspace, with a human reading the evidence and not only the summary.
- Accountability comes with the faster tools, not instead of them. The agent does the work; the researcher owns the claim.
- Hence rharness: the contracts, records, and checks that make that ownership real, written as files the agent reads and you edit.
Opinions
These are not defaults you configure. They are the product.
- A kill criterion before any spend. Every project starts with
CHARTER.md: the core question, the result that means the paper exists, and the result that means stop. - Spec before code. The headline table is designed in
spec/scoring.mdbefore a single number exists, with its control row and its ceiling row. Code without a spec is a probe and never produces a paper number. - Never rewrite history. Handoffs, changelogs, and experiment reports are dated and append-only. Corrections are added on top with a date.
- Every number traces to a scorer version and a run. Rounded values are never copied between documents.
- Manual audit before belief. A detector's first output is never reported. Read the hits, spot-check every category, check traces.
- Authoritative versus historical. Each project's
AGENTS.mdsays which documents are current and which are dated records. - Absolute dates only. Never "last Thursday" in a persistent file.
- One agent entry point.
AGENTS.mdis the source of truth for Claude Code, Codex, and any collaborator.CLAUDE.mdis a one-line include. - Prose passes the three-reader test. A strong student, a PhD student, and a senior scientist must all get the result on one pass.
- Drift is measured, not assumed.
rharness lintchecks every rule above that a script can check, and exits nonzero when one fails.
Plugins
Opt-in packs of guidance, and sometimes a helper or a hook. Installing one inserts a section into the workspace AGENTS.md, so the agent follows its rules from the next session on. Removing one takes the section out and deletes the files you did not edit.
rtk installed by default
A token-saving command proxy for Claude Code. It rewrites common shell commands such as git, grep, and test runners to compact-output equivalents through a hook, so the agent reads less and you pay less. rharness doctor checks that the hook is still registered.
Comes with rharness init. Re-add with rharness add rtk. Needs rtk and jq, installed by its setup script if missing.
figures
An SVG-first figure pipeline: a style guide, a geometry checker that fails the build on overflowing text, off-axis rows, and drifting strokes, an icon fetcher, and a matplotlib style. Every figure goes through render, inspect, critique, fix. The mark at the top of this page was made with it.
rharness add figures. Needs rsvg-convert, pdffonts, and Pillow.
review-panel
Runs your paper through panels of LLM reviewers at multiple model tiers, with a holdout canary and a hard spend ceiling. The diagnostic that matters is whether each reviewer's summary states your actual claim; misreads locate framing failures. No paid run starts without an estimate shown and your approval.
rharness add review-panel. Needs OPENROUTER_API_KEY, pdftotext, and pip install openai pyyaml.
wandb
Weights & Biases tracking rules for every training or evaluation run: descriptive names, logged config, seed, model and dataset identifiers, and the git commit. Each project gets a run initialiser that fills those fields in.
rharness add wandb. Needs WANDB_API_KEY and pip install wandb.
ideas
A ranked ideas backlog, one file per idea, with the date of its last novelty scan and a dead-cells list of ideas confirmed scooped so they are not proposed again. Re-scan before chartering.
rharness add ideas. Needs nothing.
Your own
rharness plugin new my-plugin scaffolds a plugin directory with its manifest, its AGENTS.md section, and a README. Push it to GitHub and anyone installs it with rharness add owner/repo, or owner/repo/subdir when several plugins share a repository. Local paths and git URLs work too.