Markov chain
Randomness with a short memory: what comes next depends on what is happening now, so rainy days come in runs and moods drift instead of jumping. It also invents names that sound like your world.
When you need it
When plain randomness feels too jumpy: weather, a character's mood, music that changes by itself, or names for towns and people. It also works out the long-run odds exactly, so your AI can show you as proof how often each kind of day will really come up.
Say this to your AI
Use the Markov chain from Spielerando for my weather so rainy days come in runs, and show me what share of days will be rainy in the long run.Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP
Settings
- memory (2): How many letters decide the next one in a name. More sounds closer to your list, fewer sounds wilder.
- minLength (4): The shortest name to give out.
- maxLength (10): The longest name to give out.
Your AI gets the code
The finished code and math come through the Spielerando connection, so your AI can use them right away. Connect your AI
Common questions
how do i make random weather that feels natural
Pick tomorrow's weather based on today's. Rain stays likely after rain, and sun after sun, so you get runs of weather instead of a new roll each day.
how often will it rain in my game
That can be worked out exactly from your table of what follows what. The answer tells you the share of rainy days over a long game, without playing a single day.
how do i generate fantasy names
Give it a list of names you like. It learns which letters follow which, then builds new names from those steps, so they sound like the list without copying it.