| ▲ | Show HN: Butter – A Behavior Cache for LLMs(butter.dev) | ||||||||||||||||||||||||||||||||||
| 48 points by edunteman 6 days ago | 24 comments | |||||||||||||||||||||||||||||||||||
Hi HN! I'm Erik. We built Butter, an LLM proxy that makes agent systems deterministic by caching and replaying responses, so automations behave consistently across runs. - It’s a chat completions compatible endpoint, making it easy to drop into existing agents with a custom base_url - The cache is template-aware, meaning lookups can treat dynamic content (names, addresses, etc.) as variables You can see it in action in this demo where it memorizes tic-tac-toe games: https://www.youtube.com/watch?v=PWbyeZwPjuY Why we built this: before Butter, we were Pig.dev (YC W25), where we built computer-use agents to automate legacy Windows applications. The goal was to replace RPA. But in practice, these agents were slow, expensive, and unpredictable - a major downgrade from deterministic RPA, and unacceptable in the worlds of healthcare, lending, and government. We realized users don't want to replace RPA with AI, they just want AI to handle the edge cases. We set out to build a system for "muscle memory" for AI automations (general purpose, not just computer-use), where agent trajectories get baked into reusable code. You may recall our first iteration of this in May, a library called Muscle Mem: https://news.ycombinator.com/item?id=43988381 Today we're relaunching it as a chat completions proxy. It emulates scripted automations by storing observed message histories in a tree structure, where each fork in the tree represents some conditional branch in the workflow's "code". We replay behaviors by walking the agent down the tree, falling back to AI to add new branches if the next step is not yet known. The proxy is live and free to use while we work through making the template-aware engine more flexible and accurate. Please try it out and share how it went, where it breaks, and if it’s helpful.  | |||||||||||||||||||||||||||||||||||
| ▲ | mountainriver 6 days ago | parent | next [-] | ||||||||||||||||||||||||||||||||||
I also did computer agents with a vc backed startup, ran into the same issues, and we built a fairly similar thing at one point. It’s useful but it has limitations, it seems to only work well in environments that are perfectly predictable otherwise it gets in the way of the agent. I think I prefer RL over these approaches but it requires a bit more data.  | |||||||||||||||||||||||||||||||||||
| ▲ | realitysballs 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
Funny, we are working to implement this same logic in our in-house financial categorization agent. When we have a repeat prompt it goes to a json that stores answers and only goes to AI for edge cases. It’s a good idea  | |||||||||||||||||||||||||||||||||||
  | |||||||||||||||||||||||||||||||||||
| ▲ | rajit 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
We spoke to a number of browser agent companies who said deterministic RPA with an AI fallback was their "secret" :)  | |||||||||||||||||||||||||||||||||||
  | |||||||||||||||||||||||||||||||||||
| ▲ | barapa 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
We often will repeat calls to try again. Or sometimes we make the same call multiple times to get multiple answers and then score or merge them. Is this used only in cases where you assume the answer from your first call is correct?  | |||||||||||||||||||||||||||||||||||
  | |||||||||||||||||||||||||||||||||||
| ▲ | invisibleink 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
interesting. is the answer not context specific most of the time? even if I ask LLM the same question again and again the answer depends on the context. what are some use cases where you need deterministic caching?  | |||||||||||||||||||||||||||||||||||
| ▲ | felipe-pathwave 4 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
any plans to support https://openrouter.ai/ ?  | |||||||||||||||||||||||||||||||||||
| ▲ | Jayakumark 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
What local models will it work with ? Also what will be the pricing for local llms?  | |||||||||||||||||||||||||||||||||||
  | |||||||||||||||||||||||||||||||||||
| ▲ | puppycodes 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
I like the pricing model but I'm skeptical it will last.  | |||||||||||||||||||||||||||||||||||
  | |||||||||||||||||||||||||||||||||||
| ▲ | ronbenton 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
Interesting... is it legal?  | |||||||||||||||||||||||||||||||||||
  | |||||||||||||||||||||||||||||||||||
| ▲ | banjwoorri 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
[dead]  | |||||||||||||||||||||||||||||||||||
| ▲ | sherinjosephroy 5 days ago | parent | prev | next [-] | ||||||||||||||||||||||||||||||||||
[flagged]  | |||||||||||||||||||||||||||||||||||
| ▲ | robofanatic 6 days ago | parent | prev [-] | ||||||||||||||||||||||||||||||||||
So instead of OpenAI I should pay butter?  | |||||||||||||||||||||||||||||||||||
  | |||||||||||||||||||||||||||||||||||