/CodeTrain
CodeTrain: the AI that won't write your code
An AI trainer that teaches you on your own codebase and never writes the code for you. Free, no card, live today.
CodeTrain is an AI trainer that teaches developers on their own codebase and refuses to write the code for them. It breaks a request into two to six steps, you type every line, and it runs and grades what you wrote against each step’s criteria. The free tier needs no card.
Somewhere on your team right now, a pull request is getting approved by someone who couldn’t rewrite it from scratch. Not because they’re lazy. The assistant wrote it, the tests passed, the diff looked plausible, and the sprint doesn’t stop for philosophy. Do that for a year and you get a team that ships faster every quarter and understands a little less of its own codebase every quarter too.
I ran into this a few times while building the start of InferHaven. The whole point of this company is that you shouldn’t have to hand your code to someone else to get the benefits of AI. But there’s a second thing quietly leaving the building, and no firewall catches it: the skill. When the model types and the human tabs through, the knowledge of how your system actually works stops living in your engineers and starts living in a vendor’s autocomplete.
So I built the opposite tool. Today I’m launching CodeTrain: a hands-on AI trainer that teaches developers on their own codebase, and refuses to write the code for them.
What does a lesson actually look like?
A lesson is two to six steps, each one concrete thing to write in an editor with a Run button. Your code executes immediately, the tutor grades it against that step’s criteria and shows a check or a cross beside each one, then either advances you or asks the question that makes the gap visible. Fail repeatedly and it splits the step rather than handing over the answer.
You ask CodeTrain something real. “Walk me through adding a health check to this Dockerfile.” “I don’t actually understand our retry logic, teach it to me.” It breaks that into a short lesson, usually two to six steps, each one small enough to hold in your head.
Each step is one concrete thing to write in a syntax-highlighted editor with a Run button. You type it. The code executes immediately: Python and JavaScript run right in your browser, shell and a few other runtimes run in an isolated sandbox, web stuff renders in a live preview. Then the tutor reviews what you wrote against the step’s criteria, shows you ✓ and ✗ per criterion, and either advances you or asks the question that makes you see what’s off. Fail a step multiple times and it doesn’t dump the solution on you. It cuts the step in half.
$ codetrain start --mode repo
Session a6502084e8254276a394d5be578e9229 started (repo mode).
Plan: team
Modes: sandbox, repo
Sessions: 0/1000 this month
Usage: 0% of your monthly allowance (100% left)
Models: haiku, sonnet
Your tutor is open in the browser:
http://127.0.0.1:7341
(workspace: /tmp/codetrain-repo-v555lhi7/repo)
Tutoring is live in your browser — keep this window open. Ctrl-C to stop.
That’s repo mode, the paid tier. The tutor reads your actual repository, builds lessons out of your actual code, and at the end of a guided lesson (can run exploration only if desired) it proposes one integrated patch that lands the code you wrote onto your real branch. You review it like any other diff. Free tier does not include repo mode and drops you into sandbox practice instead: same tutor, same you-type-it rule, generated exercises from natural language.
Here is that health-check lesson, start to finish. Step 2 has you draft the probe on a scratch Dockerfile where mistakes are free:
Step 3 moves the line you wrote into the real Dockerfile, all 360-odd lines of it, in the one spot where Docker will actually honour it:
Pass the final step and the tutor offers the one targeted patch it guided you on: the diff of what you typed, applied to your working tree only after you approve it.
This is not another assistant
An assistant’s job is producing code. CodeTrain’s job is producing engineers who understand code, and those two goals pull in opposite directions: the fastest way to ship a diff is to write it for you, and the fastest way to teach is to refuse. Use both tools, for different reasons.
Don’t get me wrong. I use coding assistants daily and they’re great at their job. Their job is producing code. CodeTrain’s job is producing engineers who understand code, and those jobs basically pull in opposite directions.
Default: it types
- You describe, it writes
- Output: working code, fast
- Understanding is optional
- Great when shipping is the goal
Default: you type
- It plans tiny steps, you write them
- Output: a developer who gets it
- Understanding is graded, per step
- Great when the goal IS your team
Use both. Seriously. Let the assistant ship the sprint while CodeTrain makes sure the person accepting its diffs could have written them.
Code got cheap. Understanding didn’t. Train the part that’s still expensive.
— The CodeTrain wager
An InferHaven product
The agent runs on your machine, sandbox lessons execute in your browser rather than on our servers, and repo mode works against your local checkout. You can also route lessons through your own model account. It is the same instinct as running your models offline by default, applied to a second thing that leaks: the skill.
InferHaven exists because your code is yours and should stay on your hardware. CodeTrain extends the same instinct to where your code lives secondly: wetware, brains, good ol’ humans. Keep the code in-house, keep the skill in-house with it.
It’s built the way you’d expect from us. The agent runs on your machine. Sandbox lessons execute in your browser, not on a stranger’s box. Repo mode works against your local checkout. And if you’d rather run lessons through your own model account, bring your own key: Anthropic, OpenRouter, Bedrock, Vertex, or even an Ollama endpoint you host yourself!
What does it cost, honestly?
The free tier is real: the in-browser trainer, ten lessons a month, streaks and progress tracking, no credit card. It’s capped because every managed lesson costs us actual inference money.
| Tier | Price | What it adds |
|---|---|---|
| Free | $0, no card | In-browser trainer, ten lessons a month, streaks and progress |
| Pro | $24 / month | Repo mode on your real projects, fair-use limits, sync across devices, optional BYOK |
| Team | $32 / seat | Ramp dashboard, per-seat budgets, central billing, onboarding journeys for new hires |
| Enterprise | Talk to us | SSO, and code that can’t leave your network |
Team is the one managers keep asking me about, because the dashboard answers a question nobody could answer before: who on this team actually understands what they merged. If Enterprise is you, sales@codetrain.ai.
The build itself is written up separately in how I built a tutor that refuses to write your code, including why the free tier costs so little to run.
Go type something
CodeTrain is live at codetrain.ai. Sign in, ask it to teach you something you’ve been faking your way around, and see how it feels to be the one controlling the keyboard again. There’s a real two-step lesson on the landing page now, no account needed, if you want to try it before you commit to the free tier’s grand total of… zero dollars. The bug it teaches is one that passes its own test.
InferHaven keeps your code yours. CodeTrain keeps the skill yours. Same haven, different cargo. The beacon is active!
— Ethan L.