Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ WORKDIR /app
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1

COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY requirements.prod.txt .
RUN pip install --no-cache-dir --index-url https://download.pytorch.org/whl/cpu torch==2.10.0
RUN pip install --no-cache-dir -r requirements.prod.txt

COPY game ./game
COPY rl ./rl
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ make setup
pip install -r requirements.txt
```

For deployment builds, the Dockerfile installs `requirements.prod.txt`, which
includes runtime dependencies (FastAPI + RL model) but omits local dev/test tools.

## Run the dev servers

Backend API (FastAPI + reload):
Expand Down
6 changes: 6 additions & 0 deletions requirements.prod.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
fastapi==0.128.0
gymnasium==1.2.3
numpy==2.4.1
sb3-contrib==2.7.1
stable-baselines3==2.7.1
uvicorn[standard]==0.40.0
1 change: 1 addition & 0 deletions server/session_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
from game.game import Game
from game.game_state import GameState


class AIPlayerProtocol(Protocol):
async def get_action(self, game_state: GameState, legal_actions: list) -> object: ...
def get_action_sync(self, game_state: GameState, legal_actions: list) -> object: ...
Expand Down
Loading