Skip to main content
Pre-release

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

pyrefly-torch-stubs

PyTorch type stubs with tensor shape information for Pyrefly.

This package installs torch-shape-stubs, a Pyrefly-specific stub package for runtime torch. Pyrefly discovers it by default; set use-shape-comments-and-stubs = false to opt out. Other type checkers ignore these stubs and continue using PyTorch's ordinary types.

The package is versioned in lockstep with Pyrefly and depends on the matching pyrefly-shape-extensions package. Installing it also installs torch, which provides upstream modules used by these partial stubs. The torch dependency is unpinned, so projects can choose their own PyTorch version.

Static checks use the installed Torch package for modules that this package intentionally leaves unshaped:

python3 tensor-shapes/pyrefly-torch-stubs/run_pyrefly.py

The runner uses ~/.tensor-shapes-venv by default. Set $TENSOR_SHAPES_VENV to select another virtualenv, or pass --python with an interpreter from a virtualenv that has Torch installed.

Metadata

Release files for pyrefly-torch-stubs 1.6.0.dev1

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

Source distribution (sdist)

Source distribution for pyrefly-torch-stubs 1.6.0.dev1
File Size Uploaded Provenance Actions
pyrefly_torch_stubs-1.6.0.dev1.tar.gz 71.7 kB With provenance Details for pyrefly_torch_stubs-1.6.0.dev1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pyrefly-torch-stubs 1.6.0.dev1
File Interpreter ABI Platform Actions
pyrefly_torch_stubs-1.6.0.dev1-py3-none-any.whl Python 3 none any Details for pyrefly_torch_stubs-1.6.0.dev1-py3-none-any.whl

Total release size: 153.3 kB

Release files / pyrefly_torch_stubs-1.6.0.dev1.tar.gz

Download URL pyrefly_torch_stubs-1.6.0.dev1.tar.gz
Size 71.7 kB
Tags Source
SHA-256 checksum
How to use checksums
ae34b55d06a4cdc902d979fcf380b6228bce5126116ea8e4dd572a08d9481239
BLAKE2b-256 checksum
How to use checksums
63876363f7a2726255ce82eaa70e4b119ec8dcd5105ddd35cebc184b833270a7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 21, 2026.

Transparency log

Release files / pyrefly_torch_stubs-1.6.0.dev1-py3-none-any.whl

Download URL pyrefly_torch_stubs-1.6.0.dev1-py3-none-any.whl
Size 81.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
66e47376367223b5788c950dcc5c961aeb8301b5d7e0862b986a4adc60a12d31
BLAKE2b-256 checksum
How to use checksums
5427a4e7a64c4ae1db7fd7b9a602c8dba094f5e70a893fc2ce1ef33c583ef499
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 21, 2026.

Transparency log

Security for pyrefly-torch-stubs 1.6.0.dev1

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 pyrefly_torch_stubs-1.6.0.dev1.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 21, 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