<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Antoinette C. Lennox</title>
    <description>The latest articles on Forem by Antoinette C. Lennox (@antoinette_clennox).</description>
    <link>https://forem.com/antoinette_clennox</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3941797%2Fe24b608d-1977-4946-90f9-e995766933e7.png</url>
      <title>Forem: Antoinette C. Lennox</title>
      <link>https://forem.com/antoinette_clennox</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/antoinette_clennox"/>
    <language>en</language>
    <item>
      <title>ToolOps, The Night the Dashboard Turned Red</title>
      <dc:creator>Antoinette C. Lennox</dc:creator>
      <pubDate>Mon, 25 May 2026 08:23:36 +0000</pubDate>
      <link>https://forem.com/antoinette_clennox/toolops-the-night-the-dashboard-turned-red-397n</link>
      <guid>https://forem.com/antoinette_clennox/toolops-the-night-the-dashboard-turned-red-397n</guid>
      <description>&lt;p&gt;The alert came at 2:17 a.m.&lt;/p&gt;

&lt;p&gt;Marcus didn't hear it at first. He was already awake, sitting at the kitchen table in the blue light of his laptop, watching numbers refresh that he no longer wanted to see. Three months since launch. Forty thousand users. A waitlist that kept growing. By every measure that was supposed to matter, Aria — his AI-powered research assistant — was a success.&lt;/p&gt;

&lt;p&gt;The billing dashboard said otherwise.&lt;/p&gt;

&lt;p&gt;He'd built Aria to do what human researchers did, only faster. You asked her a question, she deployed a team of sub-agents — each one specialized, each one pulling from a different paid data source — and within seconds you had an answer that would have taken a junior analyst two hours to compile. The product was elegant. The demo converted. Investors had used words like inevitable.&lt;/p&gt;

&lt;p&gt;What investors don't model for, Marcus had learned, is what happens when something inevitable reaches ten thousand conversations in a single day.&lt;/p&gt;

&lt;p&gt;His phone buzzed. Then buzzed again. Then held a continuous, low vibration that meant the alert had escalated from warning to critical. He looked at the screen.&lt;/p&gt;

&lt;p&gt;API spend: $4,340. Today.&lt;/p&gt;

&lt;p&gt;He set the phone face-down on the table.&lt;/p&gt;

&lt;p&gt;The problem, he knew, wasn't that the system was broken. It was that the system was working exactly as designed. Every sub-agent was doing its job. Every tool call was legitimate. Somewhere inside those ten thousand daily conversations, the same searches were being fired independently, simultaneously, by agents that had no way of knowing another agent had asked the same question four seconds earlier. Three agents, three API calls, three invoices — for one piece of information that had already been retrieved.&lt;/p&gt;

&lt;p&gt;At scale, that math became its own kind of catastrophe.&lt;/p&gt;

&lt;p&gt;He'd tried to fix it himself, six weeks earlier. Stayed up three nights writing a custom cache layer, proud of the architecture, satisfied with the elegance of the solution. It held for eleven days. Then a memory leak he hadn't anticipated took down the entire pipeline at peak traffic, and he spent the following morning explaining to users why Aria had gone silent for four hours.&lt;/p&gt;

&lt;p&gt;The custom fix was now disabled. The billing clock was running again.&lt;/p&gt;

&lt;p&gt;At 3:05 a.m., he sent me a message. We'd worked together briefly the year before, on an earlier project that never launched. The message was two sentences.&lt;/p&gt;

&lt;p&gt;I think I've built something people actually want. I'm not sure I can afford to keep running it.&lt;/p&gt;

&lt;p&gt;I called him the next morning.&lt;/p&gt;

&lt;p&gt;He walked me through the architecture slowly, with the particular exhaustion of someone who has explained a problem so many times that the explanation itself has started to feel like the problem. The sub-agent network. The paid tool integrations. The volume. The redundancy he couldn't eliminate without building infrastructure he didn't have time to build.&lt;/p&gt;

&lt;p&gt;I let him finish. Then I asked him one question.&lt;/p&gt;

