logoalt Hacker News

The new rules of context engineering for Claude 5 generation models

140 pointsby mellosoulsyesterday at 8:42 PM88 commentsview on HN

Comments

mycentstooyesterday at 9:46 PM

We should design a specific language to make sure that we can encode the exact requirements that we want. Something that has a limited set of keywords that are explicit. Wait a minute...

show 14 replies
firasdyesterday at 9:40 PM

I've always thought that extensive throat-clearing and prefixing the Treaties of Westphalia-length instructions into the context window was unnecessarily baroque when you can just talk to the agent.

I guess part of it is also that I don't mind doing 'hand-edits' like for example LLMs love to say "// so and so removed" I just go and remove that manually later rather than being like "don't comment about what you removed!11" cause you're really fighting deep grooves in the model's behavior at that point.

But I also have a hands-on human-in-the-loop working style so I guess maybe for people who just want to say "implement all open features in github issues" and walk away maybe there needs to be more of all this CLAUDE.md stuff

However I suspect there was always some gearhead type attraction to setting up detailed harness configs that may be unnecessary and more like hobbyist tinkering.

show 4 replies
Fordecyesterday at 9:48 PM

This all strikes me as an effort to move tailoring the harness out of the easily transferable .md file into specific Anthropic tooling to increase lock in.

I've been running Opus 5 today and it's already done accidental deletions, made far more mistakes and worked around deliberate hook controls than previous Opus versions combined. Also it looks like token usage is up as it fails at the task the first time around much more frequently than 4.8.

show 5 replies
threecheeseyesterday at 11:42 PM

They are imo over-relying on Claude automemory here, which is terrible at contextualizing memory access and makes huge leaps that don’t make sense - except when it’s actually useful, which makes the problem even worse for an operator who can’t see the thinking process anymore.

Yes, I worked on a related project, no I don’t want you to use those memories to make assumptions which emerge as decisions that I didn’t want. With reasoning traces hidden, I am sometimes not even sure if it used those memories or just independently decided that PCI-DSS subsection-whatever is somehow relevant to this PR that has the word “credit”.

There is no way for me to fully configure memory preferences at a granularity which would be useful, and so I continue to use context files (and other tools, sometimes) to ensure the right memories are stored and surfaced at the right times.

There’s a lot of room for agent memory improvement across the ecosystem, and I don’t think the LLM providers should try to own this vertical slice. This will never happen though, because it makes us “sticky”.

Or maybe I’m holding it wrong.

show 1 reply
orbital-decayyesterday at 11:10 PM

Most of this article seems like... common sense? Not sure how it's related to the latest generation in particular. I usually find Anthropic's advice on how to prompt their own models deviating from what I see in practice, which is puzzling. Their system prompt was always way too bloated and they kept it as a huge piece for some reason, instead of breaking up into parts. Shouldn't they know better? I wonder if they looked at Pi performing great with minimal amount of distractors in the context and cut their prompt down too, pretending they found something new in their recent models.

> Earlier Claude models could sometimes need repeated instructions or be more likely to listen to instructions at the end of their context window than at the start.

This seems to imply they solved serial position biases like lost-in-the-middle and recency/primacy? Sounds dubious. Labs started claiming this early 2025 and some benchmarks agree, but every time I run an eval on real use cases it's clearly there, especially at longer contexts.

show 1 reply
kloudtoday at 12:29 AM

This is quite puzzling. Back in the day I saw the breakthrough with Opus 4.5, and since then was very lightweight on CLAUDE.md, trying to declare intent, rather than prescribe imperative instructions. If it was off the mark, I would see clear mismatch, which gave me opportunity to correct, usually to clear and strip context.

Starting with Fable 5, if it goes off the rails, it is more difficult to correct it, because it is overall wrong, but covers its tracks with plausible sounding arguments, so it is hard to pin point and correct.

Now, this article points out techniques that were useful to rely on models more, but those peaked at 4.6. Now according to benchmarks Opus 5 is on the frontier. But when when it has looser reigns, it ends up gaslighting me even more with abstract word soup than any model before.

janpeukeryesterday at 10:11 PM

The point about not using examples is important, I recently noticed with the new "eagerness" of models it constraints them too much, so I use counter-examples. Recently I've switched to "think about the existing biases and assumptions in the design and try to exploit them, for example why do we X not Y".

simonwyesterday at 9:44 PM

I've been prompting Fable 5 to "use your own judgement" with respect to things like tests recently (based on earlier tips from Thariq) and it seems to work well, which is entertaining since apparently now "judgement" is a characteristic of a model that we need to care about.

show 2 replies
m3hyesterday at 10:26 PM

Is there a specific list of changes they made to the system prompt? They're claiming they removed 80% of it. That's quite substantial. It would be good to know what the model knows to do by training and what we need to avoid over-specifying in our system prompts.

Saying that "give Claude judgment" is too vague for agent implementors. Given the lack of specific details, my takeaway is that we need to go and review all context and rework prompts from prompts/descriptions from scratch until they pass the evals again.

show 1 reply
0gsyesterday at 10:20 PM

crazy to me that this starts with "I've written previously" yet continues the zero human attribution (that i could find?) trend in frontier model blog posts

show 2 replies
pianopatrickyesterday at 11:12 PM

I wonder how articles like compare to just asking AI "review my markdown files, settings, harness and so on. Tell me any ideas to improve them"

Just ask that once per week or so.

fractorialtoday at 12:04 AM

Opus 5 broke me; I can’t cognitively deal with Anthropic’s bullshit anymore.

I am thankful for the kick in the ass for me to switch full-time into my bespoke harness utilizing open weights & GPT 5.6 and discontinue yak-shaving it with Claude Code.

guybedoyesterday at 10:25 PM

so yeah we should pretty much do as we would with a junior team member:

- we should try to give good non self contradicting guidance

- we should expect the team member to have knowledge of the craft

- we should focus on higher level, taste and preferences

npstryesterday at 9:45 PM

The bitter lesson.

luciana1uyesterday at 9:37 PM

the natural endpoint of this trend is a system prompt that just says "you know what to do" and the model actually does

show 2 replies
Kiroyesterday at 10:21 PM

> Now: Auto-memory

Not Claude Code but I just had a task where it started referring another conversation that was complete nonsense and throwaway. I absolutely don't want things to get added to some memory behind my back.

A big reason I use LLMs is because I can try out wild ideas and then just throw it away. I don't want those to pollute the context.

show 3 replies
onesandofgrainyesterday at 9:46 PM

This is obvious and a meaningless article by claude. The system prompt isnt a fixed ruleset and never has been

show 1 reply
devnonymousyesterday at 11:32 PM

> In the new system prompt we say: Write code that reads like the surrounding code: match its comment density, naming, and idiom.

Hmm, so what happens in greenfield projects ? In any case, at least all the slop will be consistent.

1saadcodesyesterday at 11:16 PM

[dead]

aaronbrethorstyesterday at 10:32 PM

tl;dr: use the new `claude doctor` command to simplify the context you give your Claude models to make sure that you're getting the best results.

devnonymousyesterday at 11:25 PM

tl;dr Since nobody really understands why or how any of this shit works, last time around we just threw a bunch of crap at it to see what stuck. Seems like we could just have have thrown less crap.