{"repo":"ByteBunny777/Promptrace","free":true,"listed":false,"github":"https://github.com/ByteBunny777/Promptrace","clone":"git clone https://github.com/ByteBunny777/Promptrace.git","description":"Lightweight, dependency-free logging and analytics for LLM API calls — track tokens, cost, and latency to a plain JSONL file.","language":"Python","stars":92,"topics":["anthropic","api-monitoring","cli","cost-tracking","developer-tools","jsonl","llm","logging","observability","openai"],"license":"MIT","category":"ai-agents","readme_excerpt":"promptrace Lightweight, dependency-free logging and analytics for LLM API calls. Log every prompt/response with token counts, latency, and estimated cost to a plain JSONL file — then get instant stats from the CLI or Python API. No external services, no config, no vendor lock-in: just a file on disk you own. Why Most projects that call LLM APIs end up needing the same three things sooner or later: how many tokens am I burning through , how much is this costing me , and which calls are slow . promptrace gives you all three with two lines of code and zero dependencies — everything is Python standard library. Install Usage Log calls from your code Analyze from the command line Or from Python Privacy: redact prompt/response text If you don't want raw prompt/response text sitting on disk, turn it off globally or per-call — only a SHA-256 hash and character length are kept, still enough to detect duplicates or check length distributions: Cost estimation promptrace ships with a small, editable pricing table (USD per 1,000 tokens) covering common models. Unknown models simply report cost usd=None instead of guessing. Bring your own table: or load one from a JSON file with load pricing file(\"pricing.json\") . Design notes - Storage format is plain JSONL — one call per line, human-readable, append-only, trivially diffable, and greppable without any tooling. - No network calls, no external dependencies. The whole library is standard-library Python, so it's safe to drop into any project. ","default_branch":null,"files":null,"tree":[],"storefront":"/r/ByteBunny777","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/ByteBunny777/Promptrace/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}