Class: Antigravity::Message
Direct Known Subclasses
Instance Attribute Summary collapse
-
#content ⇒ Object
Returns the value of attribute content.
-
#model_id ⇒ Object
Returns the value of attribute model_id.
-
#role ⇒ Object
Returns the value of attribute role.
-
#thinking ⇒ Object
Returns the value of attribute thinking.
-
#tokens ⇒ Object
Returns the value of attribute tokens.
-
#tool_calls ⇒ Object
Returns the value of attribute tool_calls.
Instance Method Summary collapse
-
#initialize(role: :assistant, content: "", thinking: "", tool_calls: [], model_id: nil) ⇒ Message
constructor
A new instance of Message.
Methods inherited from Base
Methods included from Emojifiable
Constructor Details
#initialize(role: :assistant, content: "", thinking: "", tool_calls: [], model_id: nil) ⇒ Message
Returns a new instance of Message.
8 9 10 11 12 13 14 15 |
# File 'lib/antigravity/message.rb', line 8 def initialize(role: :assistant, content: "", thinking: "", tool_calls: [], model_id: nil) @role = role @content = content @thinking = thinking @tool_calls = tool_calls @model_id = model_id @tokens = { input: 0, output: 0 } end |
Instance Attribute Details
#content ⇒ Object
Returns the value of attribute content.
6 7 8 |
# File 'lib/antigravity/message.rb', line 6 def content @content end |
#model_id ⇒ Object
Returns the value of attribute model_id.
6 7 8 |
# File 'lib/antigravity/message.rb', line 6 def model_id @model_id end |
#role ⇒ Object
Returns the value of attribute role.
6 7 8 |
# File 'lib/antigravity/message.rb', line 6 def role @role end |
#thinking ⇒ Object
Returns the value of attribute thinking.
6 7 8 |
# File 'lib/antigravity/message.rb', line 6 def thinking @thinking end |
#tokens ⇒ Object
Returns the value of attribute tokens.
6 7 8 |
# File 'lib/antigravity/message.rb', line 6 def tokens @tokens end |
#tool_calls ⇒ Object
Returns the value of attribute tool_calls.
6 7 8 |
# File 'lib/antigravity/message.rb', line 6 def tool_calls @tool_calls end |