class Riffer::StreamEvents::ToolCallDelta
Represents an incremental tool call chunk (partial argument data) during streaming.
Attributes
The incremental arguments JSON fragment.
The tool call item identifier.
The tool name (may only be present in first delta).
Public Class Methods
Source
# File lib/riffer/stream_events/tool_call_delta.rb, line 18 def initialize(item_id:, arguments_delta:, name: nil, role: :assistant) super(role: role) @item_id = item_id @name = name @arguments_delta = arguments_delta end
Calls superclass method
Riffer::StreamEvents::Base::new
Public Instance Methods
Source
# File lib/riffer/stream_events/tool_call_delta.rb, line 27 def to_h {role: @role, item_id: @item_id, name: @name, arguments_delta: @arguments_delta}.compact end