Example

const retriever = new MultiQueryRetriever.fromLLM({
llm: new ChatAnthropic({}),
retriever: new MemoryVectorStore().asRetriever(),
verbose: true,
});
const retrievedDocs = await retriever.getRelevantDocuments(
"What are mitochondria made of?",
);

Hierarchy

  • BaseRetriever
    • MultiQueryRetriever

Constructors

Methods

Constructors

Methods

  • Parameters

    • fields: Omit<MultiQueryRetrieverInput, "llmChain"> & {
          llm: BaseLanguageModel<any, BaseLanguageModelCallOptions>;
          prompt?: BasePromptTemplate<any, BasePromptValue, any>;
      }

    Returns MultiQueryRetriever

Generated using TypeDoc