return self.similarity_search_by_vector_with_relevance_scores(
            vectors[0], k=k, filter=filter
        )
[docs]    def match_args(
        self, query: List[float], k: int, filter: Optional[Dict[str, Any]]
    ) -> Dict[str, Any]:
        ret = dict(query_embedding=query, match_count=k)
        if filter:
            ret["filter"] = filter
        return ret
[docs]    def similarity_search_by_vector_with_relevance_scores(
        self, query: List[float], k: int, filter: Optional[Dict[str, Any]] = None
    ) -> List[Tuple[Document, float]]:
        match_documents_params = self.match_args(query, k, filter)
        res = self._client.rpc(self.query_name, match_documents_params).execute()
        match_result = [
            (
                Document(
                    metadata=search.get("metadata", {}),  # type: ignore
                    page_content=search.get("content", ""),
                ),
                search.get("similarity", 0.0),
            )
            for search in res.data
            if search.get("content")
        ]
        return match_result
[docs]    def similarity_search_by_vector_returning_embeddings(
        self, query: List[float], k: int, filter: Optional[Dict[str, Any]] = None
    ) -> List[Tuple[Document, float, np.ndarray[np.float32, Any]]]:
        match_documents_params = self.match_args(query, k, filter)
        res = self._client.rpc(self.query_name, match_documents_params).execute()
        match_result = [
            (
                Document(
                    metadata=search.get("metadata", {}),  # type: ignore
                    page_content=search.get("content", ""),
                ),