AssistantMessage

@Serializable
@SerialName(value = "assistant")
open class AssistantMessage(val content: String?, val name: String? = null, val prefix: Boolean? = null, val reasoningContent: String? = null) : ChatMessage

Assistant-role message — either a prior model response replayed as context, or a prefix-completion seed for the deepseek-chat prefix mode.

Model responses returned by the API are represented by the specialised ChatCompletionMessage subclass, which additionally carries ToolCalls.

Inheritors

Constructors

Link copied to clipboard
constructor(content: String?, name: String? = null, prefix: Boolean? = null, reasoningContent: String? = null)

Properties

Link copied to clipboard
open override val content: String?

Assistant message text; may be null when the message only carries tool calls.

Link copied to clipboard
val name: String?

Optional participant name forwarded to the model.

Link copied to clipboard

When true, marks this message as a partial assistant response that the model should continue generating from. See the DeepSeek API docs for prefix mode.

Link copied to clipboard

For the deepseek-reasoner model: the reasoning trace associated with the response.

Functions

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
open override fun toString(): String