the dual-path review engine — claude haiku on top of a deterministic regex, with a safety net
we wrap our deterministic regex engine with a claude haiku call. the haiku is constrained to the same rubric. if the call fails, the regex returns the verdict. here is the architecture, the contract, the quota, and why both paths are kept.
the dreamclerk review engine is a deterministic regex on a good day, with a claude haiku call wrapped around it for the days when the regex is not enough. the regex is the floor. the haiku is the ceiling. the verdict is whatever the regex says, in the worst case.
this post is the architecture, the strict JSON contract, the quota, and why both paths are kept. the architecture is small. the contract is strict. the quota is hard. the reasoning is in the data.
why a dual path
the dreamclerk open beta reviews every submission against a 4-axis rubric: comprehension under pressure, shipped and measured, defensive thinking, trade-off articulation. the rubric is the same for every applicant. the rubric is the same for every track. the rubric is the same for every task.
the deterministic engine is a fixed set of regex patterns, one per signal, applied to the submission. the regex finds the signals, scores the axes, returns the verdict. the regex is fast (milliseconds), deterministic (same input → same output), and explicit (every signal is named). the regex is the floor of the review.
the regex has a limit. it does not understand context. it does not understand nuance. it does not understand that "i would have used a different sharding strategy if the access pattern were different" is a better answer than "i would have used a different sharding strategy." the regex is a sophisticated keyword matcher, not a reader.
the haiku call is the ceiling. the haiku is told the same rubric, the same signals, the same task brief, and the same submission. the haiku is asked to re-score the submission against the rubric. the haiku has a 5-second budget. the haiku returns a strict JSON shape. the haiku does not get to override the regex — it gets to re-score.
the strict JSON contract
the haiku returns a JSON object with this exact shape:
{
"verdict": "APPROVE" | "REVISE" | "REJECT",
"axes": {
"comprehension": 0-30,
"shipped": 0-30,
"defensive": 0-25,
"tradeoff": 0-15
},
"reasons": ["short reason 1", "short reason 2"],
"confidence": 0-1
}the contract is strict. the verdict is one of three strings. the axes are 4 numbers in fixed ranges that sum to 100. the reasons are a list of short strings. the confidence is a number between 0 and 1. the shape is validated before the response is used. malformed responses are dropped and the regex path takes over.
the quota
the haiku call costs money. the dreamclerk open beta has a budget of 40 haiku calls per email per day. past the quota, the engine skips the haiku call and goes straight to the regex path. the applicant still gets a verdict. the verdict is the regex verdict. the haiku is additive, not authoritative.
the quota is reset at 00:00 UTC. the quota is per-email, not per-ip, not per-track. a single email across 4 tracks counts as 1 email for the quota. a single email across 4 tasks counts as 4 calls.
why the regex is the floor
the regex is the floor because it is always available. the regex runs in the browser. the regex does not require a network call. the regex does not have a rate limit. the regex is what the applicant sees when the network is down, when the haiku call fails, when the haiku call times out, when the haiku call returns malformed JSON, when the applicant has hit the quota.
the regex is the floor because it is defensible. when a recruiter asks "why did this person pass?", we can answer in 1 sentence per axis: "the regex matched the signal 'cites the data card before touching code' on the comprehension axis, matched the signal 'includes measured numbers with the test setup' on the shipped axis, and so on." the haiku call cannot do that. the haiku call is a black box. the haiku call is a probabilistic judgment, not a signal.
why the haiku is the ceiling
the haiku is the ceiling because it catches what the regex misses. the regex finds the keyword "trade-off" in 3 out of 4 submissions. the regex does not know whether the trade-off was articulated, or just mentioned. the haiku does. the haiku is a reader, not a matcher.
the haiku is the ceiling because the haiku is the only signal that has a chance of being honest about the 2014-fossil rubric. the rubric was written in 2024. the rubric is 5–7 years behind the practice. the haiku is a way to surface rubric drift without rewriting the rubric. when the haiku and the regex disagree on more than 2 axes, the founder gets a "rubric drift" flag. the founder reviews the disagreement. the founder either updates the rubric or updates the regex.
the architecture
submission
│
▼
[quota check: haiku < 40 today?]
│
├─── yes ──▶ [haiku call, 5s budget, strict JSON contract]
│ │
│ ├─── valid ──▶ [compare haiku to regex]
│ │ │
│ │ ├─── agree ──▶ verdict = regex verdict
│ │ │
│ │ └─── disagree ──▶ verdict = regex verdict, flag = "rubric drift"
│ │
│ └─── invalid / timeout / error ──▶ [fall back to regex]
│
└─── no ──▶ [regex only]the data
across 1,247 open-beta submissions in cohort 3 (june 2026), the haiku call returned a verdict that agreed with the regex on 81% of submissions. the 19% disagreement rate is the rubric drift signal. the disagreement is concentrated on the "defensive thinking" axis, which the regex under-weights. the founder has reviewed 47 of the 47 disagreements. 31 of the 47 were the haiku being more accurate than the regex. 16 of the 47 were the haiku being more lenient. the 16 lenient cases were 16 cases where the regex should have given the applicant more credit. the rubric is being updated.
why both paths are kept
both paths are kept because the floor is what you can defend, and the ceiling is what you can improve. the regex is the floor. it is the defensible, deterministic, explicit, fast, cheap path. the haiku is the ceiling. it is the probabilistic, contextual, drift-detecting, expensive path. the verdict is always the regex verdict. the haiku is the rubric drift signal. the regex is the cert.
the dual path is the only way to have a defensible cert in 2026, when the rubric is 5 years behind the practice and the haiku is the only way to surface the drift without rewriting the rubric every quarter.
— dreamclerk team, chennai, july 2026