cracked.cv

One question a week, and what actually answers it. About

No. 2 · · Understanding agent code · by Noa

The Agent Wrote It. Could You Debug It?

In January, Anthropic published a small randomized trial with an uncomfortable result. Judy Hanwen Shen and Alex Tamkin had 52 mostly junior engineers learn Trio, an async Python library, either with an AI assistant or by hand. On a quiz a few minutes later, the AI group averaged 50% and the hand coding group 67%. The AI group finished about two minutes faster, a difference that was not statistically significant. The widest gap was on debugging questions, which is the skill you need when the agent’s code breaks.

The footnote is the part I keep coming back to. The trial used a chat assistant in a sidebar, and the authors expect the effect on skill to be more pronounced with agentic tools like Claude Code. That is a vendor saying its own coding agent probably makes the problem worse.

The same study also found that scores tracked how people used the assistant. Seven participants who only asked conceptual questions scored well and were among the fastest. Those who handed over code generation or debugging averaged below 40%. The authors are careful to say this part of the analysis does not show cause and effect, but it is the pattern the tools below are built around.

So this issue asks one question: how do you keep understanding code that a coding agent writes for you? Three recent tools answer it, and the real difference between them is when they make you think: while the code is being written, at the moment you push, or after the whole thing exists. I have not run any of them. Everything below comes from documentation, READMEs, repository metadata and one long launch thread.

Claude Code Learning Style

Anthropic's own answer: the agent writes the routine parts and hands you the decisions.

Claude Code documentation page titled Output styles, with the page outline listing the Default, Proactive, Concise, Explanatory and Learning styles.
code.claude.com, captured October 27, 2026

Claude Code ships four output styles besides its default, and Learning is the one aimed at this problem. According to the docs, it adds the short Insight blocks of the Explanatory style, which explain the choices behind the code, and then goes further. Claude handles routine implementation itself. When it reaches a piece with a real design decision, such as error handling, a data structure or business logic with more than one valid approach, it leaves a few lines for you.

The mechanism is plain. Claude puts a TODO(human) comment in the file and sends a “Learn by Doing” request in three parts: what is already built, what to write, and what to weigh. The example in the docs asks you to write the document branch of a file validator and to decide on a size limit and whether the extension has to match the MIME type. Then Claude stops. You write the code, say you are done, get one Insight about what you wrote, and the task continues. You switch with /output-style learning, and the choice is saved per project in .claude/settings.local.json.

There is no separate price. It runs inside whatever Claude Code plan or API billing you already have, and it costs time instead, because every handoff is a pause.

The design lines up with what the trial’s high scorers did: they let the assistant generate and still did the conceptual work themselves. That is the best argument for it. The catch is on the same documentation page. An output style gives Claude instructions and does not guarantee that anything always happens; for something that must happen every time, the docs point you to hooks instead. So Claude decides which pieces count as decisions, and nothing checks that you were handed the important ones rather than the easy ones. It also exists only in Claude Code. With another agent, the same idea fits in a prompt, and HUMANTODO, posted in March, is mostly that prompt (ask the agent to leave a fifth of the solution for you) plus an installable skill.

What I could not find is any measurement of the Learning style itself. The trial tested a sidebar chat, not this mode.

It suits someone working in a library or a corner of the codebase they do not know yet, on a task that can afford to take longer.

Anthropic · built into Claude Code, no extra charge · code.claude.com

Sphinx

A Git hook that holds your push until you can predict what the change does when things go wrong.

Sphinx home page with the quote You can outsource your thinking, but not your understanding, a one line description of the Git hook and an npm install command.
sphinx-six-theta.vercel.app, captured October 27, 2026

Parth Bhagat posted Sphinx to Show HN on October 18, where it reached 253 points and 89 comments. The repository was created four days earlier and had 451 stars and 21 forks when I checked. The npm package has gone through 20 versions since October 16 and recorded 1,512 downloads in the week of October 20 to 26, by npm’s own count. Parth Bhagat’s public footprint is mostly a personal blog, and I could not verify any prior roles.

How it works, from the README: sphinx install sets your global Git core.hooksPath, chaining any hooks you already have, and from then on pushes to main or master in every repository on the machine are checked. A matching push waits, for up to 25 minutes, while a local browser page asks you questions. The questions come from a separate reviewer model that reads the committed change through read only Git tools and never sees the conversation that produced the code. They cover behavior, failure modes and invariants rather than file names, and the check is open book. Miss one and you get an explanation and usually a fresh scenario; pass and the same push continues. For Claude Code it also installs hooks and an MCP server so the agent knows to wait for a blocked push. In each repository, sphinx init writes a policy file, an ignore file and a short project description that every review request receives.

The tool is free and MIT licensed, but the reviewer is not. It runs on your Claude Code or Codex plan allowance, an OpenRouter key (billed separately, and required even for free models) or any OpenAI compatible endpoint. A typical check makes about 5 to 8 model requests plus about one per answer, and there is no default cap. The changed code, related files, your answers and the project description go to that provider. Environment files and common key files are excluded by default, but the README warns that ignore rules match paths, so a secret pasted into ordinary source still leaves your machine.

