Class: LLM::OpenAI::StreamParser
- Inherits:
-
Object
- Object
- LLM::OpenAI::StreamParser
- Defined in:
- lib/llm/providers/openai/stream_parser.rb
Instance Attribute Summary collapse
-
#body ⇒ LLM::Object
readonly
Returns the fully constructed response body.
Instance Method Summary collapse
Constructor Details
Instance Attribute Details
#body ⇒ LLM::Object (readonly)
Returns the fully constructed response body
10 11 12 |
# File 'lib/llm/providers/openai/stream_parser.rb', line 10 def body @body end |
Instance Method Details
#parse!(chunk) ⇒ LLM::OpenAI::Chunk
22 23 24 |
# File 'lib/llm/providers/openai/stream_parser.rb', line 22 def parse!(chunk) tap { merge!(chunk) } end |