Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use langdetect #528

Merged
merged 1 commit into from
Oct 31, 2023
Merged

Use langdetect #528

merged 1 commit into from
Oct 31, 2023

Conversation

pierotofy
Copy link
Member

@pierotofy pierotofy commented Oct 31, 2023

Use langdetect in place of linguars. langdetect doesn't work as well as linguars, but is quite faster and should perform better than cld2.

It might be possible in the future to use lingua, as official bindings become available.

I've left the lingua branch here: https://github.com/LibreTranslate/LibreTranslate/tree/lingua

I've also refactored some logic; we were calling detect twice to account for sentences with shorter length. This should no longer be needed.

@pierotofy
Copy link
Member Author

Closes #527

@pierotofy pierotofy merged commit 92df4c3 into LibreTranslate:main Oct 31, 2023
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant