autonomous repair agent · exposed as an MCP server

Break the site.
Watch the agent stitch it back.

Reweave is a self-healing layer for web data pipelines — and you never write a selector. Paste a URL and a few golden examples and the Surgeon synthesizes the extraction spec; when a redesign breaks it, the Sentinel detects the drift, the Surgeon repairs it, and the Gate holds every fix until a named human approves — before a single bad row ships.

zero-selector onboarding golden-record validation human-approved deploys MCP-native
reweave · agent event stream
16:35:49pipeline run via demo:v1 — 8 rows, confidence 100% (spec v1)
16:35:49target site shipped a redesign (now structural era v2)
16:35:49pipeline run via demo:v2 — 0 rows, confidence 0% (spec v1)
16:35:49structural drift detected: 0 rows vs 8 golden records; title/price/url 0% extractable
16:35:49Surgeon engaged: record-anchored selector synthesis
16:35:50repair synthesized + self-tested in isolation: 4 selector changes, validation 100%
16:35:50heal heal_d4bd304690 awaiting human approval (v1 → v2)
16:36:27moorthy approved heal_d4bd304690: spec v2 deployed (+90 engineer-min saved)
16:36:27pipeline run via demo:v2 — 9 rows, confidence 100% (spec v2)
the pain

Selector surgery is a tax every data team quietly pays.

Scrapers don't crash when a site redesigns — they go quiet, or worse, ship wrong data. Someone notices days later, then spends an afternoon in devtools rebuilding selectors by hand.

10–15%
of scrapers break every week
community-reported break rate, r/webscraping
0 hrs/yr
of engineer time, per 50-scraper fleet
~325 breaks/yr × 90 minutes of manual selector surgery each
$0
burned annually on repair toil
at a fully-loaded engineering rate — pure maintenance, zero new value
90 min 30 s
per fix, with Reweave
each manual repair becomes a review-and-approve
how it works

Three roles. One healing loop.

Detection, synthesis, and approval are deliberately separated — the agent that finds the break is not the agent that ships the fix, and no fix ships without a human.

01 · Detect

Sentinel

Validates every run against golden records — facts the pipeline has already proven true. It catches silent failures, not just crashes.

  • Golden-record validation on every pipeline run
  • Per-field drift reports: row volume, extractability, confidence
  • Flags 0 rows vs 8 known-true records instead of shrugging at an empty page
02 · Repair

Surgeon

