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.
21 22 23 24 25 |
# File 'lib/server/ai/ai_config_tracker.rb', line 21 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.
14 15 16 |
# File 'lib/server/ai/ai_config_tracker.rb', line 14 def input @input end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
14 15 16 |
# File 'lib/server/ai/ai_config_tracker.rb', line 14 def output @output end |
#total ⇒ Object (readonly)
Returns the value of attribute total.
14 15 16 |
# File 'lib/server/ai/ai_config_tracker.rb', line 14 def total @total end |