Search Results for

    Show / Hide Table of Contents

    Class ThreadMessageRequest

    Inheritance
    object
    OpenAIRequest
    ThreadMessageRequest
    Implements
    IJsonRequest
    Inherited Members
    OpenAIRequest.Model
    OpenAIRequest.N
    OpenAIRequest.Metadata
    OpenAIRequest.User
    OpenAIRequest.SafetyIdentifier
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Glitch9.AIDevKit.OpenAI
    Assembly: Glitch9.AIDevKit.Provider.OpenAI.dll
    Syntax
    [JsonConverter(typeof(ThreadMessageRequestConverter))]
    public class ThreadMessageRequest : OpenAIRequest, IJsonRequest

    Constructors

    | Edit this page View Source

    ThreadMessageRequest()

    Declaration
    public ThreadMessageRequest()
    | Edit this page View Source

    ThreadMessageRequest(string, IEnumerable<ToolEnvelope>, IEnumerable<IFile>, IEnumerable<string>, IEnumerable<string>, IEnumerable<string>)

    Declaration
    public ThreadMessageRequest(string prompt, IEnumerable<ToolEnvelope> tools = null, IEnumerable<IFile> uploadFiles = null, IEnumerable<string> imageUrls = null, IEnumerable<string> fileIds = null, IEnumerable<string> imageFileIds = null)
    Parameters
    Type Name Description
    string prompt
    IEnumerable<ToolEnvelope> tools
    IEnumerable<IFile> uploadFiles
    IEnumerable<string> imageUrls
    IEnumerable<string> fileIds
    IEnumerable<string> imageFileIds

    Properties

    | Edit this page View Source

    Attachments

    A list of files attached to the message, and the tools they should be added to.

    Declaration
    [JsonProperty("attachments")]
    public List<Attachment> Attachments { get; set; }
    Property Value
    Type Description
    List<Attachment>
    | Edit this page View Source

    Content

    Required. The content of the message.

    Declaration
    [JsonProperty("content")]
    public MessageContent Content { get; set; }
    Property Value
    Type Description
    MessageContent
    | Edit this page View Source

    Role

    Required. The role of the entity that is creating the message. Currently only User is supported.

    Declaration
    [JsonProperty("role")]
    public ChatRole Role { get; }
    Property Value
    Type Description
    ChatRole

    Methods

    | Edit this page View Source

    AddInputFiles(params IFile[])

    Declaration
    public ThreadMessageRequest AddInputFiles(params IFile[] files)
    Parameters
    Type Name Description
    IFile[] files
    Returns
    Type Description
    ThreadMessageRequest
    | Edit this page View Source

    SetFileIds(IEnumerable<string>)

    Declaration
    public ThreadMessageRequest SetFileIds(IEnumerable<string> attachmentFileIds)
    Parameters
    Type Name Description
    IEnumerable<string> attachmentFileIds
    Returns
    Type Description
    ThreadMessageRequest
    | Edit this page View Source

    SetImageFileIds(IEnumerable<string>)

    Declaration
    public ThreadMessageRequest SetImageFileIds(IEnumerable<string> imageFileIds)
    Parameters
    Type Name Description
    IEnumerable<string> imageFileIds
    Returns
    Type Description
    ThreadMessageRequest
    | Edit this page View Source

    SetImageUrls(IEnumerable<string>)

    Declaration
    public ThreadMessageRequest SetImageUrls(IEnumerable<string> imageUrls)
    Parameters
    Type Name Description
    IEnumerable<string> imageUrls
    Returns
    Type Description
    ThreadMessageRequest
    | Edit this page View Source

    SetInputFiles(params IFile[])

    Declaration
    public ThreadMessageRequest SetInputFiles(params IFile[] files)
    Parameters
    Type Name Description
    IFile[] files
    Returns
    Type Description
    ThreadMessageRequest
    | Edit this page View Source

    SetPrompt(string)

    Declaration
    public ThreadMessageRequest SetPrompt(string prompt)
    Parameters
    Type Name Description
    string prompt
    Returns
    Type Description
    ThreadMessageRequest
    | Edit this page View Source

    SetTools(params ToolEnvelope[])

    Declaration
    public ThreadMessageRequest SetTools(params ToolEnvelope[] tools)
    Parameters
    Type Name Description
    ToolEnvelope[] tools
    Returns
    Type Description
    ThreadMessageRequest

    Implements

    IJsonRequest

    Extension Methods

    ArrayExtensions.ToArrayOrEmpty<T>(T)
    ArrayExtensions.ToArrayOrNull<T>(T)
    EventExtensions.ToDelta<T>(T, string, int, string, bool)
    EventExtensions.ToDone<T>(T, string, int, string)
    EventExtensions.ToEvent<T>(T)
    EventExtensions.UpcastDelta<T1, T2>(T1, string, int, string, bool)
    FallbackExtensions.IsOr<TParent, TChild>(TParent, TChild)
    ResponseCastingExtensions.GetResult<T>(T)
    SystemExtensions.GetName(object)
    • Edit this page
    • View Source
    In this article
    Back to top AI DevKit Documentation