This framework connects traditional narrative engines with AI chat experiences, allowing players to interact freely without losing story progression. With a deterministic backend, it balances player choices and character stats to create a unique gaming experience where players can express themselves while adhering to the narrative structure.
The LLM Game Engine is a unique framework that integrates the immersive narrative experience of traditional game engines like Renpy and Twine with the dynamic interactivity of AI chat systems such as SillyTavern and AI Dungeon. This innovative engine allows players significant freedom to express themselves through natural language while simultaneously ensuring structured story progression and character development through a deterministic backend that retains narrative integrity.
The LLM Game Engine stands out by offering a distinctive balance between player autonomy and narrative control. It allows players to communicate freely, but specific actions are required to advance the story and affect character stats. This controlled interaction guarantees that the gameplay experience remains focused and engaging, while still being responsive to player input.
| Feature | Traditional Game (Twine/Renpy) | AI Chat Game (SillyTavern) | LLM Game Engine |
|---|---|---|---|
| Authorial Control | Full control by the author | Total freedom for players | Controlled freedom |
| Outcome Determinism | Deterministic outcomes | Unlimited possibilities | Bound outcomes |
| Dialogue Dynamics | No dynamic dialogue | Infinite dynamic dialogue | Dynamic dialogue with progression locks |
| Story Construction | Hand-crafted responses | No structured storytelling | Structured crafting with AI-generated dialogue |
The design is influenced by Jacky Kaub's causal graph approach, enabling a sophisticated narrative model.
The LLM Game Engine is built around two core systems:
Causal Graph: This component consists of a directed graph where each node represents an impactful action. The node includes:
The engine allows players to articulate any input, with a classifier agent verifying the validity of the action. If an action does not match any available option, the player is informed that their action was ineffective.
Stat System: Characters in the game possess various attributes (e.g., trust, love, suspicion). Following each interaction with a non-player character (NPC), a system assesses the dialogue and adjusts stats according to strict parameters, ensuring gradual changes and clear character development. Stats trigger pivotal changes in NPC personas and unlock new pathways in the gameplay.
Players are enabled to engage in varied actions with specific outcomes:
| Player Action | Result |
|---|---|
| Match an available action | Progression of the story and changes in stats |
| No match found | Notification of no effect |
| Attempt to force outcomes | Regarded as non-matching input |
| Repeating an action | Filtered out and ignored |
| Inquire about advanced knowledge | NPC responses restricted to available context |
Stories are organized within the stories/<story-name>/ directory and consist of three JSON files:
graph.json — outlines the causal graphcharacters.json — defines NPCs and their statistics-based personasconfig.json — contains story configurations such as the existing stats and their initial valuesCurrent Stories:
trust stat. Interactions range from enigmatic riddles at low trust to straightforward guidance at higher trust levels.The LLM Game Engine represents an innovative approach to narrative-driven gaming by merging player freedom with structural storytelling, ensuring both engaging gameplay and comprehensive narrative continuity.
No comments yet.
Sign in to be the first to comment.