struct

Crig::Completion::Message

Inherits Struct < Value < Object

Constructors

assistant(text : String) : self
Source
assistant_with_id(id : String, text : String) : self
Source
from(content : Crig::OneOrMany(UserContent)) : self
Source
from(content : Crig::OneOrMany(AssistantContent)) : self
Source
from(text : Text) : self
Source
from(text : String) : self
Source
from(image : Image) : self
Source
from(audio : Audio) : self
Source
from(document : Document) : self
Source
from(content : UserContent) : self
Source
from(content : AssistantContent) : self
Source
from(tool_call : ToolCall) : self
Source
from(tool_result : ToolResult) : self
Source
from(tool_result_content : ToolResultContent) : self
Source
new(role : Role, content : Crig::OneOrMany(UserContent | AssistantContent), id : String | Nil = nil)
Source
system(text : String) : self
Source
tool_result(id : String, content : String) : self
Source
tool_result_with_call_id(id : String, call_id : String | Nil, content : String) : self
Source
user(contents : Crig::OneOrMany(UserContent)) : self
Source
user(text : String) : self
Source
user(content : UserContent) : self
Source
user(contents : Array(UserContent)) : self
Source

Instance methods

content
Source
rag_text
Source
role
Source

Nested types