01
Git Diff
→
02
Gristle AST
→
03
Validated Map
→
04
FalkorDB Graph
→
05
5 MCP Tools
→
06
BLOCK Verdict
→
07
Counterfactual
Stage 01 Git Integration

Detect the Real Source Code Change

In our flagship demonstration PR-900, a developer changes a contract field type in contracts/pricing.py:

@@ class PriceQuote:
-    discount_tier: str
+    discount_tier: dict

BlastGate extracts the real unified git diff between the target branch and working tree, isolating changed symbols and field-level alterations.

Evidence produced: Symbol: contracts/pricing.py::PriceQuote, Field: discount_tier, Change Type: type_changed (str → dict).
Stage 02 Gristle Subprocess

Index the AST into FalkorDB Code Graph

BlastGate executes Gristle inside an isolated virtual environment (.gristle-venv). Gristle parses the full repository AST and populates an in-memory code graph in FalkorDB with nodes representing classes, functions, and endpoints.

Gristle indexes structural relationships: 6 dependent functions and 2 API routes that reference PriceQuote.

Rigor Guard: BlastGate explicitly enforces that class-level or function-level AST links do not prove that a given function accesses the specific changed field at runtime.
Stage 03 Contract Registry

Validate Contract Mapping to Service Graph

Before traversing the service graph, code-level changes must be validated against published contract schemas in blastgate.map.json.

BlastGate verifies that PriceQuote.discount_tier is the authoritative implementation for the schema field pricing-api-v2.discount_tier emitted by the service pricing-engine.

Mapping Status: validated (Ambiguous or unmapped changes are flagged with explicit UNCERTAIN warnings rather than false CLEARs).
Stage 04 FalkorDB Cypher

Query Connected Multi-Hop Blast Radius

Once mapped, FalkorDB executes multi-hop Cypher queries along CONSUMES_FIELD and DEPENDS_ON relationships:

MATCH (s:Service)-[:CONSUMES_FIELD]->(f:SchemaField {field: $field})
OPTIONAL MATCH path = (downstream:Service)-[:DEPENDS_ON*1..4]->(s)
RETURN s, path

The query discovers that checkout-api is a direct consumer (hop 1), which feeds order-orchestrator (hop 2) and storefront-bff (hop 2), cascading further to invoice-worker and partner-gateway (hop 3).

Stage 05 MCP Tool Pipeline

Investigate via 5 Allowlisted MCP Tools

The agent orchestrator triggers five distinct Model Context Protocol tools, each answering a specific question with schema-validated arguments:

  1. inspect_change: Validates schema type and producer properties.
  2. inspect_contract_coverage: Checks consumer fallback readiness. Discovers checkout-api has fallback_enabled = false.
  3. trace_blast_radius: Traverses all transitive downstream services, identifying 5 affected systems and 3 at-risk SLAs.
  4. analyze_network_criticality: Computes sampled betweenness centrality, highlighting order-orchestrator with a critical score of 4.0 (highest in topology).
  5. retrieve_incidents_and_reviewers: Queries graph history for outage INC-2041 and assigns responsible engineers eng-alpha and eng-bravo.
Offline Demo Integrity: The offline demonstration uses a deterministic planner following tool-result next_actions. It does not fabricate autonomous live-LLM tool decisions.
Stage 06 Verdict Engine

Deterministic Verdict: BLOCK

BlastGate's deterministic verdict policy evaluates the verified Cypher evidence:

  • Critical Failure: A breaking type change reaches consumer checkout-api without fallback handling.
  • SLA Impact: Cascades to critical services checkout-api and order-orchestrator, generating an assumed $43,000 SLA penalty across SLA-CHECKOUT-99.95 and SLA-ORDERS-99.9.
  • Incident Risk: Re-exposes the root cause of past outage INC-2041.

The rule engine outputs an authoritative BLOCK. Agent commentary can explain the verdict, but cannot weaken or override it.

Stage 07 GRAPH.COPY Engine

Hypothetical Counterfactual Simulation

The developer asks: "What if checkout-api implements a backward-compatible fallback?"

BlastGate copies the active graph into a temporary isolated graph (GRAPH.COPY) in FalkorDB. On the copy, it sets checkout-api.fallback_enabled = true and re-executes the verdict engine.

The simulated outcome becomes CLEAR. BlastGate renders a visual topology diff, while keeping the production graph and authoritative BLOCK decision strictly unchanged and explicitly marked UNVERIFIED.

Experience the 7-Stage Pipeline in Real Time

Run PR-900 through the live console and observe each stage execute.

Launch Live Investigation Console →