&lt;p&gt;"What's sitting between your agents and your APIs?"&lt;/p&gt;

&lt;p&gt;Silence.&lt;/p&gt;

&lt;p&gt;"Nothing," he said. "Just the calls."&lt;/p&gt;

&lt;p&gt;That was the problem. Not the product, not the model choices, not the architecture of the agents themselves. The layer between the business logic and the external world was empty — no caching, no coalescing, no circuit breaking, no shared memory. Every call landed cold. Every duplicate query cost real money as if it were the first time it had ever been asked.&lt;/p&gt;

&lt;p&gt;I told him about &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt;. I'd been using it in my own work for a few months — a Python middleware SDK that wraps tool functions in a single decorator and handles the entire resilience layer automatically. Caching, retry logic, circuit breaking, and observability. For a multi-agent system like his, the critical feature was request coalescing: when multiple agents fire the same endpoint simultaneously, &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; executes the call once and distributes the result. Semantic caching meant that queries with identical intent but different phrasing — the kind a chatbot generates by the thousands — hit the same cache entry rather than triggering separate calls.&lt;/p&gt;

&lt;p&gt;He was quiet for a moment.&lt;/p&gt;

&lt;p&gt;"How long to integrate?"&lt;/p&gt;

&lt;p&gt;"A decorator per tool function," I said. "The agents don't change. The business logic doesn't change. You're wrapping the calls, not rewriting the system."&lt;/p&gt;

&lt;p&gt;We shipped the integration over a weekend.&lt;/p&gt;

&lt;p&gt;I remember watching Marcus go quiet on the call as the first full day of data came in. Not the anxious quiet of someone bracing for bad news. Something slower and more private — the particular stillness of a person watching a problem they'd carried for months simply stop.&lt;/p&gt;

&lt;p&gt;The duplicate calls that had been firing in parallel were coalescing into single upstream requests. The semantic cache was catching intent matches his exact-match logic had never seen. The circuit breaker — which he'd never had before — flagged one unreliable third-party endpoint that had been silently degrading his response quality for weeks, long before it showed up as an error.&lt;/p&gt;

&lt;p&gt;His spend that day was a fraction of what it had been.&lt;/p&gt;

&lt;p&gt;He didn't say much. He didn't need to. He took a screenshot of the dashboard — the same dashboard he'd been watching turn red every morning for three months — and sent it to me without a caption.&lt;/p&gt;

&lt;p&gt;The numbers were green.&lt;/p&gt;

&lt;p&gt;A few weeks later, over coffee, he told me what he'd done with the savings.&lt;/p&gt;

&lt;p&gt;Not pocketed them. Not used them to extend runway. He'd hired a front-end developer he'd been putting off, shipped a feature that had been sitting in the backlog since January, and started building an integration his enterprise users had been asking about since launch.&lt;/p&gt;

&lt;p&gt;The infrastructure efficiency hadn't just saved the product. It had funded the next version of it.&lt;/p&gt;

&lt;p&gt;He said something I've thought about since.&lt;/p&gt;

&lt;p&gt;"I kept thinking the problem was that we were growing too fast. But it wasn't that. The problem was that nothing was remembering anything."&lt;/p&gt;

&lt;p&gt;That's it, really. That's the whole lesson, told better than I could have told it.&lt;/p&gt;

&lt;p&gt;At scale, memory is money. And the systems that forget — the ones that fire every call cold, that treat every question as if it's never been asked before — pay for that forgetting, every single day, in ways that only show up when you're staring at a dashboard at 2 a.m. trying to understand how something this successful can feel this fragile.&lt;/p&gt;

&lt;p&gt;Aria is still running. Still growing. Still handling her ten thousand conversations a day.&lt;/p&gt;

&lt;p&gt;She just remembers now.&lt;/p&gt;