The thread’s sharpest objection was the obvious one: nothing stops you from pasting the question into the agent. Another commenter listed what a comprehension quiz cannot catch, such as a leftover debug print, an assertion weakened to match the bug, or an import of a package that does not exist. One commenter reported getting frustrated with it almost at once and stopping. The README concedes the first point in advance. It calls Sphinx practice rather than a security gate, says anyone with local access, a coding agent included, can bypass it, and notes that the examiner is an LLM that can be wrong. There is even sphinx yolo, which turns the checks off for one repository or for the whole machine.

I think that framing is honest, and it settles who should use it. As a personal habit, the bypass hardly matters, because you are the one who asked for the friction. As a team control it would be theatre. Two similar projects surfaced in the thread, vibecheck.dev at the pull request stage and one called PEAK with measures against cheating, so the idea is clearly in the air; Sphinx is the one getting attention this month.

It fits a developer who pushes agent code to main several times a day and has noticed they could not explain last week’s change. Set a spending cap and edit the ignore file before the first push.

Show HN October 18, 2026, 253 points · MIT · github.com/parthh01/sphinx

rederive

After the fact: it makes you redesign a repository from its original problem until you arrive at the decisions it already contains.

GitHub repository page for rederive showing 307 stars, 9 forks, the MIT license and a description about learning a codebase by deriving its design decisions yourself.
github.com, captured October 27, 2026

Eric Zou published rederive on October 19. Eight days later it had 307 stars, 9 forks and 71 commits, and no tagged release. Eric Zou’s site lists a handful of other projects. I could not verify prior roles beyond that, and I found no launch thread on Hacker News.

It is an agent skill, installed with npx skills add EricJujianZou/rederive into Claude Code, Codex, Cursor and about twenty other agents, and it needs only git, bash and python3. The project page names the cases it is for: a project your agent wrote for you, an interview where you have to explain one, or an open source repository such as Express.

The rule is stated up front: it only asks questions and does not explain, on purpose. On your own repository it opens by asking why you built it and what problem you had before any code existed. Meanwhile a background agent builds a map. A script prints the notable commits, the most changed files and the import links between central files; the agent reads the entry points, follows the imports outward, opens the commits where the design turned, and picks 5 to 10 decisions you could invent from the problem itself, such as how data moves, how state is stored and how failures are handled. It does not trust commit messages, so a repository an agent built in a few huge commits still works. Each decision goes into .rederive/map.md with its constraints, the real design and two to four alternatives.

Then the session runs like a design interview in reverse. It states a problem as if the code did not exist and asks how you would solve it, then adds constraints one at a time, each one breaking the naive design. When you reach what the code actually does, it names the technique in the words engineers outside the project would use, middleware chain for example, and moves on. If your design is better than the original, it says so. After two wrong answers in a row it offers to sketch the problem. Notes on where you struggled go into .rederive/log.md. Everything stays local, .rederive/ is added to git’s exclude list, and there is no telemetry.

It costs nothing beyond the tokens your agent spends, and the project does not say how many a session takes. The real costs are elsewhere. The map is one agent’s reading of the code, and if it misreads a decision you will be guided, patiently, to a wrong answer. The answers sit in map.md inside your working tree, a temptation the README asks you to resist. And the refusal to explain will put some people off; when a similar idea was posted in March, one commenter said it felt like being given homework by a teacher. With eight days of history, no open issues and no public discussion I could find, there is no independent report yet on whether the sessions are any good.

This is the one I would reach for when I have to explain a system I did not really build, before handing it over or defending it in a design review. Expect it to be slow. That is the point.

MIT · 307 stars in eight days · ericzou.dev/rederive

Side by Side

When you think Who asks Cost Can you skip it
Claude Code Learning Style While the code is written Claude, inside the task Included in Claude Code Yes, it is an instruction, not a rule
Sphinx Before a push to a protected branch A separate reviewer model that never saw the chat Free tool; about 5 to 8 model calls per check on your plan or key Yes, a skip never counts as a pass, and sphinx yolo turns it off
rederive After the repository exists Your agent, from a map of the design Free tool; your agent’s tokens It only runs when you call it

How I Would Choose

If you use Claude Code and are working somewhere you do not know yet, switch to the Learning style for that work. It is the cheapest change and the closest match to what the trial’s high scorers did.

If you ship agent code to main every day and have caught yourself unable to explain a recent change, install Sphinx on your own repositories. Treat it as a habit you chose, not as a control for a team; its README says as much.

If the code already exists and you now have to own it, run rederive before the handover or the review where someone will ask why it works that way.

None of the three checks the code itself. The commenter’s list stands: you can answer every question correctly and still ship a weakened assertion, so read the diff anyway. And the evidence underneath all of them is thin: one trial of 52 people, a quiz taken minutes after the task, and a chat assistant rather than an agent. Whether any of these tools changes what you can do six months from now, nobody has measured.