h/ himanshu.devDownload résumé
CASE STUDY / NPM PACKAGE · REACT + TYPESCRIPT

tokencharts

A React and TypeScript library for tracking LLM token usage, cost, latency and prompt-cache savings, published on npm.

5AI providers normalised
0dependencies in the core
SVGcharts, no canvas
SSRcore runs on the server
THE PROBLEM

Why it was hard

Every AI provider reports token usage in a different shape, so teams end up writing the same conversion and charting code again and again.

WHAT I BUILT

How it works

ReactTypeScriptSVGLLM observabilitynpm
TAKEAWAY

What I learned

A small, dependency-free core makes a package easy to trust and easy to use anywhere, from a dashboard to a server job.

MORE

Related

NEXT STEP

Need something like tokencharts?

Tell me what you want to build. I reply with questions, then a written scope before any work starts.