Files
shortdeck/shortdeck_arena/main.py
2025-09-30 18:09:49 +08:00

24 lines
529 B
Python

from __future__ import annotations
from pathlib import Path
from .agent import HumanAgent, RandomAgent
from .simulation import Simulation
def main():
agents = [HumanAgent(0), RandomAgent(1)]
sim = Simulation(agents)
print("Player cards:")
for i in range(len(agents)):
print(i, sim.player_cards(i))
print("Random agent acting...")
agents[1].try_act(sim)
print("History:", sim.history)
sim.dump_data(Path.cwd() / "shortdeck_arena_history.jsonl")
if __name__ == "__main__":
main()