Skip to content

adr: llm-proposes-engine-rolls

Status: accepted ยท Context: applies to every LLM-native prototype; first exercised by hunker.

Decision

The engine owns authoritative state and rolls all dice. The LLM never mutates state and never rolls its own randomness. Instead the LLM returns a proposal the engine adjudicates:

player_text + state_json  ->  LLM  ->  { narration, proposed_deltas, difficulty }

The engine then: validates each delta against rules + resources, rolls where a difficulty applies, applies only what's legal, and re-renders. Illegal proposals are bounced with narration ("you grab for a torch โ€” there's nothing there").

The Director follows the same shape: { weather, environment_deltas, framing_narration, threat_plan }, all applied by the engine.

Why

  • Kills "yes-and to everything." The vision's core failure mode is an LLM that grants anything. Hard integers + engine-owned dice make the LLM set stakes and say no, rather than fiat-granting success.
  • Coherence. The LLM can't hallucinate items you don't have or walk you through walls โ€” state is ground truth it only proposes against.
  • Reusability. This contract is the spine of a text world / MUD: the Director is a dungeon master, the adjudicator is "I try to X." Proving it on one screen de-risks the graduation target.

Consequences

  • Every game defines its legal-delta validation and difficulty resolution in the engine, not the prompt.
  • Prompts must be written to propose and set difficulty, never to assert final outcomes or resources.