webmil/text-language-detect-bundle
Symfony bundle for detecting the language of text using the webmil text-language-detect library. Integrates language identification into Symfony apps with service configuration, useful for localization, content filtering, and routing based on detected language.
Text_LanguageDetect library. It's useful as a cost baseline ("wrapping an existing detector is a day of integration work") against the build alternative of training/hosting a detector. It does not justify a multi-week internal build on its own.Consider it only if all of the following hold:
Look elsewhere when:
pear/Text_LanguageDetect (or a maintained fork) directly, bypassing the bundle entirely.lingua ports, fastText's lid.176, or a hosted detection API — materially outperform N-gram frequency counting on short strings and code-switched text. For most product surfaces this is the correct technical choice regardless of language.Practical guidance: if language detection is a genuine roadmap item, run a two-day bake-off on your real sample text between the underlying PEAR library and one modern alternative, and let accuracy on your data pick the winner. Do not let a Symfony2 bundle constrain a Laravel product decision.
To executives: This is a small, MIT-licensed wrapper that lets a PHP app guess what language a block of text is written in. It's not a strategic dependency — it's an old Symfony2 plug-in around an older library, with negligible community traction. The value of looking at it is narrow: it shows us the cheapest possible version of "auto-detect language on ingest," which helps us price the feature and decide whether to build, buy, or defer. Recommendation: fund a short evaluation of detection quality on our actual content, and select a maintained library rather than this bundle.
To engineering: Treat webmil/text-language-detect-bundle as a reference implementation, not a dependency. It's a DI wrapper over Text_LanguageDetect (PEAR, frequency/N-gram based) and assumes Symfony 2 — there is no Laravel integration, and the ecosystem around it is dormant. If we want this capability, the decision is between calling the underlying library directly behind our own small interface, or adopting a maintained detector (CLD3, fastText lid.176, or a hosted API). Please surface: accuracy on short strings, language coverage, latency, and whether detection runs inline or async. We should wrap whichever we choose behind our own service contract so the library is replaceable — the one durable lesson this package teaches is that these wrappers churn.
How can I help you explore Laravel packages today?