this post was submitted on 23 Aug 2026
96 points (80.4% liked)

Technology

87469 readers
3621 users here now

This is a most excellent place for technology news and articles.


Our Rules


  1. Follow the lemmy.world rules.
  2. Only tech related news or articles.
  3. Be excellent to each other!
  4. Mod approved content bots can post up to 10 articles per day.
  5. Threads asking for personal tech support may be deleted.
  6. Politics threads may be removed.
  7. No memes allowed as posts, OK to post as comments.
  8. Only approved bots from the list below, this includes using AI responses and summaries. To ask if your bot can be added please contact a mod.
  9. Check for duplicates before posting, duplicates may be removed
  10. Accounts 7 days and younger will have their posts automatically removed.

Approved Bots


founded 3 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] hirihit640@sh.itjust.works 5 points 1 day ago (2 children)

some of my work projects have 80k tokens of just documentation

I feel like there's got to be better approaches than just shoving the entire documentation into the context. Humans don't try to memorize the entire documentation. We just search for relevant pieces and remember those, or have them open in a webpage alongside the code. We probably only have like 10k context maximum.

Do the modern agent harnesses not have automatic compaction?

[–] frongt@lemmy.zip 1 points 14 hours ago (1 children)

The solution is to train a LoRA. It takes the base model, and overlays all your data on top.

[–] hirihit640@sh.itjust.works 1 points 14 hours ago

That sounds like a lot of work to just read some docs. RAG doesn't require any training at all. I assume there are other approaches as well that would be faster than LoRA

[–] MagicShel@lemmy.zip 2 points 1 day ago (1 children)

Yeah so I've been working with Claude on that. Typically it greps to find what it's looking for and that can be a lot of tokens. So I created something halfway between rag and that (semantic search), and overall it lowers token usage a bit, but even if it optimistically reduces tokens 20%, Claude is hungry for docs.

There is automatic compaction, but I typically want to control that myself when I change focus (if I don't just /clear it). Still I'd say almost all of the stuff I do runs north of 100k tokens.

[–] hirihit640@sh.itjust.works 3 points 23 hours ago (1 children)

Surprised the community hasn't found better ways to reduce context, 100k is insane. Is it possible to make the agent work on smaller pieces at a time, so less context is needed per piece?

[–] MagicShel@lemmy.zip 2 points 23 hours ago

Oh for sure. Agents often use under 30k tokens, but the orchestrator needs to have enough information to instruct the agents so it typically is a fair bit bigger in context. Agents tend to save you money on frontier models, but I'm skeptical about local LLMs. I suppose if you aren't pressed for time it's probably just fine. I haven't played that much with it because anything big enough to bother with agents I typically feel is too big for local anyway. But I'm sure others have experimented more on that front than I have.