Skip to main content

FlowGptPrompt Methods

An object defining methods for the FlowGptPrompt class.

ExecuteQueryAsync()

Executes the GPT query asynchronously and stores the results.

Returns:

Type: Task
Task without value

This is a async method. Method should be waited. Be careful if call this method without waiting.

See Also


Initialize()

Initializes the FlowGptPrompt step with necessary configurations.

Returns:

Type: void
Method does not return anything

This is a sync method. Method runs synchronously.


GetResult<T>()

Executes the query and returns the result as an IEnumerable of type T, where T is the C# class representing the JSON structure returned by the query.

Generics:

Type: T
The generic type T represents an IEnumerable where T corresponds to the C# class generated from the JSON structure returned by the query.

Returns:

Type: T
The result of the query as an IEnumerable of type T.

This is a sync method. Method runs synchronously.


ToLiquid()

Converts the query result to a Liquid-compatible format for template rendering.

Returns:

Type: object
The converted object.

This is a sync method. Method runs synchronously.