Skip to main content

atomheart

A Python chess library providing a unified interface for chess board operations and move handling.

Release 0.3.0

This release requires Python 3.14 and the published valanga==0.3.0. It preserves the validated Morpion rules, canonical identities, checkpoints, and core game behavior, with precise generic state and undo-token contracts. The base package remains installable without either optional chess backend.

Features

  • Chess board representation and manipulation
  • Move generation and validation
  • Board modification tracking
  • Support for both Python-chess and Rust-based backends
  • FEN notation support
  • Morpion Solitaire environment (5T and 5D variants)

About

atomheart is a wrapper library that provides a unified interface over popular chess engines:

This unified interface is designed for use in chess search algorithms and AI agents, allowing seamless switching between backends for optimal performance.

See the repos

  • chipiron - Lear AI agents for chess (and maybe later other games).
  • anemone - Tree search library

Installation

pip install atomheart==0.3.0
pip install 'atomheart[chess]==0.3.0'
pip install 'atomheart[chess-rust]==0.3.0'
pip install 'atomheart[all]==0.3.0'

The base install keeps the lightweight core games available. Chess support is optional, and the Rust-backed chess board is enabled by the chess-rust extra.

Quick Start

from atomheart.board import create_board
from atomheart.board.utils import FenPlusHistory

# Create a chess board
board = create_board(
    fen_with_history=FenPlusHistory(current_fen="rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1"),
    use_rust_boards=True
)

# Make a move
move_key = board.get_move_key_from_uci("e2e4")
board_modification = board.play_move_key(move_key)

Python 3.14 development

uv venv --python 3.14
uv pip install -e '.[test,dev,all]'
source .venv/bin/activate
tox

Core annotations use Python 3.14 deferred evaluation with runtime imports needed by typing.get_type_hints. The lazy chess/Rust factories retain string annotations so optional native types need not be imported. For these factories, annotationlib.get_annotations(..., format=annotationlib.Format.STRING) can inspect annotations without loading the optional backend.

The acting-role state classes retain their type-checking-only protocol bases to preserve slotted dataclass layout. Morpion rules, canonical move identities, checkpoint payloads and stable hashing are unchanged.

shakmaty_python_binding==0.1.5 currently needs a source build on CPython 3.14 on Linux; its published binary wheel targets CPython 3.11. The complete chess suite must be run against the actual compiled binding.

Tests, lint, and typing install valanga==0.3.0 from PyPI. CI and release workflows use the same published dependency through tox. The optional Rust binding has no established published CPython 3.14 wheel; a local source build was validated on Linux, and availability on other platforms is not guaranteed.

Metadata

Release files for atomheart 0.3.0

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

Source distribution (sdist)

Source distribution for atomheart 0.3.0
File Size Uploaded Provenance Actions
atomheart-0.3.0.tar.gz 69.5 kB With provenance Details for atomheart-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for atomheart 0.3.0
File Interpreter ABI Platform Actions
atomheart-0.3.0-py3-none-any.whl Python 3 none any Details for atomheart-0.3.0-py3-none-any.whl

Total release size: 151.8 kB

Release files / atomheart-0.3.0.tar.gz

Download URL atomheart-0.3.0.tar.gz
Size 69.5 kB
Tags Source
SHA-256 checksum
How to use checksums
05c5f577f04e0a2c0783a3382a6ca791e884163b4c00b9fc4818c9fe851c8bdb
BLAKE2b-256 checksum
How to use checksums
6c35028eea48936889ce79b5b592d1b8b7e9a8e61d36e930dedbc0431243f986
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 Oct 27, 2026.

Transparency log

Release files / atomheart-0.3.0-py3-none-any.whl

Download URL atomheart-0.3.0-py3-none-any.whl
Size 82.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e4472f20ebdaad80cb65dafc0a09ed1fb9f03b6870eda363112c403d945244b1
BLAKE2b-256 checksum
How to use checksums
1f513a1b3934eb73287212d79543aabefcd0a538a38f146051dfe88e2bb8e3be
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 Oct 27, 2026.

Transparency log

Security for atomheart 0.3.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

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for atomheart-0.3.0.tar.gz

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 Oct 27, 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