Table of Contents

Class ChatHistory.Message

Namespace
LMKit.TextGeneration.Chat
Assembly
LM-Kit.NET.dll

Represents a chat message exchanged in a conversation, encapsulating the author, textual content, segments, attachments, and processing status of the message.

public sealed class ChatHistory.Message : INotifyPropertyChanged
Inheritance
ChatHistory.Message
Implements
Inherited Members

Constructors

Message(Attachment)

Initializes a new instance of the ChatHistory.Message class with a single attachment and no textual content, using User as the default author role.

Message(AttachmentReference)

Initializes a new instance of the ChatHistory.Message class with a single attachment reference and no textual content, using User as the default author role.

Message(AuthorRole, Attachment)

Initializes a new instance of the ChatHistory.Message class with the specified author role and a single attachment, without textual content.

Message(AuthorRole, string)

Initializes a new instance of the ChatHistory.Message class with the specified author role and text.

Message(AuthorRole, string, Attachment)

Initializes a new instance of the ChatHistory.Message class with the specified author role, text, and a single attachment.

Message(AuthorRole, string, AttachmentReference)

Initializes a new instance of the ChatHistory.Message class with the specified author role, text, and a single attachment reference.

Message(AuthorRole, string, TextSegmentType)

Initializes a new ChatHistory.Message with an explicit initial segment type.

Message(AuthorRole, string, IEnumerable<AttachmentReference>)

Initializes a new instance of the ChatHistory.Message class with the specified author role, text, and a collection of attachment references.

Message(AuthorRole, string, IEnumerable<Attachment>)

Initializes a new instance of the ChatHistory.Message class with the specified author role, text, and a collection of attachments.

Message(IEnumerable<AttachmentReference>)

Initializes a new instance of the ChatHistory.Message class with a collection of attachment references and no textual content, using User as the default author role.

Message(IEnumerable<Attachment>)

Initializes a new instance of the ChatHistory.Message class with a collection of attachments and no textual content, using User as the default author role.

Message(string)

Initializes a new instance of the ChatHistory.Message class with the specified text, using User as the default author role.

Message(string, Attachment)

Initializes a new instance of the ChatHistory.Message class with the specified text and a single attachment, using User as the default author role.

Message(string, AttachmentReference)

Initializes a new instance of the ChatHistory.Message class with the specified text and a single attachment reference, using User as the default author role.

Message(string, IEnumerable<AttachmentReference>)

Initializes a new instance of the ChatHistory.Message class with the specified text and a collection of attachment references, using User as the default author role.

Message(string, IEnumerable<Attachment>)

Initializes a new instance of the ChatHistory.Message class with the specified text and a collection of attachments, using User as the default author role.

Properties

Attachments

Gets the collection of attachment references associated with the message.

AuthorRole

Gets the role of the message's author, defined by the AuthorRole enum.

GeneratedTokens

Gets the number of tokens generated during the text completion process.

IsProcessed

Indicates whether the message has been processed.

PreviousContent

Gets a read-only list of previous versions of the message content.

Segments

Gets the list of segments that compose this message.

TerminationReason

Gets the reason why the assistant's text generation process was terminated.

Text

Gets the textual content of the message.

Methods

ToString()

Events

PropertyChanged

Occurs when a property value changes.