AIContent Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides a base class for all content used with AI services.
public ref class AIContent
[System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.AudioContent), "audio")]
[System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.DataContent), "data")]
[System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.FunctionCallContent), "functionCall")]
[System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.FunctionResultContent), "functionResult")]
[System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.ImageContent), "image")]
[System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.TextContent), "text")]
[System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.UsageContent), "usage")]
[System.Text.Json.Serialization.JsonPolymorphic(TypeDiscriminatorPropertyName="$type")]
public class AIContent
[<System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.AudioContent), "audio")>]
[<System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.DataContent), "data")>]
[<System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.FunctionCallContent), "functionCall")>]
[<System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.FunctionResultContent), "functionResult")>]
[<System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.ImageContent), "image")>]
[<System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.TextContent), "text")>]
[<System.Text.Json.Serialization.JsonDerivedType(typeof(Microsoft.Extensions.AI.UsageContent), "usage")>]
[<System.Text.Json.Serialization.JsonPolymorphic(TypeDiscriminatorPropertyName="$type")>]
type AIContent = class
Public Class AIContent
- Inheritance
-
AIContent
- Derived
- Attributes
Constructors
AIContent() |
Initializes a new instance of the AIContent class. |
Properties
AdditionalProperties |
Gets or sets additional properties for the content. |
RawRepresentation |
Gets or sets the raw representation of the content from an underlying implementation. |
Methods
Equals(Object) |
Determines whether the specified object is equal to the current object. (Inherited from Object) |
GetHashCode() |
Serves as the default hash function. (Inherited from Object) |
GetType() |
Gets the Type of the current instance. (Inherited from Object) |
MemberwiseClone() |
Creates a shallow copy of the current Object. (Inherited from Object) |
ToString() |
Returns a string that represents the current object. (Inherited from Object) |