Record-anchored selector synthesis: it re-locates known-true facts in the redesigned DOM and works backward to the selectors that find them.

  • Re-anchors golden values ("$379.99", "Aurora 27" 4K Monitor") in the new DOM
  • Generalizes the shared structural signature across all matches
  • Validates every candidate against all golden records before proposing
  • Bootstraps new sources the same way — onboarding is a heal from zero
03 · Approve

Gate

Nothing deploys itself. The repair waits with full before/after diffs and re-extracted data until a named human signs off.

  • Side-by-side selector diffs + live re-extraction preview
  • Named approver required — accountability is part of the protocol
  • 30-second review, permanently recorded in the audit ledger

The healing loop

FETCH Bright Data Web Unlocker EXTRACT active spec vN SENTINEL VALIDATE vs golden records SURGEON SYNTHESIZE record-anchored repair GATE APPROVE named human · full diffs DEPLOY immutable spec vN+1 healthy → rows ship drift! 100% validated approved next run
Sentinel flags drift with per-field precision
Surgeon proposes only selectors that pass every golden record
Gate requires a named human before anything deploys
fetch layer

Bright Data Web Unlocker handles hostile targets — anti-bot walls, geo-blocks, rendering — so the healing loop sees the same DOM a real user sees.

agent layer

Reweave is an MCP server — nine tools, from add_source to gated deploys. The TrueForge agent harness drives onboarding, detection, and repair, with harness-level approval gates layered on top of Reweave's own Gate.

zero-selector onboarding

From zero to healing. You never write a selector.

Onboarding is the same record-anchored machinery as healing, pointed at day one. Paste a URL and two or more golden examples — records you can see on the page — and the Surgeon synthesizes and validates the extraction spec itself.

dashboard+ Add source clireweave add apiPOST /api/sources mcpadd_source
reweave add · live web, real run
$ reweave add https://books.toscrape.com
…3 golden examples pasted (title · price · url)
anchored 3/3 examples in the live DOM
container article.product_pod — most specific covering every card
title img.thumbnail@altattribute anchor
price p.price_color
spec v1 validated: 20 rows · confidence 100%
selectors written by a human: 0

Anchors in text — or in attributes

Real catalogs truncate what you can see: the page shows “A Light in the …” while the full value lives in a title= or alt= attribute. Synthesis anchors your examples in node text or attributes, groups candidates by (tag, attribute) shape, and picks the most specific container selector that covers every anchored card — so a few examples generalize to the whole page.

<article class="product_pod"> <!-- full value lives in the attribute --> <img class="thumbnail" alt="A Light in the Attic"> <!-- visible text is truncated --> <a title="A Light in the Attic">A Light in the …</a> <p class="price_color">£51.77</p> </article>
reweave · mission control — live source onboarded
Reweave mission control with a live source onboarded from three golden examples: Books catalog healthy at 20 rows and 100% confidence, autopilot toggle on, and the event stream reading spec v1 bootstrapped from 3 golden examples — no selectors written 1 2 3 4
1

The zero-selector front door. + Add source takes a URL and 2+ golden examples — the same call as reweave add, POST /api/sources, or the add_source MCP tool.

2

The Surgeon bootstraps the spec. "spec v1 bootstrapped from 3 golden examples (3 fields, validation confidence 100%) — no selectors written."

3

A real site, live. books.toscrape.com healthy on its synthesized spec — 20 rows at 100% confidence, every run's rows stored and browsable in the data drawer.

4

Autopilot, always on. Every source re-checked on a 60-second cadence. Detection and synthesis never sleep — deploys still wait at the Gate.

data out

Every run's rows are stored — the last 20 runs per source — browsable in the dashboard's data drawer and exportable as CSV or JSON: /api/sources/{id}/rows?fmt=csv, reweave export, or the get_rows MCP tool.

autopilot

Continuous background monitoring of every source — 60 s default, one dashboard toggle. Detection and repair synthesis run around the clock; deploys still wait for a named human at the gate.

live demo walkthrough

One click ships a hostile redesign. The agent does the rest.

The demo runs a real pipeline against demo://nimbusmart, a product site with a "ship redesign" button that renames every class and restructures the DOM — the exact failure that kills scrapers in the wild.

01the target mutates

Same products. Entirely new DOM.

Era v1 → era v2: light theme to dark, serif rebrand, and — the part that matters — every selector's anchor is gone. div.product-cardarticle.tile. The old spec extracts 0 rows and raises no exception. That's a silent failure.

ERA V1 · spec works
demo://nimbusmart · era v1
NimbusMart era v1: light-themed product grid where the original selectors still match

div.product-card › h3.product-name › span.price-tag
8 rows · confidence 100%

ERA V2 · spec breaks
demo://nimbusmart · era v2
NimbusMart era v2: dark redesigned product grid where every class name has changed

div.product-cardarticle.tile · h3.product-nameh2.tile__heading
0 rows · confidence 0% · no exception raised

02the agent responds

Drift caught, repair synthesized, held at the gate.

Within one run: the Sentinel reports per-field drift, the Surgeon re-anchors all 8 golden records in the new DOM and synthesizes 4 selector changes at 100% validation confidence — and the whole heal sits waiting in the approval rail. No deploy has happened yet.

reweave · mission control
Reweave mission control: fleet panel marked BROKEN, agent event stream showing drift detection and repair synthesis, and the approval gate with selector diffs, re-extracted data, and an Approve deploy button 1 2 3 4 5 6
1

Fleet status flips to BROKEN. NimbusMart's pipeline is pinned to spec v1 with 8 golden records on file — the ground truth the whole loop runs on.

2

The event stream narrates the drift. 0 rows vs 8 golden records; title, price, and url each 0% extractable. A crash-only monitor would have seen nothing.

3

The heal arrives 100% validated. heal_d4bd304690 proposes spec v1 → v2, synthesized from golden-anchored fields.

4

Full before/after selector diffs. div.product-cardarticle.tile, span.price-tagspan.cost__now — every field with its match rate against all golden records.

5

Re-extracted data, previewed live. The repaired spec is run in isolation first: real titles, real prices, before anything is trusted.

6

A named human closes the loop. The approver types their name — accountability is a required field — then Approve deploy. Until then, nothing moves.

03the loom goes quiet

Approved, deployed, healthy — in 38 seconds.

After approval the ledger records who deployed what: moorthy approved heal_d4bd304690 · spec v2 deployed. The next pipeline run returns 9 rows at 100% confidence, the fleet flips back to HEALTHY, and the approval rail reads "No repairs awaiting approval. The loom is quiet."

reweave · mission control — after approval
Reweave mission control after approval: fleet HEALTHY on spec v2, ledger showing the named approval, and an empty approval gate reading 'The loom is quiet'
safety by design

An autonomous agent that is structurally incapable of going rogue.

Reweave assumes the agent will sometimes be wrong. Every safeguard is load-bearing, not decorative — and the harness above it doesn't have to trust it.

Approval gate

Detection and synthesis are autonomous; deployment never is. Every heal waits at the Gate with full before/after diffs until a human acts.

Accountable actor

Approval requires a name. Every deploy is attributable to a specific person — "who shipped this selector change?" always has an answer.

Audit ledger

An append-only event stream records every detection, synthesis, validation score, approval, and deploy — the full provenance of every spec.

Immutable spec versions

Specs are never edited in place. v1 survives v2 forever; a bad heal rolls back with a pointer move, not a frantic re-repair.

MCP destructiveHint

The deploy tool is flagged destructive in the MCP contract itself, so any well-behaved client interposes its own confirmation — the protocol tells the truth about risk.

Defense in depth via TrueForge

The TrueForge harness drives Reweave over MCP with its own approval gates layered on top of the Gate. Two independent humans-in-the-loop, one deploy.

quantified impact

The math on a 50-scraper fleet.

Take the community's own break rate, a typical fleet, and a stopwatch. The toil is not hypothetical — it's payroll.

fleet-projection.calc
fleet_size50 scrapers
weekly_break_rate12.5% (r/webscraping: 10–15%)
breaks_per_year50 × 0.125 × 52 = 325

manual_fix_time90 min each
engineer_hours325 × 1.5 h = 487.5 h/yr
annual_toil≈ $46,312 / yr

reweave_fix_time30 s review-and-approve
engineer_hours325 × 30 s ≈ 2.7 h/yr
toil_recovered≈ $46,000 / yr back

Time per broken scraper

manual selector surgery90 min
reweave review-and-approve30 s
180×

less engineer time per fix — with a human still signing every deploy