- Expression doesn't use `img` → image tokens stay in `p`, priced at $2.50
### `len` — Context Length Variable
`len` represents the total input context length, designed for **tier condition evaluation** (e.g. `len <= 200000 ? ...`). Unlike `p`, `len` is never reduced by sub-category exclusion.
**Computation rules:**
-**Non-Claude (GPT/OpenAI format)**: `len = prompt_tokens` (the raw total from the upstream response)
-**Claude format**: `len = input_tokens + cache_read_tokens + cache_creation_tokens` (since Claude's `input_tokens` is text-only, cache must be added back to reflect full context length)
This ensures that heavy cache usage doesn't cause the tier condition to incorrectly evaluate to a lower tier. For example, if a request has 300K total context but 250K is cached, `p` with cache subtracted would be only 50K (standard tier), while `len` correctly reports 300K (long-context tier).
### Quota Conversion
Expression coefficients are $/1M tokens. Conversion to internal quota: