<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Ayooluwa Oyebade</title>
    <description>The latest articles on DEV Community by Ayooluwa Oyebade (@saturnsurfer).</description>
    <link>https://dev.to/saturnsurfer</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4192462%2F1e43bcb3-04fb-4853-ba88-7c95c12a349d.png</url>
      <title>DEV Community: Ayooluwa Oyebade</title>
      <link>https://dev.to/saturnsurfer</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/saturnsurfer"/>
    <language>en</language>
    <item>
      <title>Alibi — Autonomous Detective Agents on FalkorDB | Graph Hacks Track 01 Demo</title>
      <dc:creator>Ayooluwa Oyebade</dc:creator>
      <pubDate>Sun, 18 Oct 2026 16:42:32 +0000</pubDate>
      <link>https://dev.to/saturnsurfer/alibi-autonomous-detective-agents-on-falkordb-graph-hacks-track-01-demo-332o</link>
      <guid>https://dev.to/saturnsurfer/alibi-autonomous-detective-agents-on-falkordb-graph-hacks-track-01-demo-332o</guid>
      <description>&lt;p&gt;Every Lie Leaves a Path: How We Built an AI Detective Game Powered by FalkorDB&lt;br&gt;&lt;br&gt;
                                                                                                                                                                                                                                            By Ayo &amp;amp; Femi (Team Subaru Boys) · Built for Graph Hacks 2026 (Track 01: Agents That Act on Connected Data)&lt;br&gt;&lt;br&gt;
  ──────                                                                                                                                                                                                                                                🖼 Image: Alibi Banner → &lt;a href="https://raw.githubusercontent.com/Ayosensei/alibi/main/public/alibi-banner.jpg" rel="noopener noreferrer"&gt;https://raw.githubusercontent.com/Ayosensei/alibi/main/public/alibi-banner.jpg&lt;/a&gt;&lt;br&gt;&lt;br&gt;
                                                                                                                                                                                                                                                        When you watch a classic murder mystery—whether it's Agatha Christie's Poirot or Benoit Blanc in Knives Out—the detective never just "asks someone what happened."&lt;br&gt;&lt;br&gt;
                                                                                                                                                                                                                                                       They pace the drawing room cross-referencing railway timetables, floor plans, keycard logs, and conflicting alibis, connecting pins with red thread on a corkboard. Every alibi is a hypothesis; every locked door is a topological constraint; every statement is a soft claim waiting to collide with physical reality.&lt;br&gt;&lt;br&gt;
                                                                                                                                                                                                                                                        When we set out to build Alibi &lt;a href="https://github.com/Ayosensei/alibi" rel="noopener noreferrer"&gt;https://github.com/Ayosensei/alibi&lt;/a&gt; for Graph Hacks Track 01 (Agents That Act on Connected Data), we asked ourselves a fundamental question:&lt;br&gt;&lt;br&gt;
                                                                                                                                                                                                                                                        │ Why do current AI detective games feel so hollow?&lt;br&gt;&lt;br&gt;
                                                                                                                                                                                                                                                        The answer was immediate: Developers keep trying to make the Large Language Model act as the database, the judge, and the spatial engine all at once.                                                                                                 &lt;/p&gt;

&lt;p&gt;LLMs are extraordinary actors, but they are terrible judges. When an LLM controls game logic, it hallucinates non-existent clues, flatters the player when they make wild guesses, and completely forgets spatial geometry (like letting a suspect&lt;br&gt;&lt;br&gt;
walk through three locked doors in two minutes).                                                                                                                                                                                                      &lt;/p&gt;

&lt;p&gt;To build a detective game with real deductive rigor, we had to flip the architecture:                                                                                                                                                                 &lt;/p&gt;

&lt;p&gt;│ 💡 The Core Thesis of Alibi:&lt;br&gt;&lt;br&gt;
│ The LLM is just the voice. FalkorDB is the brain.                                                                                                                                                                                                   &lt;/p&gt;

&lt;p&gt;In this post, we’ll break down how we built Alibi, how we solved the "hallucinating AI" problem with an automated graph firewall, and how FalkorDB's connected data structures power our autonomous AI Inspector agent.&lt;br&gt;&lt;br&gt;
──────                                                                                                                                                                                                                                                &lt;/p&gt;

