-
Notifications
You must be signed in to change notification settings - Fork 14
Out OAIMessages
Outputs messages with roles and content.
Out-OAIMessages [[-Messages] <Object>] [-NoHeader] [-ProgressAction <ActionPreference>] [<CommonParameters>]
The Out-OAIMessages function is used to output messages with roles and content. It accepts an array of messages and an optional switch parameter to exclude the header.
$messages = @(
[PSCustomObject]@{
role = "Info"
content = [PSCustomObject]@{
text = [PSCustomObject]@{
value = "This is an informational message."
}
}
},
[PSCustomObject]@{
role = "Warning"
content = [PSCustomObject]@{
text = [PSCustomObject]@{
value = "This is a warning message."
}
}
}
)
Out-OAIMessages -Messages $messages
This example demonstrates how to use the Out-OAIMessages function to output messages.
Specifies the array of messages to be output.
Type: Object
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Specifies whether to exclude the header. By default, the header is included.
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
{{ 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
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.