Skip to main content

Zebra Binding for Python

Zebra Translate

Made in Vancouver, Canada by Picovoice

Zebra is a lightweight, on-device neural machine translation engine. Zebra is:

  • Private; All processing runs locally.
  • Cross-Platform:
    • Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64, arm64)
    • Raspberry Pi (3, 4, 5)

Compatibility

  • Python 3.9+
  • Runs on Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64, arm64), and Raspberry Pi (3, 4, 5).

Installation

pip3 install pvzebra

AccessKey

Zebra requires a valid Picovoice AccessKey at initialization. AccessKey acts as your credentials when using Zebra SDKs. You can get your AccessKey for free. Make sure to keep your AccessKey secret. Signup or Login to Picovoice Console to get your AccessKey.

Usage

Create an instance of the engine and translate some text:

import pvzebra

handle = pvzebra.create(access_key='${ACCESS_KEY}', model_path='${MODEL_PATH}')

translation = handle.translate('${TEXT}')
print(translation)

Replace ${ACCESS_KEY} with yours obtained from Picovoice Console, ${MODEL_PATH} with a supported translation model located here and ${TEXT} with the text to translate. Finally, when done be sure to explicitly release the resources using handle.delete().

Translation Models

Zebra translation models are located here. The selected model decides the source and target translation languages.

The format of the model follows:

zebra_params_${SOURCE}_${TARGET}.pv

Where ${SOURCE} is the language code of the source language and ${TARGET} is the language code of the target language for the translation.

Demos

pvzebrademo provides command-line utilities for translating text using Zebra.

Metadata

Release files for pvzebra 1.1.0

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

Source distribution (sdist)

Source distribution for pvzebra 1.1.0
File Size Uploaded Provenance
pvzebra-1.1.0.tar.gz 12.9 MB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for pvzebra 1.1.0
File Interpreter ABI Platform
pvzebra-1.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 25.9 MB

Release files / pvzebra-1.1.0.tar.gz

Download URL pvzebra-1.1.0.tar.gz
Size 12.9 MB
Tags Source
SHA-256 checksum
How to use checksums
3265048e76362cf31db7c34731deff44e483d04b94cf07c9022ac351b1b437c3
BLAKE2b-256 checksum
How to use checksums
43f154f232d3a9cacb25f8671618a13f2789ba797561e1acef53660d36b970d5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release files / pvzebra-1.1.0-py3-none-any.whl

Download URL pvzebra-1.1.0-py3-none-any.whl
Size 13.0 MB
Tags Python 3
SHA-256 checksum
How to use checksums
5e899218024676610dadec7d60e42b9e66422449a93fe8d04b9308e447b86a2f
BLAKE2b-256 checksum
How to use checksums
c2afee448928c99b8a31f151c605fb68192f7d0e5790c4ba5e14562c09123232
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Security for pvzebra 1.1.0

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

Release history Release notifications | RSS feed

This release

1.1.0 This release

2 release files No provenance

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