thrust_rl/env/games/mod.rs
1//! Game environment implementations
2//!
3//! This module contains various game environments for reinforcement learning:
4//! - CartPole: Classic cart-pole balancing task
5//! - GridWorld: in-tree `4x4` FrozenLake-style sparse-reward navigation task
6//! (issue #182, `i64` discrete action `0=Up/1=Right/2=Down/3=Left`, 16-dim
7//! one-hot observation, absorbing goal/hole terminals + step-cap truncation)
8//! - Snake: Snake game with configurable grid size
9//! - SimpleBandit: Simple multi-armed bandit for testing
10//! - Pong: Single-player Pong vs rule-based opponent
11//! - ContinuousLqr: 1D LQR placeholder env that exercises the continuous
12//! (`Vec<f32>`) action surface added in issue #61
13//! - PendulumSwingUp: in-tree `Pendulum-v1` swing-up task; the canonical
14//! continuous-control SAC benchmark (issue #139, length-1 `Vec<f32>` torque
15//! action, 3-dim `[cos θ, sin θ, θ̇]` observation)
16//! - MountainCarContinuous: in-tree `MountainCarContinuous-v0` classic-control
17//! task; a sparse/deceptive-reward continuous-control benchmark (issue #166,
18//! length-1 `Vec<f32>` force action, 2-dim `[position, velocity]`
19//! observation, real terminal state at the goal)
20//! - BucketBrigade (feature `env-bucket-brigade`): Slepian-Wolf MARL research
21//! env wrapping `bucket_brigade_core` with the versioned scenario registry
22//! from bucket-brigade PR #379
23//! - MatchingPennies (feature `training`): 2-agent zero-sum smoke env
24//! implementing `JointEnv` for the multi-agent + PSRO trainers; canonical
25//! testbed for mixed-equilibrium learners (issue #107).
26//! - NPlayerMatchingPennies (feature `training`): N-player "majority game"
27//! generalization. Each agent's reward is `+1` if its action matches the
28//! strict majority of *other* agents' actions, `-1` if against, `0` on tie
29//! (odd N only). Smoke env for N-player PSRO/NFSP testing (issue #119).
30
31pub mod cartpole;
32pub mod continuous_lqr;
33pub mod grid_world;
34#[cfg(feature = "training")]
35pub mod matching_pennies;
36pub mod mountain_car_continuous;
37#[cfg(feature = "training")]
38pub mod n_player_matching_pennies;
39pub mod pendulum;
40pub mod pong;
41pub mod simple_bandit;
42pub mod snake;
43
44#[cfg(feature = "env-bucket-brigade")]
45pub mod bucket_brigade;
46
47// Re-export main types for convenience
48#[cfg(feature = "env-bucket-brigade")]
49pub use bucket_brigade::BucketBrigadeMaEnv;
50pub use cartpole::CartPole;
51pub use continuous_lqr::ContinuousLqr;
52pub use grid_world::GridWorld;
53#[cfg(feature = "training")]
54pub use matching_pennies::MatchingPennies;
55pub use mountain_car_continuous::MountainCarContinuous;
56#[cfg(feature = "training")]
57pub use n_player_matching_pennies::NPlayerMatchingPennies;
58pub use pendulum::PendulumSwingUp;
59pub use pong::Pong;
60pub use simple_bandit::SimpleBandit;
61pub use snake::SnakeEnv;