Interface BaseRetrieverInterface<Metadata>

Base interface implemented by all runnables. Used for cross-compatibility between different versions of LangChain core.

Should not change on patch releases.

interface BaseRetrieverInterface<Metadata> {
    batch(inputs, options?, batchOptions?): Promise<DocumentInterface<Metadata>[][]>;
    batch(inputs, options?, batchOptions?): Promise<(Error | DocumentInterface<Metadata>[])[]>;
    batch(inputs, options?, batchOptions?): Promise<(Error | DocumentInterface<Metadata>[])[]>;
    getName(suffix?): string;
    getRelevantDocuments(query, config?): Promise<DocumentInterface<Metadata>[]>;
    invoke(input, options?): Promise<DocumentInterface<Metadata>[]>;
    stream(input, options?): Promise<IterableReadableStreamInterface<DocumentInterface<Metadata>[]>>;
    transform(generator, options): AsyncGenerator<DocumentInterface<Metadata>[], any, unknown>;
}

Type Parameters

  • Metadata extends Record<string, any> = Record<string, any>

Hierarchy (view full)

Implemented by

Methods

Generated using TypeDoc