UNPKG

@promptbook/remote-server

Version:

Promptbook: Create persistent AI agents that turn your company's scattered knowledge into action

41 lines (40 loc) 1.98 kB
import type { ChatParticipant } from '../../book-components/Chat/types/ChatParticipant'; import type { AvailableModel } from '../../execution/AvailableModel'; import type { CommonToolsOptions } from '../../execution/CommonToolsOptions'; import type { LlmExecutionTools } from '../../execution/LlmExecutionTools'; import type { ChatPromptResult, CompletionPromptResult, EmbeddingPromptResult } from '../../execution/PromptResult'; import type { Prompt } from '../../types/Prompt'; import type { string_markdown, string_markdown_text } from '../../types/string_markdown'; import type { string_title } from '../../types/string_title'; /** * Mocked execution Tools for just faking expected responses for testing purposes * * @public exported from `@promptbook/fake-llm` */ export declare class MockedFackedLlmExecutionTools implements LlmExecutionTools { protected readonly options: CommonToolsOptions; constructor(options?: CommonToolsOptions); get title(): string_title & string_markdown_text; get description(): string_markdown; get profile(): ChatParticipant; /** * Does nothing, just to implement the interface */ checkConfiguration(): void; /** * List all available fake-models that can be used */ listModels(): ReadonlyArray<AvailableModel>; /** * Fakes chat model */ callChatModel(prompt: Pick<Prompt, 'content' | 'parameters' | 'modelRequirements' | 'expectations' | 'postprocessingFunctionNames'>): Promise<ChatPromptResult & CompletionPromptResult>; /** * Fakes completion model */ callCompletionModel(prompt: Pick<Prompt, 'content' | 'parameters' | 'modelRequirements' | 'expectations' | 'postprocessingFunctionNames'>): Promise<CompletionPromptResult>; /** * Fakes embedding model */ callEmbeddingModel(prompt: Pick<Prompt, 'content' | 'parameters' | 'modelRequirements' | 'expectations' | 'postprocessingFunctionNames'>): Promise<EmbeddingPromptResult>; }