One dashboard for AI cost and behavior across your developers’ local AI tools and your product’s AI agents.
Your Local
Passive collector for Claude Code, Codex, Cursor, Ollama, Aider, and Continue.dev. Zero code changes.
Jump to setupYour Apps
One-line SDK wrapper for your product's AI calls. Python and JavaScript supported.
Jump to setupUse one or both.
Path A
Reads session files written by local AI tools on any developer machine. Supports Claude Code, Claude Desktop, Codex CLI, Ollama, Cursor, Aider, and Continue.dev.
Requirements: Python 3.9+, Mac or Linux
git clone https://github.com/Kmaralla/ai-watcher.git
cd ai-watcher/collector
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txtexport AIWATCHER_API_KEY=aw_live_...
export AIWATCHER_API_URL=https://ai-watcher-pi.vercel.app
python3 main.pyThe collector runs in the foreground and polls every 30 seconds. Sessions appear in Your Local → Sessions within one polling cycle.
| Tool | Source path |
|---|---|
| Claude Code | ~/.claude/telemetry/ and ~/.claude/projects/ |
| Claude Desktop | ~/Library/Application Support/Claude/local-agent-mode-sessions/ |
| Codex CLI | ~/.codex/state_5.sqlite |
| Ollama | http://localhost:11434 (local API) |
| Cursor | ~/Library/Application Support/Cursor/logs/ |
| Aider | ~/.aider/ |
| Continue.dev | ~/.continue/logs/ |
The collector never sends prompt content — only session metadata, token counts, model names, and timing.
Path B
Wraps your product’s AI calls and sends telemetry to AIWatcher. Each wrapped call creates a session in Your Apps with cost, token counts, and a full event timeline.
Pick your stack
Works with any Python backend: FastAPI, Flask, Django, AWS Lambda, scripts, or any other runtime.
Install
# Local install (PyPI publish coming soon)
pip install -e /path/to/ai-watcher/sdkEnvironment variables
export AIWATCHER_API_KEY=aw_live_...
export AIWATCHER_API_URL=https://ai-watcher-pi.vercel.appSingle AI call
from ai_watcher import track_llm
result = track_llm(
'classify-document', # action name
lambda: openai.chat.completions.create( # your existing call
model='gpt-4o',
messages=[{'role': 'user', 'content': doc_text}]
),
{
'human_id': current_user.email, # who triggered this
'agent_name': 'doc-classifier', # your agent name
'model': 'gpt-4o', # model being called
'session_name': 'Classify: invoice', # shown in dashboard
'input': {'doc_type': 'invoice'} # metadata, no PII
}
)
# result is unchanged — track_llm returns exactly what your fn returnsChained calls (one session, multiple model calls)
from ai_watcher import track_chain
results = track_chain(
steps=[
{
'action': 'extract',
'model': 'gpt-4o',
'input': {'pages': 3},
'fn': lambda: openai.chat.completions.create(...)
},
{
'action': 'classify',
'model': 'claude-sonnet-4-20250514',
'input': {'text_preview': preview[:100]},
'fn': lambda: anthropic.messages.create(...)
}
],
opts={
'human_id': customer_id,
'agent_name': 'shipping-pipeline',
'session_name': 'Process Shipping Document',
'framework': 'python'
}
)
# results is a list matching the order of stepsAWS Lambda
Same pattern. Add env vars to your Lambda configuration:
AIWATCHER_API_KEY = aw_live_...
AIWATCHER_API_URL = https://ai-watcher-pi.vercel.appfrom ai_watcher import track_llm
def handler(event, context):
return track_llm(
'classify-document',
lambda: openai.chat.completions.create(
model='gpt-4o',
messages=[{'role': 'user', 'content': event['text']}]
),
{
'human_id': event.get('customer_id', 'unknown'),
'agent_name': 'doc-classifier',
'model': 'gpt-4o',
'framework': 'aws-lambda',
'session_name': f"Classify: {event.get('doc_type', 'document')}",
'input': {'doc_type': event.get('doc_type')}
}
)track_llm uses only the Python standard library (urllib). No extra dependencies are added to your Lambda bundle.
After your first instrumented call, open the dashboard:
Each session shows the human ID, session name, model and token counts, estimated cost, and a full event timeline with input metadata.
Captured
Not captured
| Model | Provider | Pricing (per 1M tokens in / out) |
|---|---|---|
| claude-sonnet-4-20250514 | Anthropic | $3.00 / $15.00 |
| claude-haiku-4-5-20251001 | Anthropic | $0.80 / $4.00 |
| claude-opus-4-20250514 | Anthropic | $5.00 / $25.00 |
| gpt-4o | OpenAI | $2.50 / $10.00 |
| gpt-4o-mini | OpenAI | $0.15 / $0.60 |
| llama3 via Ollama | Local | $0 |
Codex CLI and Claude Code sessions are subscription-billed. Token usage is shown in the dashboard but no dollar cost is applied. Configure this under Settings → AI Provider Billing.
Contact the team directly:
We’re working with a small number of design partners in 2026.
We reply within 48 hours.