SmartEndpoint.Metrics
Wisej.AI.SmartEndpoint Metrics
Last updated
Wisej.AI.SmartEndpoint Metrics
Last updated
Namespace: Wisej.AI
Assembly: Wisej.AI (3.5.0.0)
Represents a collection of metrics related to token usage and call counts.
This class is used to track and manipulate metrics such as input tokens, output tokens, and the number of calls.
Initializes a new instance of the class.
: Gets the number of calls.
: Gets the number of input tokens.
Adds the specified number of input tokens, output tokens, and call count to the current metrics.
inputTokens
The number of input tokens to add.
outputTokens
The number of output tokens to add.
The number of calls to add. Default is 1.
usage
Resets the input tokens, output tokens, and call count to 0.
usage
: Gets the number of output tokens.
callCount
Returns: . The updated instance.
Adds the metrics from another instance to the current metrics.
The instance whose values are to be added.
Returns: . The updated instance.
This method updates the current metrics by adding the values from another instance.
Returns: . The updated instance.
Subtracts the metrics from another instance from the current metrics.
The instance whose values are to be subtracted.
Returns: . The updated instance.
This method updates the current metrics by subtracting the values from another instance.