haive.games.fox_and_geese.fixed_runner¶

Fixed runner for Fox and Geese game without LangGraph streaming issues.

Classes¶

FixedFoxAndGeeseAgent

Fixed Fox and Geese agent that handles state directly.

Functions¶

main()

Run the Fox and Geese game with the fixed runner.

parse_arguments()

Parse command line arguments.

Module Contents¶

class haive.games.fox_and_geese.fixed_runner.FixedFoxAndGeeseAgent(config=FoxAndGeeseConfig())[source]¶

Bases: haive.games.fox_and_geese.agent.FoxAndGeeseAgent

Fixed Fox and Geese agent that handles state directly.

Initialize the Fox and Geese agent.

Parameters:

config (FoxAndGeeseConfig) – The configuration for the Fox and Geese game.

run_fixed_game(delay=1.0, max_moves=100)[source]¶

Run the Fox and Geese game step by step, managing state directly.

This bypasses LangGraph’s stream method, which can have issues with certain state types.

Parameters:
  • delay (float) – Time delay between moves for better visualization

  • max_moves (int) – Maximum number of moves before forcing a draw

Returns:

Final game state

Return type:

haive.games.fox_and_geese.state.FoxAndGeeseState

haive.games.fox_and_geese.fixed_runner.main()[source]¶

Run the Fox and Geese game with the fixed runner.

haive.games.fox_and_geese.fixed_runner.parse_arguments()[source]¶

Parse command line arguments.