Forkable Worlds¶
engine.fork() creates a divergent Chronicle branch with a new actor identity. The fork starts from the current state and can be used to explore an alternative line of play without writing to the parent. The child Engine uses the same TypeScript dispatch path.
engine.mergeFrom(fork) merges the forked document back through Automerge conflict resolution. Merge is a state operation, not a textual replay of every action. Applications should still define how game rules interpret concurrent or incompatible outcomes before exposing branch merges to users.
Forking is distinct from persistence: a saved document resumes a state, while a fork intentionally creates a new causal branch. It is also distinct from compaction, which discards history while keeping current state.