Class: Legion::Extensions::Llm::Routing::AttemptTargetKey
- Inherits:
-
Data
- Object
- Data
- Legion::Extensions::Llm::Routing::AttemptTargetKey
- Defined in:
- lib/legion/extensions/llm/routing/records.rb
Overview
The canonical request-local exclusion target: provider family, exact instance ID, and model. No operation, offering/lane ID, generation, tier, weight, or affinity. See section 15.1.
Instance Attribute Summary collapse
-
#instance_id ⇒ Object
readonly
Returns the value of attribute instance_id.
-
#model ⇒ Object
readonly
Returns the value of attribute model.
-
#provider_family ⇒ Object
readonly
Returns the value of attribute provider_family.
Instance Method Summary collapse
-
#initialize(provider_family:, instance_id:, model:) ⇒ AttemptTargetKey
constructor
A new instance of AttemptTargetKey.
Constructor Details
#initialize(provider_family:, instance_id:, model:) ⇒ AttemptTargetKey
Returns a new instance of AttemptTargetKey.
24 25 26 27 28 29 30 |
# File 'lib/legion/extensions/llm/routing/records.rb', line 24 def initialize(provider_family:, instance_id:, model:) key = Legion::Extensions::Llm::Inventory::Identity::InstanceKey.new( provider_family: provider_family, instance_id: instance_id ) model_text = Legion::Extensions::Llm::Inventory::Identity.normalize_text(value: model, field: :model) super(provider_family: key.provider_family, instance_id: key.instance_id, model: model_text) end |
Instance Attribute Details
#instance_id ⇒ Object (readonly)
Returns the value of attribute instance_id
23 24 25 |
# File 'lib/legion/extensions/llm/routing/records.rb', line 23 def instance_id @instance_id end |
#model ⇒ Object (readonly)
Returns the value of attribute model
23 24 25 |
# File 'lib/legion/extensions/llm/routing/records.rb', line 23 def model @model end |
#provider_family ⇒ Object (readonly)
Returns the value of attribute provider_family
23 24 25 |
# File 'lib/legion/extensions/llm/routing/records.rb', line 23 def provider_family @provider_family end |