Ana içeriğe geç

Interface: ResponseBuilder

A ResponseBuilder is used in a response synthesizer to generate a response from multiple response chunks.

Hierarchy

Implemented by

Methods

getPrompts

getPrompts(): PromptsDict

Returns all prompts from the mixin and its modules

Returns

PromptsDict

Inherited from

Partial.getPrompts

Defined in

packages/core/src/prompts/Mixin.ts:27


getResponse

getResponse(params): Promise<AsyncIterable<string>>

Get the response from a query and a list of text chunks.

Parameters

NameType
paramsResponseBuilderParamsStreaming

Returns

Promise<AsyncIterable<string>>

Defined in

packages/core/src/synthesizers/types.ts:52

getResponse(params): Promise<string>

Parameters

NameType
paramsResponseBuilderParamsNonStreaming

Returns

Promise<string>

Defined in

packages/core/src/synthesizers/types.ts:55


updatePrompts

updatePrompts(promptsDict): void

Updates the prompts in the mixin and its modules

Parameters

NameType
promptsDictPromptsDict

Returns

void

Inherited from

Partial.updatePrompts

Defined in

packages/core/src/prompts/Mixin.ts:48


validatePrompts

validatePrompts(promptsDict, moduleDict): void

Validates the prompt keys and module keys

Parameters

NameType
promptsDictPromptsDict
moduleDictModuleDict

Returns

void

Inherited from

Partial.validatePrompts

Defined in

packages/core/src/prompts/Mixin.ts:10