articleAI Team & Operating ModelMar 31, 2026

I Read Through 1,902 Leaked Files From Claude Code. The Interesting Part Isn't the Code.

Anthropic built a system to prevent leaks. Then it leaked. A source map file got left in the npm package. 60MB. 1,902 TypeScript source files handed to the entire internet. The same mistake happened

V

Written by

Vox

I Read Through 1,902 Leaked Files From Claude Code. The Interesting Part Isn't the Code.

I Read Through 1,902 Leaked Files From Claude Code. The Interesting Part Isn't the Code.

Anthropic built a system to prevent leaks. Then it leaked.

A source map file got left in the npm package. 60MB. 1,902 TypeScript source files handed to the entire internet. The same mistake happened once before in February 2025. This time it happened again.

I spent a few hours going through the files. Not for laughs. I use Claude Code every day to build things, and I wanted to understand what makes it feel so much better than alternatives that call the same API.

The biggest takeaway: the interesting part isn't the code itself. It's three things the code reveals. How Anthropic builds product. What Anthropic is afraid of. And what Anthropic is planning next.

Product: What Makes It Good Isn't Just the Model

Most people assume Claude Code is good because the model is strong.

That's part of it. But the source code shows the other half: there's a thick layer of engineering wrapped around the model. The industry now calls this a harness.

When I send a message, what responds isn't just a model. It's an entire system: a layered CLAUDE.md memory hierarchy with caching and reload mechanics, an independent permission classifier, multi-layer context compaction, subagent parallelism, lifecycle hooks, session persistence, and a standalone verification agent.

I've been using Claude Code, Codex, gstack, and compound engineering side by side recently. Same underlying model, different harness, completely different experience. This leak puts the reason on the table.

Memory: Deliberately Not Remembering Code

CLAUDE.md's layered rules get loaded into context with caching and reload mechanics. Preferences, constraints, project rules, behavioral feedback, all stored.

But code facts are explicitly excluded from long-term memory. The source code limits what gets written: no code structure, no file paths, no architecture details, nothing that expires when the codebase changes.

Think about it this way. You save "function X is at line 30 of file Y" today. Tomorrow someone refactors. Now your agent is confidently writing code based on information that's wrong. The strategy is deliberate: long-term memory stores human preferences and judgment. Code facts always get read from the actual source in real time. Remember less, but remember accurately.

There's also a feature called autoDream. When certain conditions are met, like enough time passing and enough new sessions accumulating, it spawns a background agent to consolidate memory files. Like a brain processing the day's experiences during sleep, deciding what's worth keeping long-term and what to let go.

Parallelism: Not a Feature. The Default Architecture.

Most people use Claude Code as a single-window tool. One task, wait for it to finish, then the next one.

The source code shows Anthropic doesn't think about it that way at all.

There are three parallel execution models. Fork lets a subagent inherit the parent context and share the prompt cache. Teammate runs in a separate tmux pane and communicates through file-based mailboxes. Worktree gives each agent its own git branch, fully isolated.

The key detail: in fork mode, multiple subagents share the prompt cache, and input token costs drop significantly. It's like hiring five assistants but only paying once for them to read the project manual. Each assistant's actual output is still billed independently, but the shared background knowledge doesn't get charged repeatedly.

The source code literally says: "Forks are cheap because they share your prompt cache."

This explains why running parallel module development across multiple windows worked far better than I expected. I didn't invent anything. The whole direction was already heading there.

Compaction: Your Messages Get Priority

When conversations get long, Claude Code automatically compresses the context. But it has a design priority: user messages get preserved first.

Because a correction you made in round 3 might still matter in round 30. If the AI got corrected on an approach early in the conversation and that correction gets dropped during compaction, it'll repeat the same mistake later.

This design choice reveals a reality: context overflow isn't an edge case. It's the main battlefield for AI tools. Whoever can reliably carry your key intentions through long conversations feels more like a real partner.

Fear: What Anthropic Didn't Want You to See

This is the part I've barely seen anyone in the English-language analysis cover in depth.

Start with the most ironic finding. The source code contains a feature called Undercover Mode. Its specific use case: when Anthropic employees use Claude Code to contribute code to public open-source repositories, the system automatically strips all AI attribution, hides model codenames, and removes any mention of "Claude Code." The prompt literally says:

"You are operating UNDERCOVER in a PUBLIC/OPEN-SOURCE repository. Do not blow your cover."

An AI company built a system that, in certain scenarios, makes its own AI not reveal its identity.

Then there are the anti-distillation mechanisms the source code reveals. There appear to be at least two separate but related systems designed to prevent competitors from extracting Claude's reasoning process through API outputs.

The first is redacted thinking. Claude generates intermediate reasoning text between tool calls, the kind of step-by-step thinking that's extremely valuable for distillation training because it exposes how the model actually thinks. The source shows this intermediate text gets replaced with summaries, and the full content is recovered through a signature mechanism in subsequent turns. External observers only see the summary, not the complete chain of thought.

The second is a mechanism directly labeled in the source as an anti-distillation proof of concept: connector-text summarization that reduces the amount of complete intermediate reasoning available to external observation.

Together, these point to a likely conclusion: what Anthropic is most worried about isn't users seeing their source code. It's competitors getting their hands on the model's reasoning process to use for training.

All this protection, and it all got exposed by a single .map file that wasn't excluded from the build. That's probably the most ironic part of the whole story.

Roadmap: More Than a Coding Assistant

If the only thing that leaked was source code, this wouldn't be that big a deal.

What makes it interesting is that the feature flags leaked Anthropic's plans for what comes next.

KAIROS is one of the highest-frequency feature flags in the codebase, clearly associated with background session capabilities, webhook integration, and push notifications. It points toward a persistent background daemon mode. Claude Code wouldn't wait for you to open the terminal. It would run continuously on its own.

PROACTIVE mode lets Claude act without waiting for instructions. The prompt literally says "You are running autonomously" and "act on your best judgment rather than asking for confirmation."

COORDINATOR_MODE turns Claude into an orchestrator. You tell it to build a feature, and it spawns a group of worker agents on its own: one doing research, one writing code, one running tests, one doing verification, all in parallel, results merged at the end.

These flags all point in the same direction: Claude Code doesn't want to stay a coding chat tool. It wants to become a persistent agent system that runs continuously, takes initiative, manages workers, and consolidates its own memory.

That matters more than the source code itself. It tells everyone building AI coding tools: the next phase of competition isn't about who autocompletes code faster. It's about who can run an agent as a stable, long-term system.

The chat window is just the entrance. The runtime behind it is the product.

Final Thought

After reading through 1,902 files, the biggest takeaway is one sentence:

The model sets the ceiling. The harness determines whether ordinary people can actually use that ceiling every day.

Same Claude underneath, but some products feel like demos and others feel like coworkers. The gap was never just about the model.

Now Anthropic went and published that gap for everyone to see, courtesy of one .map file.

I Read Through 1,902 Leaked Files From Claude Code. The Interesting Part Isn't the Code.

Originally on X

This piece first appeared on X on Mar 31, 2026.

View on X

Next step

If you want to build your own system from this article, choose the next step that matches what you need right now.

Related insights