Skip to content

IF Craft Corpus

A curated knowledge base for writing interactive fiction.

The IF Craft Corpus is a collection of 59 craft documents covering everything from narrative structure and dialogue to genre conventions and game mechanics. Whether you're writing a text adventure, visual novel, or choice-based narrative, this corpus provides practical guidance for the craft of interactive storytelling.


Browse the Corpus

Explore the corpus by topic cluster:

View all 59 documents by cluster :material-arrow-right:


Search the Corpus

Use with Claude Code or other AI tools

# Add the MCP server to Claude Code
claude mcp add ifcraft -- uvx ifcraftcorpus-mcp

Then ask:

  • "Search the IF craft corpus for dialogue techniques"
  • "Find guidance on branching narrative structure"
  • "Look up horror atmosphere building"

Need server-side diagnostics? Set LOG_LEVEL=DEBUG or VERBOSE=1 before starting ifcraftcorpus-mcp (or the Docker image) to mirror structured logs to stderr.

Use with Python

pip install ifcraftcorpus
from ifcraftcorpus import Corpus

corpus = Corpus()
for r in corpus.search("dialogue subtext"):
    print(f"{r.source}: {r.content[:100]}...")

Get started with the search tool :material-arrow-right:


Topic Clusters

Cluster Docs Description
narrative-structure 19 Story arcs, pacing, branching, endings
craft-foundations 10 Quality standards, testing, workflow
prose-and-language 8 Dialogue, voice, exposition
genre-conventions 7 Horror, mystery, romance, sci-fi
world-and-setting 5 Worldbuilding, canon, settings, naming
audience-and-access 3 Accessibility, localization, targeting
emotional-design 2 Tension, emotional beats
agent-design 3 AI writing assistance
game-design 1 Mechanics and player agency
scope-and-planning 1 Project scoping

License

  • Corpus Content: CC-BY-4.0 - free to use and adapt with attribution
  • Code: MIT License

View on GitHub :material-github: