Jake Zhang

Why I Stopped Trusting Coding Agents to Mark Tasks Done (and Built gitvouch)

When coding agents work across long-horizon repositories (especially infrastructure-as-code or multi-step migrations), code generation is rarely the hardest problem anymore.

Trusting "done" is.

Over the past year of running Codex CLI and Claude Code against real Proxmox, OpenTofu, and Ansible infrastructure, I ran into the same two failure modes over and over:

  1. The self-closing loop: An agent writes code, runs a partial check (or no check at all), flips a Markdown checkbox to [x] or closes a ticket, and moves on. The next session inherits that false claim as ground truth.
  2. Quiet goalpost moving: Mid-task, an agent hits a thorny edge case and subtly rewrites the acceptance criteria in TASKS.md so what it built technically matches what the file now says.

Existing tools each solve part of the puzzle, but left a gap:

  • AGENTS.md is great for standing instructions, not verifying execution history.
  • Daemon or sync-branch trackers add a real task DAG, but background daemons and hidden sync branches create sharp edges across Git worktrees, and an agent can still close a ticket without proving acceptance criteria.
  • LLM-as-judge reviewers add latency, cost, and a second layer of hallucinations.

So I extracted the repository-native contract I had been running in production and packaged it into a single, zero-daemon CLI and GitHub Action: gitvouch (available on PyPI).

Four Boring Invariants (Zero Daemon, Zero LLM Calls)

Everything lives in plain JSON and Markdown inside .gitvouch/ and is verified offline with a single runtime dependency (jsonschema):

1. Freeze Acceptance Criteria at ready

When a task moves from proposed to ready, gitvouch writes an append-only event file (YYYYMMDDTHHMMSSZ--EVT-002.json) containing a full acceptance_criteria_snapshot.

If an agent later edits .gitvouch/control/tasks/T-001.json to weaken a requirement or bump task weight, gitvouch check fails closed:

gitvouch check FAILED:
  - Task T-001 acceptance criteria were modified after entering ready (tamper detected vs snapshot in EVT-002).

2. Evidence-Gated verified Transitions

No task can enter verified unless every acceptance criterion is backed by a structured, applicable, non-expired pass evidence record collected at or before verification time.

Instead of asking agents to hand-write JSON, gitvouch evidence run executes the real verification command, records the actual exit code, git rev-parse HEAD, whether the working tree was dirty, and a SHA-256 digest of stdout and stderr:

uvx gitvouch evidence run T-001 --criterion AC-1 --cmd "pytest -q"

If the command exits non-zero, it persists result: "fail" and gitvouch task verify T-001 refuses the transition.

3. Replayed Progress and verification_debt

Task state is never trusted at face value. gitvouch check replays every immutable event file chronologically and verifies that the task JSON matches replay. Progress is derived mathematically:

Progress: implemented=100.0% (5/5) | verified=60.0% (3/5) | verification_debt=2

When an agent writes lots of code without passing proof, verification_debt jumps immediately in CI and gitvouch status.

4. Auditable Durable Memory That Cannot Silently Drift

Operational facts live separately from tasks under .gitvouch/memory/ (state_snapshot.json, current_state.md, decisions.md, operation_log.md). last_reviewed must stay synchronized across machine state and human prose, and ages out with warnings when stale (gitvouch memory review --note "..." refreshes all three atomically).

Try It in 30 Seconds

uvx gitvouch init --profile application
uvx gitvouch task new --title "Add rate limiter" --scope "API middleware" --criterion "pytest passes"
uvx gitvouch task ready T-001
uvx gitvouch task start T-001
uvx gitvouch task implement T-001
uvx gitvouch task verify T-001          # Refused: missing passing evidence for AC-1
uvx gitvouch evidence run T-001 --criterion AC-1 --cmd "pytest -q"
uvx gitvouch task verify T-001          # Passes
uvx gitvouch check                      # Offline CI gate

You can also enforce it in GitHub Actions with uses: JacobYZ/gitvouch@v0.1.0 and drop skill/gitvouch/SKILL.md into Claude Code, Codex CLI, or Cursor.

Where gitvouch Is Not the Right Tool

If you are hacking on a throwaway weekend script, just use a Markdown checklist. If you want a Kanban web UI, use GitHub Projects or Linear. gitvouch is specifically for repositories where coding agents run across multiple sessions and you want deterministic, Git-reviewable proof that acceptance criteria were not quietly weakened or skipped.

Source code (MIT): github.com/JacobYZ/gitvouch