A pure Go library for fast, offline natural language detection supporting 29 languages.
getlang is a natural language detection package written in pure Go that identifies the language of text input. It uses trigram-based text categorization to detect 29 different languages and provides ISO 639 language codes along with confidence scores. The library operates entirely offline, making it suitable for applications that require local language processing without internet connectivity.
Go developers building applications that need to detect text language, particularly those working on internationalization, content filtering, or text analysis tools where offline operation is important.
Developers choose getlang for its pure Go implementation, offline capability, and fast performance without external dependencies. It provides a simple, efficient alternative to cloud-based language detection services for applications that need local processing.
Natural language detection package in pure Go
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Operates without internet connectivity, enabling local processing in constrained environments, as explicitly stated in the features for offline operation.
Uses optimized trigram-based categorization for quick language identification, highlighted in the README for its speed and efficiency.
Pure Go library with easy installation via 'go get', making it straightforward to add to existing projects with minimal setup, as shown in the getting started example.
Provides confidence scores alongside predictions, allowing developers to assess reliability, as demonstrated in the example code returning confidence levels.
Supports only 29 languages, excluding many less common languages and dialects, which restricts its use in diverse multilingual applications.
Does not update dynamically; language detection models are fixed unless the library is manually updated, limiting adaptability to new linguistic trends.
README and godoc provide minimal examples, lacking guidance on edge cases, accuracy benchmarks, or advanced usage scenarios.