import Exa, { ContentsOptions, RegularSearchOptions, SearchResult } from "exa-js";
import { BaseRetriever, BaseRetrieverInput } from "@langchain/core/retrievers";
import { Document } from "@langchain/core/documents";
/**
 * Interface for the fields required during the initialization of a
 * `ExaRetriever` instance. It extends the `BaseRetrieverInput`
 * interface and adds a `client` field of type `Exa`.
 */
export interface ExaRetrieverFields<T extends ContentsOptions = {
    text: true;
}> extends BaseRetrieverInput {
    client: Exa.default;
    searchArgs?: RegularSearchOptions & T;
}
export declare function _getMetadata<T extends ContentsOptions = {
    text: true;
}>(result: SearchResult<T>): Record<string, unknown>;
/**
 * @example
 * ```typescript
 * const retriever = new ExaRetriever({
 *   client: new Exa(
 *     process.env.EXA_API_KEY,
 *     process.env.EXA_BASE_URL,
 *   ),
 * });
 * const docs = await retriever.getRelevantDocuments("hello");
 * ```
 */
export declare class ExaRetriever<T extends ContentsOptions = {
    text: true;
}> extends BaseRetriever {
    static lc_name(): string;
    lc_namespace: string[];
    private client;
    searchArgs?: RegularSearchOptions & T;
    constructor(fields: ExaRetrieverFields<T>);
    _getRelevantDocuments(query: string): Promise<Document[]>;
}
