Last active
March 10, 2019 20:16
-
-
Save ozgurshn/da81c510fafd53b63483dd0c2064572e to your computer and use it in GitHub Desktop.
NLLanguageRecognizer
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import NaturalLanguage | |
| let recognizer = NLLanguageRecognizer() | |
| recognizer.processString("oduncu") | |
| let lang = recognizer.dominantLanguage | |
| let hypotheses = recognizer.languageHypotheses(withMaximum:2) | |
| //convenience method: NLLanguageRecognizer.dominantLanguage(for: "oduncu") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment