Skip to main content

lockstep-train

Train a policy on your own machine against a Lockstep environment's real engine.

pip install lockstep-train

In the folder lockstep invite get (or lockstep training get) wrote:

import lockstep_train

env = lockstep_train.make(".")                       # a Gymnasium environment
obs, info = env.reset(seed=7)                        # the match `lockstep run --seed 7` plays
obs, reward, terminated, truncated, info = env.step(env.action_space.sample())

vec = lockstep_train.make_vec(".", 8)                # 8 matches at once, one thread each
  • Every step is a turn of the real match: the same engine, rules and opponents as lockstep run, deterministic for the same seed and actions.
  • The spaces are the ONNX shell's: one observation per declared input, one action per tensor the shell reads (an f32 output in [-1, 1], a discrete head per coded output). Export your network with one ONNX output per action entry, put it in a policy bundle, and lockstep check --agent <bundle> plays it exactly as Lockstep will.
  • Reward: the environment's own per-turn training reward (or a series you name, reward="series:<key>", or the score at the end, "score"); info carries every declared series and, at the end, the score and the ending.
  • LabelledStream turns an environment's delayed feedback into (observation, label) pairs for supervised training.

Python 3.11 or later; wheels for macOS (Apple silicon), Linux (x86_64, arm64) and Windows (x86_64).

Metadata

Release files for lockstep-train 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for lockstep-train 1.0.0
File Actions
lockstep_train-1.0.0-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details for lockstep_train-1.0.0-cp311-abi3-win_amd64.whl
lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_x86_64.whl CPython 3.11 abi3 Linux glibc 2.39+ x86-64 Details for lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_x86_64.whl
lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_aarch64.whl CPython 3.11 abi3 Linux glibc 2.39+ ARM64 Details for lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_aarch64.whl
lockstep_train-1.0.0-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details for lockstep_train-1.0.0-cp311-abi3-macosx_11_0_arm64.whl

Total release size: 67.4 MB

Release files / lockstep_train-1.0.0-cp311-abi3-win_amd64.whl

Download URL lockstep_train-1.0.0-cp311-abi3-win_amd64.whl
Size 16.6 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
d9c70a32679c56af9e429cf0df8f5ae9bc658c0b091f04982a812e151522b2af
BLAKE2b-256 checksum
How to use checksums
c9a3a425cea432c5a79989aff1af2be0aac0ae7040da6efac11c7a64672f49ed
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Release files / lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_x86_64.whl

Download URL lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_x86_64.whl
Size 18.1 MB
Tags CPython 3.11 Linux glibc 2.39+ x86-64 abi3
SHA-256 checksum
How to use checksums
8ff7ba0390679e5be2a56d6cfb75ce35d6d81ff9154d5ebaaa13a46c8512c7b6
BLAKE2b-256 checksum
How to use checksums
3e29db8887ab396b264ba64e2ce2616ec96034c7edda810d8e8f3d7f40a8dc26
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Release files / lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_aarch64.whl

Download URL lockstep_train-1.0.0-cp311-abi3-manylinux_2_39_aarch64.whl
Size 17.7 MB
Tags CPython 3.11 Linux glibc 2.39+ ARM64 abi3
SHA-256 checksum
How to use checksums
dca5e730ce8286fc134cfd9ba7feecbefdf0b0fa5237bc3365177b4a9e5343e4
BLAKE2b-256 checksum
How to use checksums
4bc7350e23e924891f4a097cc5ea513196f7ea0421f624c42f4df8bd8b8b5577
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Release files / lockstep_train-1.0.0-cp311-abi3-macosx_11_0_arm64.whl

Download URL lockstep_train-1.0.0-cp311-abi3-macosx_11_0_arm64.whl
Size 15.1 MB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
ef7dd68c3b4a55e6dd21580456dfec9b1bd030c40069364ffce61b6c6ca5f1d7
BLAKE2b-256 checksum
How to use checksums
8986381c2928caaf1d891300c059a078c59c1c302b22344f19471fe69830ed0b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Security for lockstep-train 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 4 files in this release have been uploaded with provenance metadata.

Select from 4 files

Attestation for lockstep_train-1.0.0-cp311-abi3-win_amd64.whl

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page