Skip to main content

Woxi for Python

Python bindings for Woxi, an interpreter for a subset of the Wolfram Language implemented in Rust. Woxi is a computer algebra system (CAS), so computations are solved symbolically.

pip install woxi

Python API

import woxi

woxi.interpret("Plus[1, 2]")
# => '3'

woxi.interpret("Integrate[x^2, x]")
# => 'x^3/3'

# Session state persists across calls (per thread):
woxi.interpret("x = 42;")
woxi.interpret("x + 1")
# => '43'
woxi.clear_state()

# Capture stdout, graphics, sound, and warnings:
res = woxi.evaluate('Print["hi"]; Plot[Sin[x], {x, 0, 10}]')
res.stdout    # => 'hi\n'
res.graphics  # => '<svg …'  (SVG markup)

# Reproducible random numbers:
woxi.seed_rng(1)

# Errors raise woxi.WolframError:
try:
    woxi.interpret("1 +")
except woxi.WolframError as err:
    print(err)

Command line

The package also installs a woxi command:

woxi eval 'Plus[1, 2]'     # Evaluate an expression
woxi run script.wls        # Run a Wolfram Language file
woxi repl                  # Interactive session

For the full-featured native CLI (including the Jupyter kernel), install the Rust binary instead: cargo install woxi.

Building from source

The package is built with maturin and requires a Rust toolchain:

cd woxi-py
pip install maturin
maturin develop  # Build and install into the active virtualenv

Run the tests with:

python -m pytest tests/

License

AGPL-3.0-or-later

Download files

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

Source Distribution

woxi-0.2.0.tar.gz (4.0 MB view details)

Uploaded Source

Built Distributions

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

woxi-0.2.0-cp310-abi3-win_amd64.whl (24.7 MB view details)

Uploaded CPython 3.10+Windows x86-64

woxi-0.2.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (22.9 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ x86-64

woxi-0.2.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (23.3 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ARM64

woxi-0.2.0-cp310-abi3-macosx_11_0_arm64.whl (22.6 MB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

woxi-0.2.0-cp310-abi3-macosx_10_12_x86_64.whl (22.7 MB view details)

Uploaded CPython 3.10+macOS 10.12+ x86-64

File details

Details for the file woxi-0.2.0.tar.gz.

File metadata

  • Download URL: woxi-0.2.0.tar.gz
  • Upload date:
  • Size: 4.0 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for woxi-0.2.0.tar.gz
Algorithm Hash digest
SHA256 ecf7c25b0bfd7cc2f86deb0c69b4ac57f6fa2fd9dffab22e9757aa91251907ef
MD5 9075d190e0f1f6c7eb8145c6f8077547
BLAKE2b-256 37edb29c82b99c509c047ed3af2c14c14c1cfabc5e74f5c947b8635aa39fc0d0

See more details on using hashes here.

Provenance

The following attestation bundles were made for woxi-0.2.0.tar.gz:

Publisher: publish-pypi.yml on ad-si/Woxi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file woxi-0.2.0-cp310-abi3-win_amd64.whl.

File metadata

  • Download URL: woxi-0.2.0-cp310-abi3-win_amd64.whl
  • Upload date:
  • Size: 24.7 MB
  • Tags: CPython 3.10+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for woxi-0.2.0-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 38a88696bbaed3a752ed65f66f444b47399d0a143df35a22addfee38d983c2ef
MD5 b91c940e34661810ac10461b8cf8d736
BLAKE2b-256 1bd58cf5a77c69d5dd214ac92357e3bac5005057e607af265c06597e9ad9f1a8

See more details on using hashes here.

Provenance

The following attestation bundles were made for woxi-0.2.0-cp310-abi3-win_amd64.whl:

Publisher: publish-pypi.yml on ad-si/Woxi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file woxi-0.2.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for woxi-0.2.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3e66983b70e40bd2751d3343dd092d5299f794135401692e4a68811b9a19ae7e
MD5 83a12937892d70b745d99f8329f08c32
BLAKE2b-256 44a9ed7f08a4ca6c1c10a097b7ecc2bf54805c2122d6e7a22fbcdfbdaa6f56cd

See more details on using hashes here.

Provenance

The following attestation bundles were made for woxi-0.2.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish-pypi.yml on ad-si/Woxi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file woxi-0.2.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for woxi-0.2.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 1547c56534af38d7c6074fcb501bb3ee65b3b84f25d2858c1d951554ee1bc145
MD5 39ec196e899cead02e5c3ccf419ea8db
BLAKE2b-256 2c126a8fded756a76da025b27be183cb47697e0ec0876c2f0a66a1759225b2fd

See more details on using hashes here.

Provenance

The following attestation bundles were made for woxi-0.2.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: publish-pypi.yml on ad-si/Woxi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file woxi-0.2.0-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

  • Download URL: woxi-0.2.0-cp310-abi3-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 22.6 MB
  • Tags: CPython 3.10+, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for woxi-0.2.0-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f6d9af42fdd377edac1a154c86496adcba4838be1742ee6a4e82ddba7526ac70
MD5 10816c89ea7d28dc93e5187fdae4acad
BLAKE2b-256 b759818d58413fcc4e56f7fb9b2e92434d20660ea12ced106ea047d981533966

See more details on using hashes here.

Provenance

The following attestation bundles were made for woxi-0.2.0-cp310-abi3-macosx_11_0_arm64.whl:

Publisher: publish-pypi.yml on ad-si/Woxi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file woxi-0.2.0-cp310-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for woxi-0.2.0-cp310-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 128221f22930f8910b965a8f5965aec76ecd5d20481c217d8a2706ba01166388
MD5 c7eca591dd44383d3cc9bb84f4bd4f57
BLAKE2b-256 4cb966c3e65a4ec7e3066256e494332704640259181b938369676ebba4287c11

See more details on using hashes here.

Provenance

The following attestation bundles were made for woxi-0.2.0-cp310-abi3-macosx_10_12_x86_64.whl:

Publisher: publish-pypi.yml on ad-si/Woxi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.3.0

6 files

This release

0.2.0 This release

6 files

0.1.0

6 files

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