NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Infinite Worlds from One Example: What Local Generators Must Share

Amin Najafgholizadeh, Mohsen Afsharchi

TL;DR

Local generators like neural cellular automata (NCAs) often fail to produce valid infinite worlds from examples with long-range constraints, such as the aligned rows of a brick wall. This paper proves that such generators must share specific types of randomness (like row types or phases) to remain valid and faithful to the example. The authors provide an automated "certificate" search to identify these requirements and a method to supply them, enabling local generators to produce perfectly valid, infinite, random-access worlds.

What Problem Does This Paper Address?

Procedural content generation often relies on Wave Function Collapse (WFC), which can create complex worlds from a single small example. However, WFC is a global search process; it’s difficult to use for "infinite" worlds where you need random access—the ability to compute any region on demand without generating everything in between.

Local generators (like NCAs or convolutional diffusion models) are perfect for random access because each cell is a function of its local neighborhood. The problem is that local constraints often imply global structure. Consider a brick wall: for the wall to be valid, every row must stay aligned with the mortar lines across the entire infinite plane. If a local generator relies only on independent noise at each cell, distant parts of a row will eventually "disagree" on their vertical position, leading to broken mortar lines and "forbidden windows" (invalid local patches).

Figure 1. Worlds from one example. Each column shows a public example and the central 64 × 64 cells of a 256 × 256 canvas from shifted replay (the example tiled from a random offset), the block reference (a block solver on blocks placed at random), the rule on independent coins and the method (the learned rule given the input of Section 4), both mended, with the share of forbidden windows on the whole canvas. On the first five examples validity carries a quantity over any distance, an invariant along rows or a phase. Independent coins leave forbidden windows on all five; given the quantity, the method leaves none, and on Fabric and RedMaze its world is the tiled example. Cave carries no such quantity, and both rules are valid on it.

Methods

The authors tackle this with a mix of information theory and algorithmic search:

  1. Theoretical Lower Bounds: They prove that for any example where validity carries a quantity (like a row's phase) along an axis, a local generator using only independent noise will inevitably produce errors. The density of these errors is at least $1/r$, where $r$ is the generator's receptive field radius.
  2. Certificate Search: They developed an algorithm that analyzes the example's "overlap graph" of small patches. It looks for transported quantities—invariants or phases that must be preserved over distances. If it finds one, the example is "certified" as needing shared input.
  3. Shared Input Generation: Once a requirement is identified (e.g., "this world needs consistent row types"), they use a row-type sampler. This sampler uses the seed to generate a valid sequence of row types for the entire world. These types are fed to the local generator as extra input channels.
  4. Mending: Even with shared input, local generators might make small mistakes. The authors use a "mender"—a local, parallelizable version of WFC—to fix these defects while preserving the random-access property.

Datasets

The study evaluated its methods on:

  • 52 public examples from the original WaveFunctionCollapse repository.
  • 27 examples from other open-source implementations to test generalization.
  • 5 "held-out" examples created specifically to test the system's robustness against axes-swapping and new patterns.

Key Insights and Ideas

  • The "Brick Wall" Limit: The paper formalizes why "local" isn't enough. If a rule says "mortar must follow mortar," and you decide what is mortar based on independent coins, you will eventually fail.
  • Shared Randomness is Mandatory: To create valid worlds that vary (i.e., aren't just the same tiled image), a generator must share randomness along the direction of the constraint.
  • Automatic Discovery: You don't need to tell the system that a brick wall has rows. By searching the overlap graph of $3 \times 3$ or $4 \times 4$ patches, the system can "certify" that a row-invariant exists and automatically configure the necessary input channels.
Figure 2. The row type on Wall, a row’s place relative to the horizontal mortar lines, which validity keeps constant along every row. (a) The example and the row type of each of its rows. (b) The rule on independent coins after repair and mending, each cell tinted by the row type of the window centered on it: the type changes along rows, and the forbidden windows sit where it changes. (c) The method, given row types drawn from the seed, at the same coin seed: every row keeps its type, and no window is forbidden. (d) A mending instance with no completion (Appendix S4.1): of the cells freed around a forbidden window (hatched), two frozen patches on one row carry row types that validity cannot join, a witness (Appendix B.11).

Key Results

  • Failure of Independent Noise: On "resistant" examples (those with strong global structure), generators using independent noise stayed far from valid, even after repair.
  • Success with Shared Input: When given the certified shared input, NCAs and diffusion models became valid on most resistant examples. "Valid" here means having at most one forbidden window in a thousand after mending.
  • Dataset Performance: The complete method (NCA + shared input + mender) was valid on 45 of the 52 public examples.
  • Random Access: The entire pipeline, including mending, has a finite "reach." This means you can compute a $256 \times 256$ chunk of an infinite world knowing that it will perfectly match its neighbors, no matter what order they are generated in.

Limitations and Future Work

  • One-Sided Search: The certificate search might miss complex quantities that only appear in very large patches or non-linear directions.
  • Specific Quantities: The current implementation primarily handles row/column invariants and phases. It doesn't yet have a general input for diagonal invariants or complex 2D lattices (like the "SmileCity" example).
  • Mender Dependency: Much of the final validity comes from the mending step. Future work could explore architectures that are "valid by construction" without needing a post-processing fix.
  • Higher Dimensions: The current work is focused on 2D grids; extending these proofs and samplers to 3D voxel worlds is a logical next step.

Summary updated

BibTeX
@misc{najafgholizadeh2026infinite,
  author = {Amin Najafgholizadeh and Mohsen Afsharchi},
  title = {{Infinite Worlds from One Example: What Local Generators Must Share}},
  year = {2026},
  eprint = {2611.01048},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.01048},
}
Figure