Retrieve cumulative token usage for the current user or application
def get_usage_stats() -> Dict[str, int]
Dict[str, int]
"query"
"agent"
stats = db.get_usage_stats() print(stats["query"], "tokens consumed for queries")
Was this page helpful?