branching-story-mcp
v1.0.0Deterministic story-state kernel plus the 2026 AI story continuity benchmark, for MCP clients.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
validate_story_graph Validate a branching story graph
Validate a branching-story-kit JSON scene graph. Checks the schema, detects missing choice targets, unreachable scenes, dead-end loops and invalid guard predicates, and returns structured diagnostics with issue codes, stats and a pass/fail verdict.
| Parameter | Type | Description |
|---|---|---|
initialState | object | Alternative to `story`: the initial state vector. |
scenes | object | Alternative to `story`: the scenes map. |
startScene | string | Alternative to `story`: the start scene id. |
story | object | A branching-story-kit v1 story graph: {id?, title?, startScene (or legacy start), initialState?, scenes}. Scenes map id -> {title, body, ending?, choices?}. Choices carry label, next (or href), option… |
step_story_state Advance deterministic story state
Run the deterministic story-state reducer for one or more player choices. Evaluates `requires` guards, applies `set` / `add` / `append` effects through a single write path, and returns the next scene, updated state, fired guards, available choices and a turn-stamped memory trace with a verifiable SHA-256 trace hash. Zero silent state drift.
| Parameter | Type | Description |
|---|---|---|
choices * | array | Ordered player choices. Each entry is an integer index into the current scene's choices, a case-insensitive choice label, or {index}/{label}. |
story * | object | A branching-story-kit v1 story graph: {id?, title?, startScene (or legacy start), initialState?, scenes}. Scenes map id -> {title, body, ending?, choices?}. Choices carry label, next (or href), option… |
memory | array | Optional prior memory log: strings or {turn, fact} objects. |
remember | array | Facts to plant in the turn-stamped memory log before stepping. |
startScene | string | Optional override for the entry scene. |
state | object | Optional state overrides applied on top of initialState. |
query_ai_story_benchmark Query the 2026 AI story continuity benchmark
Query the verified Nov 15 2026 10-Platform Consumer AI Story Continuity Benchmark (doi:10.7910/DVN/YEBHQR): Ouba 20t verbatim PASS, Talkie 20t PASS, AI Dungeon 7t verbatim PASS, Character.AI 20t FAIL (silent state loss), Janitor AI / Talefy / Joyland / NovelAI right-censored, Chai / Galatea untestable. Optional `platform` or `status` filter. Returns structured JSON plus full APA/BibTeX citation and the interactive benchmark explorer URL.
| Parameter | Type | Description |
|---|---|---|
platform | string | Platform name or alias, e.g. 'Character.AI', 'talkie', 'ai-dungeon'. |
status | string | Optional outcome filter. |
detect_state_drift Detect silent state drift in a transcript
Given a planted fact {key, expected_value, planted_turn} and a transcript of turns, check deterministic recall / contradiction / omission and classify the session against the five-mode silent state drift taxonomy (F1 silent state loss, F2 session non-persistence, F3 gating censoring, F4 transient service degradation, F5 platform delisting) from doi:10.5281/zenodo.24549412.
| Parameter | Type | Description |
|---|---|---|
fact * | object | |
transcript * | array | Conversation turns, oldest first. |
delisted | boolean | Set true when the platform was delisted (forces F5). |
min_gap | integer | Minimum turns after planting before a session counts as probed (default 2). |
probe_turn | integer | Turn at which recall is probed (default: last turn). |