Return type
List[Document]
similarity_search_limit_score(query: str, k: int = 4, score_threshold: float = 0.2, **kwargs: Any) → List[Document][source]¶
[Deprecated]  Returns the most similar indexed documents to the query text within the
score_threshold range.
Deprecated: Use similarity_search with distance_threshold instead.
Parameters
query (str) – The query text for which to find similar documents.
k (int) – The number of documents to return. Default is 4.
score_threshold (float) – The minimum matching distance required
for a document to be considered a match. Defaults to 0.2.
Returns
A list of documents that are most similar to the query textincluding the match score for each document.
Return type
List[Document]
Note
If there are no documents that satisfy the score_threshold value,
an empty list is returned.[Deprecated] Returns the most similar indexed documents to the query text within the
score_threshold range.
Deprecated: Use similarity_search with distance_threshold instead.
Parameters
query (str) – The query text for which to find similar documents.
k (int) – The number of documents to return. Default is 4.
score_threshold (float) – The minimum matching distance required
for a document to be considered a match. Defaults to 0.2.
Returns
A list of documents that are most similar to the query textincluding the match score for each document.
Return type
List[Document]
Note
If there are no documents that satisfy the score_threshold value,
an empty list is returned.
Notes
Deprecated since version 0.0.272: Use similarity_search(distance_threshold=0.1) instead.