&lt;h2&gt;
  
  
  1. The Architecture: The Information Barrier
&lt;/h2&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;                                                                                                                                                                                                                                                    In a murder mystery, the player must never see the ground truth prematurely, and neither can the AI copilot. If the ground truth is stuffed into the AI’s system prompt or queried from a shared table, the model will inevitably leak spoilers through subtle phrasing or bias.                                                                                                                                                                                                                      
                                                                                                                                                                                                                                                    We solved this with Graph-Level Multi-Tenancy:                                                                                                                                                                                                        

                       ┌───────────────────────────────────────────────┐                                                                                                                                                                            
                       │          HIDDEN GROUND TRUTH GRAPH            │                                                                                                                                                                            
                       │             (truth:{caseId})                  │                                                                                                                                                                            
                       │  • Real culprit     • Murder weapon           │                                                                                                                                                                            
                       │  • Actual presence  • Hidden exhibits         │                                                                                                                                                                            
                       └───────────────────────┬───────────────────────┘                                                                                                                                                                            
                                               │                                                                                                                                                                                                    
                           GRAPH.COPY (Initial Template at Tick 0)                                                                                                                                                                                  
                                               │                                                                                                                                                                                                    
                                               ▼                                                                                                                                                                                                    
┌───────────────────────┐              ┌───────────────────────────────┐                                                                                                                                                                            
│       AI SUSPECTS     │              │     PLAYER'S DEDUCTION GRAPH  │                                                                                                                                                                            
│ (Bound by LLM Firewall│              │    (play:{playerId}:{caseId}) │                                                                                                                                                                            
│   to authored claims) │─────────────►│  • Discovered statements      │                                                                                                                                                                            
└───────────────────────┘  Creates     │  • Found keycard logs/anchors │                                                                                                                                                                            
                           (:CLAIMED)  │  • Physical room topology     │                                                                                                                                                                            
                                       └───────────────▲───────────────┘                                                                                                                                                                            
                                                       │                                                                                                                                                                                            
                                            Autonomous Cypher Traversal                                                                                                                                                                             
                                            (Q60, Q61, Q62, Q70)                                                                                                                                                                                    
                                                       │                                                                                                                                                                                            
                                       ┌───────────────┴───────────────┐                                                                                                                                                                            
                                       │      AI INSPECTOR AGENT       │                                                                                                                                                                            
                                       │  (Writes Flags &amp;amp; Hypotheses)  │                                                                                                                                                                            
                                       └───────────────────────────────┘                                                                                                                                                                            
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;ol&gt;
&lt;li&gt;The Truth Graph (truth:{caseId}): Holds the canonical reality of the crime. Only search actions and the final verdict evaluator can touch this graph.
&lt;/li&gt;
&lt;li&gt;The Player Graph (play:{playerId}:{caseId}): Starts completely blank of claims. When a case begins, FalkorDB clones the public scene template using GRAPH.COPY.
&lt;/li&gt;
&lt;li&gt;Discrete Tenants, Zero Leaks: The player's deduction graph only contains nodes the player has personally uncovered. Zero spoilers can ever leak because the data literally does not exist in the player's graph.
──────
## 2. The LLM Firewall: Actors, Not Deciders
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;In Alibi, players interrogate suspects in natural language. But unlike unstructured chat games, our suspects cannot invent facts.                                                                                                                     &lt;/p&gt;

&lt;p&gt;When you ask Dee, "Where were you at 8:20?", here is what happens:                                                                                                                                                                                    &lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[Player Question]                                                                                                                                                                                                                                   
       │                                                                                                                                                                                                                                            
       ▼                                                                                                                                                                                                                                            
[FalkorDB Q40] ──► Selects eligible authored claims for suspect                                                                                                                                                                                     
       │                                                                                                                                                                                                                                            
       ▼                                                                                                                                                                                                                                            
[Gemini Flash] ──► Voices the persona in natural dialogue:                                                                                                                                                                                          
       │           { reply: "I was running lines in the green room...", claimIds: ["c1_dee_loc5"] }                                                                                                                                                 
       │                                                                                                                                                                                                                                            
       ▼                                                                                                                                                                                                                                            