&lt;p&gt;GitHub: &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;https://github.com/hedimanai-pro/toolops&lt;/a&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>programming</category>
      <category>productivity</category>
    </item>
    <item>
      <title>ToolOps Saved My Client’s Startup. Here’s the Architecture Problem Nobody Talks About.</title>
      <dc:creator>Antoinette C. Lennox</dc:creator>
      <pubDate>Fri, 22 May 2026 07:17:14 +0000</pubDate>
      <link>https://forem.com/antoinette_clennox/toolops-saved-my-clients-startup-heres-the-architecture-problem-nobody-talks-about-4knh</link>
      <guid>https://forem.com/antoinette_clennox/toolops-saved-my-clients-startup-heres-the-architecture-problem-nobody-talks-about-4knh</guid>
      <description>&lt;p&gt;&lt;em&gt;A field report from the production layer.&lt;/em&gt;&lt;/p&gt;




&lt;p&gt;The call came at a bad time — or maybe exactly the right time.&lt;/p&gt;

&lt;p&gt;My client had built something that was actually working. An AI-powered chatbot handling web searches, pulling from multiple paid tool integrations, serving real users at real volume. The product was live. Users were engaged. By every surface metric, the startup was on track.&lt;/p&gt;

&lt;p&gt;Except the infrastructure was silently bleeding money.&lt;/p&gt;

&lt;p&gt;I've spent years helping teams build production-ready AI applications. I've seen the full range: systems that collapse under their first real traffic spike, systems that work beautifully at demo scale and become unmanageable at ten times that, and systems like my client's — architecturally sound, functionally impressive, and quietly unsustainable because of a single layer nobody had addressed.&lt;/p&gt;

&lt;p&gt;When we got on the call and he walked me through the numbers, it clicked immediately.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Architecture Behind the Problem
&lt;/h2&gt;

&lt;p&gt;The system wasn't simple. It was never going to be simple — the product didn't allow for it.&lt;/p&gt;

&lt;p&gt;The chatbot operated through a network of sub-agents. Each conversation didn't trigger one process; it triggered a cascade. Each sub-agent had its own set of tools — search APIs, data services, third-party integrations — and every single one of those tools billed per call. The architecture was correct for the product requirements. But there was no shared intelligence between the agents. No layer that could recognize when the same query had already been answered sixty seconds ago. No mechanism to prevent three sub-agents in three parallel conversations from independently firing the same API call, paying three times for one piece of information.&lt;/p&gt;

&lt;p&gt;At 10,000 conversations a day, that redundancy compounds fast.&lt;/p&gt;

&lt;p&gt;Here's what makes this problem invisible until it isn't: every individual call looks justified. The sub-agent needed that data. The tool returned the right result. Nothing failed. The system log shows clean executions from top to bottom. The billing dashboard tells a different story — one that only becomes legible when you step back and look at the aggregate, at the patterns, at the sheer volume of duplicate intent spread across thousands of simultaneous conversations.&lt;/p&gt;

&lt;p&gt;This is the infrastructure problem nobody talks about, because it doesn't produce errors. It produces invoices.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Standard Fix — And Why It Doesn't Scale
&lt;/h2&gt;

&lt;p&gt;Before I found a better solution, I would have approached this the way I'd always approached it: write a custom cache layer per tool.&lt;/p&gt;

&lt;p&gt;I've done it enough times to know the real cost of that approach. A proper cache implementation for a single tool — one that handles cache logic correctly, manages TTL, deals with edge cases, and doesn't introduce new failure modes — requires at minimum 20 lines of code. For a system with multiple paid tools spread across multiple sub-agents, you're writing that infrastructure over and over again, for every tool, maintained separately, tested separately, debugged separately.&lt;/p&gt;

&lt;p&gt;That's weeks of engineering time that produces no product value. It makes the system more complex. It gives you more surface area for failure. And it still doesn't solve the multi-agent problem cleanly, because hand-rolled cache layers don't naturally share state across independently running sub-agents.&lt;/p&gt;

&lt;p&gt;The deeper issue is philosophical: caching, retry logic, circuit breaking, and observability aren't features you bolt onto a production AI system after the fact. They're the foundation. But the tooling to implement that foundation properly hadn't existed in a form that was fast to integrate — until recently.&lt;/p&gt;




