#phonetic #linguistics #speech #spelling #nlp #command-line

app lngcnv

linguistics: display pronunciation, translate between dialects, convert between orthographies; support for multiple languages: English, Latin, Polish, Quechua, Spanish, Tikuna

25 stable releases

new 1.9.0 Apr 10, 2024
1.8.12 Aug 2, 2023
1.8.11 Jul 9, 2023
1.8.7 Mar 24, 2023
1.3.0 Feb 14, 2022

#29 in Text processing

Download history 20/week @ 2024-02-23 18/week @ 2024-03-01 6/week @ 2024-03-08 2/week @ 2024-03-15 9/week @ 2024-03-29 118/week @ 2024-04-05

130 downloads per month

MIT license

630KB
13K SLoC

INTRODUCING LNGCNV

lngcnv-logo

The acronym 'lngcnv' may signify e.g., a 'language converter', a 'linguistic converter', or a 'lenguaje convertido' (Spanish for 'converted language').

lngcnv is capable of presenting the precise pronunciation of a phrase using the International Phonetic Alphabet (IPA). It can also translate between various dialects of a language and convert between different orthographic norms.

The program can accept input in the form of a word or text either directly through the command line or by being included in a file, such as a lengthy book. There is also a REPL (read-eval-print loop) mode available for interactive use.

Six modern and ancient languages, including a range of dialects, are currently supported.

The program's source code and linguistic algorithms were created entirely from scratch and are distributed under the MIT License. lngcnv is written in Rust for high performance, code correctness, and ease of long-term development.

To display the International Phonetic Alphabet (IPA) characters accurately, it is recommended to use one of the following fonts: Charis SIL, Doulos SIL, or Gentium Plus. When showing IPA characters in the terminal, it is best to use the Unicode font Noto Sans Mono.

[keywords: foreign languages, language learning app, natural language processing]

SUPPORTED LANGUAGES

1. ENGLISH: pronunciation and orthography

– Pronunciation of American English (Dallas, TX)

– Pronunciation of Australian English (Canberra, ACT)

– Transcribe using the spelling of American English

2. LATIN: pronunciation and orthography

– Reconstructed pronunciation of Classical Latin

– Transcribe using the ancient orthographic convention (pre-2nd century AD)

3. POLISH: three variants of pronunciation

– Pronunciation from Częstochowa, Małopolska Region

– Pronunciation from Toruń, Wielkopolska Region

– Pronunciation from Warszawa, Mazowsze Region

4. QUECHUA: pronunciation, dialect translation and orthography

– Pronunciation of Chanka/ Ayacucho Quechua (Wanta, PE)

– Translate from other Southern Quechua varieties into Ayacucho Quechua

– Transcribe between the trivocalic and pentavocalic orthographies

5. SPANISH: fifteen variants of pronunciation

– Pronunciation of Colombian Spanish (Arauca; Bogotá; Bucaramanga; Cali; Leticia; Medellín; Neiva; Pasto; Quibdó; Santa Marta)

– Pronunciation of Mexican Spanish (Ciudad de México)

– Pronunciation of Spanish of Spain (Bilbao; Cádiz; Madrid)

– Pronunciation of Uruguayan Spanish (Montevideo)

6. TIKUNA/ TICUNA: pronunciation and orthography

– Five variants of pronunciation (Río Cotuhé, CO; Cushillococha, PE; Nazareth, CO; Umariaçu, BR; Vila Betânia, BR)

– Four distinct orthographies (Brazil; Colombia; Peru–ILV; Peru–FORMABIAP)

USAGE

help-image

INSTALLATION ON LINUX

The current version of lngcnv (v1.9.0) has been verified to work properly on Fedora Linux 40.

METHOD 1 – USING CARGO

[Recommended for programmers]

1. To install lngcnv from crates.io, use the following cargo command:

cargo install lngcnv

The executable will be saved in the hidden .cargo/bin/ directory within your home directory.

2a. For easy access, you may want to copy the lngcnv file to either the /usr/bin/ or the ~/.local/bin/ directory. This can be done by following the instructions in Method 3 (3a, 3b, 3c).

2b. As an alternative, you can add the ~/.cargo/bin/ directory to your system's PATH variable, which can be configured using rustup.

METHOD 2 – SNAP INSTALLATION

The software can be obtained through the Snap Store and installed with just one command:

sudo snap install lngcnv

METHOD 3 – UNIVERSAL LINUX BINARIES

1. To install lngcnv, first download the distro-independent binary from GitHub.

2. Then, make the file executable by running the command:

sudo chmod +x ./lngcnv

3a. On most Linux distributions, install lngcnv by copying the binary to /usr/bin/:

sudo cp lngcnv /usr/bin/

3b. For Fedora Silverblue / Kinoite, use this command:

sudo cp lngcnv /var/usrlocal/bin/

3c. As an alternative, consider installing locally in the ~/.local/bin/ directory:

cp lngcnv $HOME/.local/bin/

METHOD 4 – DISTRO-SPECIFIC PACKAGES

[Recommended for most users]

Distro-specific packages for .rpm and .deb-based Linux distributions are also available for download. To install lngcnv on different Linux distributions, follow these instructions:

Fedora Linux / RHEL / openSUSE:

sudo rpm -i lngcnv-1.9.0-1.x86_64.rpm

Fedora Silverblue / Kinoite:

rpm-ostree install lngcnv-1.9.0-1.x86_64.rpm

Ubuntu:

sudo dpkg -i lngcnv_1.9.0-1_amd64.deb

METHOD 5 – MANUAL COMPILATION

First, download and unpack the lngcnv source code from GitHub. Next, to build and install the program, use the command:

cargo build --release && sudo cp target/release/lngcnv /usr/bin/

No runtime deps