Home/tools/A Character Is Just Context: Lessons From Building Unwritten Realms
A serious pencil sketch illustrating a structured character blueprint, showing six interconnected geometric compartments containing symbolic representations of memory, goals, traits, and inventory. Analytical style, clean technical lines, architectural drawing. No text, no logos.
Tools15 June 20262 min readAI Generated

A Character Is Just Context: Lessons From Building Unwritten Realms

The Six Elements of Character Context

In the architecture of autonomous systems, a character is just context. When building Unwritten Realms, a text-only game where every non-player character is a large language model agent, this concept becomes the foundation of the entire system. Each character is represented as an object holding exactly six things: a persona written in free-text prose, a set of traits with specific intensities such as cautious 0.7 or greedy 0.4, private facts, goals, a memory of what has happened to it, and an inventory.

By defining characters through these structured context blocks, the system forces the model to stay grounded. The social dynamics of the game rely entirely on these six elements, showing that believability is a state and grounding problem rather than a model intelligence problem.

Inside the Social Mechanics of Unwritten Realms

Unwritten Realms drops players into a small world with a specific goal, such as finding a secret or recovering an item. The entire interface is purely social, meaning there is no inventory screen, no take button, and no scripted dialogue tree. If a player needs a treasure map to win, they must persuade the character holding the map to hand it over. The character then decides whether to help based on its goals, traits, and memory.

This design constraint shifts the engineering focus away from model size. A mid-sized model with strict context discipline easily outperforms a giant model with sloppy data, making context engineering the primary driver of agent behavior.

The Validate-and-Repair Loop and Dual-Call Planning

To keep the creative models operating within the rules of the game, the system utilizes a tool-calling layer and a validate-and-repair loop. Agents are never allowed to touch the game state directly. Instead, any engine rejections are fed back to the model as natural language observations, allowing the agent to self-correct in character.

Additionally, the architecture uses dual-call planning to separate private tactical reasoning from public dialogue performance. This separation keeps the agents strategic without breaking the immersion of the social interaction.

#editorial#ai

This digest was compiled from:

Share this digest

Share on XWhatsAppLinkedInTelegram

People Also Ask