class Riffer::StreamEvents::ToolCallDone
Riffer::StreamEvents::ToolCallDone represents a completed tool call during streaming.
Emitted when the LLM has finished building a tool call with complete arguments.
Attributes
The complete arguments JSON string.
The call identifier for response matching.
The tool call item identifier.
The tool name.
Public Class Methods
Source
# File lib/riffer/stream_events/tool_call_done.rb, line 21 def initialize(item_id:, call_id:, name:, arguments:, role: :assistant) super(role: role) @item_id = item_id @call_id = call_id @name = name @arguments = arguments end
: (item_id: String, call_id: String, name: String, arguments: String, ?role: Symbol) -> void
Calls superclass method
Riffer::StreamEvents::Base::new
Public Instance Methods
Source
# File lib/riffer/stream_events/tool_call_done.rb, line 30 def to_h {role: @role, item_id: @item_id, call_id: @call_id, name: @name, arguments: @arguments} end
: () -> Hash[Symbol, untyped]