&lt;h2&gt;
  
  
  Why ToolOps Was the Right Call
&lt;/h2&gt;

&lt;p&gt;I'd been using &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; in my own work before this client came to me. It's a Python middleware SDK built specifically for AI agent infrastructure — it wraps any async function in a single decorator and handles caching, retry logic, circuit breaking, and observability automatically, without touching your business logic.&lt;/p&gt;

&lt;p&gt;For a multi-agent system running paid tools at high volume, the critical feature is request coalescing: when multiple agents call the same endpoint simultaneously, ToolOps executes the actual API call once and distributes the result across all callers. In a system handling thousands of daily conversations with overlapping query patterns — which is exactly what my client had — this collapses cascading duplicate calls into a fraction of the original volume.&lt;/p&gt;

&lt;p&gt;The semantic caching layer compounds the effect. Unlike exact-match caching, it recognizes intent rather than literal string matches. A chatbot fielding 10,000 conversations a day generates enormous natural language variety around a relatively finite set of underlying queries. Most caching systems miss that entirely. Semantic caching catches it.&lt;/p&gt;

&lt;p&gt;The integration required no architectural overhaul. One decorator per tool function:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="nd"&gt;@readonly&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;cache_backend&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;semantic&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;cache_ttl&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;3600&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;retry_count&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;run_tool&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;query&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;paid_tool&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;call&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;query&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every tool in the system, wrapped. The sub-agents kept running exactly as before. The layer between them and the APIs changed everything.&lt;/p&gt;




&lt;h2&gt;
  
  
  What Actually Changed
&lt;/h2&gt;

&lt;p&gt;The cost reduction was significant — significant enough that my client didn't just stabilize the unit economics of his existing system. He had runway he hadn't had before.&lt;/p&gt;

&lt;p&gt;What he did with it matters more than the savings themselves: he reinvested directly into the product. Better capabilities. Improvements that had been on the roadmap for months, waiting for budget that kept getting consumed by infrastructure overhead. The efficiency gain at the tooling layer funded the next stage of the build.&lt;/p&gt;

&lt;p&gt;That's the outcome that's hard to explain to someone who hasn't seen it happen. Optimizing your token count gets you incremental savings on one line of the bill. Fixing the infrastructure layer changes what the business can do.&lt;/p&gt;

&lt;p&gt;There's something else that changed, quieter but just as real: the operational experience of running the system. Fewer unexpected spikes. A circuit breaker that detects failing endpoints and stops hammering them before the errors cascade. A single CLI command — &lt;code&gt;toolops doctor&lt;/code&gt; — that validates backend health and reports state without digging through logs. For a startup at this scale, that kind of operational clarity isn't a convenience. It's the difference between a system you can manage and one that manages you.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Pattern I Keep Seeing
&lt;/h2&gt;

&lt;p&gt;This client's situation wasn't unusual. It's representative of a failure mode I encounter consistently in production AI systems: the product architecture is solid, the model selection is thoughtful, and the infrastructure layer — the one that sits between the business logic and the external world — is either missing entirely or stitched together from custom code that's grown beyond anyone's full understanding.&lt;/p&gt;

&lt;p&gt;The mistake isn't negligence. It's sequencing. You build the product first, which is correct. You defer the infrastructure, which is understandable. And then the system scales, and the infrastructure debt becomes the most expensive line on the bill.&lt;/p&gt;

&lt;p&gt;Multi-agent architectures make this worse by nature. Every agent you add multiplies the external call volume. Every paid tool you integrate adds another billing surface. The redundancy that's invisible at demo scale becomes structurally significant at production scale — not because anything broke, but because nothing in the system was built to recognize and eliminate it.&lt;/p&gt;

&lt;p&gt;The teams that will run efficiently at scale — as models get cheaper, as agent architectures grow more complex, as API-dependent products become the norm — are the ones who treat the infrastructure layer as a first-class concern from the beginning. Not an afterthought, not a future sprint, not something to fix when the bill becomes impossible to ignore.&lt;/p&gt;

