npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

ipa-jfk

v0.4.0

Published

IPA narrow transcription of English words in New York City accent

Downloads

31

Readme

IPA-JFK

IPA narrow transcription of English words in New York City accent

Online Demo Website

Netlify Status

You can lookup words on our hassle-free Demo Website!

Prerequisites

  • Node.js
  • npm
  • Parcel (for demo and deployment usage)

Install CLI

# For cli or global usage:
npm i -g ipa-jfk

# For local usage:
npm i ipa-jfk

Local Demo

Additional instruction for Windows users: Remember to amend scripts.prepare and scripts.start fields in package.json prior to running:

"prepare": "node ./scripts/download.js"
...
"start": "node ./bin/jfk.js"

npm i
npm run demo
# A server will be running at http://localhost:1234

CLI Usage

jfk [--unicode|--html|--latex] [--phonemic] <word> [<phoneme>...]
  • Output format:
    • --unicode: (default) UTF-8 encoded IPA in unicode.
    • --html: HTML entities of IPA in unicode.
    • --latex: LaTeX script for the TIPA package.
  • --phonemic: Disable narrow transcription, only use broad one.
  • <word>: Which word to translate.
  • <phoneme>: The reference phonemes to use.

Library Usage

impotrt * as jfk from 'ipa-jfk';

// Cache the whole database to speed up future lookups
jfk.cacheDatabase();

// Get phonemes (it returns an array)
const [ph] = jfk.queryDatabase('<word>');
// Alternatively, you can supply your own phonemes.

// Get phonetics
// The third parameter is phonemic/phonetic switch.
const ir = jfk.process('<word>', ph, false);

// Output
console.log(jfk.unicode(ir));
console.log(jfk.html(ir));
console.log(jfk.latex(ir));

FAQ

  • How do you get these?

    Phonemes are retrived from The CMU Pronouncing Dictionary. Phonemes are translated into allophones using a fixed set of rules.

  • I don't understand the complex syntax!

    Go back and learn IPA. The real IPA, not simplified ones. Including diacritics.

  • I live in NYC and this is not my accent.

    You may open an issue here, but we are unlikely to change the rules.

  • Too few words available.

    You should blame CMU. Alternatively, use the reference phonemes in ARPAbet format.

  • Some phonemes are totally incorrect.

    Also blame CMU. You may want to override it by using reference phonemes.

  • Syllabification or /æ/-raising incorrect.

    You may want to override it by using hints (undocumented feature). See the source code.

License

This project is licensed under GNU AGPL v3.0 only. (AGPL-3.0-only).