Hello everyone,
A few months ago I started trying to write an interactive fiction novel. Or at least I tried. As the story started growing, the structural side of things became harder and harder to manage.
Branches multiplied, narrative state started spreading everywhere, and I found myself constantly trying to remember where certain conditions or variations lived in the story.
After fighting with that for a while, I realised the main problem (at least for me) was that the prose and the interactive logic were completely mixed together. The text of the story, the conditions, the variables, the branching… everything lived in the same place. The more the story grew, the harder it became to keep it readable and maintainable.
That got me thinking about whether those two things could be separated.
So I started experimenting with a different approach: keeping the prose as prose, and moving the interactive logic into a separate layer that controls how the text is presented.
That experiment eventually turned into a small project called iepub.
iepub is a structured format for interactive books inspired by EPUB. The idea is to keep the narrative text clean and readable, while the branching logic, conditions and state live in a separate system that decides which parts of the story appear to the reader.
With that structure, a story can include things like:
-
traditional branching choices
-
conditional variations of scenes
-
narrative fragments that appear depending on earlier decisions
-
variations triggered by variables or reader behaviour
While working on the format, I also started building an editor called ieWriter, because editing this kind of structure directly in files quickly becomes painful.
The idea behind the editor is fairly simple: it should feel like writing in a normal text editor (something closer to Google Docs than to a programming tool), but designed specifically for interactive fiction.
So the writing interface focuses first on the prose itself, but allows you to layer interactive elements on top of it without breaking the flow of writing.
Inside the editor you can:
-
define conditions that control when parts of the text appear
-
attach variables or narrative state to sections of the story
-
configure dice rolls or probabilistic events if the story needs them
-
add narrative variants that replace or extend the base text
-
visualize the structure of the story as a graph to better understand how branches connect
The goal is to make it possible to build fairly complex narrative structures while still keeping the project understandable for the author.
The whole system runs on a small reader runtime that interprets the format so the story can actually be read as an interactive book across devices.
To test everything together I started writing a demo novel using the system, so the full workflow (writing → structuring → reading) can be explored.
If anyone is curious, the project and the demo are here:
I’d genuinely be interested in hearing thoughts from people here, especially anyone who has spent time wrestling with the structural side of IF tools.