这是indexloc提供的服务,不要输入任何密码
Skip to content
Discussion options

You must be logged in to vote

Its in the util.py ...

searxng/searx/utils.py

Lines 555 to 623 in 4b42644

def detect_language(text: str, threshold: float = 0.3, only_search_languages: bool = False) -> Optional[str]:
"""Detect the language of the ``text`` parameter.
:param str text: The string whose language is to be detected.
:param float threshold: Threshold filters the returned labels by a threshold
on probability. A choice of 0.3 will return labels with at least 0.3
probability.
:param bool only_search_languages: If ``True``, returns only supported
SearXNG search languages. see :py:obj:`searx.languages`
:rtype: str, None
:returns:

Replies: 6 comments 11 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by return42
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
11 replies
@mehr32
Comment options

@mehr32
Comment options

@dalf
Comment options

@mehr32
Comment options

@return42
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants