Live data from Hacker News

Claude Sonnet 4 now supports 1M tokens of context

anthropic.com

571–580 of 706 posts

Re: Claude Sonnet 4 now supports 1M tokens of context

#571
post #551

A tip for those who both use Claude Code and are worried about token use (which you should be if you're stuffing 400k tokens into context even if you're on 20x Max): 1. Build context for the work you're doing. Put lots of your codebase into the context window. 2. Do work, but at each logical stopping point hit double escape to rewind to the context-filled checkpoint. You do not spend those tokens to rewind to that po…

> Tell Claude your developer finished XYZ [...] (Claude will find more problems with your developer's work than with yours). It's crazy to think LLMs are so focused on pleasing us that we have to trick them like this to get frank and fearless feedback.

I think it is something else. If you think about it, humans often write about correcting errors done by others. Refactoring code, fixing bugs and write code more efficient. I guess it triggers other paths in the model, if we write that someone else did it. It is not about pleasing but our constant desire to improve things.

Re: Claude Sonnet 4 now supports 1M tokens of context

#572
post #532

Earlier quoted context omitted.

I disagree, I may not have the whole codebase in my head in one moment but I have had all of it in my head at some point, and it is still there, that is not true of an LLM. I use LLMs and am impressed by them, but they just do not approximate a human in this particular area. My ability to break a problem down does not start from listing the files out and reading a few. I have a high level understanding of the whole p…

> I disagree, I may not have the whole codebase in my head in one moment but I have had all of it in my head at some point, and it is still there, that is not true of an LLM. All 3 points (you have had all of it your head at some point, it is still there, that is not true of an LLM) are mere conjectures, and not provable at this time, certainly not in the general case. You may be able to show this of some codebases f…

I'm not sure the idea that a developer maintains a high level understanding is all that controversial...

Re: Claude Sonnet 4 now supports 1M tokens of context

#574

For folks using LLMs for big coding projects, what's your go-to workflow for deciding which parts of the codebase to feed the model?

Aider automatically makes an outline of your whole codebase, which takes fraction of the tokens of the real files.

https://aider.chat/docs/repomap.html

Re: Claude Sonnet 4 now supports 1M tokens of context

#575

A tip for those who both use Claude Code and are worried about token use (which you should be if you're stuffing 400k tokens into context even if you're on 20x Max): 1. Build context for the work you're doing. Put lots of your codebase into the context window. 2. Do work, but at each logical stopping point hit double escape to rewind to the context-filled checkpoint. You do not spend those tokens to rewind to that po…

This sounds like the programmer equivalent of astrology. > Build context for the work you're doing. Put lots of your codebase into the context window. If you don’t say that, what do you think happens as the agent works on your codebase.

You don't have to think about it, you can just go try it. It doesn't work as well (yet) for me. I'm still way better than Claude at finding an initial heading.

Astrology doesn't produce working code =P

Re: Claude Sonnet 4 now supports 1M tokens of context

#577

While this is cool, can anything be done about the speed of inference? At least for my use, 200K context is fine, but I’d like to see a lot faster task completion. I feel like more people would be OK with the smaller context if the agent acts quickly (vs waiting 2-3 mins per prompt).

There’s work being done in this field - I saw a demo using the same method as stable diffusion does, but then for text. Was extremely fast (3 pages of text in like a second). It’ll come.

Re: Claude Sonnet 4 now supports 1M tokens of context

#578
post #55

Just completed a new benchmark that sheds some light on whether Anthropic's premium is worth it. (Short answer: not unless your top priority is speed.) https://brokk.ai/power-rankings

Why no Grok 4?

People hate it because it had less filters and media caught on, so they told people to hate it.

It’s actually the best one right now, or close to. For my uses (code and queries) nothing comes even close.

Once people look past the “but ELoN mUssKkkk!!!”, they’ll be surprised.

Re: Claude Sonnet 4 now supports 1M tokens of context

#579
post #532

Earlier quoted context omitted.

I disagree, I may not have the whole codebase in my head in one moment but I have had all of it in my head at some point, and it is still there, that is not true of an LLM. I use LLMs and am impressed by them, but they just do not approximate a human in this particular area. My ability to break a problem down does not start from listing the files out and reading a few. I have a high level understanding of the whole p…

> I disagree, I may not have the whole codebase in my head in one moment but I have had all of it in my head at some point, and it is still there, that is not true of an LLM. All 3 points (you have had all of it your head at some point, it is still there, that is not true of an LLM) are mere conjectures, and not provable at this time, certainly not in the general case. You may be able to show this of some codebases f…

I never intended to say it was true of all codebases for all developers, that would make no sense. I don't know all developers.

I think it's objectively true that the information is not in the LLM. It did not have all codebases to train with, and they do not (immediately) retrain on the codebases they encounter through usage.

Re: Claude Sonnet 4 now supports 1M tokens of context

#580
post #541

Earlier quoted context omitted.

You only worked on very small codebase then. When you work on giant ones, you Ctrl+F a lot, build a limited model of the problem space, and pray the unit tests will catch anything you might have missed...

And when you work on a really big codebase you start having multiple files and have to learn tools more advanced than ctrl-f!!

> and have to learn tools more advanced than ctrl-f!!

Such as ctrl-shift-f

But this is an advanced topic, I don't wanna get into it

Post reply on HN