All Superinterfaces:
Function <Query ,List <org.springframework.ai.document.Document>>
All Known Implementing Classes:
VectorStoreDocumentRetriever
public interface DocumentRetriever
extends Function <Query ,List <org.springframework.ai.document.Document>>
Component responsible for retrieving Documents from an underlying data source,
such as a search engine, a vector store, a database, or a knowledge graph.
Since:
1.0.0
Author:
Christian Tzolov, Thomas Vitale
Method Summary
All Methods Instance Methods Abstract Methods Default Methods
default List <org.springframework.ai.document.Document>
List <org.springframework.ai.document.Document>
Retrieves relevant documents from an underlying data source based on the given
query.
Method Details
retrieve
List <org.springframework.ai.document.Document> retrieve (Query query)
Retrieves relevant documents from an underlying data source based on the given
query.
Parameters:
query - The query to use for retrieving documents
Returns:
The list of relevant documents
apply
default List <org.springframework.ai.document.Document> apply (Query query)
Specified by:
apply in interface Function <Query ,List <org.springframework.ai.document.Document>>