&lt;p&gt;The caching layer is not a performance optimization. It's an architectural decision about how much of your operating cost you're willing to pay twice.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;I work with teams building production AI systems and help them move from prototype to production-ready architecture. If this pattern sounds familiar in your own stack, I'd be glad to hear about it in the comments.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Stack: &lt;em&gt;ToolOps: &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;github.com/hedimanai-pro/toolops&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>programming</category>
      <category>productivity</category>
    </item>
    <item>
      <title>ToolOps: The Python Middleware That's Quietly Cutting AI Infrastructure Costs for Teams Running at Scale</title>
      <dc:creator>Antoinette C. Lennox</dc:creator>
      <pubDate>Wed, 20 May 2026 09:20:13 +0000</pubDate>
      <link>https://forem.com/antoinette_clennox/toolops-the-python-middleware-thats-quietly-cutting-ai-infrastructure-costs-for-teams-running-at-51no</link>
      <guid>https://forem.com/antoinette_clennox/toolops-the-python-middleware-thats-quietly-cutting-ai-infrastructure-costs-for-teams-running-at-51no</guid>
      <description>&lt;p&gt;There's a number most AI teams discover too late.&lt;/p&gt;

&lt;p&gt;It's not in the documentation. It's not in the LLM provider's pricing FAQ. It shows up on the bill — usually during a routine review, usually after a production deployment that "went well." According to CloudZero's research, average monthly AI spend jumped from $63,000 in 2024 to $85,500 in 2025 — a 36% increase. And for the teams that figure out what's actually driving that number, the culprit is almost never the model they chose. It's the calls they didn't need to make.&lt;/p&gt;

&lt;p&gt;This article is about a Python SDK called &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; that I started using a few months ago. I'm not affiliated with the project. I'm a developer who was burning through LLM credits faster than I should have been, tried a few solutions, and eventually found one that actually worked.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Real Cost of Production AI Agents
&lt;/h2&gt;

&lt;p&gt;Token prices are falling. LLM API prices dropped approximately 80% between early 2025 and early 2026 — GPT-4o input pricing fell from $5.00 to $2.50 per million tokens, and newer models offer input at just $0.55/MTok. On paper, that sounds like great news for anyone building AI systems.&lt;/p&gt;

&lt;p&gt;In practice, it barely moves the needle if your architecture is inefficient.&lt;/p&gt;

&lt;p&gt;Here's why: each tool call in an agent adds the full message history back into the prompt. A 5-step agent with a 30,000-token system prompt can pay for that prompt five or more times per request. Now multiply that by concurrent agents, parallel pipelines, and repetitive queries that ask effectively the same thing in slightly different words. The token price per million is irrelevant. You're paying for the same computation over and over.&lt;/p&gt;

&lt;p&gt;The cheapest API call is the one you don't make. Efficient prompts, smart caching, and appropriate model selection matter more than provider choice. That principle sounds obvious until you're the one writing the infrastructure to enforce it — at which point you realize it's neither simple nor fast.&lt;/p&gt;




