skillfed

cmudict

A versioned python wrapper package for The CMU Pronouncing Dictionary data files.

cmudict v1.1.3 359.3K downloads/30d#7,251 on PyPI66
Copyleft license GPL-3.0-or-later Active released

What it is and what it does

cmudict is a thin Python wrapper around The CMU Pronouncing Dictionary, a linguistic dataset of English word pronunciations in phonetic notation. It bundles the dictionary data files and exposes them through a simple API with three access patterns per file: raw string, binary stream, or minimally-processed Python structures. The package maintains compatibility with NLTK's cmudict interface, making it a drop-in alternative for projects already using that corpus reader.

The main use case is looking up how words are pronounced or extracting phonetic information for speech synthesis, voice recognition, poetry analysis, or linguistic research. It requires Python 3.9+ and has minimal dependencies—only two standard-library backports—making it straightforward to install and integrate into existing projects.

Use it for:

  • Look up phonetic transcriptions of English words for speech synthesis or pronunciation guides.
  • Extract phone inventories and phonetic symbols for linguistic analysis or NLP feature engineering.
  • Build rhyming or alliteration detection tools by comparing phonetic representations.
  • Migrate from NLTK's cmudict reader to a standalone, versioned dictionary package.
  • Analyze poetry or song lyrics for phonetic patterns and stress patterns.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides Python access to the CMU Pronouncing Dictionary data files (phonetic transcriptions, phone inventories, and related linguistic data) with minimal processing and NLTK compatibility.

Yes, if you need English phonetic data. Low install friction, no security issues, active maintenance, and GPL-3.0-or-later licensing is straightforward for open-source projects. Not suitable for proprietary software without GPL compliance review. The NLTK compatibility makes it a practical choice for speech and linguistic work.

Install

cmudict on PyPI

pip

pip install cmudict

uv

uv add cmudict

poetry

poetry add cmudict

Installing cmudict

Before you install

Low friction: pure Python wheel with only two standard-library backport dependencies (importlib-metadata, importlib-resources). Actively maintained with recent commits and stable production status.

License in practice

GPL-3.0-or-later (copyleft): any derivative work or software that links this package must be distributed under the same or compatible GPL license; proprietary or closed-source projects cannot use it without legal review.

Quickstart

pip install cmudict

import cmudict

# Access phonetic dictionary (NLTK-compatible)
dict_data = cmudict.dict()

# Or get raw string contents
dict_str = cmudict.dict_string()

Requires Python 3.9 or later (supports up to 3.14).

Verify before relying

  • Size and memory footprint of the bundled CMU dictionary data files when loaded into memory.
  • Performance characteristics when querying large phonetic datasets or iterating over all entries.

Package facts

License GPL-3.0-or-later (copyleft)
Python support supports the current Python release (<4.0,>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 2 — importlib-metadata, importlib-resources
Maintenance actively maintained — 223 days since the last release
Last repo commit
First released
Downloads 359,284/month — #7,251 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: cmudict-1.1.3-py3-none-any.whl

Keywords: cmudict

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)Operating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.9Topic :: Software Development :: Libraries :: Python ModulesTopic :: Text Processing :: Linguistic

Tags

cmu pronouncing dictionary pythonphonetic transcription lookupword pronunciation datalinguistic dictionary apicmudict wrappernltk cmudict compatible
phoneticslinguisticsnlp

More Python Modules packages