You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Issue #631 proposed adding a language detection method in the REST API and CLI. The REST API part was implemented in PR #659, closing the issue. But the CLI part still remains to be done. This issue attempts to specify the CLI part.
Here is an example how it could work:
$ echo "this is some example text in an unknown language" | annif detect-language --languages fi,sv,en
en 1.0000
fi 0.2000
sv 0.2000
- 0.0000
Some notes:
the new command is annif detect-language
the candidate languages are given as the --languages parameter, separated by comma
the output is TSV (language code and score)
the results are ordered by decreasing score (best guess first)
- means unknown language (same as null value in the REST API)
the number of candidate languages is not limited (unlike the REST API method where the limit is 5 due to memory usage concerns)
The text was updated successfully, but these errors were encountered:
Issue #631 proposed adding a language detection method in the REST API and CLI. The REST API part was implemented in PR #659, closing the issue. But the CLI part still remains to be done. This issue attempts to specify the CLI part.
Here is an example how it could work:
Some notes:
annif detect-language
--languages
parameter, separated by comma-
means unknown language (same as null value in the REST API)The text was updated successfully, but these errors were encountered: