language-detector
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseLanguage Detector
语言检测器
Identify the language of text with confidence scoring.
识别文本的语言并给出置信度评分。
Features
功能特性
- 50+ Languages: Wide language support
- Confidence Scores: Probability estimates
- Batch Detection: Process multiple texts
- CSV Support: Analyze text columns
- Multiple Algorithms: Character n-gram analysis
- 50+种语言:广泛的语言支持
- 置信度评分:概率估算
- 批量检测:处理多条文本
- CSV支持:分析文本列
- 多种算法:字符n-gram分析
CLI Usage
CLI 使用方法
bash
python language_detector.py --text "Hello world" --output result.json
python language_detector.py --file texts.csv --column text --output languages.csvbash
python language_detector.py --text "Hello world" --output result.json
python language_detector.py --file texts.csv --column text --output languages.csvDependencies
依赖项
- langdetect>=1.0.9
- pandas>=2.0.0
- langdetect>=1.0.9
- pandas>=2.0.0