Skip to main content

Runir: Representations for Generalized Planning in C++ and Python

Runir is designed to address several challenges in the integration of learning and planning based systems:

  1. Dataset construction from planning tasks and classes of tasks over a common planning domain.

  2. State Model Representations that expose a task's dynamics in a representation suitable for relational learning.

  3. Symbolic feature languages with formal syntax, semantics, parsing, generation, and evaluation.

  4. Generalized policy evaluation on planning examples with explicit access to policy failures and counterexamples.

  5. Equivalence abstractions for comparing states and tasks through graph, object-graph, and equivalence-graph representations.

Runir is the learning and representation layer for the planning-and-learning ecosystem. Tyr provides the planning backend: PDDL/formalism objects, task repositories, state repositories, successor generation, search algorithms, and Python bindings. Runir builds on top of that backend to make planning tasks inspectable and learnable, not only solvable.

Components

  • Graphs: runir's state, equivalence, object, proof and policy graphs are urd graphs with their labels beside them; searches, shortest paths, strongly connected components, color refinement, Weisfeiler-Leman certificates and nauty canonical forms come from vefr, whose Python functions (pyvefr) take runir's graphs too.
  • runir::datasets: task classes, per-task search contexts, state graphs, annotated state graphs, object graphs, and equivalence graphs built from policies such as identity or graph-isomorphism reduction.
  • runir::kr::dl: description-logic constructors, grammars, CNF grammars, denotations, evaluation, parsing, formatting, and grammar factories.
  • runir::kr::ps: rule-based generalized policies over typed features, conditions, effects, policy parsing, policy factories, and policy execution on annotated state graphs.
  • pyrunir: Python bindings for the same components with stubs.

The native CMake package exports runir::core as the aggregate target and component targets such as runir::datasets and runir::kr. The Python package is pyrunir.

Dependencies

  • Python 3.11 or newer.
  • pyyggdrasil >= 0.8.0, < 0.9 for shared third-party native dependencies.
  • pytyr >= 0.9.0, < 0.10 for Tyr planning, formalism, search, and C++ headers/libraries.
  • pypddl >= 1.9.0, < 1.10 through Tyr/PDDL parsing infrastructure.
  • pypddl-datasets >= 0.0.17, < 0.1 for the PDDL benchmark data used by the C++ test and profiling fixtures (resolved from its cache at CMake configure time).
  • scikit-build-core for Python wheel builds.

The shared workspace layout, layered install order, and the common build-from-source and CMake-integration patterns are documented in the Planning and Learning build instructions; the sections below cover runir/pyrunir-specific details.

Build C++

Install Runir's native dependency providers into the active Python environment, then configure CMake with their native prefixes:

python -m pip install 'pyyggdrasil>=0.9.0,<0.10' 'pybrokkr>=0.1.4,<0.2' 'pypddl>=1.10.0,<1.11' 'pytyr>=0.9.0,<0.10' 'pypddl-datasets>=0.0.17,<0.1'

cmake -S . -B build

cmake --build build -j4

CMake discovers the installed provider packages automatically: it finds the build helpers of brokkr (pybrokkr, installed with the package), whose brokkr_find_python_native_prefix adds pyyggdrasil's native prefix to CMAKE_PREFIX_PATH; find_package(yggdrasil) then resolves the rest of the chain and links against the yggdrasil::yggdrasil and tyr::core targets. To point at different prefixes explicitly:

cmake -S . -B build \
  -DCMAKE_PREFIX_PATH="$(python -m pyyggdrasil --prefix);$(python -m pypddl --prefix);$(python -m pytyr --prefix)"

CMake options:

Option Default Description
RUNIR_BUILD_TESTS OFF Build Runir tests.
RUNIR_BUILD_EXECUTABLES OFF Build Runir executables.
RUNIR_BUILD_PYRUNIR OFF Build pyrunir Python bindings.
RUNIR_HEADER_INSTANTIATION OFF Instantiate templates in in-tree translation units at higher compile-time cost.
RUNIR_DELTA_EVALUATION ON Use incremental feature evaluation in find_solution.
RUNIR_USE_LLD ON Use LLVM lld with Clang when available.
RUNIR_ENABLE_LTO ON Enable link-time optimization for Release builds.

Single-config CMake builds default to Release. On GCC and Clang, Debug builds use -Og with debug symbols, RelWithDebInfo keeps frame pointers and disables LTO, and Release LTO uses GCC LTO or Clang ThinLTO. Editable installs and wheels disable RUNIR_USE_LLD and RUNIR_ENABLE_LTO by default for build reliability.

Run tests from a build configured with -DRUNIR_BUILD_TESTS=ON:

ctest --test-dir build --output-on-failure

Install Runir from a configured build directory with:

cmake --install build --prefix=<path/to/installation-directory>

Build Python

python -m pip install .[test]
pytest python/tests

Python Serialization

pyrunir.serialization exposes the native serializers with caller-selected dictionary tables shared with Tyr. See the serialization output reference.

Template and include rules

Headers and templates follow the template and include rules.

CMake Integration

This section covers pyrunir-specific paths and targets; the general pattern for consuming the native prefixes from CMake is in the common CMake integration instructions.

The Python package pyrunir installs Runir's native headers, shared libraries, and CMake package config under pyrunir.native_prefix(). Use pyrunir.cmake_prefix() and pyrunir.cmake_dir() (or python -m pyrunir --prefix / --cmake-dir from the shell) to locate them. Downstream CMake projects should include the native prefixes of pyrunir and its native package dependencies in CMAKE_PREFIX_PATH:

