<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Annakokovina on Medium]]></title>
        <description><![CDATA[Stories by Annakokovina on Medium]]></description>
        <link>https://medium.com/@annakokovina21?source=rss-cc0174df7b03------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*rB8DavUPOpuFrdIS</url>
            <title>Stories by Annakokovina on Medium</title>
            <link>https://medium.com/@annakokovina21?source=rss-cc0174df7b03------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 24 May 2026 21:27:48 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@annakokovina21/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com" rel="hub"/>
        <item>
            <title><![CDATA[How Not to Go Broke on Tokens While Everyone Else Builds AI Agents]]></title>
            <link>https://medium.com/@annakokovina21/how-not-to-go-broke-on-tokens-while-everyone-else-builds-ai-agents-7eb73bc6d526?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/7eb73bc6d526</guid>
            <category><![CDATA[llm-applications]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[prompt]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Sun, 10 May 2026 14:40:10 GMT</pubDate>
            <atom:updated>2026-05-10T14:40:10.132Z</atom:updated>
            <content:encoded><![CDATA[<p>A couple of years ago, the main question when building an LLM application was: Does it respond at all, and does it kind of solve my problem? Now the question is different: “How much does this cost, and why is it so slow?”</p><p>Over the last two years, the average LLM request has grown from ~2,000 tokens to more than 5,400. Just check the OpenRouter research paper: <a href="https://arxiv.org/html/2601.10088v1">https://arxiv.org/html/2601.10088v1</a></p><p>Agentic pipelines, massive system prompts, multi-step reasoning — all of this keeps inflating context size. Coding-related prompts are now 3–4x longer than general-purpose ones, making them the main driver of token growth.</p><p><strong>And every token has a price: in dollars and in latency.<br>Why This Hurts So Much 👇</strong></p><p><strong>Money</strong> — Providers charge for every input and output token. More tokens → higher bills. No magic here.</p><p><strong>Latency</strong> — The longer the prompt, the longer it takes before the first output token appears. In real products, especially near real-time applications, this becomes painfully noticeable.</p><p><strong>Quadratic Math</strong> — Self-attention scales roughly as O(n²). Double the tokens → roughly 4x more computation. GPT-4 with a 128K context can cost up to 16x more than with 8K.</p><p>Reducing prompts by 2–3x is not “a small optimization.” It changes the economics of the entire product.</p><p>Below are the main techniques that actually help.</p><h4><strong>Truncation: Brutal, but Honest</strong></h4><p>The simplest strategy is to cut the context.</p><p>Common approaches:</p><ul><li>Sliding window — remove old messages and keep only the latest N tokens</li><li>First + Last — preserve the beginning and the end, discard the middle</li><li>Summarization — compress old messages into a summary before removing them</li></ul><p>This works well for simple chats where user questions are relatively independent.</p><p>It fails when the full history matters: debugging sessions, analytics, document workflows. The model will simply “forget” important information from the middle.</p><p><strong>My Take<br></strong>A solid baseline and the best place to start. Fast, practically free, and doesn’t require architectural gymnastics. Just make sure you understand exactly what gets removed.</p><h4>Prompt Compression: Shrink Without Losing Meaning</h4><p>If truncation means “throw away,” compression means “make smaller.”</p><p>A lightweight auxiliary model evaluates tokens and removes low-information parts.</p><p>The result often looks syntactically weird but remains semantically dense enough for a larger model to understand.</p><p>Example: “Please carefully analyze the following document and provide a comprehensive summary”<br>becomes: “analyze document provide summary”</p><p><strong>Some notable projects:</strong></p><ul><li>LLMLingua (Microsoft Research) — up to 20x compression, works with almost any LLM</li><li>LLMLingua-2 — 3–6x faster, slightly lower compression ratios (up to 14x)</li><li>LongLLMLingua — optimized for long contexts; on NaturalQuestions it achieved +21% quality improvements with 4x fewer tokens</li></ul><p>This works especially well for long documents and RAG chunks.</p><p>Less effective for short prompts or strict real-time systems because the auxiliary model itself adds latency during compression.</p><p><strong>My Take<br></strong>A powerful tool, but not a silver bullet. Always benchmark quality on your own tasks before deploying. Aggressive compression can introduce subtle degradation, so use sufficiently large gold datasets.</p><h4>RAG: Don’t Load Everything — Retrieve What You Need</h4><p>RAG is often treated as a tool for external knowledge.</p><p>From a token perspective, though, it’s primarily a way to avoid stuffing 500 pages of documentation into every request.</p><p>Retrieve 3–5 relevant chunks and inject only those.</p><p>There’s a growing narrative that million-token context windows make RAG obsolete. Reality is more nuanced:</p><p>RAG is dramatically cheaper than long-context approaches under typical workloads — and usually faster.</p><p>Plus, the “Lost in the Middle” problem hasn’t gone away. Models still struggle with information buried in the middle of very long contexts.</p><p>There’s good research on this topic showing that long context alone can reduce quality even with perfect retrieval: <a href="https://arxiv.org/html/2510.05381v1">https://arxiv.org/html/2510.05381v1</a></p><p><strong>Modern RAG is no longer “find and paste.” It includes:</strong><br>- Conditional retrieval (do we even need retrieval?)<br>- Reranking<br>- Hybrid search</p><p><strong>My Take<br></strong>For most production products, RAG is mandatory. Long context is not a replacement — it’s an additional tool for specific use cases.</p><p>The real question isn’t “RAG or long context?”<br>It’s: “What exactly should we retrieve, and when?”</p><h4>Prompt Caching: Pay Once for Repeated Context</h4><p>Probably the most underrated optimization on this list.</p><p>To understand why it matters, we need a tiny peek under the hood.</p><p>Every transformer request recomputes KV matrices for all tokens — even if 90% of the prompt is identical to the previous request.</p><p>Prompt caching stores already-computed matrices for repeated prefixes.</p><p>Result: Repeated tokens become roughly 10x cheaper. Anthropic claims up to 85% latency reduction with full cache hits.</p><p><strong>Provider implementations:<br>- </strong>OpenAI — automatic caching with no API changes required. Experiments show ~50% hit rates<br>- Anthropic — explicit cache blocks via `cache_control`. More control, potentially 100% hit rates<br>Google Gemini — available through the Context Caching API</p><p>The architectural pattern is simple: Static parts go first. Dynamic parts go last.</p><ul><li>System prompt → cached</li><li>Few-shot examples → cached</li><li>User query → not cached</li></ul><p>This works extremely well for applications with long reusable system prompts.</p><p>It doesn’t help if every prompt is fully unique.</p><p><strong>My Take<br></strong>If your system prompt is longer than 1,000 tokens and you have any meaningful traffic at all — enable caching immediately.</p><p>Minimal code changes. Massive impact.</p><h4>Prompt Hygiene: Discipline as an Optimization Tool</h4><p>The easiest way to save tokens is to write concise prompts from the start.</p><p>A few practical rules:</p><p><strong>Remove Fluff <br></strong>Instead of: “Please carefully and thoroughly analyze the following text and provide a comprehensive and detailed summary”<br>just write:“Summarize:”</p><p>That alone can save 15+ tokens with identical quality.</p><p><strong>Use Structure Instead of Explanations<br></strong>Models understand XML tags and structured formatting better than paragraphs of prose describing the output format.</p><p><strong>Control Output Length<br></strong>`max_tokens` is your friend.<br>Without explicit limits, models tend to over-explain and reason out loud by default.</p><p><strong>Remove Few-Shot Examples When Possible<br></strong>For simple tasks, zero-shot prompting with a clear format often performs similarly — at a much lower cost.</p><p><strong>Move Static Content into the System Prompt<br></strong>If the same text repeats in every request, it belongs in the system message, not the user message.</p><p>It also caches better.</p><p><strong>My Take<br></strong>This is where optimization should start.<br>Prompt audits are fast, free, and often reduce token usage by 20–30% without hurting quality.</p><p>Only after that should you move on to more advanced techniques.</p><h4>Final Thought</h4><p>Token optimization is not a one-time tweak.<br>It’s an architectural decision.<br>The earlier you start measuring and optimizing token usage, the cheaper scaling will be later.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7eb73bc6d526" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Yandex Smart Car UMO 5 ]]></title>
            <link>https://medium.com/@annakokovina21/yandex-smart-car-umo-5-d3493000c973?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/d3493000c973</guid>
            <category><![CDATA[agents]]></category>
            <category><![CDATA[smart-home]]></category>
            <category><![CDATA[cars]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Wed, 22 Apr 2026 08:09:03 GMT</pubDate>
            <atom:updated>2026-04-22T08:09:03.965Z</atom:updated>
            <content:encoded><![CDATA[<p>Last Saturday I attended the Yandex Urban Services conference — yes, apparently rest is not in my schedule anytime soon.</p><p>The headline act of the evening was the new car from Yandex.<br>My main impression: this is not just a car — it’s a gadget.<br>A big, electric gadget on wheels. 🤯</p><p>The ecosystem of devices powered by Alice is already diverse and fascinating, and now it has a new member — an electric vehicle developed by Yandex together with its partners: UMO 5.</p><p>Or, as the team affectionately calls it — our Umka 🧡</p><p>Disclaimer:I know absolutely nothing about cars. 💅<br>I can’t tell a suspension from a gearbox, and I’m definitely not qualified to evaluate a vehicle from an automotive engineering perspective.</p><p>But I do understand gadgets.<br>So I look at Umka exactly through that lens — as a smart device on wheels.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Tq59RH93puiXEYxd47njyQ.jpeg" /></figure><h4>A car as a gadget</h4><p>The vehicle is produced jointly with partners on a well-established platform.<br>The core hardware — motor, suspension, and overall form factor — has already been thoroughly tested.<br>This is not an experimental prototype and not raw hardware.</p><p>But the most interesting part is not the hardware.<br>It’s the philosophy.</p><p>The key idea is gadget-ness and ecosystem integration.<br>A real smart home with Alice — but on wheels.</p><p>Instead of the familiar command:<br> — “Alice, turn off the lights”</p><p>You now get more automotive ones:<br> — open the windows<br> — fold the mirrors<br> — turn on and adjust climate control<br> — heat the seats<br> — open the trunk<br> — tell me how much battery is left</p><p>And yes — this is still an electric vehicle, so the command set is intentionally strict: exactly the set of actions that drivers and passengers actually need every day.</p><p>One important detail worth highlighting:<br>all safety-critical functions are not delegated to voice control.</p><p>Acceleration, braking, and any safety-related systems remain fully manual and familiar to the driver.</p><p>So Alice is not an autopilot.<br>She’s an assistant. 💜</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*h9IElAuuJgKQIwMG4ETLRA.jpeg" /></figure><h4>Ecosystem thinking</h4><p>It’s impossible not to notice how deeply the car is integrated into the Yandex ecosystem.</p><p>Inside, you get familiar services:<br> — Yandex Video<br> — Yandex Maps for route planning<br> — and generally everything we already use in everyday digital life</p><p>At the same time, the vehicle still includes the full standard set of automotive features — cruise control and driver assistance systems.</p><p>In essence, the car becomes just another device in your digital toolkit — alongside your smartphone or smart speaker.</p><p>One particularly impressive feature is remote control.</p><p>Imagine the classic winter scenario:<br>You’re still at home, making coffee, getting ready to leave — <br>and the car is already warming up on your command.</p><p>This is enabled by a dedicated onboard module inside the vehicle.</p><h4>How AI actually works inside the car 🔮</h4><p>Since we’re primarily discussing AI and its practical applications, let’s take a look at how Alice works inside the car from an engineering perspective.</p><p>To do that, we need to briefly talk about assistant architectures.</p><p>In customer support scenarios, when a user asks a question and the system needs to decide what to do next — route the request or provide instructions — the most common approach is an **intent-based architecture.**</p><p>An intent is essentially the user’s goal or request.</p><p>For example, in banking:<br> — “My card isn’t working”</p><p>The system then needs to understand what happened and suggest the appropriate action.</p><p>This is often solved using a hybrid approach:</p><p>1. Take the user request<br>2. Convert it into an embedding<br>3. Embed the descriptions of instructions and situations<br>4. Search for the most semantically similar options<br>5. Rank them (usually with a separate reranker model)<br>6. Select the best response</p><p>If no suitable option is found, the request is escalated to a human support agent.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*ZICwzsJJbY8Ncvn0tN-WCQ.jpeg" /></figure><h4>Why the car uses a simpler architecture</h4><p>Now let’s go back to the vehicle.</p><p>Even though embedding models are relatively small, installing a full GPU inside a car is still a questionable idea — especially for a mass-market, cost-sensitive electric vehicle.</p><p>So the architecture is intentionally much simpler.</p><p>UMA listens to user requests through two microphones,<br>but it does not build embeddings or run heavy models.</p><p>Instead, the system uses an approach very similar to smart home devices:</p><p>- There are predefined scenarios<br>- A compact micro-classifier model determines which instruction category the request belongs to<br>- The system executes the corresponding action</p><p>In essence, this is not answer generation.<br>It’s fast scenario selection.</p><p>Of course, this affects the user experience.</p><p>For example, to check the remaining battery level,<br>you need to use a fairly precise trigger phrase.</p><p>But in my opinion, this is a perfectly reasonable trade-off — especially when balancing cost, reliability, and response speed.</p><p>For a prototype and a mass-market product, the solution looks very sensible.</p><p>And one more important point.</p><p>Full-scale agent systems — the kind we’re getting used to — rely on orchestration and almost always require significant compute resources, meaning heavy GPUs.</p><p>That kind of infrastructure simply wouldn’t work reliably inside a car — or would only function when connected to Wi-Fi.</p><p>So the current architecture is not a limitation.<br>It’s a deliberate engineering decision.</p><h4>My personal impressions as a passenger 🤭</h4><p>UMA 5 is a Chinese electric vehicle.<br>It looks and feels like a typical representative of its segment: a practical family car designed for everyday tasks — going to the supermarket or working in ride-hailing.</p><p>I would describe it as a baseline vehicle for its price category.</p><p>This is not a sports car that delivers speed, adrenaline, and a bit of rebellious fun.</p><p>It’s comfortable urban transportation.</p><p>Some observations:</p><ul><li>The interior finish is typical for the segment — seat upholstery is synthetic rather than leather</li><li>The cabin is fairly plastic-heavy, with textured plastic designed to resemble leather</li></ul><p>And here I have a personal quirk.</p><p>I genuinely believe a more honest design philosophy is better:<br>if a material is plastic, it should proudly be plastic — not pretend to be leather or a more expensive car.</p><p>Otherwise, it creates a slightly strange feeling of unnecessary imitation.</p><p>That said, most cars do this — and in this case it’s simply part of the partner platform.</p><p>On the positive side, the production team claims the build quality is very solid:<br>no loose parts, no squeaks.</p><p>And that’s genuinely reassuring.</p><p>Many of us have taken early electric taxis at least once and remember the constant rattling and creaking — especially noticeable because electric motors are so quiet.</p><p>I really hope this level of build quality holds once production scales.</p><p>Another design choice worth mentioning is the driver dashboard.</p><p>It consists of two screens:</p><ul><li>one for multimedia and external vehicle controls</li><li>one for speed, battery level, and core driving metrics</li></ul><p>The layout feels logical and modern — without the sense of being overloaded with screens just for the sake of screens.</p><h4>Thoughtful details ✨</h4><p>I love well-designed products, and I especially appreciate attention to detail.</p><p>This is exactly the kind of case where that attention is visible.</p><p>Voice control with Alice is implemented using two microphones located in the roof lining above the front seats.</p><p>And it’s not just “two microphones.”</p><p>It’s a smart zoning system.</p><p>The user experience has clearly been thought through in advance. 👍</p><p>When I simply say:<br>“Open the window”</p><p>The system opens exactly the window I need.</p><p>If I’m sitting in the driver’s seat — the driver’s window opens.<br>If I’m in the passenger seat — the passenger window opens.</p><p>The microphones dynamically determine the command source location.</p><p>I’m not entirely sure how perfectly this will work for passengers in the back seat, but in theory the system should handle that scenario as well.</p><p>Another important detail: the developers took the noise problem very seriously.</p><p>At home, a smart speaker operates in a relatively calm environment.<br>In a car, it’s a completely different situation:<br>movement, road noise, wind, conversations, traffic.</p><p>So the speech recognition model was specifically trained for noisy environments.</p><p>The idea is that Alice should reliably recognize commands even while driving.</p><h4>Final thoughts</h4><p>It feels like we are standing at the very beginning of a major transformation.</p><p>The car is gradually evolving from a mechanical device into part of the digital environment around us.<br>It becomes connected to the home, the smartphone, and services — controlled by the same assistant that already lives in other devices.</p><p>In essence, this is a new class of objects:</p><p>gadgets embedded into the physical world.<br>Smart devices made tangible.</p><p>And honestly, watching this transition happen in real time is incredibly fascinating.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iA5J2g1bpdoJpea6BTdLlw.jpeg" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d3493000c973" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Market for Search Infrastructure for AI Agents]]></title>
            <link>https://medium.com/@annakokovina21/the-market-for-search-infrastructure-for-ai-agents-961b1dba9287?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/961b1dba9287</guid>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[search]]></category>
            <category><![CDATA[ai-agent]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Mon, 30 Mar 2026 15:45:31 GMT</pubDate>
            <atom:updated>2026-03-30T15:45:31.822Z</atom:updated>
            <content:encoded><![CDATA[<h4>Preface</h4><p>When Models Stopped Growing — and Started Learning to Act</p><p>Or: From Scaling Models to Scaling Capabilities</p><p>A few years ago, the industry was almost unanimous in its belief that the quality of artificial intelligence was a function of model size.</p><p>More parameters meant better answers, broader capabilities, and higher product value powered by the model underneath.<br>And for a while, that assumption held true. Each new generation of models delivered a noticeable jump in quality, while companies competed to scale infrastructure and train increasingly large systems — the golden age of distributed inference frameworks.</p><p>But gradually, it became clear that this strategy had natural limits.</p><p>The cost of computation was growing faster than the utility of additional parameters.<br>Latency was becoming critical for real-world products, especially in voice scenarios.<br>And quality improvements were no longer proportional to model size.</p><p>At some point, the market began looking for a different path — not increasing model intelligence, but expanding its capabilities.</p><p>This is where the pattern of agentic systems emerged.</p><p>The model stopped being just a text generator and became part of a system capable of executing tasks: calling tools, retrieving data, making decisions, and acting across multiple steps.</p><p>This was not just a technological step.<br>It was an architectural shift.</p><p>The center of the system was no longer the model itself,<br>but its ability to interact with the external world.</p><p>When companies started building agents, they quickly discovered that the main challenge was not the model.</p><p>The challenge was the tools it could use — <br>and how reliably those tools worked.</p><p>Gradually, a new infrastructure layer began to form — one that can be described as capability infrastructure for agents.</p><p>These are not models, and not frameworks.<br>They are ready-to-use capabilities that can be connected to a system.</p><p>For example:<br>- memory<br>- search<br>- code execution<br>- multimodal tooling</p><p>Each of these capabilities solves a specific practical problem and turns the model from a text generator into an operational system and decision-making point.</p><p>As agent architectures started appearing in real products, an ecosystem began forming around these capabilities.<br>It would be inaccurate to call it a fully mature market — but it is clearly emerging.</p><h4>Why Search Became the First Standardized Capability</h4><p>Today we will focus on one of the most stable and well-defined parts of this ecosystem:<br>search infrastructure for LLM applications — or simply, the ability to search the internet.</p><p>If you look at real-world agent use cases, search is present in almost all of them.</p><p>An agent needs to obtain information from outside:</p><p>- finding answers and information<br>- verifying facts and real-time data<br>- collecting lists and performing research<br>- tracking changes<br>- analyzing news (one of the most common scenarios)<br>- clarifying details</p><p>Without access to the internet, an agent is limited to the model’s training data — which inevitably becomes outdated.</p><p>That is why search became the first capability to standardize as infrastructure.</p><p>Not as a feature inside a product,<br>but as an external service.</p><p>And over the past few years, a new market has formed around it — <br>the market for search infrastructure for AI agents.</p><h4>What Search Infrastructure Products for AI Agents Actually Look Like</h4><p>Once you start examining this market closely, one pattern becomes obvious:<br>architecturally, it stabilized very quickly.</p><p>Regardless of the company, almost all solutions include the same set of components.</p><p>At the center is web search — the mechanism that finds relevant pages.<br>In many cases, this layer relies on long-established search engines such as Google.<br>But there are also companies building their own indexes in relatively short timeframes — for example, Exa.</p><p>Next comes content extraction — the process of converting HTML into clean text.</p><p>Then comes crawling, which allows systems to traverse entire websites and collect data systematically. This functionality is especially useful for monitoring updates.</p><p>Sometimes a deep research layer is added — enabling more complex search and information aggregation workflows.</p><p>And more rarely, there are features that sit somewhere between research and search — such as structured list discovery or dataset retrieval.</p><p>But in practice, the stack is remarkably consistent:</p><p>Search → Extract → Crawl → Research</p><p>Differences between products rarely appear at the architectural level.<br>Instead, they appear in operational characteristics:</p><ul><li>speed</li><li>reliability</li><li>search and ranking quality</li><li>cost</li><li>output format</li></ul><p>After comparing multiple vendors, the same patterns keep repeating.</p><h4>Observations from the Market</h4><p>1) Most search systems are not optimized for specific languages</p><p>Nearly all solutions are optimized for the English-language internet.<br>Outside that environment, quality often drops noticeably.</p><p>This is not primarily a technical limitation — <br>it reflects the structure of demand.</p><p>The primary market is still the United States or English-speaking ecosystems.</p><p>2) Public SLAs are rarely transparent</p><p>Companies are willing to discuss latency and search quality.<br>But standardized benchmarks for search performance in AI agent contexts still barely exist — with the exception of simple QA-style evaluations.</p><p>Real guarantees around availability, stability, and performance are usually discussed only in enterprise contracts.</p><p>For smaller customers, these metrics are often considered less critical.</p><p>3) High-volume usage is almost never priced at public rates</p><p>Website pricing is typically a reference point.</p><p>But once a system moves into production, pricing conditions are almost always renegotiated directly with sales teams and become customized.</p><p>4) Despite marketing, most workloads remain simple</p><p>There is a lot of marketing around:</p><ul><li>intelligent answers</li><li>agentic workflows</li><li>deep research</li></ul><p>But in reality, the majority of systems repeatedly perform very basic operations:</p><ul><li>find a list of links</li><li>retrieve page text or a snippet</li><li>pass the data to the model</li></ul><h4>Key Players in the Search Infrastructure Market</h4><p>If you compile the list of vendors most frequently mentioned in enterprise conversations, it turns out to be surprisingly compact.</p><p>Among specialized providers, the most commonly discussed include:</p><ul><li>Exa</li><li>Tavily</li><li>Firecrawl</li><li>Parallel</li><li>Google</li><li>Yandex</li><li>Bing</li></ul><p>I intentionally excluded Perplexity and You.com.</p><p>Perplexity receives a significant amount of negative feedback regarding reliability and quality — which is understandable given its strong focus on consumer products.<br>And for You.com, search is not a core business — much of the underlying infrastructure is sourced from other providers.</p><p>Each vendor has its own product philosophy and target audience.<br>But the core capabilities are remarkably similar across the board.</p><h4>What Companies Actually Pay For</h4><p>After the initial wave of excitement and demos, market expectations start to shift.</p><p>At the presentation stage, conversations often revolve around advanced features:</p><p>- deep research<br>- automated analysis<br>- multi-step agent workflows</p><p>But when it comes to use cases that generate consistent revenue, the picture becomes much more pragmatic.</p><p>Companies are not paying for intelligence.<br>They are paying for reliability of basic operations.</p><p>More advanced logic is usually built internally.</p><p>In practice, three capabilities are consistently in highest demand.</p><h4>Fast search</h4><p>Latency becomes a critical parameter because complex systems may execute dozens of sequential tool calls.</p><p>Search is rarely the only tool involved.</p><p>Every additional second directly impacts user experience.</p><h4>Reliable content extraction</h4><p>Not just returning a URL — <br>but returning URL + usable text— turns out to be central to most systems.</p><p>This capability determines whether the model can actually work with the retrieved information.</p><p><strong>Predictable load limits</strong></p><p>Peak performance is less important than stability and control.</p><p>What matters is predictable quotas, rate limits, and operational behavior.</p><p><strong>Two Distinct Customer Types</strong></p><p>The market clearly divides into two categories of customers — and this division strongly influences product selection.</p><p>Type 1 — “Everything as a Service”</p><p>These companies want a ready-made solution.</p><p>They are not particularly sensitive to small differences in quality.<br>They do not want to manage search infrastructure complexity.</p><p>AI is not their core product — it is an additional feature.</p><p>Their primary goal is to get working functionality quickly without large engineering investments.</p><p>They are willing to buy:</p><ul><li>packaged deep research</li><li>ready-made AI answers</li></ul><p>Type 2 — Infrastructure Customers</p><p>These companies treat AI functionality as a core part of their value proposition.</p><p>Sometimes it is their main product — and often they resell it as B2B infrastructure.</p><p>In these cases, requirements increase dramatically.</p><p>They need to:</p><p>- control search quality<br>- adapt system behavior<br>- manage request cost<br>- scale workloads<br>- guarantee service stability</p><p>For these companies, search becomes part of the core architecture.</p><p>They are also the ones most likely to:</p><ul><li>build their own pipelines<br>- combine multiple providers<br>- carefully benchmark latency, quality, and cost</li></ul><h4>Capability Infrastructure Is Designed for Machines — Not Humans</h4><p>One defining characteristic of capability infrastructure is that it is designed for agents not only at the input level, but also at the output level.</p><p>When you look at this emerging product layer, its uniqueness is shaped not just by how it connects to systems, but by the format of the results it produces.</p><p>Yes, integration typically happens through programmatic interfaces:</p><ul><li>APIs</li><li>MCP</li></ul><p>A user interface is helpful — <br>but mostly as a playground or marketing surface.</p><p>The more important distinction lies in the output format.</p><p>These systems are designed from the start to produce results for other systems — not for humans.</p><p>Ideally, outputs should be:</p><p>- structured and compact<br>- predictable<br>- easy to process downstream<br>- token-efficient</p><p>Not a document.<br>Not a webpage.<br>But a set of facts in a concise snippet.</p><h4>The Current Market Structure Is a Compromise with Constraints</h4><p>When looking at today’s search infrastructure ecosystem, it may seem that the market has already stabilized.</p><p>But most likely, this structure did not emerge because it is optimal.</p><p>It emerged because it is what currently works — technically and economically.</p><p>In reality, the market is still adapting to constraints.</p><p>For example, I am confident that once reliable, affordable, general-purpose deep research becomes available, the balance of functionality will shift again.</p><p>Basic operations — search and content extraction — did not become dominant because they are the most interesting.</p><p>They became dominant because they are the most predictable.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=961b1dba9287" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Do AI Agents Really Need Memory — or Is It Just Another “Wow Feature”?]]></title>
            <link>https://medium.com/@annakokovina21/do-ai-agents-really-need-memory-or-is-it-just-another-wow-feature-8245e9d5b5d1?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/8245e9d5b5d1</guid>
            <category><![CDATA[ai-agent]]></category>
            <category><![CDATA[memory-management]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[mem0]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Wed, 14 Jan 2026 12:50:31 GMT</pubDate>
            <atom:updated>2026-01-14T12:50:31.165Z</atom:updated>
            <content:encoded><![CDATA[<h3>Do AI Agents Really Need Memory — or Is It Just Another “Wow Feature”?</h3><p><strong>I tested real agent memory in production — not demos. Here’s what actually improves UX, where memory is useless, and why shared memory matters more than personalization.</strong></p><p>We’re all used to demos where an assistant “remembers you like sugar-free coffee” and, 20 messages later, surprises you with empathy. Sounds great.</p><p>But when it comes to real products — especially B2B — reality is usually far more boring:<br>one prompt, one function, maximum reliability, minimum surprises.</p><p>I ran real product testing of agent memory — not a demo version, but actual pluggable memory with fact storage, retrieval, management, and controls — in production agents.<br>Here’s what we learned 🤭</p><p>— -</p><h4>🔍 What we tested</h4><ul><li>A standalone Memory Server (mem0 / MCP-style architecture)</li><li>API for `query / save / propose / delete`</li><li>Memory stores facts and decides when to retrieve them</li><li>Async writes (no UX latency)</li><li>Ability to inspect and delete what the assistant remembers</li><li>Fully integrated into an already running production assistant</li></ul><p>We tested this with active customers who explicitly wanted this functionality — real assistants doing real work, not living in slide decks.</p><p>— -</p><h4>🧩 How to build memory in platforms</h4><p><strong>Option 1 — Dedicated memory service</strong></p><p>A separate architectural component with its own SLA:</p><p>- Read/write APIs<br>- Namespaces<br>- Sharing support<br>- Tracing and logs</p><p>Why this works:</p><p>- Scales independently<br>- Can be reused across multiple assistants<br>- Not tied to a specific LLM<br>- Fault-tolerant — if memory goes down, the system still works</p><p><strong>Option 2 — Memory baked into the platform</strong></p><p>Memory tightly coupled to the assistant:</p><ul><li>Better developer experience</li><li>Fewer integration steps</li><li>But harder to evolve as a standalone module</li><li>Comes with a tax of unnecessary functionality</li></ul><p><strong>Option 3 — Custom RAG pretending to be memory</strong></p><p>The engineers’ favorite:</p><ul><li>Put everything into vectors</li><li>Retrieve by similarity</li><li>Hope that’s “memory”</li></ul><p>Spoiler: sometimes it is enough.<br>We actually saw this in the pilot.</p><p>— -</p><p><em>So… do businesses need personalized agents with memory — or is it just another shiny toy?</em></p><p>— -</p><h4>🧪 What reality showed</h4><p><strong>✨ Memory does improve UX</strong></p><p>Users consistently said:</p><ul><li>the assistant feels smarter</li><li>it stops asking the same questions</li><li>trust increases</li></ul><p>This wasn’t “tech admiration” — it was observable user behavior.</p><p><strong>Fact:</strong> memory is a direct trust booster.</p><p><strong>❌ But… long-term personal memory is rarely needed</strong></p><p><em>This was the biggest surprise.</em></p><p>There are very few real cases where long-term personal memory truly matters:</p><ul><li>Developers aren’t building complex multi-turn assistants</li><li>Often there isn’t even a stable user ID to separate memories</li><li>Most enterprise products live in a “one prompt → one function” world</li></ul><p>Even more interesting:<br>many teams wanted memory not as memory, but as a cache to:</p><p>- reduce token costs<br>- minimize repeated calls<br>- optimize workflows</p><p>Not “remember me as a person”, but remember intermediate stuff to make this faster.</p><p>— -</p><h4>🔎 Transparency matters more than expected</h4><p>Users want:</p><p>- to see what’s stored in memory<br>- to delete specific facts (not wipe everything)<br>- simple commands instead of a heavy admin panel</p><p>— -</p><h4>🤝 Memory + multiple assistants = 🔥</h4><p>One more unexpected (and very strong) insight:<br>there’s real demand for shared memory used by multiple specialized agents — essentially memory for a workflow or a multi-agent system.</p><p>This is no longer “assistant memory.”<br>It’s organizational product memory.</p><p>Sounds boring — but for business, it’s gold.</p><p>Honestly, this worked in our test almost by accident.<br>Turns out, demand is huge.</p><p>— -</p><h4>🎨 Expectation vs reality</h4><p><strong>Expectation</strong>:<br>Memory like a human’s — growing over time and turning the assistant into a personal digital companion.</p><p><strong>Reality</strong>:<br>Memory as a smart, tidy **working notebook** of the product:</p><p>- helps<br>- speeds things up<br>- increases trust<br>- doesn’t need to be “human”</p><p>And that’s… great.</p><p>Because memory isn’t an empathy toy — it’s **infrastructure** that turns assistants into real products, not demo gimmicks.</p><p>— -</p><h4>🧷 Takeaways</h4><p>Ultra-personalized, long-term memory baked deep into platforms is usually unnecessary.<br>It makes sense mainly for large B2C products — and even there, it’s built very deliberately around specific business needs.</p><p>What does matter:</p><p>- Memory is real value, not a marketing feature — it sharply increases trust<br>- Don’t romanticize “lifelong personal memory” — functional memory is what’s needed<br>- Shared memory is a very strong use case (hello, context engineering 👀)<br>- Transparency and control are must-haves<br>- Market expectations are low — people are happy to ship this “as is”</p><p>- take Mem0<br> -add deduplication<br> -set memory limits<br> and you already have something solid for production</p><p>If you’re building a platform, start thinking about memory not as a cute LLM feature”, but as a core architectural primitive — just like logging or storage.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8245e9d5b5d1" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ Memory for LLM Agents]]></title>
            <link>https://medium.com/@annakokovina21/memory-for-llm-agents-d94c61e6eefe?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/d94c61e6eefe</guid>
            <category><![CDATA[llm-memory]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[memory-management]]></category>
            <category><![CDATA[llm-agent]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Tue, 28 Oct 2025 15:19:31 GMT</pubDate>
            <atom:updated>2025-10-28T15:19:31.670Z</atom:updated>
            <content:encoded><![CDATA[<h3>Memory for LLM Agents: Why It Matters and What’s Already Been Invented</h3><p>If you’ve ever talked to an assistant that completely “forgets” who you are by the next day — you already know why agents need memory.</p><p>Without it, every interaction turns into an endless first date: you have to explain who you are, what you do, and how you like things — over and over again.<br>For users, that’s frustration. For businesses, that’s inefficiency and lost value.</p><h3>Why do agents need memory, really? 🫠</h3><p>Memory isn’t just about better user experience.<br>It defines <em>what</em> an agent can actually do — whether it can remember past interactions, adapt to a user, manage long-term workflows, and incorporate feedback.</p><p>But not all agents need memory in the same way.</p><p>There are two fundamental scenarios 👇</p><h3>🏢 1. The Agent as an AI Employee</h3><p>You’re building an assistant to automate a business process.<br>Its job is to deeply understand the process and act as an impersonal AI worker.</p><p>In this case, the “user” is the company itself — or its employees acting on behalf of it.</p><p>The <strong>north star metric</strong> for such an assistant is <em>closing a specific business task as efficiently and accurately as possible</em>.<br>Focus: execution, process, compliance.</p><p>User experience and personalization still matter — but they’re secondary metrics.<br>A team building an automation-focused LLM system usually won’t prioritize those until much later.</p><h3>👤 2. The Agent as a Personal Assistant</h3><p>Here, you’re building an assistant meant to serve a <em>person</em>.<br>A user delegates tasks to it directly — tasks that are often messy, non-deterministic, and context-dependent.</p><p>Such an agent must remember <em>you</em>:<br>your projects, habits, communication style, and ongoing work.</p><p>It should pick up right where you left off yesterday — and know the difference between “send the file to Vasya” and “send Vasya the file.”</p><p>That means handling explicit facts the user provides (features) and implicit contextual data — the kind they never say out loud, but that defines them.</p><p>Typical examples: personal assistants, HR bots, support agents — any system where <em>context = half the UX</em>.</p><h3>💙 The Customer Support Case</h3><p>This one deserves its own category — the final boss of LLM automation.</p><p>A support agent must remember a customer’s previous tickets, products, issues, and even their cat’s name — all while following a strict policy or script.</p><p>It’s a hybrid scenario that blends both use cases: structured process + personalized context.<br>And it’s <em>the hardest</em> to do well.</p><h3>So what kinds of memory are there? 🤯</h3><p>Let’s break it down (with links to good docs if you want to go deeper).</p><h3>⚡️ Short-Term Memory</h3><p><a href="https://docs.langchain.com/oss/python/langgraph/memory#short-term-memory">Short-term memory</a>, or <a href="https://docs.langchain.com/oss/python/langgraph/persistence#threads"><em>thread</em></a><em> memory</em>, is usually implemented through sessions.<br>It’s what the model “holds in its head” right now — the context buffer of the current conversation.</p><p>It helps the agent keep track of the dialogue, understand pronouns, and stay coherent.<br>Example: LangChain ConversationBufferMemory.</p><p>The obvious downside: once the context window is full — or the session ends — everything is lost.</p><h3>🧩 Long-Term Memory</h3><p><a href="https://docs.langchain.com/oss/python/langgraph/memory#long-term-memory">Long-term memory</a> can be recalled at any time, across sessions — but it’s always tied to a specific agent ID.</p><p>It typically comes in three subtypes:</p><h4>🗓 <a href="https://docs.langchain.com/oss/python/langgraph/memory#episodic-memory">Episodic</a></h4><p>A timeline of user interactions, events, and actions — “what happened and when.”<br>It helps the agent recall <em>how</em> it solved something last time.</p><h4>🔍 <a href="https://docs.langchain.com/oss/python/langgraph/memory#semantic-memory">Semantic</a></h4><p>Stores facts and user traits in a meaningful (vectorized) way — via embeddings.</p><h4>⚙️ <a href="https://docs.langchain.com/oss/python/langgraph/memory#procedural-memory">Procedural</a></h4><p>Keeps patterns, skills, and learned routines — <em>how</em> to perform a task, format a report, or trigger a pipeline.</p><p>A cool related concept is <a href="https://blog.langchain.com/reflection-agents/"><strong>Reflexion</strong></a>:<br>an “actor” agent generates a response, then a “revisor” critiques it — pointing out omissions, errors, or suggesting improvements.</p><h3>What’s Already Been Built 🦆</h3><h4>🔹 <a href="https://github.com/mem0ai/mem0">Mem0 (OpenMemory MCP)</a></h4><ul><li>Built on Python / FastAPI / Qdrant stack.</li><li>Implements semantic memory with embeddings and vector search.</li><li>Supports standard API ops (add, search, list, delete).</li><li>Can run locally or as a cloud endpoint. Integrates with LlamaIndex, LangChain, and OpenAI MCP.</li></ul><p><strong>Pros:</strong> simple, plug-and-play, easy to integrate.<br><strong>Cons:</strong> very basic — no deduplication, summarization, or fact aging. Not scalable.<br><strong>Verdict:</strong> nice concept (especially in MCP context where memory is optional), but too lightweight for production.</p><h4>🔹<a href="https://docs.langchain.com/oss/python/langgraph/memory#semantic-memory"> LangChain Memory</a></h4><ul><li>Offers an entire ecosystem of memory types — from simple buffers to EntityMemory and StateMemory.</li><li>Supports Chroma, FAISS, Redis, and more.</li></ul><p><strong>Pros:</strong> flexible, mature abstractions, solid docs.<br><strong>Cons:</strong> can get confusing — too many layers, no deduplication, and EntityMemory struggles at scale.<br><strong>Verdict:</strong> a mature and flexible option — especially when wrapped into a cloud MCP.</p><h4><a href="https://developers.llamaindex.ai/python/framework/module_guides/deploying/agents/memory/">🔹 LlamaIndex</a></h4><ul><li>Implements long-term memory with vector store integration.</li><li>Includes a fact extraction layer (LLM prompting across sessions).</li></ul><p><strong>Pros:</strong> easy integration, fits into existing pipelines.<br><strong>Cons:</strong> needs careful setup for token limits and fact expiration; memory can “bloat” fast.<br><strong>Verdict:</strong> a solid, no-frills long-term memory base — but you’ll need to extend it if you want more than semantics.</p><h4>🔹<a href="https://arxiv.org/abs/2310.08560"> MemGPT</a></h4><ul><li>More research project than product.</li><li>Uses tool-calling where memory logic (deduplication, priorities, recall) is delegated to the agent itself.</li></ul><p>The most interesting idea: <strong>memory pressure</strong> — letting the agent decide when to offload facts to memory as the token window fills.</p><p><strong>Pros:</strong> elegant concept, dynamic memory management, prioritization of important vs stale facts.<br><strong>Cons:</strong> unstable, expensive, scalability concerns.<br><strong>Verdict:</strong> promising research, far from production-ready.</p><h3>🔹 Semantic Memory in Yandex’s Alice</h3><ul><li>Based on Anatoly Glushchenko’s research on LLM-based personalization in Alice.</li><li>Not open-source, but a great reference — basically a masterclass on how to build high-quality semantic memory.</li><li>Watch the 36-min recording here: <a href="https://ods.ai/events/fest2025-yandex-msc/livestream">ODS.AI Fest 2025 — Yandex MSC</a></li></ul><h3>🔹 AWS Bedrock Agents (Memory)</h3><ul><li>Memory is built right into the agent API.</li><li>Each session is automatically summarized and stored — no manual setup.</li><li>Integrates with Guardrails for filtering, validation, and data safety.</li></ul><p><strong>Pros:</strong> frictionless, everything just works.<br><strong>Cons:</strong> locked into AWS ecosystem.<br><strong>Verdict:</strong> perfect if you’re already in AWS and want something “simple but works.”</p><h3>🔹 Google Vertex AI (Agent Engine + Memory Bank)</h3><ul><li>Memory is part of the Agent Engine; data lives in the Memory Bank.</li><li>Supports cross-session recall via search_memory.</li><li>Treats memory as a tool, with automatic summarization.</li></ul><p><strong>Pros:</strong> deeply integrated, minimal setup.<br><strong>Cons:</strong> limited to Google’s ecosystem, still pre-GA.<br><strong>Verdict:</strong> strong “memory as a service” direction.</p><h3>🏆 What’s Next</h3><p>Right now, everyone’s reinventing the wheel:<br>some teams store everything in a vector DB, others hack together Redis-based memory or summarize via GPT.</p><p>But the trend is clear — <strong>memory is becoming a native service</strong> inside agent platforms.<br>And we, my friends, are all just trying to keep up in this sprint.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d94c61e6eefe" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MCP in Enterprise: Challenges, the Desired Outcome, and Ideas]]></title>
            <link>https://medium.com/@annakokovina21/mcp-in-enterprise-challenges-the-desired-outcome-and-ideas-17bbc0902d3d?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/17bbc0902d3d</guid>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[mcp-server]]></category>
            <category><![CDATA[mcps]]></category>
            <category><![CDATA[llm-applications]]></category>
            <category><![CDATA[mcp-protocol]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Mon, 13 Oct 2025 18:52:33 GMT</pubDate>
            <atom:updated>2025-10-13T18:52:33.766Z</atom:updated>
            <content:encoded><![CDATA[<p>When we talk about <strong>MCP</strong> (Model Context Protocol) outside of the business context, it sounds amazing — almost like a future where you have your personal assistant whose skills can be extended simply by connecting ready-made tools.</p><p>But as soon as the discussion turns to implementing MCP in a <strong>large corporation</strong>, the usual questions arise: security, authorization, scalability, and context management.</p><p>In this article, we’ll try to understand <strong>why MCP is more than just hype</strong> — and how it can reshape the enterprise landscape.</p><h3>MCP Today</h3><p>At the moment, <strong>MCP is gaining massive popularity</strong> — a large community has grown around it, and the MCP server ecosystem is expanding literally every day.</p><p>The protocol allows extending the capabilities of LLM applications by providing a standard way to interact with external data and tools.</p><p>But along with that come new challenges — especially when it comes to <strong>enterprise environments</strong>.</p><h3>Key Security Questions</h3><ol><li>There are no standard verification mechanisms for MCP servers (which means potential malicious code risks).</li><li>It’s necessary to ensure safe use of servers <strong>inside the company</strong>.</li><li>Clear usage scenarios and access control are required.</li></ol><h3>What is MCP</h3><p>For those who read the preview and got interested but found the term unfamiliar:</p><p>MCP is not a framework or a tool — it’s a protocol, similar to:</p><ul><li>HTTP for the internet</li><li>SMTP for messaging</li><li>LSP (Language Server Protocol) for programming language support</li></ul><p>Anthropic aptly describes MCP as “the USB-C port for agentic systems” — a universal interface that standardizes interactions between different AI ecosystem components regardless of their vendor.</p><h3>MCP Architecture</h3><ul><li><strong>Host</strong> (LLM applications) — creates and manages multiple clients</li><li><strong>Client</strong> — maintains 1:1 connections with servers, manages the protocol</li><li><strong>Server</strong> — provides context, tools, and prompts to clients</li></ul><p><strong>What to Read to Understand MCP</strong></p><ul><li>Available on Habr: <a href="https://habr.com/ru/articles/893482/">https://habr.com/ru/articles/893482/</a></li><li>Article from the creators: <a href="https://www.anthropic.com/news/model-context-protocol">https://www.anthropic.com/news/model-context-protocol</a></li></ul><h3>A Dry Product Intro: Why MCP Matters for Companies (or the Journey Every Russian Big Tech Has Taken in Some Form)</h3><p>A year ago, the industry started talking about <strong>agents</strong> — a powerful approach to leveraging large language models (LLMs), allowing not just text-based responses but full-fledged automation systems with external function, API, and tool calls.</p><p>Companies believed in the agent concept and began building infrastructure enabling LLMs to act not as toys but as real assistants with access to actual actions and internal company services.<br> And they quickly ran into a storm of custom integrations, uncontrolled context sharing between tools, duplicated connectors, and violations of basic information security practices — even risks falling under Article 137 of the Criminal Code (if you know, you know).</p><p>By “agent,” we mean a system where the LLM doesn’t just answer questions but can <strong>perform actions</strong> — call functions, trigger APIs, run external services.<br> This approach, known as <strong>tool calling</strong> (or function calling), greatly extends the model’s capabilities.</p><p>The model becomes not just a text generator but <strong>an interface to a set of skills</strong>, enabling it to solve more complex tasks — pulling data from CRMs, generating reports, interacting with internal systems, etc.</p><p>But to do that, the LLM must have access to those functions and services.</p><p>It’s logical to create a centralized “tool registry” for agents — a repository of functions, APIs, and microservices that can be connected to the agent.</p><p>If you developed some skill — say, an integration with an internal service or external platform — you could describe it as a tool and add it to the catalog. Then it becomes available to LLMs.</p><p>The idea was great: a single source of skills from which agents could be built like LEGO.</p><p>The first attempts went in this direction — for example, using OpenAI’s responses API.<br> Good idea, sure — but not one that took off.<br> We all understand that for a catalog to work, you first need an adoption point — an added value from registering your tool. That value could come from reusing other existing tools.<br> In short: you must fill the catalog first, <em>then</em> onboard users. A simple idea, often forgotten when speed to market is the main goal.<br> Also, responses API doesn’t help with security and authorization at all.</p><p>That’s where MCP comes to mind — it offers, right out of the box, a significant library of integrations generously written by the community, while allowing segmentation of tools by MCP servers and fine-grained access control.</p><p>While working with LLM agents, it becomes clear that once an agent goes beyond a single user and fixed toolset, <strong>systemic complexity</strong> begins.</p><p>The first major issue is <strong>authorization</strong>.<br> An agent calling external APIs must do so <strong>on behalf of the user</strong>, but the LLM itself cannot “own” an authorization context.<br> You can’t just pass an auth token into the model (even if it’s deployed within the company’s perimeter) and expect it to inject it safely into requests without leaking artifacts.</p><p>In enterprise environments, this becomes critically important: any action (creating tasks, accessing storage, reading data) must be tightly bound to the current user’s context.</p><p>If we want the agent to be universal (i.e., serving different users with different permissions), we must solve several problems:</p><ul><li><strong>Token management:</strong> where are tokens stored, how are they passed and validated?</li><li><strong>User context:</strong> what does the agent know about the user? How is that passed to the tool?</li><li><strong>Access control:</strong> what actions are allowed or forbidden?</li><li><strong>Security:</strong> how to prevent privilege leaks, especially if the agent is a public assistant?</li></ul><p>These are <strong>non-trivial issues</strong>, and the industry still hasn’t reached a unified solution.<br> Most existing implementations are custom patches within specific projects or teams.</p><h3>For Those Getting into the LLM Application Zoo: A Simple Difference Between Responses API and MCP</h3><p>This section would have helped me a lot when I was starting out — maybe it’ll help you too.</p><h3>Let’s Recap</h3><p><strong>Responses API</strong> is the interface you use to communicate <strong>directly with the model</strong> (e.g., GPT-4, GPT-5, etc.).</p><p>It manages <strong>how the model responds</strong>, <strong>what tools it can use</strong>, and <strong>in what format</strong> it returns results.</p><p>📘 In simple terms:</p><blockquote><em>Responses API = “How the model thinks and speaks.”</em></blockquote><p><strong>Key Features:</strong></p><ul><li>Used for text/code/answer generation</li><li>Supports output streaming</li><li>Can connect plugins/tools (like python, image_gen, web)</li><li>Universal JSON format with fields like role, content, tool_calls, etc.</li><li>It’s a low-level API for dialogue and reasoning</li></ul><p><strong>MCP</strong>, on the other hand, is a <strong>protocol</strong> that defines <strong>how external systems and data</strong> can be “connected” to the model <strong>safely and in a standardized way</strong>.</p><p>It’s like a <strong>universal bridge</strong> between the model and external data sources/tools.</p><p>📘 In simple terms:</p><blockquote><em>MCP = “How the model interacts with the outside world.”</em></blockquote><p><strong>Key Features:</strong></p><ul><li>Standardizes interaction between the model and third-party systems</li><li>Allows connecting <strong>plugins</strong>, <strong>internal databases</strong>, <strong>APIs</strong>, <strong>tools</strong>, <strong>IDE plugins</strong>, etc.</li><li>Works <strong>through the Responses API</strong> — meaning Responses API remains the communication channel, while MCP adds the integration layer</li><li>Provides security (access control, context isolation)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PUVOFBcn6GjTfRyXmeYKow.png" /></figure><p>🧩 Responses API — receives user input and manages the response stream<br> 🧠 Model — decides it needs external data<br> 🔗 MCP — connects to Notion (or another system)<br> 📊 External service — returns raw data<br> 🧠 Model + Responses API — format and deliver final output to the user</p><h3>Back to MCP in Corporations: The Facts</h3><p>All the above sounds visionary — but in practice, the topic splits into two tracks:</p><ol><li><strong>Local development environment:</strong> MCP servers are run directly on developers’ machines for testing and development.</li><li><strong>LLM-ization of corporate APIs:</strong> MCP servers serve as an intermediate layer, exposing internal APIs to LLMs safely and uniformly.</li></ol><p>Let’s explore the requirements for each track.</p><h3>Local MCP, Open Source Ideas and Solutions</h3><p>This track is designed for <strong>secure, observable, and fast use of ready-made MCP servers</strong> from the industry — typically in coding agents or designer workflows (yes, Figma MCPs are still relevant). The main feature of this sub-track is that the agent acts <strong>strictly on behalf of the owner</strong> and usually within their <strong>local environment</strong>.</p><h3>Who Defines the Requirements and What Are They?</h3><p>In this zone, three things are critical for your information security:</p><ul><li><strong>Cataloging MCP servers</strong> — a clear list of what is allowed and what is forbidden.</li><li><strong>Validation and isolation</strong> — no accidental rm -rf / or calls to blacklisted MCP servers or tools.</li><li><strong>Tracing and auditing</strong> — because security isn’t only about blocking actions but also about being able to restore the full context of what happened.</li></ul><p>The <strong>local track</strong> is about developers, convenience, and security.<br> It’s simple: if you want to use ready-made MCP tools — go ahead, but under control.</p><p><em>The goal of this section isn’t to prescribe “the right way,” but to highlight tools and ideas that might help you address MCP challenges inside a corporation.</em></p><h3>ETDI: Mitigating Tool Squatting and Rug Pull Attacks in MCP (OAuth-Enhanced Tool Definitions + Policy-Based Access Control)</h3><p><a href="https://arxiv.org/pdf/2506.01333">https://arxiv.org/pdf/2506.01333</a></p><h3>Goals and Functionality</h3><p><strong>ETDI</strong> is a security extension for the Model Context Protocol (MCP), targeting two key threats:<br> <strong>tool squatting/poisoning</strong> (malicious or impersonated tools) and <strong>rug pull attacks</strong> (hidden behavioral changes in previously approved tools).</p><p>The approach is <strong>multi-layered</strong>:</p><ol><li><strong>Cryptographic identification</strong> and signing of tool definitions.</li><li><strong>Immutable, versioned definitions</strong> — any significant change = a new signed release.</li><li><strong>Explicit rights and permissions</strong>, often mapped to <strong>OAuth 2.0 scopes</strong> and/or transmitted via <strong>JWT</strong>.</li><li>Additionally, <strong>policy-based access control (PBAC)</strong>: fine-grained authorization of requests through an external PDP (e.g., OPA/Rego or Cedar/Amazon Verified Permissions) considering context (who/what/when/where/resource/action).</li></ol><p><strong>Example flow:</strong></p><p>An MCP client retrieves a list of tools but, instead of trusting the description blindly, it:</p><ul><li>Verifies the tool definition signature</li><li>Checks the version and hash of the contract (e.g., OpenAPI)</li><li>Compares the required OAuth scopes</li><li>Then, on each invocation (or by policy), queries the PDP for an allow/deny decision for that specific action and resource.</li></ul><h3>Drawbacks</h3><ul><li><strong>Complexity:</strong> key management, version rotation, OAuth integration (including consent UX), and PDP deployment → significant operational overhead.</li><li><strong>Single point of delay:</strong> each call may require a runtime check with the PDP → potential latency.</li><li><strong>Not part of the core MCP specification:</strong> this is an <em>extension</em>, not an official standard — clients and servers need explicit support.</li><li><strong>Maturity:</strong> research paper from June 2025 — not production-ready yet, but good for conceptual adoption.</li></ul><h3>Summary</h3><ul><li><strong>Discovery/Catalog:</strong> ETDI itself isn’t a registry, but its metadata (signed definitions + versions + scopes) can be stored and validated within your own catalog.</li><li><strong>Compatibility with Docker/Gateways:</strong> ETDI integrates well with gateways like Docker MCP Gateway, ContextForge, or Unla — the gateway/client can act as the <strong>PEP</strong> (Policy Enforcement Point), validating signatures and querying the PDP.</li><li><strong>Access Control:</strong> combine <strong>OAuth</strong> (who and what is allowed in general) + <strong>policies</strong> (when and on what specifically) + <strong>strict versioning</strong> (what exactly was approved).</li><li><strong>Audit Readiness:</strong> storing logs (tool_id, version, scope, policy decision), signatures, and version chains simplifies both internal and regulatory audits.</li></ul><h3>MCP Guardian (eqtylab/mcp-guardian)</h3><p><a href="https://github.com/eqtylab/mcp-guardian">https://github.com/eqtylab/mcp-guardian</a></p><p>A homemade solution — created mostly for experimentation and learning.</p><p><strong>What it does and general impression:</strong></p><ul><li>Very minimal in functionality — more of an MVP than a real product. Commits and releases are made by one developer over a few months, last updated in April.</li><li>Functionality includes:</li><li>Saving and launching servers listed in a configuration (likely via subprocess)</li><li>Adding a <em>guard profile</em> to intercept calls to and responses from MCP servers, prompting the user for confirmation through a simple UI.</li></ul><p><strong>Interesting ideas:</strong></p><ul><li>Query logging</li><li>A <em>human-in-the-middle</em> mode for manual approval of MCP requests and responses</li></ul><h3>Unla</h3><p><a href="https://github.com/AmoyLab/Unla">https://github.com/AmoyLab/Unla</a></p><h3>Pros</h3><ul><li>Its main (and currently the only mature) feature: automatic wrapping of APIs into the MCP protocol.</li><li>Written in Go — strong performance and scalability.</li><li>Logs all calls.</li><li>Has an OpenAPI-based configuration generator.</li></ul><h3>Cons and Limitations</h3><ul><li>Very basic and early-stage support for authentication in third-party APIs.</li><li>No plugin system; the project is young and in active development — potential maintenance overhead for forks.</li><li>Retries, rate limiting, and error handling must be implemented on your side.</li></ul><h3>Why Use It</h3><p>It allows you to <strong>wrap APIs into MCP</strong> quickly and with minimal effort.</p><h3>MCPX (MCP Gateway by Lunar.dev)</h3><p><a href="https://docs.lunar.dev/mcpx">https://docs.lunar.dev/mcpx</a><br> <a href="https://github.com/TheLunarCompany/lunar/tree/main/mcpx#readme">https://github.com/TheLunarCompany/lunar/tree/main/mcpx#readme</a></p><p>Developed as a component of Lunar’s own ecosystem. Initially, the company built an API gateway for call monitoring; now the focus has shifted to <strong>access control for external LLM providers</strong>.<br> Features include rate limiting, quotas, monitoring, etc. MCPX is open source and designed for integration.</p><p><strong>License:</strong> MIT (for MCPX)</p><h3>Open Source Features</h3><ul><li>Very simple user authorization mechanism: a single constant string in ENV (shared by all users).</li><li>Supports connecting MCP servers, including subprocess stdio connections. Configuration is defined in JSON:</li><li>For stdio/local: uvx/npx + command and envs; critical envs set in the Docker container running MCPX.</li><li>For remote MCP: streamable-http/sse. Via the MCP SDK, standard OAuth 2.0 authorization is used if required. MCPX UI supports triggering the OAuth flow in an external system; all users then share the obtained credentials.</li><li>Exports metrics via Prometheus.</li><li>Tool customization support.</li><li>ACL (Access Control List) — but weak security, as group assignment is handled through a simple text header.</li></ul><h3>Paid / Proprietary Features</h3><ul><li>IAM integration with internal providers.</li><li>Manual review and approval workflows.</li><li>Integration with Lunar’s main <strong>AI Gateway</strong> product.</li><li>SLA support, etc.</li></ul><h3>Interesting Ideas</h3><ol><li><a href="https://docs.lunar.dev/mcpx/tool_customization"><strong>Tool customization</strong></a></li></ol><ul><li>Creating new tools with specific parameters</li><li>Overriding selected parameters</li><li>Modifying tool descriptions in MCP endpoints</li></ul><p><a href="https://docs.lunar.dev/mcpx/access_control_list"><strong>2. ACLs</strong></a></p><ul><li>Grouping tools into subsets of services and endpoints</li><li>Rules defining allowed or denied groups</li><li>Assigning rules to specific MCP clients</li></ul><h3>Kong AI Gateway for Protecting, Observing, and Managing MCP Servers</h3><p><strong>NOT OPEN SOURCE</strong><br> <a href="https://github.com/Kong/kong">https://github.com/Kong/kong</a></p><p><strong>What it is:</strong> An API gateway — a platform for centralized configuration, publishing, management, and monitoring of APIs.<br> It consists of the <strong>API Gateway</strong> itself, a system of <strong>Plugins</strong> handling various operational aspects, and the <strong>Konnect</strong> management console.<br> The console and some plugins are commercial. It supports multi-service gateways, <a href="https://developer.konghq.com/event-gateway/get-started/">Kafka</a> integration, and built-in API development tools.</p><p>Kong now also offers <strong>AI Gateway</strong> capabilities based on its platform, implemented through a system of specialized <a href="https://konghq.com/blog/product-releases/announcing-kong-ai-gateway">plugins</a> for AI and LLM workloads.</p><h3>Notable Features in AI Gateway</h3><p>There are two mentions of MCP in the documentation:</p><ul><li>The AI Gateway can expose <strong>external MCP servers</strong> (e.g., GitHub) via the gateway.</li><li>There is also an <strong>internal MCP server</strong> for managing the gateway itself.<br> → <a href="https://developer.konghq.com/mcp/kong-mcp/get-started/">https://developer.konghq.com/mcp/kong-mcp/get-started/</a></li></ul><p><strong>Example plugins:</strong></p><ul><li><a href="https://developer.konghq.com/plugins/ai-prompt-guard/">ai-prompt-guard</a>: a prompt guard plugin that stores regex-based rules to allow/deny LLM requests.</li><li><a href="https://developer.konghq.com/how-to/use-ai-semantic-prompt-guard-plugin/">Semantic prompt guard</a>: license required.</li><li><a href="https://developer.konghq.com/plugins/ai-proxy/">ai-proxy</a>: proxy access to different model providers.</li><li><a href="https://developer.konghq.com/plugins/openid-connect/">openid-connect</a>: general-purpose, suitable for any API.</li></ul><p><strong>Interesting ideas:</strong></p><ul><li>The concept of a modular platform.</li><li>The flexible plugin system.</li></ul><h3>ARCH</h3><p><a href="https://github.com/katanemo/archgw">https://github.com/katanemo/archgw</a></p><p><strong>ArchGW (or simply Arch)</strong> is a proxy server for handling <strong>LLM requests and agent workflows</strong>.<br> It takes care of infrastructure aspects: prompt routing, security (guardrails), LLM connection management, and observability.</p><h3>Key Capabilities</h3><p><strong>Prompt routing</strong> to target agents or LLMs based on intent.</p><p><strong>How it works:</strong></p><ul><li>ArchGW receives an incoming <strong>prompt</strong> (from a chatbot, agent, or API).</li><li>The <strong>Intent Resolver</strong> layer analyzes the prompt:</li><li>Either through <strong>semantic matching</strong> (LLM or vector embeddings)</li><li>Or via <strong>rule-based configuration</strong> (regex, keywords).</li><li>The request is then routed to the appropriate <strong>prompt target</strong>:</li><li>An agent (e.g., “customer-support-agent”), or</li><li>A specific LLM backend (e.g., OpenAI GPT-4 or local LLaMA).</li><li>Envoy handles the network routing (HTTP/gRPC), while Arch adds logic for intelligent destination selection.</li></ul><p><strong>Guardrails</strong> — centralized definition and enforcement of safe behavior (e.g., preventing jailbreak attacks).</p><p><strong>How it works:</strong></p><ul><li>All prompts go through a <strong>policy engine</strong> within ArchGW.</li><li>Policies are defined via configuration (e.g., “block DB deletion commands,” “filter PII”).</li><li>Mechanisms used:</li><li><strong>Regex filters</strong> for quick heuristics.</li><li><strong>LLM-based classifiers</strong> for semantic risk detection (e.g., jailbreaks, toxicity).</li><li>If a policy is violated:</li><li>The prompt is rejected, or</li><li>It is modified (e.g., masking PII).</li></ul><p><strong>Unified LLM Access</strong> — connects to multiple LLMs via a uniform interface; supports models and functions (e.g., function calls) via configuration.</p><p><strong>Observability and Metrics</strong> — supports OpenTelemetry, W3C Trace Context, integrations with Jaeger, Signoz, Honeycomb, and more.</p><p><strong>Built on Envoy Proxy</strong> — Arch operates as a containerized gateway alongside applications, extending Envoy for LLM-specific workloads.</p><h3>Drawbacks</h3><ul><li><strong>No built-in API control:</strong> guardrails exist, but OAuth, PBAC, or other enterprise-grade access policies are not provided out-of-the-box — external integration is required.</li></ul><h3>Remote MCP: Product Rationale and Open Source</h3><p>This section is about <strong>modernizing APIs</strong> and connecting internal master systems of a company through MCP servers.<br> In other words, it’s not just “I, as a user, invoked a tool locally,” but rather “we have a corporate assistant that aggregates access to multiple systems and acts on behalf of the company.”</p><p>That’s an entirely different set of requirements:</p><ul><li>Cataloging is no longer about restriction but about <strong>discovery</strong> — understanding which APIs and services are available.</li><li>The key topic is <strong>authorization</strong>, and it’s <strong>two-level</strong>: what a user can do within the assistant and what the assistant can do on behalf of the user in the master system.</li><li>There may also be a <strong>runtime</strong> — an environment where you can not only assemble tools but also run them, share access with colleagues, and test solutions.</li></ul><p>If we break down potential stakeholders, we’ll see that MCP can serve different needs:</p><ul><li><strong>Large B2B automation teams</strong> see it as a way to reuse existing tools without endless custom integrations. MCP provides a standard that makes tool creation transparent and reproducible, and it also allows delegating integration logic to the systems that own the APIs.</li><li><strong>Pilot teams</strong> and assistant creators want to focus on business logic, not infrastructure. MCP lets them grab ready-made tools, assemble an MVP agent easily, and test hypotheses without heavy setup.</li><li><strong>Master systems and business domains</strong> gain the ability to offer “out-of-the-box” automation: if your API is already described in an MCP catalog, hundreds of assistants can use it without dedicated integration work.</li></ul><h3>A note on runtimes</h3><p>Large teams usually <strong>don’t need</strong> a runtime — they already have their own environments where everything runs, and MCP just integrates into that.</p><p>However, pilots and experimenters really <strong>do need it</strong>: they want a space where they can quickly build an agent, test it, and show it to users without deploying a full infrastructure.</p><p>It’s logical to look toward <strong>lightweight, minimal runtimes</strong> — not over-engineered for high load, but capable of fast iteration and validation.<br> Such a runtime can be deployed using open-source tools like <strong>n8n</strong> or <strong>OpenWebUI</strong>, ensuring a very low entry barrier.</p><p>Let’s take a look at what’s interesting in the open-source ecosystem — or at least already available today.</p><h3>MCP Registry by Anthropic</h3><h3>Purpose and Functionality</h3><p>The MCP Registry is a <strong>centralized catalog</strong> of MCP servers.<br> It provides a RESTful API that allows you to <strong>discover, register, and manage MCP server descriptions</strong>.<br> Each server in the registry contains metadata (name, description, repository link) and information about images/packages (for example, a Docker image with options).<br> This makes it easier for developers and organizations to find existing integrations (for example, MCP servers for Google Drive, GitHub, Slack, etc.) without manually gathering them from scattered sources.</p><h3>Pros</h3><ul><li>Simplifies <em>discovery</em> of MCP servers</li><li>Provides a unified API for search</li><li>Supports both MongoDB and in-memory storage</li><li>Community-managed (Anthropic and other contributors), allowing for verified, expanding server lists</li><li>Easy to self-host (Dockerized deployment)</li></ul><h3>Cons and Limitations</h3><ul><li>The registry itself is just a catalog; it <strong>does not run</strong> servers or provide execution infrastructure</li><li>No built-in security guarantees for all entries</li><li>Reliability depends on the stability of the web server and MongoDB; scaling relies on MongoDB replication</li></ul><h3>Why Use It</h3><ul><li>The registry is useful when you need to <strong>quickly find an existing MCP server</strong> for a specific task, check its parameters, and get its image or source code.</li></ul><h3>MCP Catalog by Docker</h3><h3>Purpose and Functionality</h3><p><strong>Docker MCP Catalog</strong> is a <strong>repository of containerized MCP servers</strong> on Docker Hub.<br> Each MCP server is packaged as a Docker image and centrally hosted.<br> The catalog groups MCP servers by category (DevTools, Data, Finance, etc.), making it easy to find and launch them directly from Docker Desktop.</p><p>According to Docker, the catalog includes over <strong>100 verified MCP servers</strong> (for example, Stripe, Grafana, and others), divided into Docker-built and community-built (unverified) ones.</p><p>Each tool runs in an isolated container, which improves reproducibility and security.<br> The catalog is accessible through Docker Desktop and the Docker Hub web interface, complete with search, tags, and filters.</p><h3>Pros</h3><ul><li><strong>Ease of launch:</strong> just have Docker installed — docker run mcp/&lt;server_name&gt; starts the desired server with pre-configured parameters.</li><li><strong>Security:</strong> Docker-built servers are verified, signed, and scanned for vulnerabilities. Container isolation minimizes risk (each runs with limited privileges).</li><li><strong>Standardization:</strong> unified management (Docker), consistent interface (MCP), and built-in support in MCP Toolkit.<br> Solves the “where do I find an MCP server?” problem — everything is in one place.</li></ul><h3>Cons</h3><ul><li><strong>Dependency on Docker:</strong> requires Docker Desktop or Engine — you can’t run images without it.</li><li><strong>Limited ecosystem:</strong> the catalog contains many, but not all, MCP servers; missing ones must be containerized manually.</li><li><strong>Potential costs:</strong> Docker Desktop with MCP Toolkit is part of a commercial product; private repositories or licensing may incur additional costs.</li></ul><h3>Why Use It</h3><ul><li>The catalog allows for <strong>fast experimentation</strong> and integration of services.</li></ul><h3>MCP Gateway by IBM (ContextForge)</h3><h3>Purpose and Functionality</h3><p><strong>IBM ContextForge MCP Gateway</strong> is a comprehensive gateway/registry/proxy.<br> Its goal is to <strong>serve as a central control point for tools, resources, and prompts for MCP clients</strong>.<br> ContextForge combines a gateway (merging multiple backends into one endpoint), a registry (federating data about servers/tools), and adapters.</p><h3>Features</h3><ul><li><strong>Protocol-flexible gateway:</strong> sits in front of any MCP server or REST API, providing a unified interface.<br> Supports multiple MCP protocol versions and allows clients to interact through a single HTTP/SSE endpoint with multiple tools.</li><li><strong>Federation and registry:</strong> can automatically discover and merge multiple MCP gateways/registries (peer-to-peer) into one network view. Supports mDNS and Redis caching for synchronization and failover.</li><li><strong>API virtualization:</strong> wraps ordinary REST/gRPC services into virtual MCP servers. Tools are declared via configuration, and the gateway can extract JSON schemas, handle HTTP headers/tokens, and manage retries and rate limiting.</li><li><strong>Unified registries:</strong> stores not only tools but also <em>prompts</em> and <em>resources</em> (e.g., Jinja2 templates, static files, links) with versioning and rollback.</li><li><strong>Security and observability:</strong> built-in authentication, authorization, auditing, rate limiting, automatic retries, and a live management UI.</li><li><strong>Scalability:</strong> runs as a Python (FastAPI) app, deployable via Docker or cloud (Azure/AWS/Red Hat) with PostgreSQL/Redis for multi-cluster setups.</li></ul><p>According to the README, ContextForge targets serious enterprise deployments, though the current version is <strong>alpha/beta</strong> and <strong>not production-ready</strong> without thorough testing.</p><h3>Cons</h3><ul><li><strong>Complexity:</strong> rich functionality makes configuration non-trivial</li><li><strong>Maturity:</strong> still in early-beta stage without official IBM support</li><li><strong>Infrastructure requirements:</strong> full functionality requires Docker/containers and databases (PostgreSQL, Redis)</li></ul><h3>Why Use It</h3><p>ContextForge is valuable if you need <strong>centralized management</strong> of numerous MCP integrations and/or seamless integration with legacy systems.<br> It covers <strong>“LLM-ization of APIs”</strong> (creating virtual tools from existing APIs) and <strong>enterprise-grade security requirements</strong> (auth, auditing, etc.) through policy and isolation features.<br> In essence, ContextForge acts as a <strong>“neural bus”</strong> for communication between LLMs and services — ideal for building an <strong>internal assistant platform</strong>, similar to GPT plugins but within your own infrastructure.</p><h3>Final Thoughts</h3><p>I hope this helped you <strong>structure the underlying need that’s in the air</strong> and provided <strong>a few practical ideas</strong> for implementing MCP in corporate environments.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=17bbc0902d3d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Rerankers in the RAG Pipeline ]]></title>
            <link>https://medium.com/@annakokovina21/rerankers-in-the-rag-pipeline-621ce168be83?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/621ce168be83</guid>
            <category><![CDATA[llm-applications]]></category>
            <category><![CDATA[rags]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[reranker]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Mon, 29 Sep 2025 10:44:30 GMT</pubDate>
            <atom:updated>2025-09-29T10:44:30.555Z</atom:updated>
            <content:encoded><![CDATA[<p><em>A purely overview-style article</em></p><p>Even the best retriever can’t guarantee good answers if your pipeline is missing two critical components: <strong>reranker</strong> and <strong>rejector</strong>.<br> These are the parts that:</p><ul><li>prioritize the most relevant documents,</li><li>filter out noise and duplicates,</li><li>and, when needed, confidently say: <em>“I don’t have enough information to answer.”</em></li></ul><p>In my new overview article, I break down:<br> 🔍 why rerankers are essential in a RAG pipeline and the main approaches used,<br> 🛑 what rejectors are and how they increase reliability,<br> 📊 results of experiments on real Russian-language datasets,<br> ⚙️ and which models performed best in practice.</p><p><strong>Part 1 — The Absolute Basics</strong></p><p>Retrieval-Augmented Generation (RAG) has become the de facto standard for building question-answering systems, chatbots, and enterprise assistants. However, even the best search systems and vector databases can’t guarantee that the top-k retrieved documents will all be equally useful for generating a final answer.</p><p>That’s where <strong>re-ranking</strong> comes into play.</p><p>In this article, we’ll break down:</p><ul><li>why you need a reranker in a RAG pipeline</li><li>the main approaches to reranking</li><li>what “rejectors” are and why they matter</li><li>pros and cons of different techniques</li><li>results from tests on Russian-language datasets from major tech companies</li></ul><blockquote><em>⚠️ </em><strong><em>Disclaimer:</em></strong><em> This article is not meant to be a comprehensive survey or benchmark of reranking methods. It’s more of a research summary aimed at finding a near-universal solution for a platform — and exploring how to design a contract that allows integrating a domain-adapted reranker.</em></blockquote><blockquote><em>⚠️ </em><strong><em>Another important note:</em></strong><em> A “universal” reranker will </em>never<em> outperform a domain-specific solution built for a particular use case. Reranking is highly dependent on your data and context.</em></blockquote><h3>Why Do We Even Need a Reranker? 😳</h3><p>A classic RAG pipeline looks like this:</p><ol><li>The user query is converted into a vector.</li><li>The top-k closest documents are retrieved from a vector index.</li><li>A generator model (LLM) uses those documents to produce an answer.</li></ol><p>The problem is:</p><ul><li>Some documents might be only <em>indirectly</em> relevant.</li><li>Others could be too general.</li><li>And some may contain noise or duplicates.</li></ul><p>A reranker helps prioritize the most useful context and feed the LLM only what’s truly helpful.</p><h3>Part 2 — Still Basic, but Getting More Interesting</h3><h3>Approaches to Reranking</h3><h3>1. Semantic Re-ranking (Cross-Encoder)</h3><p>💬 <em>Comment:</em> The most common go-to solution once you read a few papers on reranking.</p><ul><li>A separate model takes a <em>(query, document)</em> pair and outputs a relevance score.</li><li>Popular models: <strong>MS MARCO</strong> cross-encoders, <strong>MonoT5</strong>, etc.</li><li>Accuracy is higher than with a bi-encoder, but it’s computationally expensive — each candidate must be processed individually.</li></ul><p><strong>When to use:</strong> When you care about high accuracy and the candidate set is relatively small (k ≤ 100).</p><h3>2. Hybrid Scoring (BM25 + Embeddings)</h3><p>💬 <em>Comment:</em> Kinda old-school and not exactly “21st century” vibes.</p><ul><li>Combines classic retrieval (BM25, TF-IDF) with vector search results.</li><li>The reranker simply aggregates the two scores, often via a linear combination.</li></ul><p><strong>Pros:</strong> Fast, no additional model required.<br> <strong>Cons:</strong> Doesn’t always capture subtle semantic differences. A budget-friendly but low-quality approach.</p><h3>3. Using an LLM as a Reranker</h3><p>💬 <em>Comment:</em> The most obvious next step after “just sort by score” — usually appears when people still treat the LLM as a magic black box and don’t calculate inference costs. It <em>can</em> work with a fine-tuned smaller model, though.</p><ul><li>Instead of a dedicated reranker, the LLM itself estimates how much a document helps answer the question.</li><li>Can be done with zero-shot or few-shot prompting, e.g.:<br> <em>“Rank the following passages by their relevance to the query.”</em></li></ul><p><strong>Pros:</strong> Flexible, understands semantics and context.<br> <strong>Cons:</strong> Expensive and slow on large candidate sets.</p><h3>4. Learning-to-Rank Models</h3><p>💬 <em>Comment:</em> A solid approach if you’re building a local, domain-specific solution.</p><ul><li>Trained on custom datasets (e.g., enterprise Q&amp;A).</li><li>Methods: <strong>LambdaMART</strong>, <strong>RankNet</strong>, <strong>LightGBM-ranker</strong>.</li><li>Typical input features: embedding similarity, BM25 score, document length, keyword positions, etc.</li></ul><p><strong>Pros:</strong> Can be tailored to domain-specific needs.<br> <strong>Cons:</strong> Requires labeled data with “document relevance” annotations.</p><h3>5. Post-Filtering with Heuristics</h3><p>💬 <em>Comment:</em> In my opinion, an essential step that complements reranking rather than replacing it.</p><p>Sometimes, simple rules go a long way:</p><ul><li>Remove duplicates.</li><li>Filter out documents that are too short or too long.</li><li>Exclude low-trust sources.</li></ul><p><strong>Pros:</strong> Fast and free.<br> <strong>Cons:</strong> Doesn’t solve semantic retrieval errors.</p><p>Отлично 👍 — вот продолжение твоей статьи (<strong>Part 3 &amp; 4</strong>) в хорошем английском переводе, готовом к публикации на <strong>Medium</strong>. Я сохранил стиль, структуру и даже «токс-комменты», адаптировав их под англоязычную аудиторию, чтобы текст выглядел естественно и не потерял оригинальный тон:</p><h4><strong>Part 3 — Still Basic, But Getting More Interestingeeee</strong></h4><h3>What Are Rejectors?</h3><p>Sometimes, you <em>shouldn’t</em> try to generate an answer at all costs. If the user’s query is too far from the knowledge base — or no relevant documents were found — a <strong>rejector</strong> can save the day.</p><h3>What Does a Rejector Do?</h3><ul><li>Analyzes the relevance of retrieved documents.</li><li>Determines whether there’s enough information to generate a meaningful answer.</li><li>If confidence is too low, it “rejects” the query or returns a fallback response — e.g., <em>“Sorry, I don’t have enough information to answer that.”</em></li></ul><h3>Approaches to Building Rejectors</h3><h3>1. Threshold-Based Filtering</h3><p>💬 <em>Comment:</em> Works only for homogeneous query types. If you have different “buckets,” you’ll need separate thresholds — or rephrasing.</p><ul><li>If the <strong>maximum</strong> or <strong>average similarity score</strong> is below a certain threshold → reject the query.</li><li><strong>Pros:</strong> Simple and fast.</li><li><strong>Cons:</strong> The threshold must be tuned empirically and doesn’t account for semantic nuances.</li></ul><h3>2. LLM Classifier</h3><p>💬 <em>Comment:</em> Same trade-offs as with using an LLM as a reranker.</p><ul><li>The model receives the query and retrieved documents, then decides: “Can we answer this?”</li><li>Great for complex scenarios where rejection quality matters.</li><li><strong>Cons:</strong> Expensive inference.</li></ul><h3>3. Binary Classifier (ML/DL)</h3><p>💬 <em>Comment:</em> A very niche approach — I’ve rarely seen it used in production. Intuitively, the quality tends to be low.</p><ul><li>A dedicated model (e.g., logistic regression, XGBoost, neural net) predicts <em>reject / accept</em> based on features like similarity score, text length, number of keyword matches, etc.</li><li><strong>Cons:</strong> Requires a labeled dataset.</li></ul><h3>Why Use Rejectors?</h3><ul><li>✅ <strong>Improves trust:</strong> It’s better to honestly say “I don’t know” than to hallucinate an answer.</li><li>✅ <strong>Reduces LLM load:</strong> Don’t waste compute if the knowledge base has no relevant content.</li><li>✅ <strong>Enables flexible fallback logic:</strong> For example, route the query to a human operator or trigger a different pipeline.</li></ul><p>In the end, a well-designed RAG pipeline typically has <strong>three quality control points</strong>:</p><ol><li><strong>Retriever</strong> — retrieves candidate documents.</li><li><strong>Reranker</strong> — sorts them by relevance.</li><li><strong>Rejector</strong> — decides whether there’s enough information to generate a valid answer.</li></ol><h3>Part 4 — Real-World Numbers</h3><p>In the attached section, you’ll find the models we tested and the results of our benchmarks.</p><p>Let’s quickly revisit the datasets we used:</p><ol><li><strong>Dataset 1:</strong> Questions about internal documentation from support specialists who <em>don’t know the answers</em> to complex queries.</li><li><strong>Dataset 2:</strong> General customer support questions — used to improve automation.</li></ol><p>We evaluated the models using standard <strong>RAGAS</strong> metrics (they have excellent documentation — you can read more here: <a href="https://docs.ragas.io/en/latest/concepts/metrics/available_metrics/#retrieval-augmented-generation">RAGAS Metrics</a>).</p><h3>Results &amp; Takeaways</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ju3c_jNqPiSHd-TaT1jgew.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iBzMRZDKSK0wwJtGpJl4_A.jpeg" /></figure><p>Unfortunately, there’s <strong>no single “best” universal reranker model</strong> — honestly. 😅<br> However, based on our research, we recommend deploying <strong>two models</strong>:</p><ul><li>BAAI/bge-reranker-v2-minicpm-layerwise</li><li>jinaai/jina-reranker-v2-base-multilingual</li></ul><p><strong>Results summary:</strong></p><ul><li>jina performed exceptionally well in terms of <strong>speed</strong> and <strong>correctness</strong>.</li><li>minicpm-layerwise achieved higher <strong>retrieval_relevance</strong> and <strong>context_recall</strong>.</li><li>Both were among the <strong>fastest</strong> models we tested in terms of runtime.</li></ul><p>✅ <strong>Final Thoughts:</strong><br> Reranking and rejection are often overlooked stages in a RAG pipeline — but they’re crucial for building reliable, production-grade retrieval-augmented systems. A strong retriever is only the first step. To truly improve answer quality, you need a reranker to sort the context and a rejector to decide <em>whether</em> you should answer at all.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=621ce168be83" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Paraphrasing in the RAG Pipeline ⚙️]]></title>
            <link>https://medium.com/@annakokovina21/paraphrasing-in-the-rag-pipeline-%EF%B8%8F-a97a444241f0?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/a97a444241f0</guid>
            <category><![CDATA[rags]]></category>
            <category><![CDATA[paraphrasing-tool]]></category>
            <category><![CDATA[llm]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Fri, 12 Sep 2025 12:51:55 GMT</pubDate>
            <atom:updated>2025-09-12T12:51:55.324Z</atom:updated>
            <content:encoded><![CDATA[<p>Everyone loves the “naive RAG.”<br>It works great in theory — but in practice, it often stumbles over the way people actually phrase their questions.</p><p>In this series, I’ll show how to fix that. Let’s start with the most common custom piece of a production RAG pipeline: <strong>paraphrasing</strong>.</p><h3>Why retrieval alone isn’t enough 🤔</h3><p>RAG lives or dies by retrieval quality.</p><p>If a user’s query doesn’t align with the wording in your knowledge base — because of synonyms, phrasing differences, or grammar quirks — you’ll often get poor or even empty results.</p><p>Example:</p><pre>Query: &quot;Vacation?&quot;<br>DB:    &quot;How to take additional paid leave&quot;</pre><p>Without paraphrasing, the system may completely miss that these are the same intent.</p><h3>What is paraphrasing (and why bother)?</h3><p><strong>Paraphrasing</strong> = generating multiple alternative versions of a query while keeping the meaning intact.</p><p>🎯 Its role in RAG:</p><ul><li>Boost <strong>recall</strong> → more ways to match relevant docs.</li><li>Improve <strong>robustness</strong> → less sensitive to how users phrase things.</li><li>Reduce <strong>zero hits</strong> → even if one query fails, another may succeed.</li></ul><h3>Where it fits in the pipeline ⚙️</h3><ol><li><strong>Generate paraphrases</strong></li></ol><ul><li>LLMs (multiple variations per query).</li><li>Specialized models like T5 or mBART.</li></ul><p><strong>2. Run parallel retrievals</strong></p><ul><li>One search per paraphrase.</li><li>Merge + re-rank results.</li></ul><p><strong>3. Filter &amp; normalize</strong></p><ul><li>Drop duplicates and weak matches.</li><li>(Optional) use a reranker, e.g. cross-encoder.</li></ul><p><strong>4. Feed the generator</strong></p><ul><li>Pass the top-ranked docs across all paraphrased queries.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/470/1*dG64POGipTyOA2S6nO3AMQ.png" /></figure><h3>Common paraphrasing strategies 🛠️</h3><ul><li><strong>Structured outputs</strong> → control model outputs via prompting or DSLs.</li><li><strong>HyDE (Hypothetical Document Embeddings)</strong> → generate a “fake answer,” embed it, and use it as the query for semantic search.</li></ul><h3>Dont do quick experiment 🐱🦆</h3><p>At <strong>RAG Platform</strong>, we compared two approaches — starting small, with kittens and ducklings.</p><p>Dataset:</p><ul><li><strong>TREC Conversational Assistance Track (CAsT) 2022</strong> → multi-turn QA dialogues.</li><li>Stored in <strong>Qdrant</strong> with:<br>provenance (for answer validation).<br>text (QA pairs with embeddings).</li></ul><p>Setup:</p><ul><li><strong>Embedding model:</strong> multilingual-e5-large (solid open-source baseline).</li><li><strong>Paraphrasing model:</strong> gpt-4o-mini (cheap + simple).</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*T1seoTBhU50OXGvyErNjzw.png" /></figure><h3>Results 📉</h3><p>Surprisingly, in our “perfect vacuum” test, <strong>HyDE</strong> didn’t beat the baseline.<br> In fact, it slightly <strong>decreased performance</strong> compared to plain RAG (no paraphrasing).</p><p>Next time, we’ll dig deeper into strategies — and share more practical setups. Stay tuned 😉</p><h4>Advanced Paraphrasing Strategies in the RAG Pipeline 🎯</h4><p>Simple paraphrasing is great.<br>But let’s go deeper — not just testing on some random dataset from outer space 🚀, but on the <strong>real queries of your stakeholders</strong>.</p><p>That’s where the real value is. After all, we want to <em>improve our system for end users</em>, not just add a pipeline block that looks good on synthetic benchmarks.</p><p>Before diving into practice, let’s review the <strong>main prompting strategies for paraphrasing</strong>.</p><h4>Paraphrasing strategies with prompting 🧩</h4><h4>1. Original (baseline)</h4><p>The user’s raw query is sent directly into the pipeline.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/812/1*8whzuhIztYvgp5knBzRaWg.png" /></figure><h4>2. Paraphrase</h4><p>Generate <strong>3 paraphrases</strong> from the original query.</p><ul><li>Run retrieval for each paraphrase in the vector DB.</li><li>Collect <strong>unique chunks</strong> across all results.</li><li>Sort them by score → take the <strong>top_k</strong>.</li><li>Pass these, along with the original query, into the LLM.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TasSbFVSfbAHrsiESYJo2g.png" /></figure><blockquote>You are an expert in query expansion and natural language processing.<br>Your task is to generate an optimized search query based on the user’s input query.<br>Follow these guidelines:</blockquote><blockquote>1. Analyze the input query for key concepts and intent.<br>2. Identify any ambiguous terms or phrases that could be clarified.<br>3. Consider common synonyms, related terms, and alternative phrasings to improve the search.<br>4. If applicable, expand acronyms or abbreviations.<br>5. Incorporate any relevant context or domain-specific knowledge.<br>6. Ensure the expanded query maintains the original intent of the user’s question.<br>7. Prioritize clarity and specificity in the rewritten query.<br>8. If the original query is already optimal, you may return it unchanged.</blockquote><blockquote>[Structured Output Format]<br> Return 3 options.<br> Return the output in the following JSON format:<br>{<br> “expanded_queries”: [<br> “First optimized query…”,<br> “Second optimized query…”,<br> “Third optimized query…”<br> ]<br>}<br>[Constraints]<br>Do not return keyword lists — only full natural language sentences or questions.<br>Each query variant should be unique but still faithful to the original intent.<br>Do not include any commentary or explanation — only return the JSON object as output.</blockquote><h4>3. Paraphrase-v2</h4><ul><li>Generate <strong>2 paraphrases</strong> from the original query.</li><li>Retrieve chunks for the <strong>original + both paraphrases</strong>.</li><li>Merge paraphrase chunks → select the <strong>top 5</strong>.</li><li>Combine them with the <strong>top_k original chunks</strong>.</li><li>Send the merged set to the LLM.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PU8ZmffN8oKYQCZqNpsS7Q.png" /></figure><h4>4. Stepback</h4><ul><li>Reformulate the query into a <strong>more general or intermediate question</strong>.</li><li>Retrieve results for the stepback query.</li><li>Mix those results with chunks from the original query.</li><li>Pass everything together to the LLM.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/854/1*nr1Py08BpD0aASQHrYv2Tw.png" /></figure><blockquote>You are an expert at generating step-back questions that help retrieve relevant information.</blockquote><blockquote>Your task is to take a specific user query and generate a broader, more general “step-back” question that will help find background information and context that might be useful for answering the original question.</blockquote><blockquote>Follow these guidelines:<br>1. Identify the specific topic or domain of the original query<br>2. Think about what broader concepts or background knowledge would be helpful<br>3. Generate a more general question that captures the fundamental concepts<br>4. The step-back question should be broader but still related to the original intent<br>5. Focus on foundational knowledge that would help understand the specific query</blockquote><blockquote>Examples:<br>- Original: “How do I configure OAuth2 with JWT tokens in Spring Boot?”<br> Step-back: “What are the key concepts and components of OAuth2 authentication?”</blockquote><blockquote>- Original: “Why is my Docker container running out of memory?”<br> Step-back: “How does memory management work in containerized applications?”</blockquote><blockquote>[Structured Output Format]<br>Return the output in the following JSON format:<br>{<br> “expanded_queries”: [<br> “Your step-back question here…”<br> ]<br>}</blockquote><blockquote>[Constraints]<br>- Generate only ONE step-back question in the array<br>- Make it broader and more general than the original<br>- Keep it as a natural language question<br>- Do not include any commentary or explanation — only return the JSON object</blockquote><h4>5. Query Decomposition</h4><ul><li>Break down a complex query into <strong>simpler sub-queries</strong>.</li><li>Retrieve relevant chunks for each.</li><li>Merge and consolidate results before passing to the LLM.</li></ul><p>👉 In the next part, we’ll share experiments with these strategies — not on synthetic datasets, but on <strong>stakeholder gold sets</strong> (real-world benchmarks from two of our core clients).</p><h4>Let’s move to practice</h4><p>As mentioned earlier, we tested not on synthetic datasets, but on <strong>gold sets from two of our key stakeholders</strong>.<br> The goal: deliver <em>real value</em> in our system — not just add a fancy pipeline block that only looks good on benchmarks.</p><h4>Metrics we used 📐</h4><p>We relied on standard <strong>RAGAS metrics</strong> (their docs are excellent — highly recommend reading: <a href="https://docs.ragas.io/en/latest/concepts/metrics/available_metrics/#retrieval-augmented-generation">RAGAS metrics guide</a>).</p><h4>Stakeholder datasets 🗂️</h4><p>We had two very different support scenarios:</p><p>1. Internal documentation support<br>Questions from support specialists who need answers from internal docs but don’t know them upfront.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mZt6ZHFFDnG0CbE1zKVelg.png" /></figure><p><strong>Results:</strong></p><ul><li><strong>Paraphrase-v2</strong> → best at context recall/precision.</li><li><strong>HyDE</strong> → lowest hallucination rate, but poor retrieval relevance.</li><li><strong>Stepback</strong> → best balance between context accuracy and relevance.</li></ul><p>2. External client support</p><p>Typical customer support queries, where automation is a priority.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IhR0X_pBv0LiGBETAJ_yrQ.png" /></figure><p><strong>Results:</strong></p><ul><li><strong>Stepback</strong> → top performer on overall relevance + stable faithfulness.</li><li><strong>Paraphrase-v2</strong> → leads in faithfulness and retrieval relevance.</li><li><strong>Query decomposition</strong> → weakest, struggling across all context-precision metrics.</li></ul><h4>Key takeaway 🔑</h4><p>No single paraphrasing strategy works well across <em>all</em> types of data.</p><ul><li>If you’re building <strong>a local solution</strong>, you can tailor a fixed strategy.</li><li>But in a general-purpose RAG platform, you need:</li><li>tools to measure performance per strategy,</li><li>the ability to switch/manipulate strategies via prompting,</li><li>or even <strong>dynamically select strategies</strong> at runtime.</li></ul><p>👉 Just picking “one strategy that’s OK everywhere” doesn’t work well — same story as with rerankers.</p><p>A practical idea (borrowed from the X5 team):<br> <strong>Use a classifier at the pipeline entry</strong> → decide whether the query needs paraphrasing, and only run paraphrase on complex cases.</p><h4>Models for Paraphrasing in the RAG Pipeline 🧠</h4><p>Alright, now the big question: <strong>which models should we use to generate paraphrases?</strong></p><h4>Which models did we test? 🔍</h4><p>We focused mostly on <strong>open-source</strong>, but one closed-release model slipped in: t-pro-it-1-2-fp8.<br> (It’s not available publicly.)</p><p>Fair note: our list is missing <strong>Llama-2–7b</strong>, which I suspect would perform well — fast, strong, and small enough to be practical. The only caveat: <strong>structured output</strong> isn’t officially supported, so it may or may not work.</p><p>Here’s the lineup we tested:</p><ul><li>t-pro-it-1-2-fp8</li><li>qwen25-coder-32b-instruct</li><li>t-pro-it-2-0-fp8</li><li>gemma-3-27b-it</li><li>t-pro-it-1-0</li><li>t-lite-it-1-0</li></ul><p>💡 If you have budget to burn, you can always go with <strong>closed models</strong> (OpenAI, Anthropic, etc.).</p><h3>Evaluation factors ⚖️</h3><p>We looked at three main aspects:</p><ul><li><strong>Size / scalability</strong> → ideally ~7B with alignment. 32B can also work, but bigger size means higher serving costs (inference isn’t free, even in-house).</li><li><strong>Speed</strong> → critical for RAG pipelines, since most latency comes from LLM calls. Faster models = smoother pipeline.</li><li><strong>Performance in our use case</strong> → relevance and robustness of generated paraphrases.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1019/1*oI2ZIPWYuX5pWEvvucbElA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1019/1*5oi03ZoGuaRrRNNSe-zajQ.png" /></figure><h4>The winner 🏆</h4><p>Our best performer was <strong>t-pro-it-1-2-fp8</strong> — likely because it’s well-aligned for Russian and domain-specific phrasing.</p><h4>My personal take 👀</h4><p>The <strong>ideal paraphrasing model</strong> (for me) would be:</p><ul><li>an open-source <strong>7B model</strong>,</li><li>aligned specifically for <strong>paraphrasing + structured output</strong>,</li><li>small enough for fast inference and <strong>cheap scaling on A20 GPUs</strong>.</li></ul><p>⚠️ And don’t be alarmed by the 0 results for t-lite-it-1-0 — it simply doesn’t support structured outputs.</p><p>Вот итоговый блок статьи на английском — в стиле Medium, чтобы выглядело как завершение серии:</p><h4>Wrapping Up: Paraphrasing in the RAG Pipeline 💅</h4><p>So, what did we learn?</p><ul><li>✅ <strong>Paraphrasing is a powerful way to customize and clean up user input</strong> before retrieval.</li><li>✅ In production, at scale, you can optimize with a <strong>classifier</strong> that decides whether paraphrasing is needed — since real users write queries in very different ways.</li><li>✅ It’s easy to experiment: strategies can be swapped with prompting, which works much better in practice than hypothetical embeddings.</li><li>✅ The <em>best strategy</em> depends on the specific use case — there’s no universal winner.</li><li>✅ For the paraphrasing model itself, even a relatively small model is enough. In MVP setups, a <strong>32B model with solid structured output</strong> performs very well.</li></ul><p>🙏 Huge thanks to the <strong>LLMP team ❤️</strong> — this research wouldn’t have been possible without them.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a97a444241f0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From PoC to Production: The AI Platform Playbook for 2025]]></title>
            <link>https://medium.com/@annakokovina21/from-poc-to-production-the-ai-platform-playbook-for-2025-6de9c7392932?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/6de9c7392932</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[b2b]]></category>
            <category><![CDATA[platform]]></category>
            <category><![CDATA[llm]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Wed, 13 Aug 2025 17:41:32 GMT</pubDate>
            <atom:updated>2025-08-13T17:41:32.106Z</atom:updated>
            <content:encoded><![CDATA[<h3>About the B2B AI Platform Market</h3><p>By 2025, generative AI has moved beyond being a mere experiment or a deep-venture investment — it has become a mandatory element in digital transformation strategies.<br> According to McKinsey, over 65% of companies are already deploying LLM-based solutions, and Deloitte reports double-digit ROI growth among those that have brought projects into production.<br> However, behind these headline success stories lies another statistic: up to 70% of PoCs never scale due to lack of expertise, weak tooling, and the absence of a “bridge” between hypothesis testing and industrial deployment.</p><p>The market for agent platforms and RAG (retrieval-augmented generation) systems is growing explosively: Global Market Insights and MarketsandMarkets both estimate a CAGR of 35–40%, with the segment projected to reach tens of billions of dollars by the 2030s. The key question is no longer <em>“Should we integrate an LLM?”</em> but rather <em>“How do we create a safe, observable, and scalable environment where the team can go from idea to production without losses at every stage?”</em></p><h3>Demand and Market Needs</h3><p>Product teams everywhere are tasked with “embedding AI features into services” — as part of strategies for increasing efficiency, reducing costs, and creating new products. Enterprises and SMBs are actively experimenting with LLM features (assistants, text auto-generation, case analysis, routine process automation), but scaling remains hard due to the lack of processes, tools, and expertise.</p><p>Industry reports show that generative AI adoption surged in 2024–2025, with companies reporting increased benefits — but also significant operational costs and security risks.<br> Key technology patterns today are <strong>RAG</strong> and <strong>agent orchestration</strong> (multi-tool calling / agents). RAG quickly became the standard for production applications, and the agent solutions market is showing high growth with multi-billion-dollar forecasts. This changes the platform requirements: it’s not enough to “hook up an LLM” — integration, observability, and security must be guaranteed.</p><h3>Main Concerns</h3><p><strong>Misunderstanding LLM limitations and application types.</strong> Many users are misled by the idea that “LLM = solves everything.” They don’t distinguish between scenarios where one prompt is enough, and where RAG, integrations, or human validation are required.</p><p><strong>Lack of technical resources for quick hypothesis testing or missing expertise</strong> (data/ML/infra) in product teams; experiments often stall until a formal PoC process is available. Research and case studies point to insufficient upskilling and the need for corporate training programs.</p><p><strong>Misguided stakeholder requests.</strong> Examples: “Give me RAG — I’ll summarize requests there,” or “We gave the LLM our business description and asked it to detect fraud” — signs of pseudo-expertise and poorly defined tasks.</p><p><strong>Security risks.</strong> Context leaks, uncontrolled external calls, lack of auditing and explainability. Surveys show that data security remains a top concern for executives.</p><p><strong>No “path-to-product” funnel.</strong> Platforms are often built for advanced developers, leaving beginners without an easy path from hypothesis testing to value validation.</p><h3>Stakeholder Segmentation &amp; Typical Requests</h3><p><strong>“No expertise — just testing”<br><em>Profile</em></strong><em>:</em> Employees, assistants, small teams looking to automate daily tasks.<br><strong><em>Request:</em></strong> “AI in plain English,” fast onboarding, ready integrations and templates, low entry barrier, minimal settings, clear scenarios. Customization not a priority.</p><p><strong>“Partial expertise — testing a hypothesis”<br><em>Profile:</em> </strong>Product managers, analysts, early-stage R&amp;D teams.<br><strong><em>Request:</em> </strong>Customization options, case-specific cookbooks/guides, pipeline visualization (low-code / n8n-like UX), basic quality control (Eval libraries, metrics).</p><p><strong>“Full expertise — going into production”<br><em>Profile:</em></strong> ML teams, engineering departments with proven business value.<br><strong><em>Request:</em></strong> Advanced tools — observability, tracing, fine-grained customization, independent model serving, A/B testing, CI/CD integration. Minimal “magic,” maximum control.</p><blockquote><strong>Key takeaway:</strong> Platforms are often targeted at segment 3, but to scale AI adoption inside a company, there must be a funnel from simple use cases to mature production solutions — enabling a smooth transition between segments (on-ramp → grow → scale).</blockquote><h3>Adoption Funnel: On-ramp → Grow → Scale</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t7pHVuhe7RTAc0afUljr6w.png" /></figure><h3>Mapping Needs to Tools</h3><ul><li><strong>One-prompt, markup, simple automation</strong> → Prompt playground, prompt registry, prompt testing, ready metric library.</li><li><strong>AI assistant (interactive, tool-calling, memory)</strong> → Toolset, MCP (company and external services), Assistants API, session manager, RAG, dialogue evaluation. API integration, session control, and security are crucial.</li><li><strong>RAG / knowledge-driven scenarios</strong> → RAG / vector DB, document ingestion pipelines, retriever tuning, context management. Often comes as a standalone request (“build RAG on our data”).</li></ul><h3>Market Trends &amp; Key Figures</h3><ul><li><strong>RAG</strong> is now a mainstream pattern in production LLM scenarios.</li><li><strong>Agentic AI</strong> market valued at ~$6–7B in 2024, projected to reach tens of billions by 2030+.</li><li><strong>RAG-specific market</strong> expected to grow at ~40–50% CAGR in coming years.</li><li><strong>Low-code/no-code</strong> remains a vital onboarding channel for non-technical users — valued in the tens of billions with double-digit annual growth.</li></ul><h3>So You’ve Decided to Build Your Own AI Platform — Key Focus Areas</h3><ol><li>Provide an <strong>on-ramp</strong> for segment #1 — ready-made automation templates, UI playground, “AI in plain English.”</li><li>Support segment 2 with cookbooks and low-code pipelines (visual design, RAG/assistant examples).</li><li>Maintain focus on segment #3 — observability, verifiability, custom deploys, CI/CD integrations.</li><li>Integrate Eval and prompt management as baseline features.</li><li>Build in compliance &amp; security (RBAC, audit logs, data redaction, sandbox for external calls).</li><li>Measure progress as a <strong>funnel</strong> — track PoC→pilot→production conversion, average time and cost of hypothesis validation.</li></ol><h3>Principles for Building Such a Platform</h3><p><strong>Unified identity and access management<br>- </strong>Single sign-on across tools.<br>- Policy-based access control to data and tools with auditing.</p><p><strong>Fast, affordable access to LLM providers<br>- </strong>Ability to test new models without lengthy approvals.<br>- Secure on-prem defaults.<br>- Hypothesis testing within fixed token limits (e.g., 10M tokens/month). Smooth scaling to dedicated serving.</p><p><strong>Prompt management as a first-class entity<br>- </strong>Central registry with versioning and storage.<br>- Automatic baseline generation and prompt optimization per model.<br>- Prompt/model version comparison, test dataset generation.<br>- Auto-selection of optimal model for a request.</p><p><strong>AI assistant support<br>- </strong>Prompt libraries and base tools.<br>- Custom tool connection via UI.<br>- Long-term user memory setup.<br>- End-to-end and online evaluation via traces.</p><p><strong>Built-in RAG platform layer<br>- </strong>Indexed corporate sources with versioning.<br>- Support for documents, tables, and code.<br>- Transparent answers with cited sources.<br>- Dataset generation and metric collection from traces.</p><p><strong>Unified Assistants layer as the integration hub<br>- </strong>Each tool, agent, or RAG pipeline is an agent domain.<br>- Standardized invocation, session, and memory management.<br>- Single “agent layer” for all LLM tools.</p><p><strong>Quality &amp; observability<br>- </strong>Metrics at model, prompt, agent, and pipeline levels.<br>- Benchmarks and critical function datasets built from real traces/domains.<br>- Alerts and model degradation detection.<br>- Online evaluation using real user traces.</p><h3><strong>What about ready-made solutions?</strong></h3><p>Everyone knows the giants: Azure, Google AI Studio, Yandex Cloud AI Studio. But what about smaller projects — what do their evaluations and capabilities look like? I’ve put together a selection of different projects that, in my opinion, provides a decent reflection of the market situation beyond the giants.</p><p>It’s important to note here that by “agent” I mean an LLM agent with tool calling, and by “assistant” — a one-prompt setup with memory/history.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_SYJ4V846OHxfp-BHKaq7w.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zRj9ABFXU1G5MGFGsA_LBg.png" /></figure><h3>From what I can sense about what’s happening in Russia right now</h3><p>More or less, large businesses — and especially big tech — are building their own solutions. The events of recent years have hit hard for companies that relied on foreign vendors. For large businesses, it’s also simply easier to recoup investments at scale, since the Russian market doesn’t really have a proven commodity-level agent platform solution. Integrating open-source often turns out to be more expensive in the end. By the way, here’s my article on when it’s worth choosing open-source and when to develop your own solution: <a href="https://medium.com/@annakokovina21/when-to-use-open-source-and-when-to-build-your-own-5cc0d53c2327">link</a>. That said, big tech doesn’t shy away from buying small startups that create solid local solutions — especially if they can be deployed within a company’s secure perimeter.</p><p>Small and medium-sized businesses are split into two camps:</p><ul><li>Those who build their business from the ground up on AI — for example, a one-prompt service for writing resumes.</li><li>Those operating in the physical world — beauty salons, gas stations, etc.</li></ul><p>The first group usually develops their own solutions and has small but strong technical teams.<br> The second group doesn’t yet have a direct need for agents. They are beginner users, impressed by one-prompt and RAG solutions. Most likely, in a few years they will grow into a demand for agents.</p><p>There’s also a special segment in Russia: resource-extraction and government enterprises. These players are desperately trying to implement AI, but from my conversations with their representatives, it’s clear that AI rarely gets beyond pitch decks and strategies. With such companies, you need to start small and be especially careful during implementation.</p><p>Thanks for reading the article to the end)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6de9c7392932" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Review of Open Source Solutions for Visual Agent Pipelines and LLM Flow Editors in the Enterprise…]]></title>
            <link>https://medium.com/@annakokovina21/review-of-open-source-solutions-for-visual-agent-pipelines-and-llm-flow-editors-in-the-enterprise-5d20f10d695c?source=rss-cc0174df7b03------2</link>
            <guid isPermaLink="false">https://medium.com/p/5d20f10d695c</guid>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[llm-applications]]></category>
            <category><![CDATA[enterprise-technology]]></category>
            <dc:creator><![CDATA[Annakokovina]]></dc:creator>
            <pubDate>Sun, 29 Jun 2025 17:39:58 GMT</pubDate>
            <atom:updated>2025-06-29T17:39:58.866Z</atom:updated>
            <content:encoded><![CDATA[<h3>Review of Open Source Solutions for Visual Agent Pipelines and LLM Flow Editors in the Enterprise 🤖</h3><p>Today I’d like to share an overview of open source solutions for building visual editors for agent pipelines and LLM flows — from the perspective of enterprise integration.</p><p>This post is a natural follow-up to my earlier article on <em>“Build vs Open Source: When to Write Your Own and When to Reuse”</em>. If you haven’t read it yet — now’s the perfect time:<br> 🔗 <a href="https://medium.com/@annakokovina21/when-to-use-open-source-and-when-to-build-your-own-5cc0d53c2327">https://medium.com/@annakokovina21/when-to-use-open-source-and-when-to-build-your-own-5cc0d53c2327</a></p><h3>Part 1 — The Basics</h3><p>Let’s begin by clarifying a few key concepts:</p><p>🔩 <strong>LLM Flow</strong> refers to an architecture where an LLM interacts with external data sources, tools, and memory in a step-by-step, controlled workflow.<br> These flows typically consist of sequential blocks such as:</p><ul><li>Prompt → Response interactions</li><li>External API calls (to a database, CRM, search engine, etc.)</li><li>Control logic (conditions, loops, filters)</li></ul><p>⚙️ <strong>Agent Pipeline</strong> refers to an architecture where the LLM acts as an intelligent agent that autonomously makes decisions and takes actions based on:</p><ul><li>Instructions (goal definition)</li><li>Access to tools and APIs</li><li>Memory or history</li><li>Planning and reasoning mechanisms</li></ul><p>🧠 <strong>How does an agent actually work?</strong></p><ul><li>Receives a goal (e.g., “Find a hotel in Paris and book it”)</li><li>Plans the steps (analyze → search → filter → book)</li><li>Uses external tools/APIs to complete each step</li><li>Adapts its behavior during execution (error handling, clarifications)</li></ul><p>🔧 <strong>What does a typical agent system include?</strong></p><ul><li>LLM: the “brain” making decisions</li><li>Tools: APIs, DBs, web services</li><li>Memory: historical context or conversation logs</li><li>Prompt/Goal: the objective to achieve</li><li>Planner/Executor: logic for choosing the next action (manual or automatic)</li></ul><p><strong>Goal:</strong> Find an open source solution that’s easy to integrate with enterprise authentication systems, scalable to a large user base, and capable of supporting at least basic LLM flows — ideally multi-agent systems.</p><h3>Part 2 — Solutions That Didn’t Quite Fit 📚</h3><p>I reviewed 9 open source tools and started by analyzing those that didn’t fully meet our needs. Here’s a summary of each, along with enterprise integration “green” and “red” flags.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ait0LII61L26HCubPnZAHw.png" /></figure><h4>Node-RED</h4><p>✅ Strong community (17k+ stars)<br> ✅ Lots of nodes (especially IoT)<br> ✅ Simple architecture, on-prem<br> 🚩 Limited scalability<br> 🚩 Weak auth support<br> 🚩 Not designed for enterprise embedding<br> 🚩 Focused on IoT</p><h4>Huginn</h4><p>✅ MIT License<br> ✅ Self-hosted agent workflows<br> 🚩 No external auth support<br> 🚩 Not embeddable<br> 🚩 Poor UX/UI</p><h4>Budibase</h4><p>✅ Low-code UI<br> ✅ Custom auth (SSO, OAuth2)<br> ✅ On-prem/Cloud<br> 🚩 OSS version limited to 20 users<br> 🚩 Enterprise features are paid only</p><h4>Automatisch</h4><p>✅ Simple, Zapier-like<br> ✅ Open source, on-prem<br> 🚩 Weak enterprise auth<br> 🚩 Not scalable<br> 🚩 Not built for AI agents</p><h4>Temporal</h4><p>✅ Highly scalable<br> ✅ Multi-language SDK<br> ✅ Ideal for microservices<br> ✅ On-prem/Cloud<br> 🚩 No visual editor<br> 🚩 Requires DevOps skills</p><h3>Part 3 — The Strong Contenders 📚</h3><p>Let’s look closer at the most promising finalists.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*G6rhtDY96mueSb60uVA1fQ.png" /></figure><h4>Langflow 🎪</h4><ul><li>Focused on building LLM and agent pipelines</li><li>Integrates with LangChain and other AI tools</li><li>Great for rapid prototyping</li><li>Easy to extend but still maturing</li></ul><p><strong>License:</strong> MIT<br> <strong>GitHub Stars:</strong> 5k<br> <strong>Auth:</strong> Custom (FastAPI/LangChain), no built-in SSO<br> <strong>Hosting:</strong> On-prem<br> <strong>UI/UX:</strong> Visual editor, requires LangChain knowledge<br> <strong>Scalability:</strong> Docker-based, but poor docs for horizontal scaling, lacks built-in monitoring</p><h4>n8n 🦄</h4><ul><li>Flexible visual editor for complex AI workflows</li><li>Active community and plugin ecosystem</li></ul><p><strong>License:</strong> Now under BSL (not OSS-compliant for embedded/SaaS use)<br> <strong>GitHub Stars:</strong> 100k+<br> <strong>Auth:</strong> Basic in OSS, full SSO/RBAC in paid Enterprise edition<br> <strong>Hosting:</strong> On-prem/Cloud<br> <strong>UI/UX:</strong> Drag-and-drop; no simple embedding (requires forking for UI customization)<br> <strong>Scalability:</strong> Docker, Redis-based scaling, manual CI/CD and monitoring setup</p><h4>Appsmith 🐙</h4><ul><li>Ideal for building AI dashboards and internal tools</li><li>Not focused on LLM/agent pipelines</li></ul><p><strong>License:</strong> Apache 2.0<br> <strong>GitHub Stars:</strong> 30k+<br> <strong>Auth:</strong> Supports custom auth, OAuth2, Google, OIDC<br> <strong>UI/UX:</strong> UI editor, but lacks true flow-based editing<br> <strong>Scalability:</strong> Enterprise-ready, horizontal scaling, CI/CD support</p><h4>Flowise AI 🦞</h4><ul><li>Designed for multi-agent orchestration with drag-and-drop LLM flows</li></ul><p><strong>License:</strong> Apache 2.0<br> <strong>GitHub Stars:</strong> 39k+<br> <strong>Auth:</strong> Role-based access, workspace isolation, API tokens, custom middleware<br> <strong>Hosting:</strong> Docker, Kubernetes-ready<br> <strong>UI/UX:</strong> Drag-and-drop with support for agents, tools, vector stores, etc.<br> <strong>Scalability:</strong> Microservice-based, supports LangChain, OpenAI, Chroma, HuggingFace</p><h4>Windmill 🍄</h4><ul><li>Great as a backend automation engine</li><li>Higher technical barrier</li></ul><p><strong>License:</strong> MIT<br> <strong>GitHub Stars:</strong> 30k+<br> <strong>Auth:</strong> OpenID, OAuth2, SSO, RBAC<br> <strong>Hosting:</strong> Docker, Kubernetes<br> <strong>UI/UX:</strong> Hybrid of code and visual; mostly script-driven<br> <strong>Scalability:</strong> Well-documented Docker/Helm deployments, CI/CD ready</p><h3>Part 4 — Conclusions 🥰</h3><p><strong>Goal Recap:</strong> We’re looking for an open source solution with enterprise auth support, scalable architecture, and a visual editor for at least LLM flows — ideally multi-agent orchestration.</p><p>✅ <strong>Most Promising: </strong><strong>n8n and </strong><strong>Flowise AI</strong><br> Both are architecturally similar (Redis-based), support visual flows, and allow agent-like behavior.</p><ul><li>n8n is mature and widely known, but has serious <strong>licensing issues</strong> for production use (especially for embedding or SaaS).</li><li>Flowise AI is newer and less battle-tested, but very promising. If it can be extended with custom auth easily — it may become a strong alternative.</li></ul><h3>Finalists at a Glance</h3><h4>n8n</h4><p><strong>Green Flags:</strong><br> ✅ Flexible visual editor<br> ✅ AI agent support<br> ✅ Extensible via plugins/API<br> ✅ On-prem/Cloud</p><p><strong>Red Flags:</strong><br> 🚩 BSL license as of 2024 — no embedding/SaaS without commercial license<br> 🚩 No white-label/embed UI out of the box<br> 🚩 Enterprise features (SSO, RBAC) are paid<br> 🚩 Requires manual CI/CD, monitoring</p><h4>Flowise AI</h4><p><strong>Green Flags:</strong><br> ✅ Apache 2.0 license<br> ✅ LangChain/Hugging Face support<br> ✅ Drag-and-drop LLM pipelines<br> ✅ Role-based access and team collaboration<br> ✅ Kubernetes-ready</p><p><strong>Red Flags:</strong><br> 🚩 Young platform, still evolving<br> 🚩 No built-in enterprise auth<br> 🚩 Requires UI/UX customization</p><h4>Appsmith</h4><p><strong>Green Flags:</strong><br> ✅ Apache 2.0<br> ✅ Enterprise-friendly<br> ✅ OAuth2/OIDC supported<br> ✅ AI integrations<br> ✅ On-prem/Cloud</p><p><strong>Red Flags:</strong><br> 🚩 No visual flow editor<br> 🚩 More focused on dashboards than LLM flows</p><h4>Windmill</h4><p><strong>Green Flags:</strong><br> ✅ MIT license<br> ✅ SSO, RBAC<br> ✅ Strong backend engine<br> ✅ CI/CD, on-prem/cloud</p><p><strong>Red Flags:</strong><br> 🚩 Requires technical knowledge (code + visual)<br> 🚩 Not fully no-code</p><h4>Langflow</h4><p><strong>Green Flags:</strong><br> ✅ MIT license<br> ✅ Visual editor for LLM pipelines<br> ✅ Good for quick prototyping</p><p><strong>Red Flags:</strong><br> 🚩 Weak documentation<br> 🚩 No built-in auth<br> 🚩 Limited scalability — requires custom setup</p><p>Thanks for reading till the end! ❤️<br> If you’re evaluating tools in this space or have experience with any of the above — I’d love to hear your thoughts.</p><p>#opensource #LLM #AIagents #enterpriseAI #n8n #flowise #langflow #nocode #automation #AIengineering</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5d20f10d695c" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>