banqi_rust/src/engine.rs (~1,980 lines) interleaves the game model (types, board, move generation, rules) with the search (αβ + Star1, TT, quiescence, eval). Sibling repo misty-flip-jungle keeps these in separate modules (game.rs vs engine.rs); this repo and misty-jungle do not.
Split the game logic into banqi_rust/src/game.rs, matching flip-jungle:
- Move state / board / move-gen / rules to
game.rs; have engine.rs reference them via crate::game::….
- Add
pub mod game; in banqi_rust/src/lib.rs.
- Add
#[path = "../../banqi_rust/src/game.rs"] mod game; in banqi-engine/src/main.rs, before the engine include, mirroring flip-jungle's main.rs.
Safety: the UCI binary carries golden/parity tests; cargo test -p banqi-engine must stay green (the engine reproduces the Python engine byte-for-byte).
Priority: low. Structural hygiene, not a functional change; the monolith works. Tracked so the misty engine repos converge on one module layout.
banqi_rust/src/engine.rs(~1,980 lines) interleaves the game model (types, board, move generation, rules) with the search (αβ + Star1, TT, quiescence, eval). Sibling repo misty-flip-jungle keeps these in separate modules (game.rsvsengine.rs); this repo and misty-jungle do not.Split the game logic into
banqi_rust/src/game.rs, matching flip-jungle:game.rs; haveengine.rsreference them viacrate::game::….pub mod game;inbanqi_rust/src/lib.rs.#[path = "../../banqi_rust/src/game.rs"] mod game;inbanqi-engine/src/main.rs, before the engine include, mirroring flip-jungle'smain.rs.Safety: the UCI binary carries golden/parity tests;
cargo test -p banqi-enginemust stay green (the engine reproduces the Python engine byte-for-byte).Priority: low. Structural hygiene, not a functional change; the monolith works. Tracked so the misty engine repos converge on one module layout.