refactor: update dice handling and optimization flow to return structured results

This commit is contained in:
2026-03-25 11:05:23 -03:00
parent 0470200d00
commit 7e66c98f26
5 changed files with 53 additions and 26 deletions

View File

@@ -1,11 +1,20 @@
from pathlib import Path
from diceplayer.config.player_config import RoutineType
from diceplayer.dice.dice_wrapper import DiceEnvironment
from diceplayer.state.state_model import StateModel
class OptimizationHandler:
@staticmethod
def run(state: StateModel, current_cycle: int) -> StateModel:
print(f"Running Optimization - {current_cycle}")
def __init__(self, step_directory: Path):
self.dice_directory = step_directory / "dice"
def run(self, state: StateModel, current_cycle: int, dice_environment: list[DiceEnvironment]) -> StateModel:
routine = self._fetch_current_routine(state, current_cycle)
print(f"Running Optimization - {current_cycle} - {routine}")
print(dice_environment)
return state
@staticmethod