Metadata-Version: 2.5
Name: mrkwatkins-oakemu-rl
Version: 0.1.0
Summary: Reinforcement learning extensions for mrkwatkins.oakemu.
Project-URL: Documentation, https://mrkwatkins.github.io/OakEmu-RL/
Project-URL: Homepage, https://www.mrkwatkins.co.uk
Project-URL: Repository, https://github.com/MrKWatkins/OakEmu-RL
Author-email: MrKWatkins <mrkwatkins@gmail.com>
License-Expression: GPL-3.0-only
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Requires-Python: <3.16,>=3.13
Requires-Dist: coloredlogs>=15.0.1
Requires-Dist: gymnasium>=1.4.0
Requires-Dist: mrkwatkins-oakemu>=0.0.47
Requires-Dist: msgspec>=0.22.0
Requires-Dist: numpy>=2.5.4
Requires-Dist: onnx>=1.23.2
Requires-Dist: onnxscript>=0.7.2
Requires-Dist: opencv-python>=5.0.0.93
Requires-Dist: psutil>=7.2.2
Requires-Dist: pydantic>=2.14.1
Requires-Dist: pythonnet>=3.2.1
Requires-Dist: tensorboard>=2.21.0
Requires-Dist: torch>=2.14.1
Requires-Dist: zstandard>=0.25.0
Description-Content-Type: text/markdown

# OakEmu-RL

[![Build](https://github.com/MrKWatkins/OakEmu-RL/actions/workflows/build.yml/badge.svg)](https://github.com/MrKWatkins/OakEmu-RL/actions/workflows/build.yml)
[![PyPI](https://img.shields.io/pypi/v/mrkwatkins-oakemu-rl)](https://pypi.org/project/mrkwatkins-oakemu-rl/)
[![Downloads](https://img.shields.io/pypi/dm/mrkwatkins-oakemu-rl)](https://pypi.org/project/mrkwatkins-oakemu-rl/)

Reinforcement learning for ZX Spectrum games, with Gymnasium environments and PyTorch training frameworks using OakEmu.

[Documentation](https://mrkwatkins.github.io/OakEmu-RL/) · [Python API](https://mrkwatkins.github.io/OakEmu-RL/api/)

## Local development

Use Python 3.13–3.15, uv and the .NET 10 runtime. The development lockfile selects a CUDA build of PyTorch; tests also run without a GPU.

```sh
uv sync --locked
uv run pytest --junitxml=test-results.xml tests/
uv run ruff check
uv run ruff format --check
uv run ty check
```

Build and Test runs on all three Python versions. It collects coverage for `src`, `experiments` and the assembly update script, generates the shared test and coverage reports, and validates documentation once.

## Preview documentation

Run `python3 docs/preview.py`, or use the JetBrains **Preview documentation** configuration. Open <http://localhost:5173/OakEmu-RL/>.
Restart after editing source or guides. uv and Docker are required; API generation uses static analysis and does not start .NET or import PyTorch.
Generated API and site files live under ignored `artifacts/`.

## Update emulator assemblies

Refresh and release the sibling OakEmu-Python project first. Then run:

```sh
uv run python scripts/update_assemblies.py
```

The script builds the sibling OakEmu checkout, copies resolved runtime assemblies that are not already bundled by OakEmu-Python, and removes JetBrains annotations. No NuGet version numbers are duplicated in this script.
