Detect language and country from text
Project description
lang2country
A Python package to detect language and country from text.
Installation
Install using pip:
pip install lang2country
Usage
1️⃣ Detect Language
from lang2country import detect_language
lang = detect_language("Hello my name is lang2country")
print(lang)
# Output: en
2️⃣ Detect Country
from lang2country import detect_country
country = detect_country("Hello my name is lang2country")
print(country)
# Output: United States
Dependency
This package uses:
python >=3.8
langdetect >=1.0.9
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
lang2country-1.0.0.tar.gz
(1.8 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file lang2country-1.0.0.tar.gz.
File metadata
- Download URL: lang2country-1.0.0.tar.gz
- Upload date:
- Size: 1.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.4.1 CPython/3.13.12 Windows/11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7d1a106112bacaf8f334f911782cf4c1d8443490e11a2f38bf98967eb7fed169
|
|
| MD5 |
7a11db879eea957522b828eea2bd3ddc
|
|
| BLAKE2b-256 |
6e955cac8276df8ad561d39872575bff13ae1da4547bd1788a8683a2d18faa40
|
File details
Details for the file lang2country-1.0.0-py3-none-any.whl.
File metadata
- Download URL: lang2country-1.0.0-py3-none-any.whl
- Upload date:
- Size: 2.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.4.1 CPython/3.13.12 Windows/11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
014b7cca94a48b4ef531d61ee4eef76c3c8829a75a2bcd3b1d2f9b15d7964eff
|
|
| MD5 |
c1bf515e2fc038d1086a7e987d88078e
|
|
| BLAKE2b-256 |
8ad1ebc610e72d0545dab35c3ae01b84a777c9c8eb6a8460505a16218fdee27d
|