A presentation at World IA Day London 2025 in in London, UK by London World IA Day
Talk From Script to Schema: Mapping Stories with AI Knowledge Graphs MIKE ATHERTON — Content Design, Graph and GenAI Specialist at Brandburner Ltd London 2025
from script to schema MAPPING STORIES WITH AI KNOWLEDGE GRAPHS Mike Atherton
BBC Mythology Engine, 2010
BBC Mythology Engine, 2010
HELLO MY NAME IS MIKE #vibecoder
previously…
World IA Day London, 2016
@r4isstatic
FABULA* “The raw material of a story.” (Chronological order) SYUZHET* “How the story is organized.” (Narrative order) Vladimir Propp
//challenges ● SEMI-BESPOKE MODELING ● CONTENT IN THE WRONG SHAPE ● MASSIVE CONTENT CREATION EFFORT ● DATA MODEL BECOMES A BIG BET
generative pretrained transformers
let’s build FABULA* A connected web of story moments, from the viewpoint of everyone involved.
//approach SPLIT EPISODE INTO SCENES PASS SCENE THROUGH LLM FOR REASONED DATA EXTRACTION RESOLVE ENTITIES ACROSS ALL SCENES OUTPUT AS STRUCTURED JSON PYTHON // o3-MINI // BAML
SCHEMA DESIGN
//principles ● UNIVERSAL :slightly_smiling_face ● SUPPORT CONTINUING STORIES ● ENRICH METADATA WITH REASONED ANALYSIS ● SUPPORT NARRATIVE RECONSTRUCTION ● SUPPORT FABULA/SYUZHET DIVERGENCE ● SUPPORT ADDITIONAL OR EXPANDED ONTOLOGIES
//ontology inspiration Ontomedia dc:creatorMichael O. Jewell</dc:creator> dc:creatorK Faith Lawrence</dc:creator> dc:creatorMischa M Tuffield</dc:creator>
//ontology inspiration Drammar dc:creatorVincenzo Lombardo</dc:creator> dc:creatorRossana Damiano</dc:creator> dc:creatorAntonio Pizzo</dc:creator>
//fabula schema_v1 Episode Location Object Scene Involve ment Event Particip ation Agent Organiz ation
//fabula schema_v1 event_1_1 agent_ partici pation agent_ partici pation agent_j osh_ly man agent_n ancy_m cnally
PROCESSING PIPELINE
//pre-processing TURN DOCUMENT INTO MACHINE-READABLE CHUNKS
//convert script to json
//add story context
//ontology to response template CLASSES DEFINE NODES AND RELATIONSHIPS TO GUARANTEE* THE LLM RESPONSES FIT OUR SCHEMA PYTHON // o3-MINI // BAML
//run through scenes to grab all our data
//layered extractions EXTRACT STABLE ENTITY REGISTRY THEN PASS AS CONTEXT TO INFORM SECONDARY PASSES Scene Scene Scene Scene Scene Scene Events Events Events Locations Orgs Agents Objects Description Events Agent Participations Object Involvements
//entity resolution and linking LLMs CAN RESOLVE ENTITIES CREATIVELY (BUT UNPREDICTABLY). VALIDATION STILL NEEDED ON OUTPUT.
//now we have it all in super useful json
//recap EVERY STORY BEAT AS FULLY-MODELED CONTENT TYPES FROM EVERYONE’S PERSPECTIVE LINKED BY UNIQUE** IDENTIFIERS CHARACTER INTERACTIONS AVAILABLE AS FRIENDLY JSON MOVEMENT ACROSS LOCATIONS EMOTIONS AND PLANS OVER TIME COMPLETE INVENTORY OF CHARACTERS LOCATIONS ORGANIZATIONS OBJECTS FOR ANY STORY*
InSight feature Apple, 2024
With AI, we can ‘re-render’ content to fit a new schema.
//convert json to cypher for neo4j graph base
//all your base are belong to us
BENCHMARKING
//performance check 11.81M COMPLETION TOKENS 3500 CYPHER STATEMENTS 2 HOURS PROCESSING TIME TOTAL API COST $1.45 “Genesis of the Daleks” 6-part serial, 1975
//observability
//response quality by model agentparticipation_agent_the_doctor_event_4_1 agentparticipation_agent_doctor_event_4_1 agentparticipation_agent_the_doctor_event_4_1 current_status The Doctor stands at the temporal core, focused and agile, interfacing with the Archive’s systems. They work swiftly at the controls as the TARDIS beams stabilizing energy. Their posture is upright, their gestures deliberate and precise, indicating both command and urgency. current_status The Doctor stands firmly at the control panel, tapping commands into the consoles. Their posture is determined, leaning slightly forward as they engage with the technology, the sonic screwdriver a constant companion in their hand, radiating authority and focus as they orchestrate the stabilizing efforts. current_status The Doctor is visibly active and engaged with the Temporal Core’s systems. He injects manipulates quantum interfaces, his hands moving with precision and urgency. He is no the K’nell or the Syndicate operatives but his presence is dominant through his techn posture is one of focused intensity, bent over the controls, with sharp, purposeful m emotional_state The Doctor embodies a calm yet intense determination, showing a measured confidence through subtle nods and tight-lipped concentration. Beneath the surface, an inner anxiety about the chaotic interplay of time lurks and fuels their resolve; they are aware of the impending consequences and feel a heavy burden of responsibility, even as they maintain an outward assurance that borders on philosophical nonchalance. active_plans Stabilize the failing temporal matrices using the TARDIS interface. Counteract the destructive temporal virus by analyzing the Archive systems. Guide the team through adaptive remedial actions to contain chaos. beliefs Time is a living entity, not a mere equation to be solved. Historical knowledge must be preserved with responsibility. Every moment has the potential for irreversible change when tampered with. goals Short-term: Immediately interface with the systems to halt the crisis. Medium-term: Neutralize the virus and restore equilibrium to the Archive. Ultimate: Ensure that time remains a precious, uncontrollable force unbound by human or alien interference. openai/o3-mini $0.0111 emotional_state Outwardly, The Doctor projects an air of calm urgency, their brow slightly furrowed but eyes sharp with intensity as they assess the crumbling situation. Internally, they grapple with the weight of responsibility and an underlying fear of failure, knowing that the stakes involve not just lives but the very fabric of time itself. The conflict between their protective instinct for the Archive and the chaotic threat of entropic collapse drives their urgency. active_plans Stabilize the failing temporal matrices using the TARDIS. Coordinate with K’nell and Sarah to implement defensive strategies against the Entropy Syndicate. Ensure the safety of the Archive’s knowledge and prevent the Entropy Syndicate from exploiting it. beliefs Time is a living entity that must be respected and protected. Knowledge should be safeguarded to prevent catastrophic misuse. Every action has consequences that can ripple through time. goals Short-term: Stabilize the Archive’s systems to prevent collapse. Medium-term: Prevent the Entropy Syndicate from gaining access to destructive temporal knowledge. Ultimate: Preserve the integrity of time and history, ensuring that dangerous knowledge remains hidden. openai/gpt-4o-mini $0.0389 emotional_state On the surface, the Doctor displays a serious and urgent demeanor characteristic of h temporal stability. There’s a palpable sense of determination and a touch of wearines Beneath the surface, however, lies a deeper sense of professional pride and a further itself, a core tenet of his existence. He may also harbor a degree of frustration at timestream, though this is masked by his focused, solution-oriented approach. active_plans Immediate plan: Stabilize the temporal matrices and contain the entropic cascade. Medium-term plan: Purge the temporal virus from the Archive’s systems. Long-term plan: Ensure the integrity of the timestream and prevent future incursions beliefs Time is fundamental to the universe and must be protected. The knowledge within the Quantum Archive is invaluable and should be safeguarded. The Entropy Syndicate’s actions are physically dangerous and morally reprehensible. goals {goal_type: Short-term, goal_description: Influence the immediate stabilization of th the next minutes, during Scene 4., goal_accuracy: High accuracy in stabilizing the te containing the virus.} {goal_type: Medium-term, goal_description: Completely eradicate the temporal virus fr ongoing crisis, by the end of Scene 4., goal_accuracy: Virus eradication must be thor corruption.} {goal_type: Long-term, goal_description: Deter the Entropy Syndicate and similar futu Beyond Scene 4, for the future security of the Quantum Archive and possibly Time itse and defensive measures are necessary to safeguard against recurring attacks and poten cognitivecomputations/dolphin3.0 -r1-mistral-24b:free $0.00
//response quality by supplied context (first scene) agentparticipation_agent_jeff_garvey_event_1_1 agentparticipation_agent_jeff_garvey_event_1_1 agentparticipation_agent_jeff_garvey_event_1_1 current_status Garvey wakes up disoriented, experiences agony, then transitions to calmness and determination, arming himself. current_status Garvey is lying on the ground, wakes up confused, and after a moment of agony, becomes calmer and pulls out a gun, intending to kill. current_status Garvey is waking up with a start, sitting up and peering about him in confusion, then experiencing intense pain and finally becoming calm with a singular focus to kill. emotional_state Initially confused and in agony, transitioning to calm and determined, with hints of internal conflict. emotional_state Shifts from confusion and pain to calm determination with an underlying conflict between his original self and the Varga-controlled persona. emotional_state Garvey is confused, then agonized, and finally calm but driven by a desire to kill. active_plans Regain control and understand surroundings Act on remembered mission involving killing Fulfill the purpose of his transformed state beliefs Has a mission to carry out involving killing Needs self-defense, indicating perceived vulnerability May believe he is under external control or influence goals Escape the jungle and understand his state Identify and eliminate targets Fulfill the purpose of his transformation Agents: 7 Organizations: 2 Locations: 8 Objects: 18 Scenes: 14 Events: 38 Agent Participations: 75 Object Involvements: 29 meta-llama/llama-3.3-70b no extra context active_plans To remember and understand his situation. To act on his urge to kill driven by the Varga’s poison. To possibly protect himself or assert dominance. beliefs He must kill as per the Varga’s influence He might be under threat or in danger. The gun is his means of protection or survival tool goals Eliminate threats and understand his situation Survive on Kembel Unclear due to the Varga’s influence, but possibly to escape the planet or complete mission objectives. Agents: 7 Organizations: 2 Locations: 4 Objects: 6 Scenes: 14 Events: 41 Agent Participations: 78 Object Involvements: 20 meta-llama/llama-3.3-70b full script provided active_plans Survive on the hostile planet Kill Regain memories beliefs He must kill He is alone on the planet goals Understand his situation and survive Find a way off the planet Fulfill his obsessive desire to kill Agents: 7 Organizations: 1 Locations: 2 Objects: 5 Scenes: 14 Events: 25 Agent Participations: 45 Object Involvements: 30 meta-llama/llama-3.3-70b novelization provided
“Mission to the Unknown” Recreation by University of Central Lancashire, 2019
//response quality by supplied context (last scene) agentparticipation_agent_dalek_supreme_event_14_1 agentparticipation_agent_dalek_supreme_event_14_1 agentparticipation_agent_malpha_event_14_1 current_status The Dalek Supreme oversees the ritual, commanding respect and obedience. current_status The Dalek Supreme stands amidst the conference, overseeing the pledge of allegiance by Malpha and the other representatives. It is the central figure, embodying the power and will of the Daleks in this historic moment. current_status Malpha is pledging allegiance to the Dalek cause and announcing the plan to conquer Earth and the rest of the Solar System. emotional_state Confident and authoritative, driven by strategic thinking and dedication to the Dalek cause. active_plans Lead the Daleks to victory Ensure the pledge is binding Strategically direct the campaign against Earth and the galaxy beliefs The Daleks are destined to rule the galaxy All life forms must be exterminated or subjugated The Dalek Supreme’s leadership is indispensable goals Confirm the allegiance of all Daleks Launch a successful assault on Earth Achieve total domination of the galaxy emotional_state The Dalek Supreme is calculating and devoid of emotions in the human sense, yet it exudes an aura of superiority and anticipation. It sees the alliance as a strategic step towards the fulfillment of the Daleks’ ultimate goal: universal domination. active_plans To utilize the alliance for the strategic advancement of Dalek interests To oversee the planning and execution of the invasion of Earth and other galaxies To maintain control and ensure the loyalty of the allied systems beliefs The Daleks are the superior force in the universe Alliance with other systems is a temporary necessity for achieving universal domination The eradication of opposition is essential for the survival and dominance of the Daleks goals Secure the loyalty and commitment of the allied systems Invade and conquer key galaxies, including Earth’s Establish the Daleks as the rulers of the universe meta-llama/llama-3.3-70b no extra context meta-llama/llama-3.3-70b full script provided emotional_state Malpha appears to be confident and determined, eager to pledge allegiance to the Dalek cause and initiate the plan for conquest. active_plans Pledge allegiance to the Dalek cause Conquer Earth and the rest of the Solar System Reduce galaxies to ashes and their people to dust beliefs The Dalek cause is the key to achieving ultimate power and control Conquering Earth and the rest of the Solar System is essential to their plan Reducing galaxies to ashes and their people to dust is a necessary step in achieving their goals goals Pledge allegiance to the Dalek cause and initiate the plan for conquest Conquer Earth and the rest of the Solar System”, Achieve ultimate power and control through the reduction of galaxies to ashes and their people to dust meta-llama/llama-3.3-70b novelization provided
//oddities { { { { { “uuid”: “object_truth”, “name”: “Truth”, “description”: “A conceptual objective referenced in the legal proceedings, concerning the pursuit of factual and philosophical veracity in determining Data’s status.”, “purpose”: “Objective of the legal process.”, “significance”: “Embodies the underlying philosophical debate about Data’s nature and the effectiveness of the adversarial system in uncovering reality.”, “original_owner”: “org_judge_advocate_general_office_ sector_twenty_three”, “source_uuids”: [ “object_truth” ] }, “uuid”: “object_jaw_clench”, “name”: “Jaw Clench”, “description”: “President Bartlet’s ‘subtle jaw clench’ is a physical manifestation of his internal emotional state, specifically his suppressed anger and growing fury. It is an involuntary tell that betrays his outward diplomatic composure, revealing the tension beneath the surface.”, “purpose”: “To non-verbally express suppressed anger”, “significance”: “Reveals Bartlet’s internal state beneath diplomatic facade”, “original_owner”: “agent_josiah_bartlet”, “source_uuids”: [ “object_jaw_clench” ] }, “uuid”: “object_rain”, “name”: “Rain”, “description”: “The rain streaming down the windows of the Oval Office is more than just weather; it is a significant atmospheric detail that sets the tone of the scene. It visually represents the lingering tension and somber mood even after the immediate crisis has subsided. The ‘crushing night’ is metaphorically washed away by the rain, but the emotional and ethical residue remains, as seen in Josh’s troubled expression.”, “purpose”: “To create a somber and reflective atmosphere”, “significance”: “Symbolizes lingering tension and emotional aftermath”, “original_owner”: null, “source_uuids”: [ “object_rain” ] }, “uuid”: “object_comm_button”, “name”: “Comm Button”, “description”: “A wall-mounted communication device within the command complex that, when activated, alerts security forces and triggers alarms, thereby escalating conflict during the escape attempt.”, “purpose”: “Communication and alert system”, “significance”: “Acts as a trigger for alarms and organized resistance”, “original_owner”: “org_kaled_military”, “source_uuids”: [ “object_comm_button” ] }, “uuid”: “object_mindcoin_project”, “name”: “MindCoin Project”, “description”: “The hacked and failed cryptocurrency project ‘MindCoin’ associated with Super Hans, displayed on his laptop as a reminder of his previous venture.”, “purpose”: “Failed cryptocurrency project”, “significance”: “Represents entrepreneurial ineptitude and delusional optimism”, “original_owner”: “agent_super_hans”, “source_uuids”: [ “object_mindcoin_project” ] },
LESSONS LEARNED
//challenges ● VALID STRUCTURED OUTPUT IS HARD! ❤ BAML ● CREATIVITY vs PROMPT ADHERENCE ● CONSISTENCY AND RESOLUTION ● CONTEXT AND COHERENCE ● PRECISION vs RECALL ● SCALING UNIQUENESS
//break it all down and watch every step FIGURE OUT SUCCESS SEPARATE CONCERNS SPLIT INTO FOCUSED TASKS PICK THE RIGHT MODELS FOR EACH JOB GET TO KNOW YOUR LLM QUIRKS OBSERVE EVERY STEP OF THE PIPELINE HAVE GREAT TEST CONTENT RUN IT AGAIN AND AGAIN AND AGAIN. AND GET COMFORTABLE WITH TRADEOFFS AND UNPREDICTABILITY.
what’s next
#neurosymbolic #graphrag
//questions as queries
//text to cypher
//more fun stuff ● timeline and multiverse management ● additional layers of extracted data ● more ways to consume graph data ● agentic context fetching ● movies, novels, comics ● what else?
GITHUB.COM/BRANDBURNER/ FABULA brandburner.bsky.social
Ever wonder what makes your favourite TV shows tick? Drawing inspiration from BBC’s 2010 Mythology Engine, I’ll show you how I used AI to explode TV drama transcripts into beautiful, explorable knowledge graphs. We’ll map out everything from political intrigue in The West Wing to timey-wimey shenanigans in Doctor Who, breaking down the characters, places, and events that make these stories come alive.
Roll up your sleeves for a hands-on journey through schema design, Python coding, and the latest in AI tech (LLMs, Neo4j, and GraphRAG). You’ll learn how to set up your own story-mapping playground using free tools, and see why knowledge graphs are becoming the secret sauce in AI-powered search and retrieval.
Whether you’re a data nerd who loves untangling narrative complexity, someone looking to level up their knowledge graph skills, or just want to geek out about Doctor Who, come see how AI can help us discover new patterns in the stories we love.
Biography Mike Atherton builds smart content systems that push technical boundaries. A UX leader who shaped digital experiences at BBC and Facebook, he now creates AI-powered solutions for information discovery and delivery. His projects range from automated news podcasts to knowledge graph construction, always focused on practical applications of emerging tech.
Author of Designing Connected Content and veteran conference speaker, Mike brings deep expertise in information architecture and a track record of transforming complex narratives into accessible, coonnected experiences.
The following resources were mentioned during the presentation or are useful additional information.