pemistahl / lingua-py

The most accurate natural language detection library for Python, suitable for short text and mixed-language text
Apache License 2.0
1.08k stars 44 forks source link

Support ONNX format for language models #152

Open BaMarcy opened 1 year ago

BaMarcy commented 1 year ago

Hi! I'm reaching out to kindly request the availability of the ONNX file for the language detector model that is currently being utilized within the project. Thanks.

ogencoglu commented 1 year ago

+1

pemistahl commented 11 months ago

Hi @BaMarcy, I'm sorry for the late response. As far as I understand, the ONNX format is for neural networks, right? My library uses Naive Bayes models but not neural networks. So the ONNX format is not applicable here, I guess. I'm not sure whether it's a good idea to switch the models to neural networks, though.

ogencoglu commented 11 months ago

ONNX is not only for neural nets. It supports most scikit-learn models for example (see sklearn-onnx).

BaMarcy commented 11 months ago

well I have never used ONNX for traditional ML algorithms but it is good to know that your solution is a NB classifier.