section 5 — system architecture

Five layers, written so a non-specialist evaluator can follow it.

Layers 1–3 are detection: they tell you a plan is contradictory as written, after the fact. Layer 4 is forecasting. Layer 5 is what makes either usable inside a government.

L1

Document Intelligence

Ingests the full planning corpus (~8,000–12,000 pages) and builds a normalised index. Core challenge is entity resolution: the same program appears under different names across ministries and cycles.

  • Two-stage pipeline: named-entity extraction, then embedding-based alias matching against a verified anchor list.
  • Target ontology: 1,200–1,500 normalised programs; entity-resolution accuracy >85% as a go/no-go gate.
  • Retrieval is two-stage: dense embedding search for recall, cross-encoder re-ranking for precision — this is what keeps unsupported-claim rates low enough for government use.
L2

Agent Swarm

Six specialised agents, sequenced by build priority. The fundable MVP is the two P0 agents, not all six in parallel.

  • Contradiction Detector (P0) — Flags directionally incompatible targets across ministries using semantic entailment, not keyword matching.
  • Budget Coherence Agent (P0) — Matches budget allocations against strategic-plan commitments; flags unfunded commitments and orphaned budget lines.
  • Stigmergic Tracer (P1) — Maps cross-ministry dependencies by accumulating confirmed connections over repeated passes.
  • Regional Signal Agent (P1) — One lightweight instance per province; flags divergence between regional and national targets.
  • Historical Precedent Agent (P2) — Benchmarks current programs against historical delivery rates for analogous past programs.
  • SDG / Reporting Alignment Agent (P2) — Maps programs to reporting taxonomies (e.g. SDGs); flags coverage gaps and double-counting.
L3

Coordination Graph

Agents never message each other. Each writes findings into a shared graph: nodes are programs, edges are detected relationships.

  • A finding confirmed independently across multiple passes gets weighted up; an unconfirmed one decays.
  • After each pass the graph is analysed for structural criticality — which programs would disrupt the most others if they failed.
  • This produces prioritisation without anyone hand-specifying what 'important' means.
L4

Predictive Simulation — "Policy Flight Simulator"

Layers 1–3 detect contradictions after publication. Layer 4 forecasts what a draft policy breaks downstream, before money or political capital is committed.

  • Causal/structural model over the Coherence Graph — structural causal models / Bayesian networks (DoWhy, EconML, pgmpy).
  • Gaussian Process forecasting — point forecast plus calibrated confidence interval; direct reuse of the author's existing SFFM reliability model.
  • Agent-based / system-dynamics simulation — cascade effects across the 34-ministry system (Mesa); output is a distribution of futures, not one prediction.
  • Survival analysis on historical outcomes — Cox proportional hazards / Weibull (lifelines) on RPJMN 2015–2024 outcome data.
L5

Human Interface & Accountability

Every output carries source passage or model basis, confidence score, severity, and a recommended action. No finding triggers an automated action.

  • Decision authority stays with human analysts — required by Indonesian planning law and the trust mechanism that makes adoption possible.
  • Forecasts always show the confidence interval, never a bare point prediction.

layer 2 — agent swarm

Six agents, sequenced — not built in parallel.

The original design proposed all six at once. For a fundable MVP the sequence is the two P0 agents first: they map directly to the two failure modes buyers pay to fix fastest, and both can be validated against Bappenas' public 2024 evaluation without waiting for 2027.

Contradiction Detector

P0

Flags directionally incompatible targets across ministries using semantic entailment, not keyword matching.

Build first — maps to the failure mode buyers pay to fix fastest.

Budget Coherence Agent

P0

Matches budget allocations against strategic-plan commitments; flags unfunded commitments and orphaned budget lines.

Build first — validatable against the public 2024 evaluation.

Stigmergic Tracer

P1

Maps cross-ministry dependencies by accumulating confirmed connections over repeated passes.

Feeds edge weight into the Coherence Graph.

Regional Signal Agent

P1

One lightweight instance per province; flags divergence between regional and national targets.

34 provincial instances at full deployment.

Historical Precedent Agent

P2

Benchmarks current programs against historical delivery rates for analogous past programs.

Upgraded to survival analysis inside Layer 4.

SDG / Reporting Alignment Agent

P2

Maps programs to reporting taxonomies (e.g. SDGs); flags coverage gaps and double-counting.

Reporting surface, not a detection primitive.

why this is defensible

The moat is the historical outcomes dataset, not the LLM calls.

Causal inference, calibrated uncertainty and cascade simulation are a different discipline from text generation — none of the four Layer 4 components is something a general-purpose LLM does well natively. They also depend on a data asset a competitor cannot easily acquire: labelled historical outcomes for RPJMN 2015–2019 and 2020–2024.

DoWhy / EconML / pgmpyGaussian Process (SFFM reuse)Mesa ABMlifelines — Cox / Weibull

Each deployment also produces labelled outcome data — what the predictive layer forecast versus what actually happened — which improves calibration for the next deployment. That is the argument for why country #2 is easier to sell and serve than country #1.

section 5.7 — validation methodology

A confidence score is meaningless without a process for checking whether it was right.

Backtest design

Train the Gaussian Process and survival models on RPJMN 2015–2019 program data and outcomes; test predictions against what actually happened in RPJMN 2020–2024, which is already known. This gives a real accuracy/calibration number before the 2027 evaluation exists.

Calibration check, not just accuracy

For forecasts issued at 80% confidence, roughly 80% should actually occur over enough predictions. Report calibration curves, not only point accuracy.

ABM/cascade validation

The hardest of the four: validated by checking whether the pattern of downstream effects matches historical cascades, not by expecting exact numeric agreement.

Until backtesting is run and published, every confidence number shown to an investor or pilot buyer is labelled provisional / pre-validation.