跳到正文
Hidden Door · AI 叙事与游戏工程· 一手来源·· 22 天前精选AI 评分64

我们的智能体故事框架内部

Inside our agentic story harness

推荐理由

原文展示其用工具调用模型、世界上下文与手写叙事手册支撑动态剧情,读者可理解智能体叙事架构如何影响互动故事体验。

正文 · 原文

Every Hidden Door experience today runs on our narrative world model, which represents the state and narrative trajectories of all of the people, places, and things in the world. This week we updated our core turn-by-turn engine, and you can feel the difference: the story reacts more sharply to what you do, remembers what happened chapters ago, and brings it back when it matters.

Great interactive storytelling means your choices matter: they change where the story goes. Games have always had to approximate this. A writer can only author so many branches, so sooner or later every path folds back into the same few outcomes.

We think instead about narrative setups, tropes, arcs and resolutions, and then the system that can draw out and build on your creativity to make a really fun story experience that’s responsive to your character’s choices but also keeps you immersed in the world and the drama that you don’t control.

We’re inspired by what a great tabletop Dungeon Master does, and think of that role as two distinct jobs. The first is telling the story in the moment: describing the scene, voicing the characters, reacting to what the players just did.

The second is preparation. A good DM plans just enough ahead that, whatever the players do, there's great material to work with: a secret waiting to come out, a rival who holds a grudge, a thread from three sessions ago ready to pay off.

Most AI storytelling only does the first job. Our story harness is built to do both.

The agentic story harness

At the center is a strong, tool-using model acting as your DM. Instead of improvising everything from one giant prompt, it reaches for tools when it needs them:

  • World context: the people, places, and rules of the world you're playing in
  • History: what's happened so far, including facts and hooks from earlier chapters
  • Quality: a check on how well the current scene is actually working as a story
  • Narrative playbooks: hand-written directions to the system for how to tell a chunk of story well – things like revealing a secret, a slow burn seduction, or a really satisfying brawl.

Each turn, the DM:

  1. Pulls the context it needs from the world model
  2. Judges how well the current scene’s narrative is working, and adjusts
  3. Follows the relevant playbook
  4. Offers a menu of possibility for the next moment of story, while updating the longer-term planning and game state
  5. Receives the player’s choices and intentions for their character, and decides what actually should happen next

Because it's always planning a little ahead, the GM can hold onto a detail from an earlier chapter and bring it back at exactly the right moment. We call this Chekov’s Armory – every open thread is tracked and used when it can best pay off.

Counterintuitively, this system has much less enforced structure than our previous ones, and more small, clear tools. It means the harness ends up being much more adaptable to the complexity of the narrative and the player’s choices.

Finally, the hand-written playbooks are key, otherwise you end up with the classic problem of LLM stories – they are all a bit sames-y. This is where our amazing narrative designers can enforce their own approaches to narrative in the system.

If this architecture sounds familiar, it should. Coding harnesses like Claude Code and Codex give a model tools for planning, writing, and reviewing code. Ours gives it tools for context, quality, planning, and human-written storytelling. Same architecture, extremely different goal: great immersive stories.

What's underneath

Our story engine includes the harness and other technology we’ve built:

  • Fast and slow architecture: generative games need to both get results to players in seconds, while solving hard problems
  • Fractal memory: a system for storing narrative context by moment and long-term trajectory
  • Combinatorial story tropes: a lot of the fun of the system is playing into our expectations for a trope, but then subverting it, while combining with other tropes

We'll dig into each of these in the coming weeks. In the meantime, the best way to see the difference is to play.

来源:Hidden Door · AI 叙事与游戏工程 · hiddendoor.co