Know what the estimate means.
A single token number can conceal very different levels of certainty. Multimodal payloads, endpoint behavior, usage reports, and model settings need a vocabulary that tells a developer what is known.
Decisions that
shape the system.
Name the evidence level
Expose exact_api, actual_usage, and offline_estimate instead of silently presenting an estimate as an exact count.
Match behavior across languages
Use shared schemas, fixtures, and catalog-generated metadata for TypeScript and Python APIs.
Connect counting to decisions
Provide usage normalization, cost estimation, budget validation, and model-policy checks rather than an isolated text counter.
Keep credentials on the server
Treat the separate key-pool prototype as infrastructure with its own access, tenancy, accounting, and production-readiness requirements.
- Request profile
- Count or estimate
- Budget check
- Actual usage
- Reconcile
Inside the implementation
The key design choice is explicit uncertainty. An offline estimate remains labeled as such, and an unsupported component remains unknown. Model settings and dated catalogs inform policy; they do not magically change the certainty of an input-token estimate.
What the work
demonstrates.
The repository contains a dual-language SDK release candidate with common contracts and documented accuracy tiers. Echo uses the SDK locally for its accounting integration.
Why it matters to a client
Useful for teams integrating AI into products that need explainable costs, shared budgets, and predictable interfaces.