Class: Riffer::StreamEvents::ReasoningDone
- Defined in:
- lib/riffer/stream_events/reasoning_done.rb
Overview
Represents completion of reasoning during streaming.
Emitted when the LLM has finished producing reasoning/thinking content. Only available with providers that support reasoning (e.g., OpenAI with reasoning option).
Instance Attribute Summary collapse
-
#content ⇒ Object
readonly
The complete reasoning content.
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(content, role: :assistant) ⇒ ReasoningDone
constructor
– : (String, ?role: Symbol) -> void.
-
#to_h ⇒ Object
– : () -> Hash[Symbol, untyped].
Constructor Details
#initialize(content, role: :assistant) ⇒ ReasoningDone
– : (String, ?role: Symbol) -> void
14 15 16 17 |
# File 'lib/riffer/stream_events/reasoning_done.rb', line 14 def initialize(content, role: :assistant) super(role: role) @content = content end |
Instance Attribute Details
#content ⇒ Object (readonly)
The complete reasoning content.
10 11 12 |
# File 'lib/riffer/stream_events/reasoning_done.rb', line 10 def content @content end |
Instance Method Details
#to_h ⇒ Object
– : () -> Hash[Symbol, untyped]
21 22 23 |
# File 'lib/riffer/stream_events/reasoning_done.rb', line 21 def to_h {role: @role, content: @content} end |