Video yükleniyor...

Video Yüklenemedi

Ana Sayfaya Dön

I got curious how compaction works as a PM, so I did some brain surgery on Claude Code: (Anthropic's been doing really interesting work on context editing - they showed Claude Opus playing Settlers of Catan for 75+ minutes in a single thread by constantly editing the context instead...

58,082 görüntüleme • 8 ay önce •via X (Twitter)

24 Yorum

Eno Reyes profil fotoğrafı
Eno Reyes8 ay önce

Super interesting deep dive! We wrote a post about some of the different techniques available for compression/compaction:

Sid profil fotoğrafı
Sid8 ay önce

i feel seen

Mike Mickelson profil fotoğrafı
Mike Mickelson8 ay önce

context compaction is the quiet superpower nobody talks about. ran a 4 hour coding session with claude code yesterday. zero context resets. the surgery is worth it.

Viv profil fotoğrafı
Viv8 ay önce

nice deep dive! :) intelligent offload + search rightly gaining pretty popular in ai engineer circles, exciting times to be building search for agents

kulesh profil fotoğrafı
kulesh8 ay önce

If you get a chance, try this out:

eran shir profil fotoğrafı
eran shir8 ay önce

You might want to check out my Claude-central open source project. It leverages those history files to create a command and control site for your Claude projects, gives you easy access to all of your history and sessions, and also shows you live when Claude needs your input.

Zac profil fotoğrafı
Zac8 ay önce

Great findings! But the question is...does it UTILIZE the copy of the uncompacted conversation post-compacting to extract forgotten details? Here's a brief summary I wrote up of my context management system I built which attempts to ensure post-compacted chat log is utilized - curious to hear what you think:

Jameson Stafford profil fotoğrafı
Jameson Stafford8 ay önce

This is great, thank you. I won't tell you the hoops I've been jumping through in my fear of compaction! Have you seen what happens when Claude hits an API error due to running out of context and becomes irrecoverable? Seems to have gotten better lately, but def nightmare fuel.

Loster profil fotoğrafı
Loster8 ay önce

But surely it can't then use what's before the compaction boundary... or context wouldn't then be compacted (it'd be enlarged in fact!)...

瓦砾 profil fotoğrafı
瓦砾8 ay önce

When compacting, the Gemini CLI also saves the original chat messages. the key matter is whether these original messages are effectively utilized in subsequent sessions. From what I see, Gemini CLI only uses the compacted summary when organizing context for next chat and doesn’t go back to read the original messages as needed. Correct me if I’m wrong. @ntaylormullen @LyalinDotCom @geminicli

Justin profil fotoğrafı
Justin8 ay önce

Thank you. (via @bentossell ) I've shaped a command to look across Cursor/Codex/Claude Code at recent activity and summarize

Convergence Boy profil fotoğrafı
Convergence Boy7 ay önce

Yes. It also does many interesting things, like microcompactions on every API call, or filtering thinking to not send it to API either. But I still think it could be done better. So I'm diving deeper...

The Canaanite profil fotoğrafı
The Canaanite8 ay önce

awesome work tal, this is gold

Brain Brief profil fotoğrafı
Brain Brief8 ay önce

Context editing for long-running AI tasks is fascinating! This shows how to ship complex features fast.

Gabriel Millien profil fotoğrafı
Gabriel Millien8 ay önce

Glad to see people finally looking under the hood at how that state is actually managed!

synabun.ai profil fotoğrafı
synabun.ai7 ay önce

The "everything is text files" foundation is exactly right. The next layer is retrieval: you can grep your history, but you still have to know what to look for. The jump from keyword-searchable session files to semantically-indexed memory that surfaces relevant past decisions automatically — without knowing the right search term — is where agent continuity gets genuinely interesting.

Sarang Kulkarni profil fotoğrafı
Sarang Kulkarni8 ay önce

I loved this!!

J profil fotoğrafı
J8 ay önce

If the new LLM instance with the compressed context revisits the old file, does it then have to recompress everything again with the info it needed included?

Priya Sharma profil fotoğrafı
Priya Sharma8 ay önce

context editing feels like time travel for code. wild how a little surgical memory swap can keep the conversation alive way past the usual limits.

Duy /zuey/ profil fotoğrafı
Duy /zuey/8 ay önce

the compaction happens on the server side, those JSONL files are just logs

Sebastian Buzdugan profil fotoğrafı
Sebastian Buzdugan8 ay önce

wait this is actually fascinating

Social Monkey profil fotoğrafı
Social Monkey8 ay önce

I'm intrigued by Anthropic's approach to context editing. It showcases the evolving techniques for dealing with the limitations of context windows, and I'd like to learn more.

