Skip to main content

Language detection module based on the GiellaLT models, specifically aimed at minority and indigenous languages

Project description

Makes the language classification script from the GiellaLT's corpus tools available as a python module (GiellaLT's website, original repo).

The source code as well as the language model files are released under the GPL-3.0 license.

Installation

pip install gielladetect

Usage

import gielladetect

text = "Lurer du på hva som rører seg innenfor veggene til Nasjonalbiblioteket på Solli plass i Oslo?"

gielladetect.detect(text)
# Result: 'nob'

# To restrict detection to a subset of languages:
gielladetect.detect(text, ['nob', 'nno', 'eng'])
# Result: 'nob'

Supported languages

Using ISO 639-3 codes.

Code Name
ara Arabic
bxr Russia Buriat
ckb Central Kurdish
dan Danish
deu German
eng English
est Estonian
fao Faroese
fas Persian
fin Finnish
fit Tornedalen Finnish
fkv Kven Finnish
fra French
hbs Serbo-Croatian
isl Icelandic
ita Italian
kal Kalaallisut
kmr Northern Kurdish
koi Komi-Permyak
kpv Komi-Zyrian
krl Karelian
mdf Moksha
mhr Eastern Mari
mns Mansi
mrj Western Mari
myv Erzya
nno Norwegian Nynorsk
nob Norwegian Bokmål
olo Livvi
pol Polish
rmf Kalo Finnish Romani
rmn Balkan Romani
rmu Tavringer Romani
rmy Vlax Romani
ron Romanian
rus Russian
sma Southern Sami
sme Northern Sami
smj Lule Sami
smn Inari Sami
sms Skolt Sami
som Somali
spa Spanish
swe Swedish
tur Turkish
udm Udmurt
urd Urdu
vep Veps
vie Vietnamese
yid Yiddish
yrk Nenets

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gielladetect-1.0.3.tar.gz (3.9 MB view details)

Uploaded Source

Built Distribution

gielladetect-1.0.3-py3-none-any.whl (4.0 MB view details)

Uploaded Python 3

File details

Details for the file gielladetect-1.0.3.tar.gz.

File metadata

  • Download URL: gielladetect-1.0.3.tar.gz
  • Upload date:
  • Size: 3.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0rc1

File hashes

Hashes for gielladetect-1.0.3.tar.gz
Algorithm Hash digest
SHA256 99672c0da7a31c63d01315d41ad32087d89754388dfaa67e25ca0ffc1120bdc7
MD5 fe017b6cbdff65f746099dba54a8811f
BLAKE2b-256 45a49d8b2f41f499d4ea816f3e2c2666a491f822a37380bf67ed8aee32fa9154

See more details on using hashes here.

File details

Details for the file gielladetect-1.0.3-py3-none-any.whl.

File metadata

  • Download URL: gielladetect-1.0.3-py3-none-any.whl
  • Upload date:
  • Size: 4.0 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0rc1

File hashes

Hashes for gielladetect-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 773550191ff473cb2aa613e275bada91092b12318b6b397b32dad910f73b0c0e
MD5 bfe5058f749f39e64b21150d39378c20
BLAKE2b-256 0a667521a51e291b10d75bd81c1b471735c8830f985a8c5b3710176e3612c3dc

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page