Class: Rubino::Agent::FallbackChain::Entry
- Inherits:
-
Struct
- Object
- Struct
- Rubino::Agent::FallbackChain::Entry
- Defined in:
- lib/rubino/agent/fallback_chain.rb
Overview
One backend in the chain. provider/model are required to be usable; an entry missing either is treated as invalid and skipped on advance.
Instance Attribute Summary collapse
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#base_url ⇒ Object
Returns the value of attribute base_url.
-
#model ⇒ Object
Returns the value of attribute model.
-
#provider ⇒ Object
Returns the value of attribute provider.
Instance Method Summary collapse
Instance Attribute Details
#api_key ⇒ Object
Returns the value of attribute api_key
39 40 41 |
# File 'lib/rubino/agent/fallback_chain.rb', line 39 def api_key @api_key end |
#base_url ⇒ Object
Returns the value of attribute base_url
39 40 41 |
# File 'lib/rubino/agent/fallback_chain.rb', line 39 def base_url @base_url end |
#model ⇒ Object
Returns the value of attribute model
39 40 41 |
# File 'lib/rubino/agent/fallback_chain.rb', line 39 def model @model end |
#provider ⇒ Object
Returns the value of attribute provider
39 40 41 |
# File 'lib/rubino/agent/fallback_chain.rb', line 39 def provider @provider end |
Instance Method Details
#usable? ⇒ Boolean
40 41 42 |
# File 'lib/rubino/agent/fallback_chain.rb', line 40 def usable? !provider.to_s.strip.empty? && !model.to_s.strip.empty? end |