[LLM Firewall] ──► Validates returned claimIds match graph preconditions                                                                                                                                                                            
       │                                                                                                                                                                                                                                            
       ▼                                                                                                                                                                                                                                            
[FalkorDB Write] ─► CREATE (p:Person {id: 'dee'})-[:CLAIMED {at: 5}]-&amp;gt;(r:Room {id: 'green_room'})                                                                                                                                                   
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;If the LLM tries to invent an alibi not authored in the mystery, the firewall rejects it and falls back to authored dialogue. The LLM handles the dramatic voice; FalkorDB records the structural assertion.&lt;br&gt;&lt;br&gt;
──────                                                                                                                                                                                                                                               &lt;/p&gt;

&lt;h2&gt;
  
  
  3. How Connected Data Solves Detective Reasoning
&lt;/h2&gt;

&lt;p&gt;Once statements and scene evidence enter FalkorDB, our reasoning tools execute deterministic OpenCypher queries to expose lies.                                                                                                                       &lt;/p&gt;

&lt;h3&gt;
  
  
  A. Instant Contradiction Detection (Query Q60)
&lt;/h3&gt;

&lt;p&gt;In relational SQL, cross-referencing statements against physical evidence requires complex self-joins over dynamic time windows. In FalkorDB, it is a direct graph pattern match:                                                                     &lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;MATCH (s:Statement)-[:AT_TIME]-&amp;gt;(t:Slot), (a:Anchor)-[:AT_TIME]-&amp;gt;(t)                                                                                                                                                                                
WHERE s.subject = a.subject AND s.room &amp;lt;&amp;gt; a.room                                                                                                                                                                                                    
RETURN s.by AS suspect, s.room AS claimed_room, a.room AS actual_room, t.slot AS time_slot                                                                                                                                                          
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;When Dee claims she was in the Green Room at 8:20, but the electronic keycard reader logs her entering the Prop Store at 8:20, FalkorDB identifies the conflict in sub-2ms execution time.                                                            &lt;/p&gt;

&lt;p&gt;In the UI, our Pocket Graph renders this immediately as a glowing red conflict ray connecting Dee's claim to the physical anchor.                                                                                                                     &lt;/p&gt;

&lt;h3&gt;
  
  
  B. Unmasking Rehearsed Alibi Pacts (Query Q61)
&lt;/h3&gt;

&lt;p&gt;In Case 1 (A Quiet Pact), three suspects—Dee, Kofi, and Hana—conspire to cover for each other. When interrogated individually about their whereabouts at 8:20, they all claim to have been running lines in the Green Room, and they all recite the&lt;br&gt;&lt;br&gt;
  exact same curious detail: "the interval bell rang twice."                                                                                                                                                                                            &lt;/p&gt;

&lt;p&gt;FalkorDB detects this collusion cluster instantly:                                                                                                                                                                                                    &lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;MATCH (s:Statement {kind: 'location'})                                                                                                                                                                                                              
WHERE s.detail &amp;lt;&amp;gt; ''                                                                                                                                                                                                                                
WITH s.slot AS slot, s.room AS room, s.detail AS detail, collect(DISTINCT s.by) AS suspects                                                                                                                                                         
WHERE size(suspects) &amp;gt;= 2                                                                                                                                                                                                                           
RETURN slot, room, detail, suspects                                                                                                                                                                                                                 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;The graph identifies that multiple independent suspects are sharing an identical authored detail, exposing their cover story before any physical evidence is even found!                                                                              &lt;/p&gt;

&lt;h3&gt;
  
  
  C. Physical Room Walking Feasibility &amp;amp; Shortest Paths
&lt;/h3&gt;

&lt;p&gt;Can a suspect be in the Box Office at 8:00, commit a murder in the Prop Store at 8:20, and return to the Foyer by 8:40?                                                                                                                               &lt;/p&gt;

&lt;p&gt;In Alibi, estate floor plans are modeled as a connected room graph: (:Room)-[:CONNECTED_TO]-&amp;gt;(:Room). Moving between adjacent rooms takes 1 time slot. FalkorDB computes the physical feasibility:                                                    &lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Feasible ⟺ shortestPath⎛Room , Room ⎞ ≤ │Slot  - Slot │
                       ⎝    A      B⎠   │    B       A│
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;If locked doors or keycard restrictions block the corridor, FalkorDB's shortestPath() traversal mathematically clears innocent suspects and exposes impossible travel claims.&lt;br&gt;
──────&lt;/p&gt;

