Introduction
I built this pipeline after watching a client ship "optimized" landing pages where the eval agent invented passing scores for content it had also rewritten. The model was grading its own homework. Separation of read and write fixed that in one sprint.
Five agents, one fixed order, guardrails on both ends. It handles GEO (Generative Engine Optimization) and SEO quality for pages before they go live. The orchestration pattern is similar to what I describe in supervisor vs handoffs multi-agent systems, with explicit role boundaries.
The five agents
| Agent | Job | Read/Write |
|---|---|---|
| Orchestrator | Route tasks, manage state | Neither (directs only) |
| CORE Evaluator | 40 GEO criteria (C-O-R-E) | Read only |
| EEAT Evaluator | 40 SEO criteria (E-E-A-T) | Read only |
| Schema Validator | JSON-LD and HTML semantics | Read only |
| Rewrite Agent | Failing sections only | Write only |
CORE, EEAT, and Schema run in parallel. Rewrite runs after eval completes. That cuts runtime about 60% versus sequential eval.
Model routing per agent
Do not run Opus on every step. Roughly 80% of calls stay on Haiku and Sonnet.
- Orchestrator: Sonnet 4.6 for tool routing and state management.
- CORE Evaluator: Sonnet 4.6 for 40-item structured eval and reliable function calling.
- EEAT Evaluator: Haiku 4.5 for binary pattern checks at one-fifth Sonnet cost.
- Schema Validator: Haiku 4.5 for deterministic JSON-LD classification.
- Rewrite Agent: Opus 4.7 only on failing sections, with self-check every rewrite.
The cost rule matches what I cover in stop paying frontier prices for classification: one frontier call per failing section, not per page.
Input guardrails (zero tokens on bad inputs)
- URL reachability: abort 404, 403, timeout within 200ms.
- Content type detection: blog, FAQ, guide, landing. Wrong type means wrong rubric.
- Content length floor: below 300 words, skip E and R dimensions.
- Language detection: non-English scoped out before any model call.
Output guardrails (broken output never leaves)
- 01Score integrityRecalculate scores independently. If divergence exceeds 5 points, re-run eval.
- 02Fix completenessEvery Fail must have a Fix. Orphan failures force a rewrite pass.
- 03Citation verificationFetch rewrite URLs. Remove non-200 links before delivery.
- 04Rewrite self-checkMax 2 loops per section. Opus checks its own output against the criterion.
- 05Schema validationStrip invalid JSON-LD and flag for manual fix.
Three memory layers
Not one context dump. Three layers keep tokens lean.
- CAG (cached in prompt): 80-item benchmarks, error patterns, schema mapping. Stable for months. ~90% cost reduction on cache hit.
- RAG (retrieved at eval): schema.org specs and rewrite examples by criterion ID. Only 2–3 specs per run.
- Session context: page content, eval results, rewrite task list. Cleared after every run, never persisted.
Memory layer choice follows the same rules as wrong memory, dead agent: CAG for stable rubrics, RAG for specs that change, session for ephemeral task state.
The fixed pipeline order
- 01Validate inputFour input guardrails. Zero cost on bad URLs, wrong language, thin content.
- 02Evaluate in parallelCORE, EEAT, Schema simultaneously.
- 03Score and sortGEO-first failures first, then dual failures, then SEO-first.
- 04Rewrite to specFailing sections only. Opus only. Self-check every output.
- 05Validate outputFive output guardrails. Pass/fail confidence flag against all five.
Conclusion
Run this pipeline on every piece of content before publish. Same order every time. The deliverables are dimension scores across 8 dimensions, a priority fix list sorted by GEO impact, rewritten failing sections, and a pass/fail flag. Build it once, run it forever.


