Skip to main content

Core microsimulation engine enabling country-specific policy models.

Project description

PolicyEngine Core

codecov PyPI version Ruff

A fork of OpenFisca-Core that powers PolicyEngine country models (policyengine-uk, policyengine-us, policyengine-canada, policyengine-il, policyengine-ng) and the downstream apps and APIs. Provides the simulation engine, parameter tree, variable system, and reform machinery that each country package builds on top of.

Install

pip install policyengine-core

Supports Python 3.9 – 3.14.

Usage

Most users reach this package transitively through a country model. Import directly if you're building a new country model, writing a reform, or extending the core:

from policyengine_core.simulations import Simulation
from policyengine_core.reforms import Reform

See the documentation for API reference and tutorials.

Development

# Install dev dependencies (uses uv)
make install

# Run the full test suite
make test

# Run a single test
uv run pytest tests/core/test_file.py::test_name -v

# Format before committing (CI enforces)
make format

Always use uv run for Python commands; bare python / pytest / pip may pick up the wrong environment.

Contributions: see CONTRIBUTING.md for branching, PR conventions, and the towncrier changelog.d/ workflow. Default branch is master.

License

Distributed under the AGPL License. See LICENSE for details.

Acknowledgements

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

policyengine_core-3.25.1.tar.gz (464.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

policyengine_core-3.25.1-py3-none-any.whl (230.9 kB view details)

Uploaded Python 3

File details

Details for the file policyengine_core-3.25.1.tar.gz.

File metadata

  • Download URL: policyengine_core-3.25.1.tar.gz
  • Upload date:
  • Size: 464.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for policyengine_core-3.25.1.tar.gz
Algorithm Hash digest
SHA256 6ccb89469f30e6c02d57977aef1f5a2e2802c4c8f10b831529052fc8f1cb90a5
MD5 d094475774d59b75e1278f65f1374d5b
BLAKE2b-256 3766a858dcefd08d0146c12c5c1e28a7614ed1ed673c3a7bf8c342027d694368

See more details on using hashes here.

File details

Details for the file policyengine_core-3.25.1-py3-none-any.whl.

File metadata

File hashes

Hashes for policyengine_core-3.25.1-py3-none-any.whl
Algorithm Hash digest
SHA256 196f26e067c1893aba6bde44ae4d1ede799fb6c0823866200500adcf4459d254
MD5 a07cc3cc9bebaa3d45be89fb5567fcd9
BLAKE2b-256 4fcf4acec9277399ca9452bb66df796a07af90271355f7f8122fbc490603fed1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page