Skip to main content

@okcashpro/okai v0.1.7-alpha.1 / generateTextArray

Function: generateTextArray()

generateTextArray(opts): Promise<string[]>

Send a message to the model and parse the response as a string array

Parameters

opts

The options for the generateText request

opts.runtime: IAgentRuntime

opts.context: string

The context/prompt to send to the model

opts.modelClass: string

Returns

Promise<string[]>

Promise resolving to an array of strings parsed from the model's response

Defined in

packages/core/src/generation.ts:764