Skip to main content

lingolix

Python client for the Lingolix pronunciation scoring API. Send a recording, get back per-syllable accuracy with expected vs. detected IPA, pitch and timing — in 21 languages.

Get an API key at lingolix.com/api-portal, then set LINGOLIX_API_KEY in your environment. Keep it server-side — never ship it to a browser.

Install

pip install lingolix      # or: uv add lingolix

Usage

from lingolix import Lingolix

with Lingolix() as client:                       # key from $LINGOLIX_API_KEY
    r = client.check("audio.wav", sentence="Guten Morgen", language="de")

    print(r.overall, r.accuracy, r.fluency, r.speaking_rate)
    for word in r.words:
        for s in word.syllables:
            print(s.text, s.expected_ipa, "→", s.detected_ipa, s.pitch, round(s.accuracy, 2))

Async is the same class with an Async prefix:

from lingolix import AsyncLingolix

async with AsyncLingolix() as client:
    r = await client.check(audio_bytes, sentence="こんにちは", language="ja")

check() takes a path, bytes, or any file-like object. Drop sentence and the audio is transcribed first, then scored against its own transcription — useful for free-form speech.

Result shape

Field Meaning
text What the audio was scored against — your sentence, or the transcription
overall The score to show, 0–1: accuracy and fluency weighted as human raters weigh them
accuracy How well the sounds were pronounced, 0–1
fluency Pace and pauses, 0–1; None/null when the utterance is too short to time (then overall = accuracy)
completeness How much of the expected utterance was actually said, 0–1
speaking_rate Syllables (Japanese: morae) per second
target_speaking_rate Pace from which fluency gets full credit (60% of a typical native pace)
model_version Which model and scoring produced the numbers, e.g. "2026-11"; changes when an update shifts scores
words[] text, accuracy, completeness, start_ms, end_ms, char_start, char_end, hesitation_ms (pause before or inside the word, else None/null), is_error (mark the word wrong; same as accuracy < 0.7)
words[].syllables[] text, expected_ipa, detected_ipa, accuracy, completeness, pitch, duration_ms, start_ms, end_ms, is_missing, is_extra

pitch is one of "high", "flat", "low", "unknown".

Errors

Every failure is a subclass of LingolixError carrying .status and .detail.

Class HTTP Cause
InvalidAudioError 400, 413 Undecodable audio, or over the 10 MiB limit
AuthenticationError 401 Missing, malformed or unknown API key
SubscriptionError 403 No active API subscription
QuotaExceededError 429 Monthly quota exhausted
ServiceUnavailableError 503 Scoring service temporarily down

QuotaExceededError also carries plan, remaining_minutes, quota_percentage and upgrade_url:

from lingolix import Lingolix, QuotaExceededError

try:
    r = Lingolix().check("audio.wav", language="en")
except QuotaExceededError as e:
    print(f"{e.plan} plan is out of minutes — upgrade at {e.upgrade_url}")

Languages

bg cs da de el en es fi fr hu it ja ko nb nl pl pt ru sv tr uk — the default is ja.

Audio

Anything ffmpeg can read: WAV, MP3, M4A, OGG/Opus, FLAC, WebM. Uploads are capped at 10 MiB, checked client-side before sending. Prefer a compressed format — a single utterance is well under 1 MiB as MP3 or Opus.

MIT licensed.

Metadata

Release files for lingolix 0.3.1

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

Source distribution (sdist)

Source distribution for lingolix 0.3.1
File Size Uploaded Provenance Actions
lingolix-0.3.1.tar.gz 8.7 kB With provenance Details for lingolix-0.3.1.tar.gz

Built distribution (wheel)

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

Total release size: 16.4 kB

Release files / lingolix-0.3.1.tar.gz

Download URL lingolix-0.3.1.tar.gz
Size 8.7 kB
Tags Source
SHA-256 checksum
How to use checksums
b453d8ba52c6d97eee2975c4baf8fd106f7fc65d6ca0f11060fba3242a3babf4
BLAKE2b-256 checksum
How to use checksums
c87b6975b4fcbb24305bde85f46dc6dc082ad6eefb04d37336866b77bd0eebc4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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

Transparency log

Release files / lingolix-0.3.1-py3-none-any.whl

Download URL lingolix-0.3.1-py3-none-any.whl
Size 7.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e25069d8f5434b4a6c5bd5cba2fc883a9de8b33bfe83dd587a240aa613817b1b
BLAKE2b-256 checksum
How to use checksums
a6f5c0c657ceecf457fa2cc6eb72b6d59aa4af95e856b8071cb5287d341fe83c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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

Transparency log

Security for lingolix 0.3.1

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 lingolix-0.3.1.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 15, 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