Interface: ResponseBuilder
A ResponseBuilder is used in a response synthesizer to generate a response from multiple response chunks.
Extends
Partial
<PromptMixin
>
Methods
getPrompts()?
optional
getPrompts():PromptsDict
Returns all prompts from the mixin and its modules
Returns
PromptsDict
Inherited from
Partial.getPrompts
Source
packages/core/src/prompts/Mixin.ts:27
getResponse()
getResponse(params)
getResponse(
params
):Promise
<AsyncIterable
<string
>>
Get the response from a query and a list of text chunks.
Parameters
• params: ResponseBuilderParamsStreaming
Returns
Promise
<AsyncIterable
<string
>>
Source
packages/core/src/synthesizers/types.ts:52
getResponse(params)
getResponse(
params
):Promise
<string
>
Parameters
• params: ResponseBuilderParamsNonStreaming
Returns
Promise
<string
>
Source
packages/core/src/synthesizers/types.ts:55
updatePrompts()?
optional
updatePrompts(promptsDict
):void
Updates the prompts in the mixin and its modules
Parameters
• promptsDict: PromptsDict
Returns
void
Inherited from
Partial.updatePrompts
Source
packages/core/src/prompts/Mixin.ts:48
validatePrompts()?
optional
validatePrompts(promptsDict
,moduleDict
):void
Validates the prompt keys and module keys
Parameters
• promptsDict: PromptsDict
• moduleDict: ModuleDict
Returns
void
Inherited from
Partial.validatePrompts