UNPKG

@promptbook/remote-server

Version:

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

44 lines (43 loc) 1.75 kB
import type { ChatParticipant } from '../../book-components/Chat/types/ChatParticipant'; import type { AvailableModel } from '../../execution/AvailableModel'; import type { LlmExecutionTools } from '../../execution/LlmExecutionTools'; import type { string_markdown, string_markdown_text } from '../../types/string_markdown'; import type { string_title } from '../../types/string_title'; import { computeOpenAiUsage } from './computeOpenAiUsage'; import { OpenAiCompatibleExecutionTools } from './OpenAiCompatibleExecutionTools'; /** * Execution Tools for calling OpenAI API * * @public exported from `@promptbook/openai` */ export declare class OpenAiExecutionTools extends OpenAiCompatibleExecutionTools implements LlmExecutionTools { get title(): string_title & string_markdown_text; get description(): string_markdown; get profile(): ChatParticipant; /** * List all available models (non dynamically) * * Note: Purpose of this is to provide more information about models than standard listing from API */ protected get HARDCODED_MODELS(): ReadonlyArray<AvailableModel>; /** * Computes the usage of the OpenAI API based on the response from OpenAI */ protected computeUsage: typeof computeOpenAiUsage; /** * Default model for chat variant. */ protected getDefaultChatModel(): AvailableModel; /** * Default model for completion variant. */ protected getDefaultCompletionModel(): AvailableModel; /** * Default model for completion variant. */ protected getDefaultEmbeddingModel(): AvailableModel; /** * Default model for image generation variant. */ protected getDefaultImageGenerationModel(): AvailableModel; }