Class: Durable::Llm::Providers::DeepSeek::DeepSeekChoice
- Inherits:
-
Object
- Object
- Durable::Llm::Providers::DeepSeek::DeepSeekChoice
- Defined in:
- lib/durable/llm/providers/deepseek.rb
Overview
Choice wrapper for DeepSeek response choices
Instance Attribute Summary collapse
-
#finish_reason ⇒ Object
readonly
Returns the value of attribute finish_reason.
-
#message ⇒ Object
readonly
Returns the value of attribute message.
Instance Method Summary collapse
-
#initialize(choice) ⇒ DeepSeekChoice
constructor
A new instance of DeepSeekChoice.
- #to_s ⇒ Object
Constructor Details
#initialize(choice) ⇒ DeepSeekChoice
Returns a new instance of DeepSeekChoice.
150 151 152 153 |
# File 'lib/durable/llm/providers/deepseek.rb', line 150 def initialize(choice) @message = DeepSeekMessage.new(choice['message']) @finish_reason = choice['finish_reason'] end |
Instance Attribute Details
#finish_reason ⇒ Object (readonly)
Returns the value of attribute finish_reason.
148 149 150 |
# File 'lib/durable/llm/providers/deepseek.rb', line 148 def finish_reason @finish_reason end |
#message ⇒ Object (readonly)
Returns the value of attribute message.
148 149 150 |
# File 'lib/durable/llm/providers/deepseek.rb', line 148 def @message end |
Instance Method Details
#to_s ⇒ Object
155 156 157 |
# File 'lib/durable/llm/providers/deepseek.rb', line 155 def to_s @message.to_s end |