Skip to main content
Formal Specification

Diabolo (Chinese Yo-yo) — Formal Specification

Taiwan · dexterity-small · Confidence: low

← Back to game page

Implementation Suitability

Suitability: adaptation-requiredFidelity: probabilistic-proxyGap-fills: 3
# Cheling — AI-optimized specification ## General idea A traditional dexterity folk sport modeling the manipulation, acceleration, aerial toss, and technical string-wrapping of an hourglass-shaped spool (diabolo / *chě líng*). Competitors manage rotational velocity and axis stability across a fixed time window, executing a sequence of scored trick combinations while avoiding spool stalls, line knots, and ground drops. ## Formal model - **Abstraction taken:** Continuous 3D aerodynamics, string friction, and centrifugal gyroscopic balance are abstracted into a discrete state machine tracking rotational RPM, tilt angle, string wrap state, and execution success probabilities for parameterized trick maneuvers. - **Player/agent count:** 1 agent per routine (evaluated in comparative heats of 2 to 8 competitors). - **Turn model:** Real-time ticked simulation (T=120 discrete 1-second time steps per routine) or turn-based trick-selection sequence. ## Formal rules R1. **State & Energy Dynamics:** The spool possesses: - `rpm`: Rotational velocity ∈[0,5000] (decay rate δrpm=15 RPM/sec under zero acceleration). - `axis_tilt`: Tilt deviation angle θ∈[−45∘,+45∘] relative to the horizontal plane (0∘=balanced). - `string_state`: ∈{Open, Single-Wrap, Double-Wrap, Knot-Error}. - `spool_location`: ∈{On-String, Airborne, Stick-Balanced, Ground-Drop}. R2. **Acceleration Action (`accelerate`):** Active player whips the dominant hand stick. - Increases `rpm` by +150×efficiency. - Reduces `axis_tilt` error if compensated with counter-tension. R3. **Trick Execution & Difficulty Ratings:** The player may select from categorized trick classes: - **String Traversal (*Slide/Elevator*):** Base difficulty D=2; requires RPM≥800. Base score =10. - **Body Orbit (*Wrap-around*):** Base difficulty D=4; requires RPM≥1200. Base score =25. - **High Toss & Catch (*Big Jump*):** Base difficulty D=6; requires RPM≥1800; spool is airborne for 2 time ticks. Base score =45. - **Multi-Element Combo (*Sun-Moon Sequence*):** Base difficulty D=9; requires RPM≥2500. Base score =80. R4. [gap-fill] **Success Probability Resolver:** For any trick of difficulty D, success probability Psuccess is computed as: Psuccess=clamp(skill_rating10⋅rpmrpm_req⋅cos⁡(axis_tilt)−0.05×D,0.05,0.98) - If successful: Add base trick score ×(1+combo_streak×0.1) to `total_score`; consume D×20 RPM. - If failed: Trigger fault condition (wobble, knot, or drop). R5. **Fault Deductions:** - **Axis Wobble (|θ|>25∘):** −5 points, doubles RPM decay rate until corrected with `tune_axis()`. - **String Knot (`Knot-Error`):** −15 points; forces agent to spend 2 time ticks on `untangle()`. - **Spool Drop (`Ground-Drop`):** −30 points; resets `rpm` to 0; requires 3 time ticks to perform `restart_spool()`. R6. [gap-fill] **Routine Duration & Completion:** The routine lasts exactly 120 discrete seconds (ticks). When `ticks_remaining` reaches 0, no further actions are allowed, and final routine score is evaluated. R7. [gap-fill] **Victory Determination:** In competitive multi-agent matches, all agents execute their 120-tick routine under identical initial conditions. The agent with the highest final `total_score` wins. ## Edge cases - **Tie at the end condition:** If two agents achieve identical total points, the tie is broken by: (1) fewest total faults/drops, (2) highest single trick score, (3) remaining final RPM. - **A player with no legal move:** When a spool drops or knots, the only legal actions are mandatory recovery actions (`untangle`, `restart_spool`). - **Repetition / cycles:** Spamming low-difficulty acceleration or simple slides yields diminishing returns: repeating the same trick within 3 consecutive actions reduces trick score by 50%. - **Simultaneous claims on the same resource or position:** Not applicable; routines are evaluated on independent individual lanes or synchronized sequential flights. - **Player elimination mid-round:** If an agent experiences 3 consecutive spool drops resulting in negative cumulative score, the routine is marked as disqualified/terminated early with current points. - **Resource exhaustion:** Routine time (120 ticks) is strictly bounded and decrements by 1 every action step. - **Termination guarantee:** Guaranteed by strict decrement of finite discrete time ticks (`ticks_remaining` reaches 0 in 120 steps). ## State representation - **Persistent state:** - `agent_id`: integer. - `skill_rating`: float in [1.0,10.0]. - `total_score`: float. - `fault_count`: integer. - `trick_history`: list of completed trick IDs. - **Per-tick ephemeral state:** - `ticks_remaining`: integer in [0..120]. - `rpm`: float in [0.0,5000.0]. - `axis_tilt`: float in [−45.0,+45.0] degrees. - `string_state`: enum `[Open, Wrapped, Knot]`. - `spool_location`: enum `[On-String, Airborne, Balanced, Dropped]`. - `combo_streak`: integer ≥0. - **Observable information:** Fully observable internal engine state and performance metrics. ## Action space - `accelerate()`: Whip stick to boost RPM (+150 RPM, −1 time tick). - `tune_axis(direction)`: Adjust string angle to reduce `axis_tilt` toward 0∘ (−1 time tick). - `wrap_string()` / `unwrap_string()`: Toggle wrap state to modify acceleration multiplier. - `execute_trick(trick_id)`: Attempt specified trick (preconditions: `spool_location == On-String`, `rpm >= rpm_req`). - `catch_spool()`: Mandatory action when `spool_location == Airborne` to complete a high toss. - `untangle()` / `restart_spool()`: Error recovery actions. ## Playability notes - **Single-player-vs-AI:** Highly playable optimization problem; AI formulates optimal control policies (Markov Decision Process / Dynamic Programming) to maximize score while managing RPM buffer and risk tolerance. - **Group games (n>4):** Evaluated as a tournament leaderboard across individual independent runs. - **Physical-skill games:** Replaced with a probability curve balancing trick difficulty D, current RPM velocity, and gyro tilt angle. - **What is lost in the adaptation:** Physical muscle memory, acoustic feedback from bamboo sound slits, and visual crowd flair. ## Implementation hints - Model as a finite horizon discrete-time Markov Decision Process (MDP) with 120 stages. - The state vector is low-dimensional `(rpm, tilt, string_state, combo_streak, time_remaining)`. - Suggested first milestone: Build the single-routine simulation loop with RPM decay, acceleration actions, and basic 3-trick scoring.

Download as JSON

Download the full game corpus entry for this game as structured JSON.

Download JSON
Cite this page

Diabolo (Chinese Yo-yo) (Taiwan). (n.d.). Games of Countries. https://gamesofcountries.com/games/tw-taiwan/cheling

@misc{gamesofcountries-tw-taiwan-cheling,
  title = {Diabolo (Chinese Yo-yo) (Taiwan)},
  year = {n.d.},
  publisher = {Games of Countries},
  url = {https://gamesofcountries.com/games/tw-taiwan/cheling}
}