Track exactly how much time your team spends debugging AI-generated code.
Whether you're a solo developer or a 500-person engineering org, bugclock gives you honest data on the real cost of AI-generated code — so you can make smarter decisions about when and how to use it.
Claude (and other AI tools) write code fast. But debugging that code takes time — time that's invisible in sprint planning, productivity metrics, and AI ROI discussions.
bugclock makes that time visible.
Total debug time (last 30 days): 143.5 min
Average per session: 11.9 min
Most debugged file: src/auth/login.py (4 sessions, 61.5 min)
# Python
pip install bugclock
# JavaScript / Node.js
npm install -g bugclockRequires Python 3.8+ or Node.js 16+. Works on macOS, Linux, and Windows.
# 1. Initialize in your project repo
cd your-project/
bugclock init
# 2. Mark AI-generated files
bugclock mark src/auth/login.py
# — or add a comment anywhere in the file —
# @claude-generated
# 3. Start a debug session
bugclock start -f src/auth/login.py -n "JWT tokens not expiring"
# 4. Fix it, then stop
bugclock stop --resolved
# 5. See your analytics
bugclock report| Method | Example |
|---|---|
| Comment marker | Add # @claude-generated to any file (any language) |
| Git commit message | Commits containing [claude] or generated by claude |
| Manual mark | bugclock mark <file> — saved to a team-committable registry |
After bugclock init, a silent post-commit hook runs on every commit:
- Checks if modified files are AI-generated
- Looks for fix-related keywords in the commit message (
fix,bug,patch,resolve…) - Estimates session duration from file modification timestamps
- Auto-records the debug session — no
start/stopneeded
Your team gets data even when they forget to run any commands.
bugclock init Set up DB + git hooks in the current repo
bugclock start Begin a debug session
-f / --file <path> File(s) being debugged (repeatable)
-n / --note <text> Note about the bug
bugclock stop End the active session
--resolved / --abandoned Outcome (default: resolved)
bugclock status Show the active session + elapsed time
bugclock report Full analytics dashboard
--days <N> Time window in days (default: 30)
bugclock sessions List recent sessions
--limit <N>
--status resolved|abandoned|active
bugclock scan Find all AI-generated files in the repo
bugclock mark <file> Manually tag a file as AI-generated
bugclock export Export data as JSON or CSV
--format json|csv
--days <N>
-o / --output <path>
bugclock uninstall Remove git hooks
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
bugclock · last 30 days
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Total Sessions: 12
Resolved: 10
Abandoned: 2
Total Time: 143.5 min
Avg / Session: 11.9 min
Longest: 48.2 min
Daily Debug Time (minutes)
2026-04-12 12.3 ████████░░░░░░░░░░░░
2026-04-13 0.0 ░░░░░░░░░░░░░░░░░░░░
2026-04-14 48.2 ████████████████████
2026-04-15 8.5 █████░░░░░░░░░░░░░░░
Most-Debugged Files
src/auth/login.py 4 sessions 61.5 min
src/api/payments.py 3 sessions 38.0 min
src/utils/parser.py 2 sessions 22.0 min
The registry is a simple JSON file — commit it so every teammate's tracker stays in sync:
git add .claude-tracker/marked_files.json
git commit -m "chore: mark AI-generated files for debug tracking"# CSV → Excel / Google Sheets / Tableau
bugclock export --format csv --days 90 -o debug_data.csv
# JSON → Grafana / internal dashboards
bugclock export --format json --days 90 -o debug_data.json# .github/workflows/debug-report.yml
name: Weekly Debug Report
on:
schedule:
- cron: "0 9 * * MON" # every Monday at 9am
jobs:
report:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: pip install bugclock
- run: bugclock report --days 7Any of these work — pick what fits your language:
# @claude-generated ← Python// @claude-generated ← JavaScript / TypeScript// generated by claude ← Go// @claude-generated ← Rust// @claude-generated ← Java-- generated by claude ← SQLOr use your commit message — no file changes required:
git commit -m "[claude] add user authentication flow"| Data | Where it lives | Committed? |
|---|---|---|
| Session timings | .claude-tracker/sessions.json |
No — gitignored |
| Marked file registry | .claude-tracker/marked_files.json |
Optional — your choice |
Nothing is ever sent to any server. The tracker is entirely local.
Pull requests are welcome. To get started:
git clone https://github.com/adhithyakiran/bugclock
cd bugclock
# Python
pip install -e ".[dev]"
# Node.js
cd npm && npm installPlease open an issue first for large changes.
- npm: https://www.npmjs.com/package/bugclock
- PyPI: https://pypi.org/project/bugclock/
- GitHub: https://github.com/adhithyakiran/bugclock
MIT — Adhithya Kiran