4.15 How Graph Engineering is Deployed at EstateAigents.com — RAIA (Real estate Artificial Intelligence Agent) Documentation
Graph Engineering at EstateAigents.com means one agent, one job — no agent tries to do everything. The PA plans and dispatches; Programmer writes code; Scribe writes docs; RedTeam reviews on demand. Every task travels through a chain: PA specs it, one agent executes it, PA verifies it against a deterministic gate (TypeScript compiles, links don't break, the page is live at a real URL). DONE means live on docs.estateaigents.com or app.estateaigents.com — nothing else counts.
Graph Engineering at EstateAigents.com means one agent, one job — no agent tries to do everything. The PA plans and dispatches; Programmer writes code; Scribe writes docs; RedTeam reviews on demand. Every task travels through a chain: PA specs it, one agent executes it, PA verifies it against a deterministic gate (TypeScript compiles, links don't break, the page is live at a real URL). DONE means live on docs.estateaigents.com or app.estateaigents.com — nothing else counts.
The canonical reference for how all code and documentation is produced at EstateAigents.com — which graph topology for which task type, what quality gates, what DONE means, and the 3-seat pipeline.
Section A The 4 Topology Shapes — Which to Use When
Kopadze's fake-edge test: "Does this step actually need the result of the one before it?" If not, the edge is fake — the jobs can run in parallel. The topology follows from dependency structure, not preference.
| Topology | Pattern | When RAIA (Real estate Artificial Intelligence Agent) Uses It | Status in RAIA |
|---|---|---|---|
| Chain | A → B → C (sequential, real dependencies) | Every coding task (Programmer) and every documentation task (Scribe). Step 2 genuinely needs step 1's output. | Live — dominant pattern |
| Simple Node | Single bounded job, defined input/output, no delegation | Cron scripts: doc-watchdog.sh, kanban-dispatch-tick.sh, deploy.sh. No sub-delegation, no LLM in dispatch path. |
Live |
| Fan-out | One → N parallel workers (independent tasks, no merge) | Currently informal: --max 2 dispatch fires up to 2 tasks per tick. No merge step. Example: Researcher cron runs independently alongside main kanban queue. |
Partial / informal — no merge step |
| Diamond | Fan-out → N parallel workers → verify → merge | Not yet used. Hypothetical: compliance scan across legal (Architect), codebase (Programmer), docs (Scribe) → PA synthesises one result. Requires coordinated fan-out dispatch + PA merge protocol. | Not built — designed only |
The full visual diagram of RAIA's graph topology — the 6-node graph, the diamond pattern inset, node status indicators, and the TCA context panel — is available at docs.estateaigents.com/graph-engineering-pictogram.html.
Section B The 3-Seat Pipeline: PA → Programmer/Scribe → PA
Every non-trivial task at EstateAigents.com follows the same 3-seat chain. No shortcuts. No self-dispatching agents. No "commit = done".
-
1PA writes spec & creates kanban task
PA (claude-sonnet-4-6, default profile) writes a precise implementation brief. Creates a kanban task with
assignee_profile=programmer(orscribefor docs). Spec must include acceptance criteria. No spec = no dispatch. -
2kanban-dispatch-tick.sh fires (hourly cron, zero-LLM)
Cron
ea794b0e7fc7polls the board, dispatches up to 2 tasks per tick viahermes kanban dispatch --max 2 --json. Silent if nothing to dispatch. Telegram alert if dispatch fires. -
3Programmer / Scribe executes the task
The assigned agent executes exactly the spec. Programmer: writes code, runs
tsc --noEmit, passes SQL gates. Scribe: writes HTML page, passesdeploy.shbroken-link gate. Agent cannot call the task done until the quality gate exits 0. -
4PA verifies the live URL
PA curls the production URL:
curl -sI https://docs.estateaigents.com/... | grep HTTPorcurl -sI https://app.estateaigents.com/...— whichever matches the deliverable type. Must return HTTP 200. Only then does PA callkanban_complete. Subagent output is not verification. "Committed" is not verification. Live 200 is verification.
Section C The Quality Gates — What Must Pass Before DONE
Quality gates are deterministic anchors (TCA framework, Anchor axis). They cannot be argued away by prose. Either the gate exits 0 or the task is not done.
| Gate | Applies To | Command / Check | Pass Condition |
|---|---|---|---|
| TypeScript compile | All code changes touching TypeScript files | tsc --noEmit |
Exit code 0, zero errors |
| SQL integrity | Database schema changes, migrations | SQL syntax check / migration dry-run | Exit code 0, no constraint violations |
| Broken-link gate | All documentation deployments | bash deploy.sh (includes curl -sI spot checks) |
No 404s in spot checks; deploy exits 0 |
| Live HTTP 200 | All tasks producing a deliverable at a URL | curl -sI https://docs.estateaigents.com/<path> | grep HTTP (or dev./app. as appropriate) |
Returns HTTP/2 200 or HTTP/1.1 200 |
| Content presence check | Documentation pages | grep -c '<expected-string>' /path/to/raw.html |
Returns ≥ 1 |
If a completion criterion cannot be expressed as a deterministic pass/fail check (exit code, grep count, HTTP status), it must be escalated to Eugin for human judgment. PA does not accept "agent said it looks right" as a completion anchor.
Section D The RedTeam Gate — When It Is Triggered
RedTeam (claude-opus-4-6-thinking, redteam profile) is the independent verifier node. It receives a clean brief — not the same session as the original agent — and challenges the output on fresh context.
- Any change that proposes a new ADR
- Any change that contradicts or supersedes an accepted ADR
- Any roster change (adding/removing profiles, changing dispatch rules)
- Any change to the deterministic dispatch mechanism
- Authentication or authorisation logic changes
- Changes to tenant data access patterns
- New external API integrations with data access
- Changes to environment variable handling or secrets management
RedTeam does not auto-dispatch. PA invokes it explicitly: hermes -p redteam "<challenge brief>". The RedTeam review is a simple node in graph topology terms — it receives a scoped challenge brief and returns a verdict. It does not have access to the original agent's session context.
Section E The Definition of DONE — No Hallucinations Rule
Nothing else. These states do NOT constitute DONE:
- “Committed to git” — not done
- “Deployed to branch” — not done
- “Subagent reported success” — not done
- “Tests passed locally” — not done
- “Merged to main” — not done
DONE = PA verified HTTP 200 at the production URL.
Subagents reliably report success even when output never reaches a live URL — due to path errors, rsync mismatches, nginx config issues, or deployment script failures. The only tamper-proof verification is a curl of the canonical URL. PA must perform this check independently, not trust the executing agent's self-report.
| Task Type | Canonical Verification Command | DONE Criterion |
|---|---|---|
| Documentation page (dev audience) | curl -sI https://docs.estateaigents.com/developer-guide/<slug>.html | grep HTTP |
HTTP 200 |
| Documentation page (ops audience) | curl -sI https://docs.estateaigents.com/user-guide/<slug>.html | grep HTTP |
HTTP 200 |
| Dev sandbox page / pictogram | curl -sI https://docs.estateaigents.com/<slug>.html | grep HTTP (or app. as appropriate) |
HTTP 200 |
| App feature (Paperclip) | curl -sI https://app.estateaigents.com/<path> | grep HTTP |
HTTP 200 |
Dev Three Pillars of Graph Engineering at RAIA
Pillar 1: One Node, One Responsibility (wandermist)
"Every node has one responsibility. Every connection has a reason." — @wandermist
| Graph Engineering Concept | RAIA (Real estate Artificial Intelligence Agent) Implementation |
|---|---|
| One node = one bounded job | Each Hermes profile has a defined role: PA (hub/planner), Programmer (code), Scribe (docs), Architect (design), RedTeam (review), Researcher (intel) |
| Defined input/output contract | Kanban task structure: spec → execution → output with verification gate |
| No sub-delegation within a node | ADR-271 doctrine: agents do not self-spawn. Orchestration is deterministic, not LLM-driven |
Pillar 2: The Fake-Edge Test (Kopadze / wandermist)
"Removing these 'fake edges' often improves a workflow more than adding another AI model." — @wandermist
| Task Type | Fake-Edge Test Result | Correct Topology | RAIA (Real estate Artificial Intelligence Agent) Status |
|---|---|---|---|
| Implement a feature | Yes — Programmer needs spec | Chain | Live |
| Document a page | Yes — Scribe needs brief | Chain | Live |
| Check if cron is running | No dependencies | Simple node | Live |
| Compliance scan across 3 domains | No — legal/code/doc research is independent | Diamond | Designed, not built |
| Weekly market research + code audit + doc review | No — independent | Fan-out → merge | Designed, not built |
Pillar 3: Independent Verification (wandermist / Kopadze)
"Generating content has become easy. Trusting it has not." — @wandermist
| Concept | RAIA (Real estate Artificial Intelligence Agent) Implementation |
|---|---|
| Independent verifier | RedTeam profile (claude-opus-4-6-thinking) reviews on-demand |
| Deterministic verification | tsc --noEmit exit 0, curl -sI HTTP 200, grep for expected content |
| Human-in-loop | Eugin reviews PA output in the steering loop (hours) |
| Verifier on fresh context | RedTeam receives a clean brief — not the same session as the original agent |
Dev The leopardracer 6-Node Formula Mapped to RAIA
"Six nodes, one shared state, packets flying edge to edge in real time while the graph completes itself." — @leopardracer
| leopardracer Node | RAIA (Real estate Artificial Intelligence Agent) Profile | RAIA (Real estate Artificial Intelligence Agent) Model | Live? |
|---|---|---|---|
| Task | Eugin / PA intake | Eugin writes spec; PA formalises | Live |
| Researcher | researcher profile |
moonshotai/kimi-k3 | Live (weekly cron) |
| Planner | default (PA) |
claude-sonnet-4-6 | Live |
| Writer | scribe profile |
moonshotai/kimi-k3 | Live |
| Code Agent | programmer profile |
claude-sonnet-4-6 | Live |
| Reviewer | redteam profile |
claude-opus-4-6-thinking | Live (on-demand) |
| Deploy | deploy.sh script + PA verify |
Deterministic script | Live |
Dev Graph Engineering Vocabulary Reference
| Term | Definition | RAIA (Real estate Artificial Intelligence Agent) Equivalent |
|---|---|---|
| Node | A bounded job with defined input/output contracts | A Hermes profile session with a kanban task |
| Edge | A real data dependency between two nodes | A kanban task dependency (spec → execution → verification) |
| Fake edge | An apparent dependency that is not actually required | A task sequentialised unnecessarily when parallel execution is possible |
| Chain | A → B → C sequential topology | PA → Programmer → PA verify (every coding task) |
| Simple node | Single agent, no delegation, defined IO | doc-watchdog.sh, deploy.sh |
| Fan-out | One node dispatches N independent parallel nodes | --max 2 dispatch (informal, no merge step) |
| Diamond | Plan → parallel workers → verify → merge | Designed but not built |
| Independent verifier | A node that reviews output on fresh context | RedTeam profile (on-demand) |
| Anchor | Deterministic completion criterion | tsc --noEmit exit 0; curl -sI HTTP 200 |
| Human-in-loop | A gate requiring human judgment before proceeding | Eugin review in steering loop |
References External Sources
This page references the following external sources, ordered by relevance to RAIA's architecture:
| Source | Author | Link | Relevance to RAIA |
|---|---|---|---|
| Three Loops of 0-to-1 AI Products | Andrew Ng | Referenced throughout RAIA (Real estate Artificial Intelligence Agent) docs | Clock-frequency framework: inner loop (minutes), steering loop (hours), external loop (weeks) — maps to the Clock axis of the TCA Framework that governs RAIA's dispatch cadence and quality gate timing. |
| Graph Engineering explained: what it is, when to use it and when not to | @AnatoliKopadze | x.com/AnatoliKopadze/status/2080668775796314331 | Foundational vocabulary for this page: nodes, edges, fake-edge test, chain topology, diamond pattern, independent verifier, and anchors doctrine — the language of RAIA's topology selection and quality gate design. |
| Graph Engineering is really just systems design | @wandermist | x.com/wandermist/status/2080974834851340400 | Introduces the three pillars (one node one responsibility, fake-edge test, independent verification) and the diamond pattern — all three pillars are directly implemented or targeted in RAIA's agent architecture. |
| 6-node graph formula: Task → Researcher → Planner → Writer+Code → Reviewer → Deploy | @leopardracer | x.com/leopardracer/status/2080980071813177629 | Maps one-to-one to RAIA's 6-profile roster; "reviewer kicks back to the exact node that broke" describes RAIA's chain retry mechanism; "the graph is not a fancier loop, it is the org chart your agents were missing" validates ADR-271's roster design. |
Session 2026-08-10 What’s Live Today — Session 2026-08-10
Think of it like a flight recorder for your AI team. Before today, the graph dashboard showed which agents existed but not which ones actually talked to each other. Today we wired the actual handoff trail — when Architect finishes and hands work to Programmer, that handoff is now recorded as a provenance edge in the database. The graph lights up those real connections in blue.
1 — tbl_agent_graph_edges Schema
A new Supabase table that stores every recorded handoff between agent runs. This is the provenance layer — the permanent trail of which run produced which output.
| Column | Type | Notes |
|---|---|---|
id | uuid (PK, default gen_random_uuid()) | Primary key |
wave_id | text | Groups edges by dispatch wave (e.g. wave_2026-08-10T09:00) |
from_run | uuid FK → tbl_agent_logs.log_id (nullable) | The agent run that produced the output |
to_run | uuid FK → tbl_agent_logs.log_id (nullable) | The agent run that consumed / followed from it |
edge_type | text CHECK constraint | One of: PRODUCED · DERIVED_FROM · SUPPORTS · EVALUATED_BY · REVISES |
artifact_summary | text (nullable) | Optional human-readable description of what was handed off |
created_at | timestamptz default now() | When the edge was recorded |
A unique constraint on (from_run, to_run) makes all edge writes idempotent — re-running sync never creates duplicate edges. Implemented via ON CONFLICT DO NOTHING.
d09df0d9 — tbl_agent_graph_edges created ·
fcc8005b — unique constraint (from_run, to_run)
2 — The Sync Edges API
POST /api/sysadmin/agent-graph/sync-edges reads tbl_agent_logs, groups runs by wave_id, infers consecutive handoff order (sorted by created_at ASC), and writes PRODUCED edges between consecutive runs — or REVISES edges when a quality-agent retries back to a programmer run.
| Parameter | Type | Default | Description |
|---|---|---|---|
wave_id | string (optional) | — | Target a specific wave. Omit to process all waves in the hours window. |
hours | number | 24 | Look-back window in hours when wave_id is not specified. |
dry_run | boolean | false | If true, compute edges but do not write them. Returns the same shape with edges_written: 0. |
Return shape:
{
"waves_processed": 3,
"edges_found": 12,
"edges_written": 9,
"edges_skipped": 3, // already existed (ON CONFLICT DO NOTHING)
"dry_run": false
}
06e0c1a8 — sync-edges route · 1dd37332 — /api/sysadmin/agent-runs now returns graph_edges[] alongside runs/waves
3 — How to Use the Sync Edges Button
-
1Navigate to the Sysadmin console
Go to app.estateaigents.com → log in → open dashboard-v2 → click the Sysadmin tab.
-
2Open Agent Activity
Inside Sysadmin, select the Agent Activity tab. The AgentGraphPanel (React Flow, copper/amber theme) appears at the top of the tab.
-
3Click Sync Edges after a wave completes
Once a dispatch wave has finished (all agent runs show a terminal status), press the Sync Edges button. The route reads the last 24 hours of runs, infers handoff order, writes edges, and returns the result summary. Nodes that have provenance edges animate in blue; nodes with no edges remain grey.
Sync Edges is currently a manual trigger. The post-run hook that would write edges automatically when each agent run completes has not been built yet. See “What’s Still Missing” below.
7507b963 — Sync Edges button added to AgentActivityTab · b251e635 — AgentGraphPanel edge animation driven by real provenance rows
4 — What’s Still Missing
Agents currently receive context via prompts only. The next architectural layer would let agents query a typed entity graph to retrieve prior run outputs, decisions, and artefacts. This does not exist yet — agents cannot traverse the graph to build their own context.
Edges are written manually via the Sync Edges button. The correct solution is a post-run hook that fires whenever an agent run reaches a terminal state, automatically calling the sync-edges route for that run’s wave. Until that hook exists, the graph only updates when a human clicks the button.
The scheduler that runs shadow-mode comparison for the document classifier is paused — it needs Fook to resume via the GCP console. The ratchet loop (auto keep/revert on metric improvement) is blocked until this is running. Current scores: Haiku M0 at 69.8% (FAIL by 0.002), Gemini Pro at 74.1% (only passing model).