@langchain/core
Version:
Core LangChain.js abstractions and schemas
27 lines • 1.04 kB
text/typescript
import { CallbackManagerForLLMRun } from "../../callbacks/manager.cjs";
import { BaseLLMParams, LLM } from "../../language_models/llms.cjs";
import { GenerationChunk } from "../../outputs.cjs";
export declare class FakeLLM extends LLM {
response?: string;
thrownErrorString?: string;
constructor(fields: {
response?: string;
thrownErrorString?: string;
} & BaseLLMParams);
_llmType(): string;
_call(prompt: string, _options: this["ParsedCallOptions"], runManager?: CallbackManagerForLLMRun): Promise<string>;
}
export declare class FakeStreamingLLM extends LLM {
sleep?: number;
responses?: string[];
thrownErrorString?: string;
constructor(fields: {
sleep?: number;
responses?: string[];
thrownErrorString?: string;
} & BaseLLMParams);
_llmType(): string;
_call(prompt: string): Promise<string>;
_streamResponseChunks(input: string, _options?: this["ParsedCallOptions"], runManager?: CallbackManagerForLLMRun): AsyncGenerator<GenerationChunk, void, unknown>;
}
//# sourceMappingURL=llms.d.cts.map