sonara-client
Talk to the Sonara text-to-speech runtime from Python 3.9+. Standard library only.
import sonara_client
with sonara_client.connect("my-app", runtime_path=r"C:\path\to\sonarad.exe") as sonara:
item = sonara.speak("Hello.", label="greeting")
sonara.set("rate", 240)
with sonara.subscribe(["state", "items"]) as events:
for e in events:
if e["event"] == "item" and e["item_id"] == item and e["phase"] != "started":
break
connect(client_name, *, runtime_path=None, home=None, autostart=True, require=(), extensions=(), keep_alive=False): finds the shared runtime throughruntime.json, starts the bundledsonarad.exewhen none is usable (runtime_path, defaultSONARA_RUNTIME), takes over an idle incompatible one.speak(text, mode=None, interrupt=None, label=None)returns the item id;control(action);set(key, value)/get(key);voices(engine=None).subscribe(events)opens an event stream on its own connection: iterate it, orread(timeout).channels,agent,system: extension namespaces that send the protocol's extension messages as they are.- Errors are
SonaraErrorwith acode. The client is thread-safe.
Guide: Bundle Sonara in your app. Tests: python -m pytest clients/python/tests -q (the end-to-end ones need cargo build -p sonarad).
MIT. Ship THIRD_PARTY_NOTICES.md with an app that bundles the runtime.
Metadata
Release files for sonara-client 0.21.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| sonara_client-0.21.7.tar.gz | 20.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| sonara_client-0.21.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 36.3 kB
Release files / sonara_client-0.21.7.tar.gz
| Download URL | sonara_client-0.21.7.tar.gz |
|---|---|
| Size | 20.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5ea0c351e600765bc73d9c9f14e6a1094a73c6e3d6ff56979f955eeaba7598f7
|
|
BLAKE2b-256 checksum How to use checksums |
3c189879eca8bf9a6baa254c43194dbc9c6d7f0145887b809f114150d0e44229
|
| 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 Oct 6, 2026.
Transparency logRelease files / sonara_client-0.21.7-py3-none-any.whl
| Download URL | sonara_client-0.21.7-py3-none-any.whl |
|---|---|
| Size | 16.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7a0f3376bbd19ca65cbf857ef1c8d88a5cc3b15eb83e1279249998ce6d2d006b
|
|
BLAKE2b-256 checksum How to use checksums |
9f7aa300ee1ec58765886c38dd5527faf43b6de99a95821a5f25866e6319069e
|
| 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 Oct 6, 2026.
Transparency log