Repository navigation
Add Python bindings and PyPI wheels - #28
Merged
Merged
Conversation
The online feature now uses hf-hub's ureq client with ureq's default rustls, so builds no longer link the system OpenSSL. Python wheels then need no libssl bundled, and reqwest and tokio drop out of the tree.
The scriptrs package wraps the long-form pipeline with PyO3: one abi3 wheel per platform, Core ML on macOS arm64 and CUDA on Linux x86_64, with cuBLAS from the nvidia-cublas-cu12 wheel. Models are picked at load time as "parakeet/v2" (the default, as in the crate) or "parakeet/v3", so later model families fit the same naming. It also adds a scriptrs command line, pytest suite, and a workflow that builds wheels and the sdist, tests them, and publishes tags to TestPyPI and then PyPI through trusted publishing. The long-form pipeline exposes its base pipeline and config so transcribe_many can queue short clips on the already loaded model.
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 9 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
The published v3 encoder has no metadata.json, so every v3 Core ML download failed with a 404. Core ML never reads the file, so it is no longer part of the download list.
# Conflicts: # justfile
scriptrs moved to 0.4.0, and release tags carry its version, so the bindings follow. The sdist job now fails a pull request whose bindings version differs from the crate's, instead of the mismatch surfacing only when a tag is published.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a
scriptrsPython package. It is built with PyO3 and maturin as one abi3 wheel per platform: Core ML on macOS arm64, and CUDA on Linux x86_64 (manylinux_2_28). The CUDA wheel gets cuBLAS from thenvidia-cublas-cu12wheel."<family>/<version>"so other model families can be added later. The default isparakeet/v2, the same as the Rust crate.scriptrs.Model.PARAKEET_V2andscriptrs.Model.PARAKEET_V3also work, and so do NVIDIA's ids (nvidia/parakeet-tdt-0.6b-v3).transcribe,transcribe_file, andtranscribe_manyrelease the GIL.transcribe_manyruns short clips through the batching queue on the model that is already loaded.scriptrs transcribecommand prints the bare transcript for one file. For several files it prints a==> file <==header before each transcript, likehead.--jsonprints one object per file.python.ymlbuilds the wheels and the sdist, then tests them. On a tag it publishes to TestPyPI, installs from there, and then publishes to PyPI through trusted publishing.Before the first release, trusted publishers for
scriptrsmust be set up on PyPI and TestPyPI, usingpython.ymlwith the environmentspypiandtestpypi.metadata.json. The published v3 encoder has none, so everyparakeet/v3Core ML download got a 404. Core ML never reads the file.Tested on Linux with an RTX 5090 and on an M-series Mac mini from an empty model cache. On each machine, 19 tests passed and 1 was skipped (the Linux no-driver check), across both models. The wheels are 3.7 MB on Linux and 2.6 MB on macOS, and the Linux wheel bundles no libssl.