Hook

Their other posts in the index, biggest breakout first.
I found a powerful hidden feature in Claude Code that no one knows about. To the best of my knowledge, no one has written about it, no one has talked about it. I took a few days to think about whether I should share it. I'm gonna share it. I'm Pete. I run a software development agency in New York City. We work at startups and Fortune 500 companies to bring their products to market. So the other day, I noticed prompt suggestions, the feature where a Claude predicts what you'll type next. It disappeared from Claude Code. It was there for a few weeks, and then it was gone. And I wanna know why. So I turned to the Claude Code binary itself. Turns out you can force enable suggestions with a single environment variable. But that raises a bigger question. Why build prompt suggestions, ship them, and then pull them back? What's the endgame? So I went deeper into the binary, and I found something no one's talking about. It's called "Speculation." Internally, I think it's called speculative execution. So here's how it works. You ask Claude to do something, it finishes, it generates a prompt suggestion, like document the new feature. But then in the background, it assumes you're going to accept that suggestion and starts executing it before you even press enter. By the time you've even read the suggestion, Claude has already fetched the relevant files, run searches, and started working, all in a sandboxed overlay file system. Every file write gets redirected to that sandbox. Your real code base is never touched. If you accept the suggestion by pressing enter, the overlay copies back to your real file system, and the results inject into your conversation instantly. And if you type something different, the overlay gets deleted. Side note I'm gonna keep going, but I go way deeper into how all this works on my Substack. It's free. There's a link in my bio. Okay, so now here's where it gets interesting. There are permission tiers built into this, like read only tools, file reads, grep, ls. They run freely, but file edits get redirected to the sandbox. And bash commands only run if they've already been approved. The moment it hits something that needs your permission, speculation stops and it waits. And it goes even further than that. When a speculation completes, it immediately generates the next prediction and starts speculatively executing that too. So it tries to stay a step ahead of you the entire time. So you're probably asking like, Pete, how do you know all this? Well, I saw it in the binary, but I also wanted to test this. But the gate function is hard coded to return false. It's controlled by a server side flag called tengu_speculation. Anthropic didn't give me access, so I reverse engineered the binary and flipped the return value from false to true. Then I ran in debug mode. So before the patch, speculation enabled was false after the patch, speculation is running in the background. It's set to true. After a few hours of testing. My honest reaction was this kind of sucks right now. The permission wall kills it. Every time speculation hits a command that needs approval, it stops. Which is most of the time. But then I remembered something that anthropic shipped like a few days ago called auto mode. It's not as risky as dangerously skip permissions. It's an intelligent classifier that evaluates each command before it runs. If it's safe, it proceeds automatically. If it's risky, it blocks and prompts the user. And suddenly the picture clicked. If you look at what it actually suggests, it's not "build me a new feature". It's "run the tests" or "update the docks." The stuff you have to do but nobody wants to do, the stuff that kills your flow. Now imagine auto permissions plus speculation running together so Claude finishes your feature. The prompt suggestion says run the tests. You glance at it, hit enter, and the tests have already started running. Results are instant. Then it suggests "document this new feature." Enter already done. Push and open a PR. Enter already done. You just focus on building. Claude handles the entire best practices pipeline, testing, linting, committing, documentation in the background without you ever asking. By the time you think about it, it's already finished. This is fully built. The overlay file system, the permission tiers, the pipelining. It's all there in the binary. Waiting behind a server flag. Anthropic is measuring time saved metrics. They're tracking speculation acceptance rates. I can see this in the binary. So this thing appears to be on its way to the public. I wrote the full technical breakdown, the suggestion prompt, the gating logic, the overlay architecture, all of it. It's on my substack. It's free. There's a link in my bio.