Skip to main content

ct_engine (Python)

High-performance, deterministic Pokémon TCG Standard engine with zero-copy NumPy observations, deterministic replay, and CT-Bench scoring.

pip install ct-engine
import json
import numpy as np
import ct_engine

decks = ct_engine.builtin_decks()
g = ct_engine.Game(decks["Dragapult"], decks["N's Zoroark"], seed=42)
print(g.turn(), ct_engine.rule_hash(), len(ct_engine.all_card_data()))

# ct-ui/1: legal-perspective snapshot + semantic action descriptors
ui = g.ui_snapshot(viewer=0)
acts = g.action_descriptors(viewer=0)

# Single-seat Gymnasium environment / vectorised BatchEnv are also exported:
# from ct_engine import PTCGEnv, PTCGVectorEnv

case = open("bench/cases/dragapult-midgame.json").read()
actions = json.loads(case)["reference_actions"]
print(json.loads(ct_engine.bench_score(case, actions))["score"])

The wheel bundles the Rust extension (ct_engine._ct_engine); no Rust toolchain is required at install time. See the repository root README, docs/UI_PROTOCOL.md for ct-ui/1, and docs/CT_BENCH.md for the replay/benchmark protocol.

Metadata

Release files for ct-engine 0.1.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 ct-engine 0.1.0
File Actions
ct_engine-0.1.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ x86-64 Details for ct_engine-0.1.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
ct_engine-0.1.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64 Details for ct_engine-0.1.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
ct_engine-0.1.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details for ct_engine-0.1.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
ct_engine-0.1.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details for ct_engine-0.1.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Total release size: 5.7 MB

Release files / ct_engine-0.1.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL ct_engine-0.1.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 1.4 MB
Tags CPython 3.13 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
14566de56a96028d443e3e3564e70c108edb088a666954098f85caaafd4ce495
BLAKE2b-256 checksum
How to use checksums
7b8757ee67a0a849f232a45c630b10dbd2bb0a5fe7443efff62f4e1d3a1068e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / ct_engine-0.1.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL ct_engine-0.1.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 1.4 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
68f6620558b68f9e64683e1bcff302862c1ec63c6752532c1eca590d9e6622ce
BLAKE2b-256 checksum
How to use checksums
bd934dcc092c52be5f4f97f1fd5ac0dda47ce9e6525a14c659d6987b8a4ef660
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / ct_engine-0.1.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL ct_engine-0.1.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 1.4 MB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
57b9866d8e2e95b05aee619284757a0e43c969b2e6495e6d1cd145dfde189c4a
BLAKE2b-256 checksum
How to use checksums
4ad736637efd07d20a89fdba31a114ba3d592c8ae0b6ff7448e6b57bff74c9fc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / ct_engine-0.1.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL ct_engine-0.1.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 1.4 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
f86779b7f0c33bc00919c0ed05352ea3aa8b25677bf8462674010d6755031fcf
BLAKE2b-256 checksum
How to use checksums
136c754457f40cce533eae8fa981779a487787d1b3425f49387f07e503c50cc2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for ct-engine 0.1.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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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