Socket
Socket
Sign inDemoInstall

cmu-pronouncing-dictionary

Package Overview
Dependencies
0
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    cmu-pronouncing-dictionary

All the 134,000+ words in the CMU pronouncing dictionary as a simple JSON object


Version published
Maintainers
1
Install size
4.44 MB
Created

Readme

Source

cmu-pronouncing-dictionary

All the 134,000+ words in the CMU pronouncing dictionary as a simple JSON object

The CMU Pronouncing Dictionary (also known as cmudict) is a public domain pronouncing dictionary created by Carnegie Mellon University (CMU). It defines a mapping from English words to their North American pronunciations, and is commonly used in speech processing applications

There are a handful of npm modules for working with the CMU pronouncing dictionary, but none so simple as this one. Unlike the alternatives, this module simple exports an object containing words as keys and their Arpabet transcriptions as values. Here's a sample:

{
  "allergen": "AE1 L ER0 JH AH0 N",
  "allergens": "AE1 L ER0 JH AH0 N Z",
  "allergic": "AH0 L ER1 JH IH0 K",
  "allergies": "AE1 L ER0 JH IY0 Z",
  "allergist": "AE1 L ER0 JH AH0 S T",
  "allergist's": "AE1 L ER0 JH AH0 S T S",
  "allergist's(1)": "AE1 L ER0 JH AH0 S",
  "allergists": "AE1 L ER0 JH AH0 S T S",
  "allergists(1)": "AE1 L ER0 JH AH0 S",
  "allergy": "AE1 L ER0 JH IY0",
  "allers": "AO1 L ER0 Z",
  "allert": "AE1 L ER0 T",
  "allerton": "AE1 L ER0 T AH0 N",
  "alles": "EY1 L Z",
  "alleva": "AA0 L EY1 V AH0",
  "alleviate": "AH0 L IY1 V IY0 EY2 T",
  "alleviated": "AH0 L IY1 V IY0 EY2 T IH0 D",
  "alleviates": "AH0 L IY1 V IY0 EY0 T S",
  "alleviating": "AH0 L IY1 V IY0 EY2 T IH0 NG"
}

Installation

Download node at nodejs.org and install it, if you haven't already.

npm install cmu-pronouncing-dictionary --save

Usage

const words = require('cmu-pronouncing-dictionary')

words.length
// => 133779

words.phenomenon
// => 'F AH0 N AA1 M AH0 N AA2 N'
words.zygote
// => 'Z AY1 G OW0 T'

Tests

npm install
npm test

Dependencies

None

Dev Dependencies

  • code: assertion library
  • mocha: simple, flexible, fun test framework
  • standard: JavaScript Standard Style

License

ISC

Generated by package-json-to-readme

Keywords

FAQs

Last updated on 02 Sep 2015

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc