Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Guppy

pypi codecov py-version

Guppy is a quantum programming language that is fully embedded into Python. It allows you to write high-level hybrid quantum programs with classical control flow and mid-circuit measurements using Pythonic syntax:

from guppylang import guppy
from guppylang.std.builtins import owned
from guppylang.std.quantum import cx, h, measure, qubit, x, z


@guppy
def teleport(src: qubit @ owned, tgt: qubit) -> None:
    """Teleports the state in `src` to `tgt`."""
    # Create ancilla and entangle it with src and tgt
    tmp = qubit()
    h(tmp)
    cx(tmp, tgt)
    cx(src, tmp)

    # Apply classical corrections
    h(src)
    if measure(src):
        z(tgt)
    if measure(tmp):
        x(tgt)

teleport.check()

Documentation

🌐 Guppy website

📖 Language guide

📒 Example notebooks

Install

Guppy can be installed via pip. Requires Python >= 3.10.

pip install guppylang

Development

See DEVELOPMENT.md for instructions on setting up the development environment.

Attribution

If you use this software, please cite it using CITATIONS.bib or CITATION.cff (click "Cite this repository" in the About section of the repository landing page).

License

This project is licensed under Apache License, Version 2.0 (LICENCE or http://www.apache.org/licenses/LICENSE-2.0).

Download files

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

Source Distribution

guppylang-1.0.0rc2.tar.gz (84.9 kB view details)

Uploaded Source

Built Distribution

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

guppylang-1.0.0rc2-py3-none-any.whl (84.5 kB view details)

Uploaded Python 3

File details

Details for the file guppylang-1.0.0rc2.tar.gz.

File metadata

  • Download URL: guppylang-1.0.0rc2.tar.gz
  • Upload date:
  • Size: 84.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for guppylang-1.0.0rc2.tar.gz
Algorithm Hash digest
SHA256 91d900e3a6a96066d1d8df7d07e7bb553e823780d529c85300abb29253c61cd6
MD5 19e8b21b11d7bb0694b365581e0b2caa
BLAKE2b-256 a15f150d904319a36440b53aea86bf7df81f13664dceeb6e8e9685d12c25e294

See more details on using hashes here.

Provenance

The following attestation bundles were made for guppylang-1.0.0rc2.tar.gz:

Publisher: python-wheels.yml on Quantinuum/guppylang

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

File details

Details for the file guppylang-1.0.0rc2-py3-none-any.whl.

File metadata

  • Download URL: guppylang-1.0.0rc2-py3-none-any.whl
  • Upload date:
  • Size: 84.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for guppylang-1.0.0rc2-py3-none-any.whl
Algorithm Hash digest
SHA256 6614ab028e996734cd614da7dd6aada2b761670c88ed93aaef2d13123a70880a
MD5 aa1b07becf84981e7c33980e822277cd
BLAKE2b-256 d96354ca5dbbe0f98b2912354e40d525f70a44b28719ba74d5071d6dd1b32a1f

See more details on using hashes here.

Provenance

The following attestation bundles were made for guppylang-1.0.0rc2-py3-none-any.whl:

Publisher: python-wheels.yml on Quantinuum/guppylang

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

Release history Release notifications | RSS feed

1.0.1

2 files

1.0.0

2 files

This release

1.0.0rc2 This release

2 files

0.21.16

2 files

0.21.15

2 files

0.21.14

2 files

0.21.13

2 files

0.21.12

2 files

0.21.11

2 files

0.21.10

2 files

0.21.9

2 files

0.21.8

2 files

0.21.7

2 files

0.21.6

2 files

0.21.5

2 files

0.21.4

2 files

0.21.3

2 files

0.21.2

2 files

0.21.1

2 files

0.21.0

2 files

0.20.0

2 files

0.19.1

2 files

0.19.0

2 files

0.18.2

2 files

0.18.1

2 files

0.18.0

2 files

0.17.1

2 files

0.17.0

2 files

0.16.0

2 files

0.15.0

2 files

0.14.0

2 files

0.13.1

2 files

0.13.0

2 files

0.12.2

2 files

0.12.1

2 files

0.12.0

2 files

0.11.0

2 files

0.10.0

2 files

0.9.0

2 files

0.8.1

2 files

0.8.0

2 files

0.7.0

2 files

0.6.2

2 files

0.6.1

2 files

0.6.0

2 files

0.5.2

2 files

0.5.1

2 files

0.5.0

2 files

0.4.0

2 files

0.3.0

2 files

0.2.0

2 files

0.1.0

2 files

Supported by

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