# Token counter telemetry

> **Upcoming in 1.0 (preview). These pages describe the main branch of LLMSlim Core, which becomes the 0.13 release candidate and then 1.0. `pip install llmslim` installs 0.12.0 today, which doesn't have everything described here.** Docs for what pip installs: https://www.llmslim.app/docs.md

> Understand token-count precision in each result.

Read token_counter_used and handle the heuristic fallback appropriately.

Category: API Reference · Version: 1.0 · Updated: September 2026 · 2 min read

## Inspect the counter

token_counter_used reports the process-level active counter: tiktoken or heuristic.

tokens.py:

```python
from llmslim import compress
result = compress(long_text)
print(result.token_counter_used)
```

## FAQ

### When is the heuristic used?

When the process cannot load the tiktoken encoder. LLMSlim emits one warning per process.

## Related

- [Compression quickstart](https://www.llmslim.app/docs/1.0/getting-started.md)

Canonical page: https://www.llmslim.app/docs/1.0/telemetry
