filter the resulting set of retrieved docs
Returns
List of Tuples of (doc, similarity_score)
similarity_search_with_score(query: str, k: int = 4, distance_func: Literal['sqrt_euclid', 'neg_dot_prod', 'ned_cos'] = 'sqrt_euclid', **kwargs: Any) → List[Tuple[Document, float]][source]¶
Run similarity search with distance.
similarity_search_with_score_by_vector(query_vector: List[float], k: int = 4, distance_func: Literal['sqrt_euclid', 'neg_dot_prod', 'ned_cos'] = 'sqrt_euclid', **kwargs: Any) → List[Tuple[Document, float]][source]¶
Return docs most similar to query vector, with its score.