## Concept explanation A **world model** is an internal, structured map of an environment: it keeps track of **what objects exist** and **where each one is**. Instead of storing only a picture-like view, a world model represents the room in a form that can be reasoned about, such as `Player at (1, 4)` or `Key at (4, 1)`. That structure helps an agent remember the layout, predict what matters next, and plan actions like getting the key before going to the door. ## What you see You’re looking at a small grid room with four objects: the player, key, door, and goal. When the symbolic model is visible, the side panel lists the same objects with their grid locations, and curved highlight lines connect each room object to its matching entry. That pairing shows that the model is not a second picture of the room—it is a compact description of the same environment. ## Try it yourself - **Click `Hide model`** to look at the room by itself and notice that you can still see the environment, but not the structured summary. - **Click `Show model`** to bring back the symbolic panel and compare each object in the room with its matching location entry. - **Trace one connector at a time** from the player, key, door, or goal to see how a visible object becomes a symbolic statement about the world. - **Compare the room and the list** and notice that the side panel answers two questions clearly: **what exists** and **where it is**. - **Press `Reset view`** to restore the room-plus-model layout if you want to restart the comparison. ## Concept explanation A **world model** is an internal representation an **agent** builds from what it observes. Instead of storing raw pixels forever, the agent identifies meaningful **objects** such as a wall, coin, key, door, or enemy, and records their **locations**. That conversion from observation to named entities is powerful because it turns messy visual input into a structured state the agent can reason about, plan over, and update as the scene changes. ## What you see On the left, you see a small top-down grid that acts like the agent’s raw observation of a scene. On the right, you see empty slots for the objects the agent can detect. When you classify an item in the scene, the matching slot fills with the object’s name and grid coordinate, showing how the observation is being transformed into a compact world model. ## Try it yourself - **Click an item in the grid** to classify it and watch its matching world-model slot fill in. - **Switch the detection mode** to `Hover to classify` and move your pointer across the scene to simulate rapid automatic recognition. - **Toggle the positions checkbox** to compare a model that stores just object identity versus one that stores identity plus location. - **Adjust the highlight pulse** to make detected entities stand out more clearly as they enter the model. - **Press `Reset model`** and rebuild the scene description from scratch, noticing that the world model starts empty until observations are interpreted. ## Concept explanation A **world model** is an internal record of what the environment is like right now, not just a map of where things are. In a changing environment, the model must update as events happen: when you move, the player position changes; when you collect the **key**, `hasKey` switches to `true`; and when you reach the door with the key, `doorOpen` becomes `true`. This shows that useful models track **dynamic state** over time, not only the static layout of walls, objects, and goals. ## What you see You can compare two views of the same world at once. On the left is the grid world with the player, the key, the door, and the scripted path. On the right is a compact state table that records the current model variables, plus a short change log. Each time the player advances one step, both the scene and the table update together so you can see how the visible world and the model stay synchronized. ## Try it yourself - **Press the `Step` button** a few times and watch `player.x` and `player.y` change as the player moves. - **Stop on the key tile** and notice that `hasKey` flips from `false` to `true` exactly when the key is collected. - **Keep stepping until the player reaches the door** and see `doorOpen` change from `false` to `true` when the door opens. - **Compare the grid and the table after every step** to see that the model reflects new events, not just the original map. - **Turn on `Auto play`** to let the scripted sequence run automatically and observe the full state-update story. - **Press `Reset`** and replay the sequence to check that the same environment changes produce the same model updates. ## Concept explanation A **world model** is an internal simulation that lets you predict what will happen *before* you act. Instead of trying an action blindly, the model checks the current **state** of the world—where you are, whether a wall blocks movement, whether you hold a key, and whether a door is locked—and forecasts the likely outcome. That makes decision-making smarter, because you can compare options, avoid failed moves, and choose actions that change the world in useful ways. ## What you see You are looking at a small grid world with a player, a nearby wall, a key, and a locked door. The solid player shows the current state, while the translucent ghost marks the model’s predicted next position or state change for the selected action. The panel underneath reports whether the action should succeed, fail, or update inventory, and when you confirm the action, the actual world changes to match the prediction. ## Try it yourself - **Click `Move up`** and notice that the prediction says the move is blocked by the wall before anything happens. - **Click `Move right`** to see the ghost preview shift into the next square, then **press `Confirm action`** and check that the real player lands exactly there. - **Choose `Pick up`** when you are near the key and watch the prediction panel show an inventory change before you confirm it. - After taking the key, **select `Open door`** and see how the model predicts a world-state change rather than a movement. - **Reset the world** and compare different actions first in the preview, then after confirmation, to see how prediction can guide better choices. ## Concept explanation A **world model** is an internal picture of the environment an agent uses to decide what might be true, even when it cannot see everything directly. Under **partial observability**, the agent only has local evidence, so its model mixes three kinds of belief: what is visible **now**, what was seen **before** and is being remembered, and what is still **unknown**. This means the model is not a perfect copy of the world—it is a changing set of beliefs supported by recent observation and memory. ## What you see You are looking at a grid world with a movable player and a limited sensing radius. Tiles near the player are currently observed, explored areas outside that radius remain in memory, and unexplored regions stay hidden behind question marks. Objects become solid when they are in view, then fade after you move away, showing that the model still stores remembered beliefs even when direct evidence disappears. The side panel summarizes how much of the map is known, remembered, or unresolved. ## Try it yourself - **Drag the player** along the open corridors and watch nearby cells switch from unknown to currently known. - **Move away from a discovered object** and notice how it stays in the model as a faded memory rather than disappearing entirely. - **Increase the vision radius** to see how stronger sensing reduces uncertainty and expands the known region faster. - **Lower or raise the memory opacity** to emphasize the difference between fresh observations and remembered beliefs. - **Switch the summary mode** from `Tiles` to `Objects` to compare uncertainty about locations versus uncertainty about items. - **Press `Reset world`** and explore a different route to see how the world model changes based on what the player has actually observed. ## Concept explanation A **reactive agent** chooses actions from what it can sense right now, so it often follows the most obvious local cue even when that leads to a worse overall route. A **model-based agent** keeps an internal **world model** of objects and rules — here, that the **key** unlocks the **door** and creates a shortcut — so it can plan ahead before moving. You can see that extra internal representation improve decisions because the model-based agent accepts a small short-term cost to get the key, then benefits from a better long-term path. ## What you see You are comparing the same maze in two panels. The left panel shows the reactive agent following visible arrows toward the long open route, while the right panel shows the model-based agent using the key-door rule to plan for the shortcut. The path lengths and finish times make the contrast visible: both agents face the same world, but the one with a usable internal model tends to reach the goal more efficiently as complexity increases. ## Try it yourself - **Move the maze complexity slider** to make the long open route less attractive and see how the planning advantage grows. - **Press Play** to animate both agents from the same start state and compare their choices. - **Adjust playback speed** if you want to slow the run down and inspect when the model-based agent detours for the key. - **Press Reset** to return both agents to the start and test another scenario. - **Watch the right panel’s planned route** and notice how knowledge of hidden consequences changes the action sequence.