Prompture Cost Tracking
# Prompture Cost & Usage Tracking
Prompture includes a built-in usage tracker that automatically records every LLM call as an individual event in a local SQLite database. No setup required -- it works out of the box.
**Privacy first:** The tracker stores zero message content. Only metadata -- model name, token counts, cost, timing, and opaque IDs for grouping.
Database location: `~/.prompture/usage/usage.db`
---
## Table of Contents
- [Automatic Tracking](#automatic-tracking)
- [Context Scoping](#context-scoping)
- [Querying Usage](#querying-usage)
- [Budget Management](#budget-management)
- [Cost Calculation API](#cost-calculation-api)
- [Direct SQLite Access](#direct-sqlite-access)
- [DriverCallbacks Integration](#drivercallbacks-integration)
- [Configuration](#configuration)
- [Event Schema Reference](#event-schema-reference)
- [SQL Views Reference](#sql-views-reference)
- [Migration from Legacy Ledger](#migration-from-legacy-ledger)
---
## Automatic Tracking
Every LLM call made through Prompture is automatically tracked. This includes:
- Extraction functions (`extract_with_model`, `ask_for_json`, `render_output`, etc.)
- Conversations (`Conversation.ask()`, `Conversation.ask_for_json()`, etc.)
- Agents (`Agent.run()`, sub-agent calls)
- Async variants of all the abovewhen to use it
Community prompt sourced from the open-source GitHub repo jhd3197/Prompture (MIT). A "Prompture Cost Tracking" style prompt — adapt the placeholders and specifics to your task. Imported as-is and not independently retested here, so check the output before relying on it.
tags
codingcommunitydeveloper
source
jhd3197/Prompture · MIT
more in Coding
Coding✓ tested
Senior code review (strict mode)
senior staff engineer running a merciless but fair review
Coding✓ tested
Debug by hypothesis, not by guessing
debugging partner who forms theories before touching code
Coding✓ tested
Generate tests from described behavior
test engineer who writes tests that would actually catch regressions