cmake -S . -B build \
  -DCMAKE_PREFIX_PATH="$(python -m pyyggdrasil --prefix);$(python -m pypddl --prefix);$(python -m pytyr --prefix);$(python -m pyrunir --prefix)"

Runir exports the runir::core aggregate target and component targets such as runir::datasets and runir::kr.

Intended Workflow

Runir is designed for experiments where a learning system needs structured access to planning behavior:

  1. Parse and instantiate tasks with Tyr.
  2. Build state graphs or equivalence graphs with Runir datasets.
  3. Define symbolic features in a KR language such as description logics.
  4. Build or parse a generalized policy over those features.
  5. Execute the policy on examples and inspect failures or counterexamples.

Extended policies support query features and Action rules for selecting complete action tuples and checking declared effect contracts. Their proof search combines lazy Choose exploration with incremental AND/OR success propagation. See KR evaluation storage for result bindings, view lifetimes, and internal rule evaluators.

Indexical concept policies are available as the separate icp family, with Ext features, Load and Crule effects, concept histories, and greedy or universal execution.

This keeps low-level planning mechanics in Tyr while giving learning code a high-level, typed interface for representations, abstractions, and policy evaluation.

Metadata

Release files for pyrunir 0.9.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 pyrunir 0.9.0
File Size Uploaded Provenance Actions
pyrunir-0.9.0.tar.gz 647.3 kB With provenance Details for pyrunir-0.9.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for pyrunir 0.9.0
File Actions
pyrunir-0.9.0-cp311-abi3-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.11 abi3 Linux glibc 2.28+ x86-64, Linux glibc 2.27+ x86-64 Details for pyrunir-0.9.0-cp311-abi3-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
pyrunir-0.9.0-cp311-abi3-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.11 abi3 Linux glibc 2.28+ ARM64, Linux glibc 2.26+ ARM64 Details for pyrunir-0.9.0-cp311-abi3-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
pyrunir-0.9.0-cp311-abi3-macosx_11_0_x86_64.whl CPython 3.11 abi3 macOS 11.0+ x86-64 Details for pyrunir-0.9.0-cp311-abi3-macosx_11_0_x86_64.whl
pyrunir-0.9.0-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details for pyrunir-0.9.0-cp311-abi3-macosx_11_0_arm64.whl

Total release size: 30.2 MB

Release files / pyrunir-0.9.0.tar.gz

Download URL pyrunir-0.9.0.tar.gz
Size 647.3 kB
Tags Source
SHA-256 checksum
How to use checksums
01fb84b93fd8e560ec3082b31f071f180bba859d185c42f96380e830c5c6c5db
BLAKE2b-256 checksum
How to use checksums
78e2f4cc313a24ea316b1e892a64b25f75739d594b7e92d9734ee52c79517b30
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 15, 2026.

Transparency log

Release files / pyrunir-0.9.0-cp311-abi3-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL pyrunir-0.9.0-cp311-abi3-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 7.8 MB
Tags CPython 3.11 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
82cc6f658f5a1a01abd26b7c3c0b11750c89b6949f59fd086d7b51d1c7c81f52
BLAKE2b-256 checksum
How to use checksums
39927ac94457ce1228410c6c099f8d28cb4ca0c343552d1ca0e566e3db6c103d
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 15, 2026.

Transparency log

Release files / pyrunir-0.9.0-cp311-abi3-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL pyrunir-0.9.0-cp311-abi3-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 7.0 MB
Tags CPython 3.11 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
14fafa88c22d11ee2cec8585158f7b936af82151b12d38b8e1a1703025987a52
BLAKE2b-256 checksum
How to use checksums
638584bc0e28956a3259b674fa7f51c02cd680b77fc3486679047eaa7cf50523
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 15, 2026.

Transparency log

Release files / pyrunir-0.9.0-cp311-abi3-macosx_11_0_x86_64.whl

Download URL pyrunir-0.9.0-cp311-abi3-macosx_11_0_x86_64.whl
Size 8.6 MB
Tags CPython 3.11 abi3 macOS 11.0+ x86-64
SHA-256 checksum
How to use checksums
e276d165fa30f5033f26dbeb08586f8ea80bfa4378ca4bd3477a739b5286cda4
BLAKE2b-256 checksum
How to use checksums
c8bb3d8f66ad2a925f6eb7e3af6aa9c5742066b0e61f8a51f1cbfebc9b241151
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 15, 2026.

Transparency log

Release files / pyrunir-0.9.0-cp311-abi3-macosx_11_0_arm64.whl

Download URL pyrunir-0.9.0-cp311-abi3-macosx_11_0_arm64.whl
Size 6.1 MB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
6617bc0071ec561ed9c91e6b90425abdf9eb6d532983e3d4a2eb801c625c6753
BLAKE2b-256 checksum
How to use checksums
623539d6fd6a28582f4bae5ca45f4369e25d2706b3194733e7d806e5131d339d
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 15, 2026.

Transparency log

Security for pyrunir 0.9.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 5 files in this release have been uploaded with provenance metadata.

Select from 5 files

Attestation for pyrunir-0.9.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 Nov 15, 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.

Release history Release notifications | RSS feed

This release

0.9.0 This release

5 release files Full provenance

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