Wen will it be done? — the one question every AI coding assistant answers badly.
wen is a skill for Claude Code that replaces hand-wavy time estimates ("this'll take about an hour") with token-grounded estimates: concrete, honest, and sharper every time you use them.
- The problem in one minute
- What you get
- How to read the estimate
- It gets smarter every time
- Install
- Try it
- FAQ
- What's in this repo
- Under the hood (optional)
When you ask an AI assistant "how long will this take?", it guesses in minutes or hours. Those guesses are almost always wrong — and not randomly wrong, but structurally wrong:
- An AI cannot feel time pass. From inside its own loop there is no clock, so any minutes figure is essentially made up.
- Different AI models work at very different speeds (up to ~3× apart). "10 minutes" means nothing without saying which model.
- Most of the real time goes into reading files and running commands, not "thinking" — and a naive guess ignores that entirely.
What an AI can actually count is tokens — the small pieces of text (roughly, fragments of words) that it reads and writes. Tokens are real, countable, and tied to a specific model's speed. So wen budgets in tokens first, then converts to time honestly.
In one line: time is invisible to an AI; tokens are not.
wenmeasures the thing that's actually measurable.
Before, you'd get a shrug:
"This should take a couple of hours, I think."
After installing wen, before any work starts you get a clean budget:
Estimate: ~52k tokens (38k in / 14k out)
Model: Sonnet ×4 + Opus ×1 (design step)
Wall: p50 ~6 min · p90 ~12 min
Tools: ~22 calls · cache: ~60% hit
Dispatch: 2 parallel Sonnet subagents for the edit phase
Five lines that tell you the size of the job, which AI model fits each part, a realistic time range, and whether the work should be split across parallel helpers.
For most tasks it's instant. Routine requests get a one-line version right inside the reply — no waiting, no extra step:
Estimate: ~34k tokens · Wall: p50 ~4 min · p90 ~7 min · smallThe fuller block above appears only for big or complex jobs, where the detail earns its keep.
| Line | What it means in plain English |
|---|---|
| Estimate | Total size of the job in tokens (the AI's natural unit), split into reading vs. writing. |
| Model | Which AI model suits each part — faster ones for bulk work, the strongest one for the tricky design step. |
| Wall | A realistic time range. p50 is the typical case; p90 is a bad-but-plausible day (about 1.8× longer). |
| Tools | How many file-reads and commands it expects, and how much already-loaded context it can reuse ("cache"). More reuse = faster. |
| Dispatch | Whether to split the work across parallel helper AIs ("subagents"), or just do it in order. |
You never compute any of this yourself. The skill produces the block automatically whenever the AI is about to estimate a duration or split up work.
Most estimators guess once and never check whether they were right. wen closes the loop.
When a task finishes, wen quietly records one line comparing the estimate to what actually happened — measured from real data, not the AI's memory (which, again, can't see it). Over time it learns its own bias and corrects future estimates on its own.
- 2026-05-21 · "add dark mode toggle" · est: 52000t · actual: 71000t · drift: 1.37
drift above 1.0 means the job was bigger than estimated; below 1.0 means smaller. After a handful of entries, wen stops using a generic safety factor and starts using your real history.
This log lives only on your machine, one per project. Nothing is ever sent anywhere.
Requirements: Claude Code, plus python3 and bash (already present on macOS and most Linux).
git clone https://github.com/0x2kNJ/wen.git ~/.claude/skills/token-budgetOpen ~/.claude/settings.json and add this hooks block (merge it with anything already there):
{
"hooks": {
"SessionStart": [
{ "hooks": [{ "type": "command", "command": "bash ~/.claude/skills/token-budget/hooks/session-start.sh" }] }
],
"Stop": [
{ "hooks": [{ "type": "command", "command": "python3 ~/.claude/skills/token-budget/hooks/stop-ledger.py" }] }
]
}
}- The SessionStart hook reminds the AI to use
wenwhenever it's about to estimate time. - The Stop hook records real results so the skill can learn.
That's it. Next time you ask "how long will this take?", you'll get the block.
Prefer not to edit JSON? You can skip Step 2 — the skill still works when invoked directly. You just won't get the automatic reminders or the self-learning log.
Ask Claude Code something like:
"How long would it take to add user login to this app?"
Instead of a vague guess you'll get the estimate block — and once the work is done, a new line appears in the learning log.
Do I need to understand tokens? No. You read the time range and the suggestion; the skill handles the tokens.
Does this slow Claude Code down? Barely. The recording step runs in well under a tenth of a second, and only after a turn ends.
Does it send my data anywhere? No. The learning log is a plain text file on your machine, one per project. It never leaves.
What if I ignore the "parallel helpers" suggestion? That's fine — and useful. The skill notices when its advice was overridden and uses that to recalibrate.
Is the time estimate guaranteed?
No estimate ever is. That's exactly why you get a range (p50/p90) and why it learns from real outcomes instead of pretending.
| File | What it's for |
|---|---|
SKILL.md |
The skill itself — the instructions Claude Code follows. |
taxonomy.md |
The dials: model speeds and per-task size defaults. Editable. |
ledger-init.md |
How the learning log works and how to read it. |
hooks/session-start.sh |
Reminds the AI to use the skill. |
hooks/stop-ledger.py |
Records real results automatically — the self-learning engine. |
DESIGN.md |
The "why" — original design rationale, for the curious. |
For the technically curious: wen decomposes a task into typed subtasks, assigns each a model and token cost from taxonomy.md, sums them, and corrects the total by the median "drift" from recent history. The Stop hook reads the session transcript after each turn, sums real token usage (deduplicated per message, since one response spans several transcript lines), bounds each task's time window, folds in any subagent costs, and writes one calibrated ledger line. When the skill recommends splitting work across parallel subagents, it also records what the sequential alternative was predicted to cost — so across many tasks you can see whether parallelizing actually pays off, without ever fabricating a number that can't be measured.
Full mechanics live in SKILL.md and ledger-init.md.
MIT — free to use, fork, and tune the dials.