| Crates.io | langid-rs |
| lib.rs | langid-rs |
| version | 1.1.0 |
| created_at | 2025-07-18 10:45:37.667099+00 |
| updated_at | 2025-09-19 11:33:51.08337+00 |
| description | A fast and lightweight language identification library in Rust, inspired by py3langid. |
| homepage | |
| repository | https://github.com/frederik-uni/langid |
| max_upload_size | |
| id | 1758853 |
| size | 7,695,148 |
This is a rust conversion of the py3langid library.
This is only a deployment of the library. For training use the original library.
use langid_rs::Model;
fn main() {
let model = Model::load(false).unwrap();
//model.set_langs(Some(vec![...])).unwrap();
let text = "This text is in English.";
let classification = model.classify(text).unwrap();
println!("{:?}", classification);
}