&lt;h2&gt;
  
  
  What Most Teams Do (And Why It Doesn't Scale)
&lt;/h2&gt;

&lt;p&gt;The standard approach to managing these costs involves writing custom infrastructure: a cache layer, retry logic, a circuit breaker for when APIs go down, observability hooks so you can debug what's happening, and concurrency controls to prevent 40 agents from hammering the same endpoint in parallel.&lt;/p&gt;

&lt;p&gt;Every piece of that is necessary. And every piece of it is code you write yourself, from scratch, for each project.&lt;/p&gt;

&lt;p&gt;When you build AI agents, external calls — LLMs, APIs, databases — are expensive, unreliable, and slow. &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; eliminates the boilerplate: it's a framework-agnostic middleware SDK that wraps any Python function in a single decorator, instantly upgrading it with caching, resilience, observability, and concurrency control.&lt;/p&gt;

&lt;p&gt;That's the pitch. Here's what it actually looks like in code.&lt;/p&gt;




&lt;h2&gt;
  
  
  One Decorator. Everything Else Is Handled.
&lt;/h2&gt;

&lt;p&gt;The before/after is stark.&lt;/p&gt;

&lt;p&gt;Before &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt;, a properly resilient LLM tool call involves cache management, retry logic, circuit breaker state, timeout handling, and tracing — spread across dozens of lines of infrastructure code that wraps three lines of actual work.&lt;/p&gt;

&lt;p&gt;After:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="nd"&gt;@readonly&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;cache_backend&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;semantic&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;cache_ttl&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;3600&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;retry_count&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;ask_llm&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;query&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;llm&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;complete&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;query&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Automatically cached, retried, and traced. Every agent developer hits a wall when moving from demo to production — and that one decorator is what stands between a clean codebase and an unmaintainable nest of infrastructure scaffolding.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;@readonly&lt;/code&gt; decorator signals that this function is idempotent — safe to cache and retry. The &lt;code&gt;@readonly&lt;/code&gt; / &lt;code&gt;@sideeffect&lt;/code&gt; decorator split is opinionated in a good way: it forces you to be explicit about whether a tool call is idempotent or not, which matters a lot when deciding what's safe to cache and retry.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Feature That Makes the Biggest Difference at Scale
&lt;/h2&gt;

&lt;p&gt;For teams running multi-agent systems — which is increasingly the default architecture for any serious AI workflow — there's one &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; feature that changes the economics of high-volume operations more than anything else.&lt;/p&gt;

&lt;p&gt;Request coalescing.&lt;/p&gt;

&lt;p&gt;If 50 agents call the same endpoint simultaneously, &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; executes the real API call once and multicasts the result.&lt;/p&gt;

&lt;p&gt;At first pass, this sounds like a minor optimization. It's not. In a production pipeline where multiple agents are processing similar inputs concurrently, this collapses what would be dozens of identical upstream requests into a single one. In a 50-concurrent-call benchmark, 50 calls collapsed to 1 upstream request — the thundering herd problem on cache miss is real, and this handles it cleanly.&lt;/p&gt;

&lt;p&gt;One request. One credit charge. One point of failure.&lt;/p&gt;

&lt;p&gt;For large-scale document processing, RAG pipelines, customer-facing AI products, or any architecture that handles bursty, repetitive loads — this is a structural cost reduction that no amount of model-switching will replicate.&lt;/p&gt;




&lt;h2&gt;
  
  
  Semantic Caching: Catching Costs That Exact-Match Misses
&lt;/h2&gt;

&lt;p&gt;Standard caching is binary: the input either matches a cached key or it doesn't. That works well for structured data. For natural language queries — which is most of what LLM-powered agents process — it misses an enormous opportunity.&lt;/p&gt;

&lt;p&gt;The semantic caching in &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; uses an intent-matching approach that's genuinely useful for NLP tool inputs. Queries like "Check status of invoice #442" and "Is invoice 442 paid?" hit the same cache entry, reducing LLM token usage noticeably.&lt;/p&gt;

&lt;p&gt;This matters more than it might seem. In customer support agents, document analysis pipelines, and data extraction workflows, users phrase the same underlying question dozens of different ways. Every variation that misses an exact-match cache is a redundant API call. Semantic caching eliminates that category of waste entirely.&lt;/p&gt;




&lt;h2&gt;
  
  
  Production-Grade Resilience Without the Ceremony
&lt;/h2&gt;

&lt;p&gt;Beyond cost reduction, there's the reliability side of production AI infrastructure.&lt;/p&gt;

&lt;p&gt;LLM APIs go down. External services rate-limit. Downstream databases return transient errors. The naive response is to let your agent fail. The correct response is a circuit breaker that detects consistent failures, temporarily halts calls to the affected service, and allows recovery — without you having to build that logic yourself.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; includes this out of the box. A single CLI command — &lt;code&gt;toolops doctor&lt;/code&gt; — validates all your backends and reports circuit breaker state. It's exactly what you want to wire into a health check endpoint.&lt;/p&gt;

&lt;p&gt;That kind of operational visibility — knowing the status of every backend, every circuit breaker, without digging through logs — is the difference between an agent that fails silently and one you can actually run in production with confidence.&lt;/p&gt;




&lt;h2&gt;
  
  
  Framework Compatibility: It Works With What You Already Use
&lt;/h2&gt;

&lt;p&gt;The natural concern when evaluating any new piece of infrastructure is migration cost. How much do I have to change?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; decorates plain Python async functions, making it 100% compatible with your favorite agent frameworks. It works across LangGraph, CrewAI, LlamaIndex, and MCP natively.&lt;/p&gt;

&lt;p&gt;You don't rewrite your agents. You don't change your business logic. You add a decorator to the functions that make external calls and configure backends once at startup.&lt;/p&gt;

&lt;p&gt;You register backends once at application startup, then reference them by name. &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; supports multiple backends simultaneously. Redis for persistent caching, in-memory for low-latency hot paths, semantic backends for NLP tools — you configure the combination that fits your architecture. Then you stop thinking about it.&lt;/p&gt;

&lt;p&gt;The core package has zero external dependencies. You only install what you need. No forced opinions on your stack, no transitive dependency conflicts on day one, no bloat.&lt;/p&gt;




&lt;h2&gt;
  
  
  Who Benefits Most From This
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; is most valuable in three specific situations.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;High-volume production pipelines.&lt;/strong&gt; If your system makes thousands or tens of thousands of API calls per day, even modest cache hit rates translate to significant cost reductions. At scale, organizations can achieve cost reductions of 50% to 90% while maintaining or even improving the quality of their AI applications.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-agent architectures.&lt;/strong&gt; The request coalescing feature was built for this. The more agents you run in parallel on overlapping workloads, the more redundant upstream calls you're generating without it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Teams who've been hand-rolling infrastructure.&lt;/strong&gt; If your codebase currently has a custom retry wrapper, a homemade cache manager, and a circuit breaker you wrote yourself — that's infrastructure debt &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; replaces directly. The integration is one decorator per function, with zero changes to business logic.&lt;/p&gt;




&lt;h2&gt;
  
  
  Getting Started
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pip &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="s2"&gt;"toolops[all]"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;From there, it's backend configuration at startup and decorator placement on your tool functions. The &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;GitHub repository&lt;/a&gt; covers the full setup, and the &lt;a href="https://hedimanai.vercel.app/projects/toolops.html" rel="noopener noreferrer"&gt;official documentation&lt;/a&gt; walks through backend configuration and the decorator API in detail.&lt;/p&gt;

&lt;p&gt;The project is early — a web dashboard and budget control features are still on the roadmap — but the core resilience layer is solid. It's Apache 2.0 licensed. Open source, production-ready for its current feature set, actively developed.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Architecture Principle It Enforces
&lt;/h2&gt;

&lt;p&gt;There's something more fundamental happening here than a useful library.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; is built on the idea that every external call an AI agent makes should be treated as a first-class operation — not an afterthought. Caching, retry logic, circuit breaking, observability, and concurrency control aren't optional production concerns you bolt on later. They're the minimum viable infrastructure for anything that talks to an LLM or an external API.&lt;/p&gt;

&lt;p&gt;Most teams know this. Most teams also don't have time to build it properly for every project. &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; packages that infrastructure into a decorator and gets out of the way.&lt;/p&gt;

&lt;p&gt;Don't over-optimize for today's prices. What matters is building the architecture that can take advantage of future pricing improvements. The teams that will operate efficiently as models get cheaper, as APIs multiply, as agent systems scale — are the ones who built the right plumbing early. &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;ToolOps&lt;/a&gt; is that plumbing.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;If you're building production AI agents and you've hit the credit-burn problem, I'd genuinely like to hear how you've handled it. Drop a comment below.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;GitHub: &lt;a href="https://github.com/hedimanai-pro/toolops" rel="noopener noreferrer"&gt;github.com/hedimanai-pro/toolops&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>python</category>
      <category>programming</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
