Skip to main content

Interface: PromptTemplate<SOURCE_PROMPT, TARGET_PROMPT>

Prompt templates format a source prompt as a target prompt.

Type parameters

Name
SOURCE_PROMPT
TARGET_PROMPT

Hierarchy

Methods

format

format(sourcePrompt): TARGET_PROMPT

Formats the source prompt as a target prompt.

Parameters

NameType
sourcePromptSOURCE_PROMPT

Returns

TARGET_PROMPT

Defined in

packages/modelfusion/src/model-function/PromptTemplate.ts:8