mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-08-10 08:21:54 +00:00
Apply ruff formatting to usage metrics helpers.
This commit is contained in:
@@ -120,12 +120,9 @@ class UsageMetrics(BaseModel):
|
||||
reconciling here, ``prompt_tokens`` and ``total_tokens`` undercount
|
||||
billed usage on cached Anthropic workloads.
|
||||
"""
|
||||
return (
|
||||
"input_tokens" in usage_data
|
||||
and (
|
||||
"cache_read_input_tokens" in usage_data
|
||||
or "cache_creation_input_tokens" in usage_data
|
||||
)
|
||||
return "input_tokens" in usage_data and (
|
||||
"cache_read_input_tokens" in usage_data
|
||||
or "cache_creation_input_tokens" in usage_data
|
||||
)
|
||||
|
||||
@staticmethod
|
||||
|
||||
Reference in New Issue
Block a user