skip to content
Active

monerex

An AI-driven development lifecycle for Claude Code. From a request to a merged pull request, agents do the work in gated stages, hooks hold the rules, and you approve the plan, anything posted under your name, and the merge.

5 min read

Why it exists

My skills each cover one job well: reviewing a pull request, answering reviews, fixing a bug. What they do not cover is the path in between: how big the task is, what was actually asked for, whether the plan was agreed before code changed, and which model should do which part. Left to that path on its own, an agent writes code before anyone has settled what is wanted, reviews its own work in the same context that produced it, and runs every step on whatever model the session happens to be on.

The other gap is where the rules live. “Never push to the default branch” or “the checks passed on this commit” written in a prompt is a request the model may forget under pressure. Written in a hook, it is a refusal.

monerex puts both into one loop: stages with gates, agents with narrow jobs, and rules that a tool call cannot talk its way past.

How it works

Each task goes through stages that start fresh and hand over through a short file, not through the conversation. A trivial T0 task (a typo, a rename) is edited inline and runs only the checks; from T1 up, the full loop applies:

  • start sizes the task from T0 (trivial) to T3 (large) and sets risk flags: auth, money, migrations, secrets, a public API, a new dependency.
  • intent asks the few questions whose answers change the design, for T2 and above.
  • plan writes the design, the tasks and the commands that prove it works. Nothing changes until the plan is approved.
  • build makes the change test-first through one implementer agent, the only agent that may edit code. The change is then committed and taken out once more to prove its tests fail without it.
  • verify runs the checks again in a fresh context and compares the diff with the plan.
  • review is a fault-finding review in a fresh context: one reviewer, or up to four with separate angles for a feature or a risky change (five when the diff touches a query, a remote call or a loop over outside data), plus a second model family on a risk-flagged change when one is set up. Every finding is checked against the code before it is reported.
  • ship, feedback and bugfix push the branch, open the pull request, work the review comments and take a tracked bug from report to fix. Each runs only when typed, and the text of every pull request and reply is shown for approval first.
  • retro reads the logged tasks and proposes a handful of changes to the way of working, each tied to a number, and says whether the ones accepted earlier moved theirs.

Nine agents share the work, each with a narrow tool list. A routing table picks the model and effort per stage from the tier and the risk flags. When a stage fails, the gap is named and the stage escalates: a skipped step raises the effort, a wrong diagnosis raises the model, and an unclear requirement comes back to the user instead of being retried.

Beside the loop, /monerex:consult puts one question to a specialist agent (web research, machine learning or data science) and checks the claims a decision rests on; /monerex:dispatch starts a task in another repository as its own background session; and saved workflows fan out for wider jobs: a multi-angle review whose every finding faces a verifier told to refute it, a read-only audit across many paths, competing designs judged against each other, and one mechanical change made at many sites, each in its own worktree.

Design decisions

  • Rules in hooks, not prompts. The hooks refuse a force-push, a push to the default branch, a skipped git hook, a merge, a push before the checks passed on what it pushes, and edits to protected files: secrets, lockfiles not in the plan, the test a bugfix locked, agent configuration, CI workflows. A private list of terms, and secrets, are kept out of commands, edits and web requests. They are early warnings that stop accidents. The real boundaries remain a sandbox, branch protection and the user’s own review, and the documentation says so.
  • A test has to be able to fail. Build takes its own change back out and reruns the tests. A test that still passes without the change proves nothing, and the stage is sent back; only for a refactor must the tests pass both ways.
  • Fresh eyes, recorded. A verify verdict or a review’s counts are not recorded unless that agent actually ran and finished in the session recording them, so a stage cannot be skipped by claiming it passed.
  • Untrusted text becomes claims. Issues, review comments and bot output go through a reader agent that turns them into a fixed list of claims and reports embedded instructions instead of following them.
  • Model and effort are chosen, never inherited. By default searching runs on the smallest model, building and verifying on the middle one, planning, debugging and review on the largest.
  • Measured, not assumed. Evals run the plugin for real against stored baselines, with held-out tasks kept apart from tuning. On the smoke suite it passed 30 of 30 runs, against 6 of 30 without the plugin.
  • Installing changes nothing. The hooks do nothing until a repository opts in with /monerex:init. No server, no telemetry; logs stay in the repository.
  • Works with oxn. When a repository has an oxn.yaml, the plan carries its architecture constraints, build runs its gate on every change and review quotes what it measured.

Status

Early, at 0.3.0. The whole loop and the pull-request stages have run for real on the project itself, and the guards have been through several review rounds. A careful first release, not a finished product. MIT licensed.

Click any figure or table to zoom.