log_usage
Log an LLM API call with token counts to track usage. Use after each Claude, GPT, or Gemini response.
Instructions
Log a single LLM API call with token counts. Call this after every Claude/GPT/Gemini response.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | Yes | Model ID, e.g. claude-sonnet-4-6 | |
| input_tokens | Yes | ||
| output_tokens | Yes | ||
| session_id | No | default | |
| provider | No | anthropic | |
| cache_read_tokens | No | ||
| cache_write_tokens | No | ||
| task_type | No | e.g. coding, debugging, writing | |
| project | No | ||
| notes | No |