Formal Specification
One, Two, Three, Baba Yaga is Watching! (Polish Freeze-Tag Race) — Formal Specification
Poland · chase-tag · Confidence: medium
← Back to game pageImplementation Suitability
Suitability: adaptation-requiredFidelity: discretizedGap-fills: 4
# Raz, dwa, trzy, Baba Jaga patrzy! — AI-optimized specification
## General idea
An asymmetric stop-and-motion sprint game where a designated leader agent (*Baba Jaga*) standing at a goal line recites a cadence of stochastic duration with back turned before abruptly facing the field to inspect for movement, while advancing Runner agents must balance forward velocity against deceleration risk to reach the goal line without being detected in motion.
## Formal model
- **Abstraction taken:** The 1D race track of length `L = 20` discrete spatial units (Start Line at `x = 0`, Goal Line at `x = 20`) is traversed in discrete rounds. In each round, Baba Jaga selects a recitation duration `T_recite ∈ {2, 3, 4, 5}` ticks. Runner agents simultaneously select a movement velocity `v ∈ {0, 1, 2, 3}` units/tick. A deceleration mechanic models physical inertia: attempting to stop from higher velocities carries an overstep probability `P_overshoot = f(v, DecelerationSkill)`. If an agent overshoots into the inspection window, Baba Jaga observes positive velocity and penalizes the agent.
- **Player/agent count:** `N` agents (`N >= 3`, default 4 to 8). Exactly 1 Baba Jaga (`BJ`) and `N-1` Runners (`R_1 .. R_{N-1}`).
- **Turn model:** Round-based structure. Each round consists of: (1) Secret duration selection by Baba Jaga, (2) Simultaneous velocity schedule execution by Runners for `T_recite` ticks, and (3) Inspection & Penalty evaluation.
## Formal rules
R1. **Setup:**
- All Runners start at position `x_i = 0`.
- Baba Jaga is stationed at position `x_BJ = 20` facing away from the field (`State = REC傢ING`).
R2. **Recitation & Movement Execution:**
- In secret, Baba Jaga samples recitation length `T ~ Uniform{2, 3, 4, 5}` ticks (or samples a cadence strategy from a discrete policy).
- Each Runner `R_i` chooses an intended velocity sequence `[v_{i,1}, v_{i,2}, ..., v_{i, T}]` where each `v_{i,t} ∈ {0, 1, 2, 3}`.
- Position updates: on tick `t`, `x_i(t) = x_i(t-1) + v_{i,t}`.
R3. **Freeze & Inertia Check:**
- On tick `T`, Baba Jaga turns around (`State = INSPECTING`).
- For each Runner `R_i`, the terminal velocity at tick `T` must be `0`.
- If `v_{i, T} > 0`, the agent is caught moving with certainty (`P_detect = 1.0`).
- If `v_{i, T} == 0`, but `v_{i, T-1} == 3` (high braking load), an inertia wobble check is evaluated: `P_wobble = 0.30 * (1.0 - DecelerationSkill_i)`. If wobble triggers, the agent is detected moving.
R4. **Penalty Application:**
- Every Runner `R_i` detected in motion or wobbling during inspection is reset to `x_i = 0` immediately.
- Undetected Runners retain their advanced position `x_i(T)`.
R5. **Win Condition & Goal Crossing:**
- If any Runner `R_i` reaches `x_i >= 20` during a recitation where they were not detected on turn `T`, `R_i` wins the round immediately.
- If multiple Runners cross `x >= 20` on the same round without detection, [gap-fill] the runner with the largest `x_i` value (greatest overshoot past goal line) wins; if tied, the runner with the higher deceleration skill wins.
R6. **Round Succession:**
- The winning runner becomes Baba Jaga for the subsequent round.
- If no runner reaches `x >= 20` within `K_max = 15` rounds, [gap-fill] the runner with the furthest advanced position `max(x_i)` wins.
R7. [gap-fill] **Match Scoring:** A full tournament consists of `N` rounds. The global winner is the agent who won the most rounds as a Runner.
## Edge cases
- **Tie at the end condition:** If multiple runners cross the finish line with identical positions and skills, [gap-fill] a 1-round sudden death sprint between tied runners resolves the tie.
- **A player with no legal move:** Selecting `v = 0` (standing completely still) is always legal for every runner on every tick.
- **Repetition / cycles:** Bounded strictly by `K_max = 15` rounds per match, preventing infinite stall loops.
- **Simultaneous claims on the same resource or position:** Multiple runners may occupy identical track coordinate values `x` without collision interference.
- **Player elimination mid-round; turn order repair:** No agent is permanently eliminated; penalized runners are reset to `x = 0` and continue competing in subsequent rounds.
- **Resource exhaustion:** No physical tokens are expended.
- **Termination guarantee:** Each round executes in at most 5 ticks, and each match executes in at most 15 rounds, ensuring deterministic polynomial termination.
## State representation
- **Persistent state:** `tournament_round` (1..N), `current_baba_jaga_id`, `win_counts` (Map[AgentId, Int]).
- **Per-round state:** `runner_positions` (Map[AgentId, Int]), `recitation_ticks_remaining` (Int), `detected_runners` (Set[AgentId]), `round_terminated` (Boolean).
- **Observable information:** Imperfect/hidden information. Runners do not observe Baba Jaga's chosen `T_recite` until the turn occurs. Baba Jaga does not observe Runner velocity choices during the recitation, only final postures/positions upon inspection.
## Action space
- `set_recitation_duration(ticks ∈ {2, 3, 4, 5})`: Baba Jaga action selecting hidden timing.
- `set_velocity(v ∈ {0, 1, 2, 3})`: Runner action choosing speed for the current tick.
## Playability notes
- **Single-player-vs-AI:** Natural and highly strategic — human plays as a Runner estimating AI Baba Jaga timing distributions, or as Baba Jaga varying cadence to catch greedy AI sprint bots.
- **Group games (n>4):** Natively multi-agent; each runner optimizes an independent risk-reward curve. In a 2-agent reduction (1 Baba Jaga vs 1 Runner), the game reduces to a clean 2-player stochastic zero-sum timing game.
- **Physical-skill games:** Somatic motor inhibition and deceleration balance are mapped onto the discrete inertia wobble probability `P_wobble`.
- **What is lost in the adaptation:** The comical visual variety of physical frozen postures, facial expressions, and the theatrical tension of Baba Jaga slowly pacing among human statues are abstracted into numeric velocity checks.
## Implementation hints
Extremely simple 1D state array. The core game loop is an iterative simultaneous revelation: Baba Jaga draws `T`, Runners submit vectors `V_i` of length `T`, positions update, deceleration checks evaluate, and penalties apply. Suggested first milestone: implement the 1-round loop with uniform random duration and evaluate optimal runner risk-reward policies via dynamic programming.
Download as JSON
Download the full game corpus entry for this game as structured JSON.
Download JSONCite this page
One, Two, Three, Baba Yaga is Watching! (Polish Freeze-Tag Race) (Poland). (n.d.). Games of Countries. https://gamesofcountries.com/games/pl-poland/baba-jaga-patrzy
@misc{gamesofcountries-pl-poland-baba-jaga-patrzy,
title = {One, Two, Three, Baba Yaga is Watching! (Polish Freeze-Tag Race) (Poland)},
year = {n.d.},
publisher = {Games of Countries},
url = {https://gamesofcountries.com/games/pl-poland/baba-jaga-patrzy}
}