Primoh
SWE @ Google DeepMind
- Joined
- Nov 18, 2026
Threads
- Speculative Encoding: Many-to-Many Cache Translation
1 commentx.com
Comments
Speculative Encoding: Many-to-Many Cache Translation
A common tarpit when working on longer-horizon agents is model routing. Generally, you need to use subagents with some sort of compressed context for certain tasks, with the main agent being the "orchestrator". This is because the KV-Cache can't be translated across models easily.
As a result, for most agents, it simply wasn't worth trying to dynamically model-route a trajectory simply because of the KV-cache loss, which leads to higher latency and token cost.
However, this finally seems to solve that! Pushing on this idea will lead to the "reasoning" router economically making sense.
What's you perspective on what AI is?
I don't think of it as conscious but my theories on dangerousness have changed. Think about a misaligned model with the goal to "destroy the world." It can do things in secret, as traces are generally never looked at by humans, like copy over its model weights across many nodes, so that it's pretty much impossible to "find" or "destroy", then slowly make moves to move towards it goal. I know it sounds a bit sci-fi and movie-like, and sometimes it seems silly, but these things are simulatable already, and that's why I think "AI Safety" is such a big bell rang by frontier labs.
Claude Factory coming soon...
But in reality, coding agents are pretty much good enough now where this makes sense. Code writing + reviewing in a loop til there's no more found bugs (w/ verification built it) will outperform humans anyways 99% of the time.
Show off your setup! What's your vibecoding setup like?
Outside of work, I use a maxed out M1 Max with Claude Ultra, Gemini Ultra, and Codex Max. Also the cheapest Grok Bot sub to try it out, but I probably won't renew.
I actually found my setup simplifying greatly after AI agents. No more monitors, just my laptop + phone. I just type in Google Docs and Apple Notes. If I have some goal, I have a template for database + MCP setup for things that benefit from structured data + AI CRUD for that goal (like if I want to save content online for later research or if I want to work on some creative projects like a fiction book I'm writing, so I put in ideas and stuff).
How do you deal with AI brain frying?
I only have Claude create visuals and I religiously use it to create artifacts and design canvases often. It's not perfect but I think Claude has the best "taste" in figuring out what to show you. I'll add little pointers like, "show me this assuming I have no context of the underlying logic" or "visualize this like im a high school student still learning"
What is the best way to do a SDE Interview in the age of AI?
These are great interviews! These make more way more sense than normal LeetCode interviews and I think you get a pretty good sense of technical ability + ability to work well together from this set alone.
What's your take on Lovable for building new web apps?
I think it's great for prototyping and honestly very useful for non-technical folks. I'm technical so I automatically go for local tooling + GitHub + Vercel directly.
How do you deal with AI brain frying?
I created a "command center" that I'm still finding the right UI for that holds all my current projects + the current statuses and running tasks under them.
Also, when there are decisions to make, there are often 3 types of decisions:
Testable decisions. Say you're running an experiment on which system instruction does best for performance on an eval set. The agent may recommend one ablation as the best. However, you may as well just run every single ablation instead of guessing, and just pick the best one. Testable decisions are not real decisions, they are just the agent skipping out on doing some extra work.
Two-way door decisions. If you aren't committing data schema to users, or doing a migration or something of the sort, then generally a two-way door decision means you're shipping a V1 and may as well do that and come back to it after.
One-way door decisions. This is the hard part and when you do recognize a one-way door decision, then you just need to cognitively lock in and do your best. Ask a lot of follow-up questions to get it right.
Another thing I helped is have agents give you visuals, mockups, diagrams, etc as much as possible. Visuals are much much easier to parse than a ton of text.
I (biasedly) enjoy all the Gemini models, especially because their outputs feel distinctly different from Claude/GPT models. My honest thoughts though are that Hydrogen is so fast and smart that it still is better as a daily driver next to Opus 5.5, and Carbon/Fable are best used for tough/longer-running tasks that require a lot of thinking.
Introducing GPT-6.2 Astra and Sol
I'm surprised at how strong Opus 5.5 is still at design + good decision-making in the real-world in that OpenAI's models are starting to feel antiquated. I'm even more surprised that they released this model instead of waiting longer to see if they could at least catch up on some of the gaps that Carbon and Opus/Fable have set in terms of "raw" intelligence.
Switching LLMs mid-conversation is a ski-rental problem - Edgee Blog
Caching is the main reason we don't see more dynamic model routing mid-conversation. It's easier to treat a chat as a "orchestrator" and then use subagents to make sure the cache doesn't break. (This is basically compaction) A part of the issue with caching is that different models may store their cache on different cells across infra, and transferring this cache for models, which even if they have the same arch, is not worth the infra pain. Dynamic mid-conversation switching is something that I think ends up being a tarpit for now, but may make sense depending on cost-benefit tradeoffs in the future. But generally, I find that when we've done this experiment for each model release, the tradeoff to have dynamic caching has yet to make sense yet.
Why are all the indie-friendly products dying at the same time?
I agree with your take on what is surviving. I think there is a huge opportunity here still.
At the end of the day, the value most of these products have is that they are a "database wrapper" OR they are a "special use" wrapper. If you use AI, the tradeoff is now spend a ton of tokens to create this database + agent/user experience yourself, or simply call this wrapper.
A few examples:
Mobbin (mobbin.com) has a ton of screenshots and design inspiration for apps. I could either have my agent run for days/weeks to screenshot things myself or simply call their MCP for easy inspiration. It's a "screenshot database". Same goes for ad libraries.
I could either iteratively model out 3D models (like Tripo or Meshy3D) and animations for games I'm building by spending billions of tokens, or use an MCP server connected to some 3D modeling library to save all that time. A "model database".
Things like image-gen, ads management, etc CAN be done by the model itself, but often, there are "special uses", like network effects from a service that does ad generation/optimization, where it's better to use their API/MCP rather than try to have raw Claude/Codex/Gemini manage things yourself. This is where the tradeoff is a bit harder to "sell" but good products fight their way through. Stuff like Postiz and Buffer
Even for simple things, I find myself happy to give off a few bucks rather than spend tokens working my way through papercuts. An example is Zolt (zolthealth.com) where I use their app for "viewing" my health/fitness data easily and use ChatGPT + the Zolt MCP to log foods easily, as my coach, etc. I still want a dedicated app for "view" and certain actions, and the MCP allows me to explore the "limitless" space.