Live data from Hacker News

Claude Code's source code has been leaked via a map file in their NPM registry

twitter.com

191–200 of 1001 posts

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#191

Earlier quoted context omitted.

Random aside: I've seen a 2015 game be accused of AI slop on Steam because it used a similar concept... And mind you, there's probably thousands of games that do this. First it was punctuation and grammar, then linguistic coherence, and now it's tiny bits of whimsy that are falling victim to AI accusations. Good fucking grief

To me, this is a sign of just how much regular people do not want AI. This is worse than crypto and metaverse before it. Crypto, people could ignore and the dumb ape pictures helped you figure out who to avoid. Metaverse, some folks even still enjoyed VR and AR without the digital real estate bullshit. And neither got shoved down your throat in everyday, mundane things like writing a paper in Word or trying to deal w…

No there is a very loud minority of users who are very anti AI that hate on anything that is even remotely connected to AI and let everyone know with false claims. See the game Expedition 33 for example.

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#192

Earlier quoted context omitted.

the "useCanUseTool.tsx" hook, is definitely something I would hate seeing in any code base I come across. It's extremely nested, it's basically an if statement soup `useTypeahead.tsx` is even worse, extremely nested, a ton of "if else" statements, I doubt you'd look at it and think this is sane code

I'm not that familiar with TypeScript/JavaScript - what would be a proper way of handling complex logic? Switch statements? Decision tables?

[deleted]

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#193

I have a feeling this is like llama. Original llama models leaked from meta. Instead of fighting it they decided to publish them officially. Real boost to the OS/OW models movement, they have been leading it for a while after that. It would be interesting to see that same thing with CC, but I doubt it'll ever happen.

Yes, I also doubt it'll ever happen considering how hard Anthropic went after Clawdbot to force its renaming.

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#194

Earlier quoted context omitted.

An LLM company using regexes for sentiment analysis? That's like a truck company using horses to transport parts. Weird choice.

Because they want it to be executed quickly and cheaply without blocking the workflow? Doesn’t seem very weird to me at all.

It looks like it's just for logging, why does it need to block?

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#195

Really surprising how many people are downplaying this leak! "Google and OpenAi have already open sourced their Agents, so this leak isn't that relevant " What Google and OpenAi have open sourced is their Agents SDK, a toolkit, not the secret sauce of how their flagship agents are wired under the hood! expect the takedown hammer on the tweet, the R2 link, and any public repos soon

Is https://github.com/google-gemini/gemini-cli not 'the flagship agent' itself? It looks that way to me, for example here's a part of the prompt https://github.com/google-gemini/gemini-cli/blob/e293424bb49...

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#196
post #149

Earlier quoted context omitted.

export function extractSearchToken(completionToken: { token: string; isQuoted?: boolean; }): string { if (completionToken.isQuoted) { // Remove @" prefix and optional closing " return completionToken.token.slice(2).replace(/"$/, ''); } else if (completionToken.token.startsWith('@')) { return completionToken.token.substring(1); } else { return completionToken.token; } } Why even use else if with return...

I always write code like that. I don't like early returns. This approximates `if` statements being an expression that returns something.

> This approximates `if` statements being an expression that returns something.

Do you care to elaborate? "if (...) return ...;" looks closer to an expression for me:

  export function extractSearchToken(completionToken: { token: string; isQuoted?: boolean }): string {
    if (completionToken.isQuoted) return completionToken.token.slice(2).replace(/"$/, '');

    if (completionToken.token.startsWith('@')) return completionToken.token.substring(1);

    return completionToken.token;
  }

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#197

Earlier quoted context omitted.

To me, this is a sign of just how much regular people do not want AI. This is worse than crypto and metaverse before it. Crypto, people could ignore and the dumb ape pictures helped you figure out who to avoid. Metaverse, some folks even still enjoyed VR and AR without the digital real estate bullshit. And neither got shoved down your throat in everyday, mundane things like writing a paper in Word or trying to deal w…

It's how people resisted CGI back in the day. What people dislike is low quality. There is a loud subset who are really against it on principle like we also have people who insist on analog music but regular people are much more practical but they don't post about this all day on the internet.

Not really. The scale is entirely different. I think less of someone as a person if they send me AI slop.

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#198
post #84

They have an interesting regex for detecting negative sentiment in users prompt which is then logged (explicit content): https://github.com/chatgptprojects/claude-code/blob/642c7f94... I guess these words are to be avoided...

so frustrating..

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#199
post #185

Earlier quoted context omitted.

An LLM company using regexes for sentiment analysis? That's like a truck company using horses to transport parts. Weird choice.

Because they actually want it to work 100% of the time and cost nothing.

Then they made it wrong. For example, "What the actual fuck?" is not getting flagged, neither is "What the *fuck*".

Re: Claude Code's source code has been leaked via a map file in their NPM registry

#200
post #84

They have an interesting regex for detecting negative sentiment in users prompt which is then logged (explicit content): https://github.com/chatgptprojects/claude-code/blob/642c7f94... I guess these words are to be avoided...

Ridiculous string comparisons on long chains of logic are a hallmark of vibe-coding.

It's actually pretty common for old sysadmin code too..

You could always tell when a sysadmin started hacking up some software by the if-else nesting chains.

Post reply on HN