Class: LaunchDarkly::Server::AI::TokenUsage
- Inherits:
-
Object
- Object
- LaunchDarkly::Server::AI::TokenUsage
- Defined in:
- lib/server/ai/ai_config_tracker.rb
Overview
Tracks token usage for AI operations.
Instance Attribute Summary collapse
-
#input ⇒ Object
readonly
Returns the value of attribute input.
-
#output ⇒ Object
readonly
Returns the value of attribute output.
-
#total ⇒ Object
readonly
Returns the value of attribute total.
Instance Method Summary collapse
-
#initialize(total: nil, input: nil, output: nil) ⇒ TokenUsage
constructor
A new instance of TokenUsage.
Constructor Details
#initialize(total: nil, input: nil, output: nil) ⇒ TokenUsage
Returns a new instance of TokenUsage.
19 20 21 22 23 |
# File 'lib/server/ai/ai_config_tracker.rb', line 19 def initialize(total: nil, input: nil, output: nil) @total = total @input = input @output = output end |
Instance Attribute Details
#input ⇒ Object (readonly)
Returns the value of attribute input.
12 13 14 |
# File 'lib/server/ai/ai_config_tracker.rb', line 12 def input @input end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
12 13 14 |
# File 'lib/server/ai/ai_config_tracker.rb', line 12 def output @output end |
#total ⇒ Object (readonly)
Returns the value of attribute total.
12 13 14 |
# File 'lib/server/ai/ai_config_tracker.rb', line 12 def total @total end |