&lt;h2&gt;
  
  
  4. The Autonomous AI Inspector Copilot
&lt;/h2&gt;

&lt;p&gt;Alibi doesn't leave the player alone with raw Cypher. We built an AI Inspector powered by the Model Context Protocol (MCP) and Vercel AI SDK.&lt;/p&gt;

&lt;p&gt;The Inspector is an autonomous agent that acts directly on connected data:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;It queries FalkorDB using high-level graph tools: getContradictions(), getEliminations(), getAlibiChain(), and getMotivePaths().&lt;/li&gt;
&lt;li&gt;It analyzes the paths returned by FalkorDB.&lt;/li&gt;
&lt;li&gt;It autonomously creates (:Flag) and (:Hypothesis) nodes directly inside the player’s FalkorDB graph, giving each hypothesis a confidence score based on physical anchors.&lt;/li&gt;
&lt;li&gt;It explains its deduction step-by-step to the player, pointing directly to the graph path.
──────
## 5. What We Learned Building on FalkorDB&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Building a full-stack, real-time graph game within the hackathon window was an exhilarating challenge. Here are our biggest takeaways:&lt;/p&gt;

&lt;h3&gt;
  
  
  ⚡ 1. The Speed of GraphBLAS is Real
&lt;/h3&gt;

&lt;p&gt;FalkorDB’s C-based GraphBLAS engine is shockingly fast. In Alibi, every single suspect interaction triggers:&lt;/p&gt;

&lt;p&gt;• Live graph updates&lt;br&gt;
  • Contradiction scans across 8 time slots&lt;br&gt;
  • Rehearsed alibi checks&lt;br&gt;
  • Clearance checks across room topologies&lt;/p&gt;

&lt;p&gt;Even with all these queries running in sequence, our backend roundtrip latency remained under 15ms. That speed makes the UI feel completely instantaneous.&lt;/p&gt;

&lt;h3&gt;
  
  
  🛡 2. GRAPH.COPY is a Game Changer for Multi-Tenancy
&lt;/h3&gt;

&lt;p&gt;Creating isolated sandbox environments usually involves either complex schema migrations or risky row-level security filters (WHERE user_id = ...). FalkorDB's ability to clone an entire graph template with GRAPH.COPY in milliseconds gave us&lt;br&gt;&lt;br&gt;
  bulletproof information security with zero boilerplate.&lt;/p&gt;

&lt;h3&gt;
  
  
  🧩 3. Graphs are the Missing Half of Agentic AI
&lt;/h3&gt;

&lt;p&gt;LLMs have conquered human language, but they struggle with structured state, spatial awareness, and mathematical consistency. Giving our AI agent access to a live FalkorDB knowledge graph gave it something prompt engineering never could: an&lt;br&gt;&lt;br&gt;
  objective ground truth that it could traverse, verify, and prove.&lt;br&gt;
  ──────&lt;/p&gt;

&lt;h2&gt;
  
  
  Try It Out
&lt;/h2&gt;

&lt;p&gt;• 🌐 Play Alibi: &lt;a href="https://alibi-project.vercel.app" rel="noopener noreferrer"&gt;https://alibi-project.vercel.app&lt;/a&gt;&lt;br&gt;&lt;br&gt;
  • 📦 GitHub Repository: &lt;a href="https://github.com/Ayosensei/alibi" rel="noopener noreferrer"&gt;https://github.com/Ayosensei/alibi&lt;/a&gt;&lt;br&gt;&lt;br&gt;
  • 🎥 Watch the Demo Video: YouTube Walkthrough &lt;a href="https://youtu.be/FuiIWO71Ogg" rel="noopener noreferrer"&gt;https://youtu.be/FuiIWO71Ogg&lt;/a&gt;                                                                                                                                                                           &lt;/p&gt;

&lt;p&gt;Special thanks to FalkorDB and WeMakeDevs for hosting Graph Hacks 2026. Happy investigating!&lt;/p&gt;

</description>
      <category>agents</category>
      <category>ai</category>
      <category>devchallenge</category>
    </item>
  </channel>
</rss>
