Skip to content

Get OAIFunctionCallSpec

dfinke edited this page Apr 20, 2024 · 2 revisions

Get-OAIFunctionCallSpec

SYNOPSIS

Retrieves the OpenAI function call specification for a given function.

SYNTAX

Get-OAIFunctionCallSpec [[-functionInfo] <FunctionInfo>] [-ProgressAction <ActionPreference>]
 [<CommonParameters>]

DESCRIPTION

The Get-OAIFunctionCallSpec function retrieves the OpenAI function call specification for a given function. It takes a FunctionInfo object as input and returns the function call specification in a tool-specific format.

EXAMPLES

EXAMPLE 1

Function Test-Func {param($x)}; $functionInfo = Get-Command -Name "Test-Func"
Get-OAIFunctionCallSpec -functionInfo $functionInfo

This example retrieves the function call specification for the "Get-Process" function.

PARAMETERS

-functionInfo

Specifies the FunctionInfo object representing the function for which to retrieve the function call specification.

Type: FunctionInfo
Parameter Sets: (All)
Aliases:

Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ProgressAction

{{ Fill ProgressAction Description }}

Type: ActionPreference
Parameter Sets: (All)
Aliases: proga

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

[System.Management.Automation.FunctionInfo]

Accepts a FunctionInfo object representing the function for which to retrieve the function call specification.

OUTPUTS

[System.Object]

Returns the function call specification in a tool-specific format.

NOTES

RELATED LINKS

Clone this wiki locally