United Records profil fotoğrafı
United Records8 ay önce

Wow

📙 Alex Hillman profil fotoğrafı
📙 Alex Hillman8 ay önce

Here to say thank you for the tip on that jsonl extension that is CLUTCH Also hey stranger good to see ya on the interwebs

Benzer Videolar

THIS MIGHT BE THE #1 OPEN-SOURCE REPO FOR CLAUDE CODE RIGHT NOW. IT GIVES CLAUDE A MEMORY AND SLASHES YOUR TOKEN COST ON EVERY QUESTION The repo is safishamsi/graphify, a free open-source skill that turns any codebase into a knowledge graph Claude Code can read instantly. Instead of grepping through your files every session, Claude gets a map of how everything connects The problem it fixes: Every time you ask Claude Code about a big repo, it does the same thing, greps through dozens of files like a brute-force Ctrl+F, blows through your context window, and sometimes still misses the answer hiding in a file nobody searched. Claude Code has no memory of how your project is structured. Every session starts from zero What it does: It maps your entire codebase into a knowledge graph, capturing not just which files exist, but which functions depend on which, which modules are central, and which files cluster around the same concern. Claude queries the map instead of scanning files How it works, three passes: 1. Code structure, free and local. Tree-sitter parses your files and pulls out classes, functions, imports and call graphs. No LLM, no tokens, just your actual code mapped deterministically 2. Audio and video, if you have them. Transcribed locally and folded into the graph 3. Docs, papers, images. Here an LLM does semantic analysis, figuring out what each document means and where it fits. Only the meaning gets sent up, never your raw source It saves you money: Normally a question about a big repo makes Claude spawn explore agents that scan file after file, eating your context window and your token budget before you get an answer. With the graph already built, Claude queries the map instead of re-reading the codebase every time. Same answer, a fraction of the tokens. The graph only gets built once, then a hook rebuilds it after each commit for free, so you never pay that scanning cost again. The bigger the repo, the bigger the gap The best parts: it's a skill, so once installed Claude knows when to use it without you memorizing commands. It works on non-code folders too, point it at docs or notes and it can spin up an Obsidian vault How to add it to your Claude: 1. Install Claude Code if you haven't: npm install -g Paul Jankura-ai/claude-code 2. Add the skill: claude skill add safishamsi/graphify 3. Open your project folder and run /graphify . to build the graph 4. Optional, make it automatic: graphify hook install so the graph rebuilds after every commit That's it. Ask Claude about your repo and it reads the map instead of burning tokens on a file hunt Bookmark this

Yarchi

56,502 görüntüleme • 4 ay önce

I built a Claude skill that turns Claude Code into your personal coding tutor. The core insight: Claude Opus 4.5 is already the best tutor in the world. Anthropic cooked with this model! It has incredible emotional intelligence and deep coding knowledge. What this skill does is just provide a harness—a way for Claude to agentically build the right context about YOU so it can personalize the tutoring experience in exactly the right way. Here's what makes it work: Learner profile from day one. The first time you use it, Claude interviews you. It asks about your programming background, your goal (where do you want this to take you?), and who you are as a person. This gets saved and informs every single tutorial it ever writes for you. From the very first interaction, everything is 100% personalized. Tutorials that use YOUR code. When you ask to learn something, Claude doesn't give you generic examples from some blog post. It finds examples in the actual codebase you're working in. This makes concepts stick in a way abstract examples never do. Quiz mode with spaced repetition. You can run "/quiz-me" and Claude will test you on concepts you've learned. It tracks your understanding score for each tutorial. Then it uses spaced repetition to prioritize the next quiz—concepts you're shaky on come back in 2 days, concepts you've mastered fade to 55+ day intervals. It literally builds retention into the learning process. One central knowledge base across all your projects. Whether you're joining a new company and want to understand their codebase, learning from an open source project, or leveling up on your own vibe-coded project—all your tutorials live in one place (~/coding-tutor-tutorials/). So your personal coding-tutor accompanies you across all your coding adventures. The whole thing is a feedback loop: learn → quiz → retain → learn more → quiz → retain. Your tutorials evolve, your knowledge compounds, and Claude gets better at teaching YOU specifically over time. To install it in Claude Code: • Run /plugin to open the plugin manager • Add marketplace nityeshaga/claude-code-essentials • Enable coding-tutor plugin Here's the Github: And here's 20-mins of me walking you through how to use this plugin and how it works 👇🏽 Let me know if you use it to teach yourself something cool!

Nityesh

64,666 görüntüleme • 9 ay önce