{
  "markdown": "# claude-eta\n\n<p align=\"center\">\n  <a href=\"https://github.com/mmmprod/claude-eta/blob/main/LICENSE\"><img src=\"https://img.shields.io/badge/license-MIT-blue?style=flat-square\" alt=\"MIT License\" /></a>\n  <a href=\"https://nodejs.org\"><img src=\"https://img.shields.io/badge/node-%3E%3D18-brightgreen?style=flat-square&logo=node.js&logoColor=white\" alt=\"Node >= 18\" /></a>\n  <a href=\"https://claude.com\"><img src=\"https://img.shields.io/badge/Claude_Code-plugin-D97757?style=flat-square&logo=claude&logoColor=white\" alt=\"Claude Code Plugin\" /></a>\n  <img src=\"https://img.shields.io/badge/data-100%25_local-222?style=flat-square&logo=shield&logoColor=white\" alt=\"100% local by default\" />\n  <a href=\"https://github.com/mmmprod/claude-eta/stargazers\"><img src=\"https://img.shields.io/github/stars/mmmprod/claude-eta?style=flat-square&color=yellow\" alt=\"GitHub stars\" /></a>\n</p>\n\n## Claude has no concept of time. claude-eta gives it one.\n\nClaude says \"this should take about 2 days.\" You finish in 12 minutes.\n\nLLMs have zero feedback between what they promise and what actually happens.\nclaude-eta creates that loop: it times every task, learns your velocity,\nand feeds real data back into Claude before it responds.\n\nAfter 10 tasks of the same type, ETAs appear automatically — calibrated on YOUR project.\n\n<p align=\"center\">\n  <img src=\"docs/eta-demo.gif\" alt=\"claude-eta ETA demo\" width=\"979\" />\n</p>\n\n### How it works\n\n1. You type a prompt\n2. claude-eta classifies it, starts a timer, injects your velocity stats\n3. Claude works. Tool calls, file ops, errors counted silently.\n4. Task completes. Real duration recorded. Next estimate improves.\n5. After 10 tasks of the same type, ETAs appear automatically at the start of Claude's responses.\n\n## Eval results\n\nWalk-forward replay over real, single-developer task history.\n\n- **p80 coverage at prompt** typically lands in the **75–80% target range** (target: ~80%, since p80 is by definition the value the real duration should fall at or below 80% of the time).\n- **MdAPE** (median absolute % error) sits in the **70–95% range** depending on the evaluator stage (`prompt` / `first edit` / `first bash`) — expected for a single-user dataset and tightens as task volume grows.\n\nThe exact numbers, the per-stage breakdown, and the version they were captured at live in [docs/eval-snapshot.md](docs/eval-snapshot.md), refreshed at each release. Run `/eta eval` to compute the same report on your own local task history.\n\n### Also catches repair loops\n\n<p align=\"center\">\n  <img src=\"docs/loop-detector-demo.gif\" alt=\"claude-eta loop detector demo\" width=\"979\" />\n</p>\n\nWhen Claude hits the same error 3+ times, claude-eta detects the pattern and intervenes:\n\n- At 3x: warning injected at the next prompt\n- At 5x: blocks and forces a strategy change\n\nThe key: it fingerprints error CONTENT, not just count. TDD (different errors each time) won't trigger it.\n\n### Also catches hallucinated estimates\n\nWhen Claude says \"2 days\" for a 10-minute task, the bullshit detector corrects inline\nusing your measured project data.\n\n## Requirements\n\n- Node.js >= 18\n- Claude Code CLI (latest recommended)\n- macOS, Linux, Windows (WSL)\n\n## Install\n\nTested with the current Claude Code CLI. The working install flow is:\n\n```bash\nclaude plugin marketplace add mmmprod/claude-eta\nclaude plugin install claude-eta\n```\n\nIn any already-open Claude Code session, run `/reload-plugins` before trying `/eta`.\n\nFallback from a local checkout:\n\n```bash\ngit clone https://github.com/mmmprod/claude-eta.git\ncd claude-eta\nclaude plugin marketplace add ./\nclaude plugin install claude-eta --scope local\n```\n\nCurrent Claude Code uses `claude plugin install`, not `claude plugin add`.\n\n### Update\n\n```bash\nclaude plugin marketplace update claude-eta && claude plugin update claude-eta@claude-eta\n```\n\nThen restart Claude Code or run `/reload-plugins`.\n\n### Uninstall\n\n```bash\nclaude plugin uninstall claude-eta\n```\n\nLocal data stays under `${CLAUDE_PLUGIN_DATA}` (typically `~/.claude/plugins/data/claude-eta-*/`) until you delete it manually.\n\n## Commands\n\n| Command | What it does |\n|---------|-------------|\n| `/eta` | Current session: active task, completed count, durations, tool calls |\n| `/eta history` | Last 20 completed tasks with real durations and classifications |\n| `/eta stats` | Averages by task type: median duration, tool calls, files touched |\n| `/eta insights` | 9 deep analyses: timing patterns, model trends, error overhead, fatigue |\n| `/eta eval` | Offline walk-forward accuracy report on your own data |\n| `/eta inspect` | Raw view of stored data: project fingerprint, turn count, latest entry |\n| `/eta auto` | Auto-ETA status and per-type accuracy |\n| `/eta auto on/off` | Toggle automatic ETA injection at the start of Claude's responses |\n| `/eta compare` | Read-only comparison against community baselines |\n| `/eta contribute` | Preview anonymized data (dry run, requires `/eta community on` first) |\n| `/eta contribute --confirm` | Upload anonymized data |\n| `/eta community on/off` | Enable or disable community sharing consent |\n| `/eta export` | Save anonymized data locally as JSON |\n| `/eta recap` | Today's daily journal summary |\n| `/eta help` | Full command list |\n\n## Why not just `--max-turns`?\n\n| | `--max-turns` | claude-eta |\n|---|---|---|\n| Detection | Counts turns blindly | Fingerprints error content |\n| Trigger | After N turns (any turns) | After 3x same error |\n| Response | Kills the session | Injects correction context |\n| False positives | Cuts long legitimate sessions | Only fires on repeated identical errors |\n| Learning | None | Learns your project's patterns over time |\n\n`--max-turns 20` stops Claude after 20 turns whether it's stuck or productive.\n\nclaude-eta only intervenes when the same error repeats, and instead of killing\nthe session, it tells Claude what's going wrong and asks it to change strategy.\n\nThey're complementary: use `--max-turns` as a hard ceiling, use claude-eta\nfor intelligent early intervention.\n\n## Privacy\n\nEverything is local by default. No cloud. No telemetry. No upload unless you explicitly opt in.\n\n`/eta inspect` shows the current stored view.\n\n`/eta contribute` is manual and opt-in only. It previews exactly what would be sent before upload.\n\nSee [SECURITY.md](SECURITY.md) for the full storage and community-data details.\n\n## Performance\n\nclaude-eta hooks run on every Claude Code lifecycle event.\nTypical overhead is 30–50ms per hook on modern hardware (dominated by Node.js cold start).\n\nRun `./scripts/bench-hooks.sh` to measure on your machine.\n\nPostToolUse is the hot path. It reads and writes a single small JSON file (~1KB).\nNo historical data is loaded. No stats are computed.\n\n## Advanced\n\n<details>\n<summary>How the loop detector works</summary>\n\n```text\nTDD (normal):     edit -> test fail A -> fix -> test fail B -> fix -> pass\n\nRepair loop:      edit -> test fail A -> edit -> test fail A -> edit -> test fail A\n                                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n                                        claude-eta detects this pattern\n```\n\nThe key difference: in a loop, the same error keeps returning. claude-eta fingerprints\nerror content, normalizing away paths, numbers, and quoted values so structurally identical\nfailures match.\n\n</details>\n\n<details>\n<summary>Auto-ETA (opt-in estimated duration at response start)</summary>\n\n`/eta auto on` enables automatic ETA injection when claude-eta has enough local calibration for the task type.\n\n`/eta auto` shows whether the feature is active and how accurate its recent p80 upper-bound coverage has been.\n\n</details>\n\n<details>\n<summary>Community baselines</summary>\n\n`/eta compare` is read-only and fetches aggregate community baselines.\n\n`/eta contribute` stays blocked until you explicitly run `/eta community on`.\n\nOnly anonymized per-task aggregates are sent. Prompts, code, file paths, event logs, and project names are not uploaded.\n\n</details>\n\n<details>\n<summary>Self-hosting community baselines</summary>\n\nTo point `/eta compare` and `/eta contribute` at your own Supabase project, set:\n\n- `CLAUDE_ETA_SUPABASE_URL`\n- `CLAUDE_ETA_SUPABASE_KEY`\n\nThe shipped anon key is intentionally public and restricted to `INSERT velocity_records`\nand `SELECT baselines_cache`.\n\n</details>\n\n<details>\n<summary>Insights (9 analyses)</summary>\n\n`/eta insights` surfaces deeper patterns once enough task history exists:\n\n- task type breakdowns\n- tool and file-operation correlations\n- timing patterns\n- model and workflow trends\n\n</details>\n\n## License\n\nMIT\n",
  "bytes": 8562,
  "sha": "8926b26d058568b781840ddef7680c2022c5d75bec0a42a2999de7cb2068ca90",
  "repo_slug": "mmmprod/claude-eta",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/plg_mmmprod_claude_eta_claude_eta_cbcdca00/readme"
}