This is an alternative site for discovering Elm packages. You may be looking for the official Elm package site instead.
We were not able to find the expected elm-package.json file at this tag.
Tag 6.0.1
Committed At 2021-02-14 17:58:53 UTC



    Elm Narrative Engine

    A tool for building interactive story games.


    worldModel =
            [ entity "PLAYER.fear=1"
            , entity "TORCH.item.illumination=7.current_location=PLAYER"
            , entity "CAVE.location.dark"
            -- etc...
    rules =
            [ rule "entering dark places"
                ON: *.location.dark
                "It's too dark to go in there!"
            , rule "entering the cave with a light source"
                ON: CAVE
                IF: *.item.illumination>5.current_location=PLAYER
                DO: PLAYER.current_location=CAVE.fear+2
                "You enter the cave, {PLAYER.fear>4? your heart pounding | bravely}..."
            -- etc...

    Try it out in a live sandbox at

    You can also clone to play with it locally.


    • "Schemaless" world model - define your world any way you like
    • "Salience-based" and "quality-based" rule matching system - craft immersive and reactive stories
    • "View agnostic" - build your views however you want

    Additional features:

    • Import all data from external sources (like a spreadsheet)
    • Simple and intuitive authoring syntax
    • Advanced querying system
    • Embeddable in a larger code base
    • Designed with the Entity-Component-System pattern


    The engine has two main parts: the world model, and the rules. You can use the authoring syntax shown above to define both of these.

    From there, you can query the world model as needed to build your view, and you can find the best matching rule when a player interacts with an entity given the current state of the world, to update the world and show side effects like story text.

    See the example link above for more context.

    More information

    Read the dev blog

    Play sample stories made with the Elm Narrative Engine