YAML Story Format Guide
NarrativeFork stories can be written in YAML format for maximum control over branching narratives. Upload your YAML file to create a complete interactive story.
Basic Structure
title: "My Story Title"
description: "A brief description"
genre: Fantasy
maturity_rating: "PG — Mild Themes"
rule_system: "Simple Choices"
start_node: start
nodes:
- node_id: start
content: |
You stand at a crossroads...
choices:
- text: "Go left"
next_node: left_path
- text: "Go right"
next_node: right_path
- node_id: left_path
content: |
The left path leads to a forest.
is_end_node: trueConditions & Variables
Use condition and set expressions to create dynamic stories with tracked variables.
choices:
- text: "Pick up the sword"
next_node: armed
set: "has_sword = true"
- text: "Fight the dragon"
next_node: dragon_fight
condition: "has_sword == true"Dice Rolls
Use roll(dN) in set expressions for random outcomes.
set: "attack = roll(d20)"
Input Prompts
Ask the player for text or number input.
- node_id: name_entry content: "What is your name, adventurer?" input_prompt: "Enter your name:" input_variable: player_name input_type: text