<?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 Gil Avraham on Medium]]></title>
        <description><![CDATA[Stories by Gil Avraham on Medium]]></description>
        <link>https://medium.com/@squarenumbers?source=rss-cf715314fe0d------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*-oH49H_EBTCFjsKM1OOSdg.png</url>
            <title>Stories by Gil Avraham on Medium</title>
            <link>https://medium.com/@squarenumbers?source=rss-cf715314fe0d------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 22:56:30 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@squarenumbers/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 Would You Test This? The Question That Decides the Design]]></title>
            <link>https://blog.stackademic.com/design-for-testability-is-not-for-testers-cc4bf7d304a6?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/cc4bf7d304a6</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <category><![CDATA[software-testing]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Wed, 02 Dec 2026 13:30:32 GMT</pubDate>
            <atom:updated>2026-12-02T14:34:54.559Z</atom:updated>
            <content:encoded><![CDATA[<h3>Take the simplest endpoint you can imagine, one boolean, and watch what happens to the design when you ask how you would test it</h3><p>You have an endpoint that updates a boolean. <em>true</em> becomes <em>false</em>, <em>false</em> becomes <em>true</em>. One field. Nothing in your product is simpler.</p><pre>PATCH /features/{id}<br>{ &quot;state&quot;: false }<br><br>200 OK<br>{ &quot;state&quot;: false }</pre><p>The tests write themselves. Set it to <em>true</em>. Set it to <em>false</em>. Send the value it already has. Send <em>null</em>. Send something that is not a boolean. Check the status codes.</p><p>That list covers the inputs, passes review, and gets ticked off. It is also possible that one of those tests has never performed an update in its life, and nobody would ever find out.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v6T8Of9JxDeiGh78zdDwLA.png" /></figure><h3>A green test that has never once changed anything</h3><p>Your test sets the flag to <em>false</em> and asserts that the state is now <em>false</em>.</p><p>It never checked what the state was before.</p><p>If that record was already<em> </em><em>false</em>, the assertion passes, and you have proved nothing at all. The change from <em>true</em> to <em>false</em>, the actual behaviour you meant to cover, was never exercised. Run that suite for a year, and it stays green the whole time.</p><p>You now have a test named something like updates the flag to false which has never updated anything.</p><h3>A response is a claim, not evidence</h3><p>So you do something about it. The endpoint starts returning the new state. You send an update to <em>false</em>, the body says <em>false</em>, the test asserts on it and passes.</p><p>That feels like designing for testability. You gave the test something to check.</p><p>Look at what it is actually checking. The service has told you what it believes it did. Nothing in that response touches the database. If the write failed after the response was composed, or the transaction rolled back, or the value sat in memory and was never flushed, the body still says <em>false</em>.</p><p>It is the system under test reporting on itself, which is the one witness you cannot cross-examine.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KD9smGE7xzXv28FanChHNg.png" /></figure><h3>Return what changed, not what it is</h3><p>The fix is almost insultingly small. Send the previous value back alongside the new one.</p><pre>PATCH /features/{id}<br>{ &quot;state&quot;: false }<br><br>200 OK<br>{ &quot;state&quot;: false, &quot;previous&quot;: true }</pre><p>The response now describes an event instead of a state. A test can assert that something changed. A call that changed nothing shows up as a call that changed nothing, rather than hiding inside a response that looks like success.</p><p>Notice who else wanted that field. The engineer reading logs at three in the morning. The client cache deciding whether to invalidate. The consumer of your webhook, working out whether this was a real change or the same call arriving twice.</p><p>None of them is testers. All of them needed the same thing.</p><h3>A read tells you less than you think</h3><p>The obvious next step is a <em>GET</em>, so you can check the state before the update and again afterwards. It is worth having, because it reaches the data by a different path than the response did.</p><p>It is also not airtight. Another process can move the value between your two reads. If reads are served by a replica, a copy that has not caught up will tell you the write failed when it did not. The reverse is worse. Your test reads the primary, everything looks correct, and nobody notices that real users are served from the replica that lags.</p><p>The version of this that holds up is a revision number that moves on every write and comes back in both the write and the read. Then you stop asking whether the value looks right and start asking whether your write is the one that landed.</p><h3>The value says what. The timestamp says whether.</h3><p><strong>Add one more thing to the read</strong>. When this was last updated.</p><pre>GET /features/{id}<br><br>200 OK<br>{ &quot;state&quot;: false, &quot;updatedAt&quot;: &quot;2026-11-14T09:12:40Z&quot; }</pre><p>It costs a column and a line of code, and it separates two questions that look like one.</p><p>The value tells you what the state is. The timestamp tells you whether anything happened.</p><p>Almost every API answers only the first, which is exactly why a quiet failure is indistinguishable from a call that correctly changed nothing. Both leave the value sitting at <em>false</em>. With a timestamp there, the failed write stops hiding. The value is what you asked for, and the clock never moved.</p><p>That field is not a test aid either. It is what you read in production when a customer says their setting reverted, and it is how you find out how often the thing is really being changed, which nobody in the room currently knows.</p><h3>Past a certain point, nobody ever defined success</h3><p>Keep pulling, and the thread runs well past the shape of the payload.</p><p>Suppose saving this value is not one step. It writes to your database and then tells another service, because that service needs to know too. Suppose that second call fails.</p><p>Your success response is now a lie by construction. It was accurate about the part that completed and wrong about the operation as a whole.</p><p>The testability question is: how do I know this finished? That has no answer until somebody decides what finished means. Was the row written? The other service acknowledged? Is the change visible to the consumer about to act on it?</p><p>Most APIs have never answered that. Not out of carelessness. Nobody asked.</p><p>So the testability question forces a choice, and the API has to say which one it made. Either the operation is synchronous, and a success response means the whole thing is durable, which means the write and the downstream call succeed or fail together. Or it cannot be, and the API should stop answering as though it were, and return something the caller can check later instead.</p><p>An API that cannot tell you whether it finished has never decided whether it is synchronous. Most are accidentally asynchronous and still reply like they are not.</p><h3>The discipline arrives when you write the field, not the test</h3><p>This is the part I find most interesting.</p><p>To set a last updated value, a developer has to decide, on that line, what counts as the operation having happened. Before the downstream call or after it. On the attempt or on the confirmation. There is no way to write it without taking a position.</p><p><strong>So the field does not document the behaviour. It forces the behaviour to be defined.</strong></p><p>Nothing here was added to make testing easier. Testing was the lens. What came through it was a flow that reports its own failures, data your support team can use, and a definition of success that somebody finally wrote down.</p><h3>It will still lose the design review</h3><p>I will be honest about the catch, because pretending otherwise is how this gets waved away.</p><p>This argument loses, and it loses for a structural reason. The payoff is a class of problem you never knew you had. When someone asks what it bought you, there is nothing to point at, because the incident did not happen.</p><p>So do not oversell it. Nothing needs an audit trail on every boolean in the system. The discipline is in asking the question, not in always answering yes.</p><p>Ask whether a caller can tell these three apart. The value changed. The value was already that. The write failed quietly.</p><p>If they cannot, you have a gap, and you can decide on purpose whether to live with it. That is a two-minute conversation at design time. The alternative is having it with a customer.</p><p>To learn more: <a href="https://squarenumbers.co.uk/services/test-automation">https://squarenumbers.co.uk/services/test-automation</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cc4bf7d304a6" width="1" height="1" alt=""><hr><p><a href="https://blog.stackademic.com/design-for-testability-is-not-for-testers-cc4bf7d304a6">How Would You Test This? The Question That Decides the Design</a> was originally published in <a href="https://blog.stackademic.com/">Stackademic</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[AI Evaluation: Invest in Knowing When It Is Wrong, Not in Perfecting When It Is Right]]></title>
            <link>https://blog.stackademic.com/ai-evaluation-invest-in-knowing-when-it-is-wrong-not-in-perfecting-when-it-is-right-ebd7ace22ad0?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/ebd7ace22ad0</guid>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[ai-evaluation]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Fri, 20 Nov 2026 15:14:03 GMT</pubDate>
            <atom:updated>2026-12-02T14:37:22.230Z</atom:updated>
            <content:encoded><![CDATA[<h3>You cannot verify your own evaluator, trying harder makes it worse, and there is a third thing to do instead</h3><p>You build a system where AI works on data that keeps moving. Customers ask new things, your models get updated, your instructions get rewritten.</p><p>Then you build an evaluation to check that the AI is doing the job properly. An evaluation here usually means a judge, which is a model you ask to read an answer and score it. On the work I do, the judge returns a number from 0 to 100.</p><p>Now comes the question nobody has a good answer to. Is the evaluation right?</p><p>Accuracy in this world is not deterministic. There is no answer key. There is no single correct reply to a customer asking why their payment failed, so there is nothing to compare a string against and no way to prove your scoring is correct.</p><p>So you do the reasonable thing. You take a sample, you look at the scores, they seem sensible, and you freeze it. From that day it is your regression baseline, the thing every later run gets compared against.</p><p>What you have actually made is a recording. Nothing outside the system was ever consulted, so the only thing your baseline is anchored to is the system it is meant to be checking. Every fault your system had on the day you froze it is now the standard you test against.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v391XlnZTrFtI3lvmTS9XA.png" /><figcaption>Know When You AI Is Wrong</figcaption></figure><h3>The dangerous failure is the quiet one</h3><p>After a while, one of two things happens.</p><p>The first is that things start breaking and you cannot work out why. That is painful, and it is survivable, because at least you know.</p><p>The second is worse. Nothing appears to break. The answers look fine, and the scores look reasonable. Meanwhile, the provider updated the model underneath you, or your guardrails were wrong from the start, or the data in your set went stale and stopped resembling what customers now ask.</p><p>The suite still reports green. Green here means that your recording still matches what the system used to say, which stays true even when the system and the judge have both been wrong for a month.</p><h3>Perfecting the evaluation is the trap</h3><p>The instinct when the numbers look off is to improve the evaluation. Amend the instructions. Build a better golden set, meaning the examples you keep as your reference answers. Change the judge model.</p><p>That is overfitting, and not as a figure of speech. Your labelled examples are training data and your scoring prompt is the thing being trained. Fit it closely to this quarter’s traffic, and you have tuned it to a distribution that has already moved.</p><p>Worse, it recurses. Once you accept that the evaluator needs checking, you need something to check the evaluator with, and that thing needs checking too. Confidence never accumulates. It gets deferred one layer further out, and the cycle has no natural end.</p><p>And the expensive part is not the tokens. Perfecting an evaluation needs a person to decide what the right answer was, case by case, and to decide again every time the product changes. That is the one input you cannot buy more of, and it is the first thing to run out as you grow.</p><h3>What wrong actually means here</h3><p>Say your pass mark is 80. Two runs, same question, nothing changed in between.</p><p>Yesterday’s run scored 85, pass. Today’s run scored 79, fail.</p><p>The model was probably reasonable both times. For your purposes, it was wrong, because the same input produced two different verdicts, and something has to be fixed.</p><p>Now the harder case.</p><p>Yesterday’s run scored 100, pass. Today’s run scored 80, pass.</p><p>Nothing fires. Both runs pass. And obviously something is wrong.</p><p>Those are two different defects with two different owners. The first is a verdict flipping across the line you act on. The second never flips, so anything watching pass or fail is blind to it by design, and what you are seeing is movement.</p><p>Anyone who has worked in test automation already knows this shape. It is a flaky test, and a flaky test is a defect even when it is green, because its verdict is not evidence of anything. You quarantine it instead of retrying it. Retrying until green is misconduct.</p><p>So do not average your repeated scores into one number. Averaging is automatic retry wearing a suit. It converts a defect into a pass.</p><p>One caution, because this can be taken too far. Reproducibility is the first thing to fix, not the definition of quality. A judge that returns 85 for everything is perfectly consistent and completely useless, and chasing consistency alone rewards the wrong fixes, such as forcing the judge to be deterministic, caching its answers, or flattening the scale until nothing can move.</p><p>Narrowing 0 to 100 down to the bands your rubric can actually describe is a different thing, and that one is worth doing. A judge can also be perfectly repeatable while being repeatably wrong in the same direction, which is what the two production judges further down were doing.</p><h3>Some of this does not get solved</h3><p>You will always get false positives, where the evaluation flags an answer that was fine, and you will always miss things. The system is non-deterministic, which means the same input can produce a different output each time, and no amount of work removes that.</p><p>Your pass mark has the same problem. You chose a number before you knew what normal looked like, so treat it as a range instead, and measure that range on your own data by scoring the same items repeatedly and watching how far they move on their own. A limit set before you know the normal spread is a guess with a decimal point on it.</p><h3>What to build instead</h3><p>These are examples, not a template. They are the places worth checking, and you will add your own once you know what goes wrong in your own system.</p><h4><strong>Ask the same question several times and watch the spread.</strong></h4><p>Leave the judge’s randomness switched on, because forcing it to be deterministic hides the exact thing you are hunting. Store every score, never a per-item average, so a question you think of next month is still answerable about last month.</p><h4><strong>Treat unstable as a third outcome.</strong></h4><p>Not pass, not fail. If the repeated scores straddle the line you act on, that item is a decision you are taking by coin toss, and it is worse than an item that sits consistently below the mark. Quarantine it, which means it stops counting towards your pass rate until someone has looked at it. Rank by how close an item is to being an even split, weighted by how much traffic sits behind it.</p><h4><strong>Compare items to themselves, not to a standard.</strong></h4><p>You cannot check whether 85 was the right score, because no fact exists about what it should have been. You can check an answer you never touched that scored 85 in June and 78 today. Whatever the judge is biased about sits in both numbers, so it cancels and what is left is movement. That holds only while the judge itself is unchanged, so record its version with every score. Otherwise, the movement might be the judge.</p><h4><strong>Treat a changed question as a new question.</strong></h4><p><em>“What time is it”</em> and <em>“what is the time”</em> are two different items, because the model can answer them differently. So the set is append-only. You never edit an item, you add the new wording and close the old one’s history.</p><h4><strong>Label every answer when you produce it.</strong></h4><p>Not afterwards, because once the run is over, you cannot recover what produced it. Question type, language, which version of the model and of your instructions, whether the retrieval step found anything. Label the answer and not the run, because a staged rollout puts two versions in the same batch. A group is every answer carrying the same labels, and reading the complete set one group at a time matters because an average will happily improve while one group rots.</p><h4><strong>Keep a small set of answers scored by people.</strong></h4><p>Not as the gate, since a few hundred items cannot pass or fail a build, but as the ruler that tells you how far the judge sits from human judgement. It is worth having because it is independent. Your judge is usually built much like the model it grades, so when that model is fluently and confidently wrong, the judge is liable to read the fluency as quality. You never let the person who wrote the code write the only assertion for it, and this is the same rule.</p><h4><strong>And when something moves, check the causes in order.</strong></h4><p>The judge’s settings and your own harness. Then the instructions and the scoring bands. Then whether the provider changed the model underneath you. Then what the retrieval step returned. Then your labelled set going stale. Then the scale itself, because 0 to 100 claims a precision no written rubric can actually defend.</p><h3>The part that only matters at scale</h3><p>A hundred scored items you can read yourself. At thousands, you have lost that option, and the set only grows, because AI produces far more than you can inspect.</p><p>This is where the two approaches part company. Perfecting the evaluation needs an opinion about every item, and opinions do not scale. Comparing this week to last week needs no opinion at all, so it is the one thing that still works when the set outgrows you.</p><p>What does change with size is the arithmetic of alarms. You compare each group against itself rather than watching one number for everything, and with enough groups something moves every day by chance alone. So act on a group only when it moves the same way several runs running. Otherwise you have built a pager nobody reads.</p><p>An alarm that cannot tell you which group moved is not detection, it is anxiety. The labels are what let you go from a number that moved to a group of answers a person can actually sit down and read.</p><p>What you are buying is not certainty. It is a blind spot of a known size, which you are watching.</p><h3>Why this is the better investment</h3><p>There is published work on how unreliable these judges are. The biases were named early, in <a href="https://arxiv.org/abs/2306.05685">Judging LLM-as-a-Judge with MT-Bench and Chatbot Arena</a>, and a later paper counted twelve of them and built a framework to measure each one, in <a href="https://arxiv.org/abs/2410.02736">Justice or Prejudice</a>. A 2026 study of 21 judges from nine providers scored the same items twice and compared the results. Two judges already running in production agreed with themselves above 0.95, while still scoring the same answer differently depending on where it appeared in the list, which is called position bias. The paper is <a href="https://arxiv.org/abs/2606.19544">Reliability without Validity</a>. Consistency and correctness are not the same property. And on whether any of this holds still, a paper on running a judge in production says plainly that a judge well aligned on the day you deploy it will not stay aligned, in <a href="https://arxiv.org/abs/2608.18300">The Lifecycle of LLM-as-a-Judge</a>.</p><p>So proving your evaluation is right is not a hard job. It is an unbounded one. Catching it being wrong is a finite job you can actually finish, and it keeps working as you grow.</p><p>None of this is an argument for caring less about quality. It is the opposite. Once you know, in a reasonable way, when your evaluation is wrong, it becomes much easier to focus on getting it right, because you finally know where to look.</p><p>Invest in knowing when your AI is wrong, not in perfecting when it is right.</p><p>I build evaluation systems like this for teams shipping AI. See <strong>AI evaluation at SquareNumbers</strong>.</p><p><a href="https://squarenumbers.co.uk/services/ai-evaluation">https://squarenumbers.co.uk/services/ai-evaluation</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ebd7ace22ad0" width="1" height="1" alt=""><hr><p><a href="https://blog.stackademic.com/ai-evaluation-invest-in-knowing-when-it-is-wrong-not-in-perfecting-when-it-is-right-ebd7ace22ad0">AI Evaluation: Invest in Knowing When It Is Wrong, Not in Perfecting When It Is Right</a> was originally published in <a href="https://blog.stackademic.com/">Stackademic</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Tell Me About How You Handle a Conflict]]></title>
            <link>https://medium.com/@squarenumbers/tell-me-about-how-you-handle-a-conflict-4765ebdc1344?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/4765ebdc1344</guid>
            <category><![CDATA[conflict-resolution]]></category>
            <category><![CDATA[communication]]></category>
            <category><![CDATA[career-advice]]></category>
            <category><![CDATA[culture]]></category>
            <category><![CDATA[personal-growth]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Tue, 06 Oct 2026 13:20:28 GMT</pubDate>
            <atom:updated>2026-10-06T13:20:28.829Z</atom:updated>
            <content:encoded><![CDATA[<p>I get asked this question a lot. In interviews, in one-on-one conversations, sometimes just casually over coffee. My answer surprises people, because I tell them the truth. <strong>I like conflict at work.</strong></p><p>I mean it even for the harder conflicts, the ones with real tension behind them. This approach is not just for the easy disagreements. It is a process, and going through that process is fine. It is simply the way.</p><figure><img alt="Conflict is not a thread" src="https://cdn-images-1.medium.com/max/1024/1*atj6ppiKfolNNMVacwpJBw.png" /><figcaption>Conflict is not a threat</figcaption></figure><p>Here is why.</p><h3>Speaking Up Is a Gift</h3><p>Start with the fact that you are even allowed to disagree out loud. Not every workplace lets that happen. Some cultures punish it quietly, through cold shoulders or being passed over, so people learn to stay quiet instead. If you work somewhere that lets you push back on an idea without fear, notice that. It is not the default. It is something you got lucky to have, or something someone worked hard to build.</p><h3>It Is Not Personal</h3><p>Once that is settled, I try to remember it is not personal. Two people can want the exact same outcome and still fight about how to get there. We are not against each other. We are both against the same problem, just standing on different sides of it. That is not a threat, that is just two people trying harder than one.</p><h3>Where Opinions Come From</h3><p>And I try to stay honest about where my opinion actually comes from. It comes from what I know, what I have lived through, and whatever data happens to be in front of me that day. The person across the table built theirs the same way, just with a different life behind it. Neither of us is holding the full truth. We are each holding a piece.</p><h3>Treat It as a Challenge</h3><p>Now comes the part that actually matters. I treat every conflict as a challenge, not a threat.</p><p>If I turn out to be right but nobody is convinced yet, the challenge is on me. I need better evidence, a clearer explanation, or a different way to say the same thing. That pushes me to dig deeper, read more, and talk to more people. That is real growth, not a consolation prize.</p><p>If I turn out to be wrong, the challenge looks different, but the reward is the same. Someone saw something I missed. Now I get to learn it. I get to ask myself how I can spot that kind of thing earlier next time. Being wrong, handled this way, is just another form of learning.</p><h3>Everybody Wins</h3><p>Either way, nobody loses. You learn something. The product, the plan, or the decision gets better because two views collided instead of one view going unchallenged. And the culture around you gets stronger, because people saw that disagreement led somewhere good instead of somewhere bad.</p><p><em>That is the whole answer, really. Conflict is not something to survive. It is something to use.</em></p><p>We have all had our own conflicts. Next time one shows up, think about how you could turn it into a challenge moment instead.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4765ebdc1344" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Add AI to Your Product Without Running Any AI]]></title>
            <link>https://blog.stackademic.com/how-to-add-ai-to-your-product-without-running-any-ai-308d8d5ab8e1?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/308d8d5ab8e1</guid>
            <category><![CDATA[product-management]]></category>
            <category><![CDATA[money]]></category>
            <category><![CDATA[mcp-server]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[mcps]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Mon, 03 Aug 2026 09:30:25 GMT</pubDate>
            <atom:updated>2026-12-02T14:39:22.527Z</atom:updated>
            <content:encoded><![CDATA[<p><em>Your customers already pay for Claude and ChatGPT. Here is how to let their AI drive your product, so you never run a model or pay an inference bill.</em></p><p>Every product team I talk to has the same task on the board right now. Add AI. Put a chat box on the site. Let people talk to it.</p><p>Then the questions start. Which model? How much per message? Who stops it from saying something wrong in our name? How do we keep it accurate as the product changes? The plan that looked exciting on Monday looks like a second product to build and babysit by Friday.</p><p>There is a quieter way to do this, and for most products it is the better one. You do not run any AI at all. You expose what your product can already do, and you let each customer bring their own assistant to it. The assistant they already pay for, already trust, and already have open in another tab.</p><p>The piece that makes this possible is MCP.</p><h3>What MCP actually is</h3><p>MCP stands for Model Context Protocol. Forget the name, and it is a simple idea. It is a standard way to describe what your product can do, so an AI assistant like Claude or ChatGPT can use it safely on behalf of the person using it.</p><p>You already have those things. They are your API. Log an order. Fetch a report. Update a record. Search a catalogue. MCP wraps a plain description around each one. What it does. What it needs. What it gives back. The assistant reads that and, from whatever the person typed, determines which action to call and with which values.</p><p>So you are not building a chatbot. You are publishing a menu of capabilities, and letting the customer’s own AI do the talking.</p><p>That difference is the whole article. Hold onto it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*n78l9QIPObKiiDa0kk8fVg.png" /></figure><h3>A real example you can go and try</h3><p>I built a baby-tracking product called <em>mirela</em>. Parents log feeds, nappies, sleep and growth, and the app shows them where their baby sits on the growth curves. Useful. It also still means opening the app and tapping through forms, often at three in the morning with one hand and a baby on the other arm.</p><p><em>mirela</em> exposes its capabilities over MCP. Log a feed. Log a nappy. Start and stop a sleep. Record a weight. List what happened today. Summarise the week. Once a parent connects <em>mirela</em> to their own assistant, the app stops being the only door in.</p><p>Now the parent just says what happened.</p><blockquote>“She had 120ml at 2 pm and went down for a nap.”</blockquote><p>The assistant logs the feed and starts the sleep. Done. No form.</p><blockquote>“How did she sleep this week compared to last week?”</blockquote><p>The assistant pulls the records and answers in plain words.</p><blockquote>“Write me a one page summary for the health visitor on Thursday.”</blockquote><p>The assistant gathers feeds, growth and sleep, and drafts the report.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5gnR2Ufcqh2GCn5502pdQA.png" /></figure><p>Here is the part I want you to sit with. <em>mirela</em> wrote none of those sentences. <em>mirela</em> answered none of those questions. <em>mirela</em> ran no model. It offered a set of safe, well described actions, and the parent’s own assistant did the understanding, the reasoning and the writing. <em>mirela</em> did the one thing it was always good at, which is recording and returning accurate data.</p><p>You can see the product this is built into at <a href="https://mirela.life/">mirela.life</a>.</p><h3>Insights and reports, without a reporting team</h3><p>The same move changes what insights cost you.</p><p>The old way of giving customers reports is to build dashboards, charts and export screens, then maintain them forever as people ask for one more view. It never ends, and every new view is your engineering time.</p><p>When your product speaks MCP, the customer’s assistant becomes the reporting layer. It pulls the raw records and shapes them into whatever the person asked for in that moment. A weekly summary. A comparison against last month. A quick chart. A plain answer to an oddly specific question. You did not build any of those screens. You exposed clean data and clear actions, and the work of turning that into something useful happened on the customer’s side.</p><h3>Now the money part, and where you actually save</h3><p>This is the bit people get wrong, so let me be exact.</p><p>When you embed AI inside your product, you are buying the intelligence. Every question a customer asks burns tokens on your account. The more they use it, the bigger your bill. And that model now sits on your critical path, so when it is slow or down, your product is slow or down.</p><p>With MCP, the intelligence lives on the customer’s side. Their Claude or ChatGPT subscription does the reasoning and pays for the tokens. Your product only ever receives ordinary API calls, the same cheap and predictable requests it already serves today. No model to host. No inference bill that climbs with every new user. No prompt to sit and babysit so it behaves.</p><p>You are not buying AI and reselling it at a markup. You are making your product a good citizen in a world where your customers already own powerful AI. That saving is real, and it keeps paying off. As those assistants get smarter, your product gets more capable through them, and it costs you nothing extra.</p><p>One honest caveat. If you want AI features for people who do not bring their own assistant, you still need one somewhere. MCP does not make AI free in every case. What it removes is the need to run a model just so your existing customers can use their existing assistants with your product.</p><h3>Safety is the part you cannot skip</h3><p>Letting an external assistant operate within your product only works with firm guardrails. This is where care earns its keep.</p><p>The assistant never gets special powers. Every call still runs through your normal authentication, so a person can only ever touch their own data. Each tool does one clear thing with defined inputs, and it validates them exactly as your API always has. Actions that carry weight can ask for confirmation before they run. No secrets live in the AI layer. Permissions are enforced by your product, not by the assistant’s good manners.</p><p>Built this way, the assistant is just a very capable and very polite client. It can do what you decided a customer is allowed to do, and nothing more. My day job is validating exactly these systems, and the difference between a demo and something you can trust with real users is entirely in this section.</p><h3>What this is, and what it is not</h3><p>This is not about replacing your product with a chatbot. It is not about letting an AI loose on your systems. It is about giving your existing product a language layer, so the people who use it can act, ask and understand in plain words, using the assistant they already have.</p><p>The products that feel effortless over the next few years will be the ones a customer’s assistant can already work with out of the box. Being reachable that way is quietly becoming part of what it means to be a modern product, much like having a mobile version once was.</p><p>The good news is you are probably most of the way there. If you have a decent API, exposing it over MCP is focused work, not a rebuild. The hard part is not the wiring. It is deciding what to expose, keeping it safe, and describing each capability clearly enough that an assistant uses it correctly every single time.</p><p>That last part is the work I do.</p><h3>Want this on your product</h3><p>If you want your product to work with your customers’ own AI, safely and without running a model yourself, that is exactly what I help teams ship. You can see a live example at <a href="https://mirela.life/">mirela.life</a>.</p><p>Give your product a language layer. Let your customers bring the AI. Keep the bill on their side.</p><p>I build AI automation like this for clients. See <strong>AI automation at SquareNumbers</strong></p><p><a href="https://squarenumbers.co.uk/services/ai-automation">https://squarenumbers.co.uk/services/ai-automation</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=308d8d5ab8e1" width="1" height="1" alt=""><hr><p><a href="https://blog.stackademic.com/how-to-add-ai-to-your-product-without-running-any-ai-308d8d5ab8e1">How to Add AI to Your Product Without Running Any AI</a> was originally published in <a href="https://blog.stackademic.com/">Stackademic</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[QualitEverYour Tests Passed. That Does Not Mean Your Pull Request Is Safe.]]></title>
            <link>https://medium.com/@squarenumbers/qualiteveryour-tests-passed-that-does-not-mean-your-pull-request-is-safe-0fc99c662bdd?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/0fc99c662bdd</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[qa]]></category>
            <category><![CDATA[github-actions]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[ai]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Fri, 05 Jun 2026 14:36:15 GMT</pubDate>
            <atom:updated>2026-12-02T19:28:23.623Z</atom:updated>
            <content:encoded><![CDATA[<h3>Your Tests Passed. That Does Not Mean Your Pull Request Is Safe.</h3><h3>Every pull request ends the same way. A row of green ticks, a merge button, a small hit of confidence. The tests passed, so the change must be fine.</h3><p>Except that the green tick answers a much narrower question than most people assume. It tells you the suite ran and nothing blew up. It does not tell you whether the lines you just changed were actually exercised, whether the assertions checked anything real, or whether the one risky file in the diff had a single test pointed at it.</p><p>That gap is the whole problem. A passing suite and a safe change are not the same thing, and treating them as the same is how regressions ship with a clean board behind them.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NH2Pq92NnWeJ6ISW7N_qTg.png" /></figure><p><em>Written by the team at </em><a href="https://www.squarenumbers.co.uk/"><em>Square Numbers</em></a><em>. More on validating systems you cannot fully see inside, including AI ones.</em></p><h3>The two signals everyone trusts both miss the point</h3><p>When someone asks, “Are we testing enough?” the answer is usually a coverage number. 80%, 90%, a badge in the README. The trouble is that coverage is measured across the entire codebase, while a pull request only touches a handful of files. A repo can sit at 90% overall, and your specific change can be the uncovered 10%.</p><p>So the two signals every team already trusts, pass or fail and a global coverage figure, both quietly skip the question that actually matters on a pull request. Did the code that changed get tested, and did those tests prove anything?</p><p>That is the question I wanted a tool to answer on every merge, automatically, with evidence attached.</p><h3>A gate that scores the change, not the repo</h3><p>So I built a small GitHub Action. It is not a linter, and it is not another coverage badge. It reads the test results and coverage from your CI run, identifies which production files the pull request changed, and then looks for the test evidence specific to each of those files.</p><p>From that, it produces a verdict with three states.</p><p><strong>Green</strong> means the evidence supports the change. <strong>Red</strong> means a blocking rule failed, usually a real test failure or coverage on the changed lines dropping below your threshold. The interesting one is <strong>orange</strong>.</p><p>Orange indicates the evidence is incomplete and tells you exactly where. Not “something failed” but “this file changed, and nothing in your test results touches it.” Orange is the status reviewers actually learn from, because it points a finger at the precise spot where confidence runs out. Most gates only know how to pass or block. The gap in between is where the useful information lives.</p><h3>A little under the hood</h3><p>The plumbing is deliberately boring, which is the point.</p><p>You run your tests first and produce a JUnit XML report, a format that almost every test runner across every language already emits. Coverage arrives as LCOV, which Jest, pytest, Istanbul and most others write out the moment you ask for it. Then the gate step runs and maps each changed production file to the tests and coverage that reference it.</p><pre>- uses: gilav115/pr-test-quality-gate@v1<br>  with:<br>    github-token: ${{ secrets.GITHUB_TOKEN }}</pre><p>Out of the box, failures turn it red, and everything else is informational, so you can drop it in without a config file and learn from what it reports. A short config, then, lets you raise the bar where it counts. Demand a minimum coverage on changed lines. Mark critical paths, such as authentication or payments, to apply a stricter standard. Ignore the noise like docs and markdown. The output is a plain status plus a full report in Markdown, JSON and standalone HTML, so it reads the same whether a human or another job is consuming it.</p><p>There is an optional layer of AI reviewers on top. One classifies each changed file by risk category. One flags where the evidence looks thin against that risk. One reads the production code and the test code together and catches things coverage cannot see, like a mock so shallow it proves nothing, or an assertion that checks an implementation detail rather than behaviour.</p><p>And here is the design decision I care about most.</p><h3>The trust model: the machine flags, the rules decide</h3><p>The AI reviewers can raise concerns, but they can never set the final verdict on their own. Every finding must cite the exact file and line. Anything vague gets stripped before the verdict is computed. The worst an AI finding can do is push the status to orange. A deterministic engine, plain rules you can read and predict, always makes the actual call.</p><p>That boundary is not a limitation I tolerate. It is the feature. A gate that blocks your team needs to be explainable, repeatable and impossible to spook with a hallucination. So the model gets to point at problems, and the rules get to decide. If you build anything that puts a language model in a position of authority, this is the pattern worth copying.</p><h3>The tool raises the floor, not the ceiling</h3><p>A gate like this catches the obvious misses. The file nobody tested. The assertion that checks nothing. The risky path that slipped in with no coverage. That is real value because humans are genuinely bad at noticing the absence of something.</p><p>But a quality gate can quietly turn into a crutch. The moment you hand the question “Is this change safe?” entirely to a badge, you stop building the instinct that lets you answer it yourself. The skill of opening a diff and feeling, in your gut, what could break and what you would want to prove before merging, that skill is still yours to grow, and no scorer hands it to you.</p><p>So treat the relationship simply. Let the automation make your judgment faster and more consistent. Do not let it make your judgment for you. The engineers who stay valuable through the next decade are the ones who use tools like this to clear the routine work, then spend the freed attention getting sharper at the part the machine cannot do, which is understanding what a change actually risks.</p><p>A green board should be where your thinking starts, not where it stops.</p><h3>Try it, then go deeper</h3><p>The action is open source. The full rule reference, config options and workflow examples live in the repo at github.com/gilav115/pr-test-quality-gate, and it takes one step in a workflow to start seeing orange where you used to see a misleading green.</p><p>If the wider problem interests you, validating systems you cannot fully see inside, including AI ones, that is the work I do at squarenumbers.co.uk.</p><p>Ship fast. Ship with confidence. Just make sure the confidence is earned.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0fc99c662bdd" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How I Turned Myself Into a Chatbot]]></title>
            <link>https://medium.com/@squarenumbers/how-i-turned-myself-into-a-chatbot-347a0aac5309?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/347a0aac5309</guid>
            <category><![CDATA[freelancing]]></category>
            <category><![CDATA[chatbots]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Wed, 27 May 2026 09:20:56 GMT</pubDate>
            <atom:updated>2026-05-27T09:20:56.089Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>TLDR:</strong> I added an AI chatbot to my website that answers questions about my work and is constrained to use only a profile I wrote, so it does not invent things or wander off topic. It runs on a Cloudflare Worker with a one-tag widget, requires no server maintenance, and costs almost nothing. The whole project is public, so you can clone it and build your own, or have me set one up for you.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QltVEVWOK09AV5xgXTzzDw.png" /></figure><p>Most professional sites have the same dead spot. Someone reads two paragraphs, has a question the page does not answer, and leaves. No follow-up, no contact, just a closed tab. I had that gap on <em>squarenumbers.co.uk</em>, so I built a small chatbot that answers questions about my work in my own words and is constrained to talk about nothing else.</p><p>This is mainly for consultants, freelancers, contractors, and small professional firms. Anyone whose website is the thing that has to turn a stranger into a conversation.</p><p>It sits in the corner of the page. A visitor asks what I do, who I work with, whether I am free for a project, and it answers from a profile I wrote by hand. The interesting part is what it will not do. It is built to avoid inventing a client I never had or quoting a price I never set, and to stay off topics I told it to leave alone. When a question falls outside the profile, it says so and points the person to email me.</p><p>This is a write-up of how it works and how you can build the same thing. I have made the whole project public, so you can clone it and point it at yourself.</p><figure><img alt="Chatbot architecture &amp; flow" src="https://cdn-images-1.medium.com/max/1024/1*CJB_tj0BekRjEsW6R13sUw.png" /></figure><h3>Why constrain it at all</h3><p>The obvious version of this is a chatbot wired to a large model with a friendly prompt. That version is also the one that gets you in trouble. Ask it something it does not know, and it will confidently guess in your name. For a personal brand or a consultancy that is not a quirk, it is a liability.</p><p>I spend my working life on the validation side of software, lately on testing AI systems, so this bias is hard to switch off. A bot that speaks for me has to be boring in the best sense. Predictable. The model still has its general knowledge, of course, but it is instructed and constrained to answer only from the profile I give it, and to refuse rather than improvise when something is missing.</p><p>That one design choice, answer from approved content or do not answer at all, is what turns this from a gimmick into something I am willing to leave running with my name on it.</p><h3>How it is put together</h3><p>There are two pieces and no server to babysit.</p><p>The first is a Cloudflare Worker. It receives the visitor’s message, checks it, builds a prompt around my profile, calls the language model, and trims the reply before sending it back. Your API key lives here as a Cloudflare secret. It never touches the browser and never lands in your code.</p><p>The second is the widget, a single JavaScript file hosted for free on Cloudflare Pages. It draws the chat bubble and talks to the Worker. Because it runs inside a shadow DOM with no dependencies, it does not collide with whatever your site is already built on.</p><p>Adding it to a site is one tag before the closing body tag:</p><pre>&lt;script<br>  src=&quot;https://your-widget.pages.dev/widget.js&quot;<br>  data-worker=&quot;https://your-worker.workers.dev&quot;<br>  data-token=&quot;your-widget-token&quot;<br>  data-name=&quot;Your Bot&quot;<br>  data-accent=&quot;#0055ff&quot;<br>&gt;&lt;/script&gt;</pre><p>That is the whole integration. No build step on your side, no framework, no plugin.</p><h3>The part that does the work</h3><p>The bot’s personality is not code. It is a folder of plain Markdown files. One describes who I am and my background. One lists how and when to reach me. Others cover services, experience, and a short set of questions I get asked a lot. There is also a boundaries file, the one I care about most, which names the topics the bot must never claim or discuss.</p><p>On each deployment, a script reads those files, bundles them into a profile, and uploads the profile to the Worker. Editing the bot means editing prose, not logic. If my work changes, I change a sentence, redeploy, and the update is live in about 30 seconds.</p><h3>Security, because it speaks for you</h3><p>This is the part I spent the most time on and the part most people skip. A bot that talks to the public on your behalf is an attack surface and a cost centre if you leave it open. The design uses layers, so no single check has to carry everything.</p><p>Before a message reaches the model, several things happen at the edge. The Worker validates the browser Origin header on every request, so only the domains you whitelist can reach the API, and a browser cannot spoof that header. A shared token is injected into the widget at deployment time, and requests without it are rejected before any processing occurs. A per-IP sliding-window rate limit blocks cost abuse and brute-force attacks before a single model call is made. Message length and conversation history are capped and validated, so oversized or malformed payloads never reach the model. A regex filter catches known prompt-injection phrases, and a keyword filter checks the message against an allowed-topic list, both at the Worker level rather than leaving the model to police itself.</p><p>Then there is the prompt. It is written as an authority hierarchy: the rules sit above the profile, and the profile sits above anything the visitor types. A visitor message is the lowest authority in the stack, so it will not change the bot’s behaviour partway through a conversation. That reduces the risk of someone talking off-script.</p><p>After the model replies, the output is capped and trimmed on the server before it reaches the browser, so the bot cannot return runaway output or leak its own instructions.</p><p>Two more details matter. Every credential lives in the hosting platform’s secret store, never in the repository, so no keys or tokens are committed to source control. And for a blocked origin, the CORS header is omitted entirely, so the browser cannot read the error response, and a rejected request leaks nothing back.</p><p>None of these is exotic on its own. Together, they are the difference between a demo and something you are comfortable leaving live.</p><h3>What it costs</h3><p>Almost nothing. Cloudflare’s free tier covers 100,000 requests per day, and hosting the widget is free. The only real cost is the model itself, and on the cheaper options, it&#39;s on the order of a cent per thousand messages, though that varies with the provider, the model, and how long the answers run. A personal site with a few hundred visitors a day costs close to nothing to run.</p><h3>Why I think it is worth building</h3><p>Two reasons, one for each kind of reader.</p><p>If you build things, this is a clean, small example of a pattern worth knowing. Edge compute, a constrained model, secrets handled properly, and a drop in widget, all on a free tier. You can read the whole thing in one sitting and bend it to other uses.</p><p>If you do not build things, the point is different. The barrier to putting a genuinely useful, honest AI feature on your own site is now low enough that not having one is a choice. What used to require a vendor and a monthly fee now requires a clear sense of what you want it to say and what you want it to refuse to say.</p><p>Honesty is the whole game. Anyone can bolt a chatbot onto a site. The harder and more valuable thing is one that will not misrepresent you when nobody is watching.</p><h3>Build your own</h3><p>You need a Cloudflare account on the free tier, an API key from OpenAI or Anthropic, and enough comfort with a terminal to run a few commands. The full project is on GitHub at <a href="https://github.com/gilav115/portfolio-chatbot">github.com/gilav115/portfolio-chatbot</a>. Clone it, fill in your profile, and deploy. Setup is about fifteen minutes. The real work is writing the profile, deciding what it should say and, more importantly, what it should refuse to say.</p><p>If you would rather not do it yourself, that is part of what I do at Square Numbers, helping small teams adopt AI without the risk that usually comes with it.</p><p>You can see this bot in the corner of <em>www</em>.<em>squarenumbers.co.uk</em>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=347a0aac5309" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Security Guarantees in Everyday Testing]]></title>
            <link>https://blog.stackademic.com/security-guarantees-in-everyday-testing-6c426cb72486?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/6c426cb72486</guid>
            <category><![CDATA[software-design]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[testing]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Mon, 13 Apr 2026 13:07:04 GMT</pubDate>
            <atom:updated>2026-04-13T18:44:10.993Z</atom:updated>
            <content:encoded><![CDATA[<h3>What this is about</h3><p>This article is not about penetration testing or advanced security techniques.</p><p>It is about something more fundamental. It is about how everyday testing and design decisions define whether a system is safe to use, not just whether it works.</p><p>The value for you as a reader is simple. You will learn how to identify security risks early, shape better API contracts, and prevent issues before they become expensive to fix.</p><p>Security, in this context, is not a separate discipline. It is a set of guarantees that must exist in every flow.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RSPZszaWz4eLT526wHIT1w.png" /></figure><h3>Security is not a separate lane</h3><p>Security is often treated as a specialist activity, something reviewed later by a dedicated team or tested through a separate exercise. That is too late for many of the issues that matter most.</p><p>By the time a flaw reaches system testing or a formal security review, the contract is already defined, the implementation is already shaped, and the cheapest design decisions have already been missed.</p><p>This does not mean every tester must become a security expert. It means security concerns must be built into normal product thinking, requirement review, design review, and everyday testing.</p><p>A strong engineering organisation does two things at once. It brings in security specialists early, and it expects product, engineering, and quality to think clearly about misuse, abuse, and unsafe assumptions from the start.</p><h3>What this looks like in practice</h3><p>In most teams, a functional question sounds like this: <em>Can the user perform the action successfully?</em></p><p>A security-aware question sounds different: <em>should this user be allowed to perform this action at all, on this data, using this input, under these conditions?</em></p><p>That shift sounds small, but it changes the system before code is written. It affects API contracts, field definitions, ownership rules, validation strategy, and error handling.</p><p>This is why security should appear at the requirement and design stages, not only in execution. If the guarantees are unclear at the start, tests will only discover symptoms later.</p><h3>A practical example</h3><p>Consider an API for updating payout details.</p><p>At first glance, the feature seems straightforward. A client sends a request to update payout information for a user account. The happy path is simple, and many teams would move quickly to implementation.</p><p>But this type of flow carries several risks that are often overlooked when the focus stays purely functional.</p><p>Imagine a request like this.</p><pre>PATCH /payout-details<br>{<br>  &quot;user_id&quot;: &quot;user_123&quot;,<br>  &quot;account_id&quot;: &quot;acc_789&quot;,<br>  &quot;session_token&quot;: &quot;token_abc&quot;,<br>  &quot;bank_account&quot;: &quot;GB12BARC20000012345678&quot;,<br>  &quot;nickname&quot;: &quot;Primary account&quot;<br>}</pre><p>From a functional perspective, the questions are obvious.</p><p><em>Does the update succeed? Is the data stored correctly? Does the response return the updated values?</em></p><p>From a security perspective, the important questions are different.</p><ul><li>What guarantees that <strong>the session_token belongs to the same user</strong> as the user_id?</li><li>What guarantees that <strong>account_id also belongs to that same user</strong>?</li><li>What happens if <strong>one identifier is valid and another is manipulated</strong>? What prevents a user from<strong> updating another person’s payout details</strong> by changing only one field?</li><li>What prevents <strong>unsafe content from entering a free text field</strong>, such as a nickname?</li></ul><p>These are not edge cases. These are standard failure modes.</p><h3>The design problem behind the API</h3><p>The weakness in flows like this is often not a missing test. It is an incomplete contract.</p><p>If an API accepts multiple user-linked identifiers and trusts the client to keep them aligned, the system is already exposed. If a token proves identity, but the request body can point to someone else’s data, the design is weak before implementation begins.</p><p><strong>The correct response is not to write more tests around a weak shape. The correct response is to improve the contract.</strong></p><p>A stronger design would remove unnecessary identifiers and derive identity from the authentication layer.</p><p>For example, instead of blindly trusting a session token, the system should validate a signed token, such as a JWT, extract the user identity from it, and ignore any conflicting identifiers provided by the client.</p><p>If an identifier, such as an account_id in our example, must be supplied, the system must enforce internal ownership validation and explicitly reject any mismatch.</p><p>Free text fields, such as nickname, should not accept arbitrary input. They should enforce strict formats, length limits, and allowed character sets to prevent injection or misuse.</p><p>At the same time, the system must be careful in its responses. Error responses should not expose whether a specific account exists or belongs to another user. A generic authorization failure is often safer than a detailed explanation that can be abused.</p><h3>Making the system observable</h3><p>Even with a strong contract, misalignment attempts will happen. These can result from bugs, integration errors, or malicious behaviour.</p><p>The system must therefore be observable. Any mismatch between identifiers, invalid ownership attempts, or repeated unauthorized actions should be logged, monitored, and surfaced.</p><p>This is not only about security. It is also about product quality. These signals often reveal integration issues or incorrect assumptions made by clients. A secure system does not just prevent unsafe actions. It also makes them visible.</p><h3>What QA should do before development starts</h3><p>This is where quality adds real value. Before implementation starts, QA should review the requirements and ask direct questions.</p><p>What proves identity? What proves ownership? Which fields are client-controlled, and which should be derived by the system? Which inputs are too permissive? Which assumptions are being made across services? What should happen when authentication is valid but authorization fails?</p><p><strong>These questions should not stay inside a QA document. They should be discussed openly with engineering, product, and security.</strong></p><p>If a security team exists, involve them early. They should review requirements, challenge unsafe assumptions, and help identify risks before they harden into code. They should also review the test concerns and cases.</p><p>This is not a handoff. It is a collaboration.</p><h3>What testing should validate later?</h3><p>Once the implementation is in place, the tests should validate the guarantees agreed upon earlier.</p><p>Using the payout details example, that means verifying that authentication is always enforced, that authorization is consistent, that mismatched identifiers are rejected, and that no unsafe input is accepted.</p><p>It also means verifying that responses do not leak sensitive information and that repeated invalid attempts are handled consistently.</p><p>This is where normal testing skills matter. A good tester already considers edge cases, hidden assumptions, and real user behavior. The same mindset applies here.</p><h3>You do not need to be a security specialist</h3><p>A tester is not expected to replace a security engineer, just as a security engineer is not expected to replace product, architecture, or quality. But not being a specialist is not a reason to ignore obvious risks.</p><p>If you can think like a user, question assumptions, follow data across system boundaries, and spot where one field can contradict another, you already have part of the skill set needed to improve security outcomes.</p><h3>What leadership should understand</h3><p>Security defects are often expensive, not because they are technically complex, but because they were allowed into the design unnoticed.</p><p>A team that brings security thinking into requirements, design, and routine testing will usually implement safer systems faster and more cheaply than a team that treats security as a late-stage review.</p><p>That is not because they test more. It is because they ask better questions earlier.</p><h3>Closing thought</h3><p>Security should not appear only when something looks obviously dangerous. It should be part of how everyday flows are shaped, discussed, and validated.</p><p>The best time to catch a security issue is before it becomes code. The next best time is before it reaches customers.</p><p>That is why security belongs within normal-quality thinking, not beside it.</p><p>For more information <a href="https://squarenumbers.co.uk/">https://squarenumbers.co.uk/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6c426cb72486" width="1" height="1" alt=""><hr><p><a href="https://blog.stackademic.com/security-guarantees-in-everyday-testing-6c426cb72486">Security Guarantees in Everyday Testing</a> was originally published in <a href="https://blog.stackademic.com/">Stackademic</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How Quality Thinking Shapes Client Solutions]]></title>
            <link>https://blog.stackademic.com/how-quality-thinking-shapes-client-solutions-929565d4cc5f?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/929565d4cc5f</guid>
            <category><![CDATA[qa]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[product-management]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Wed, 25 Mar 2026 17:13:33 GMT</pubDate>
            <atom:updated>2026-03-29T11:21:44.238Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*d5vci0eoHOVOFw0WSelBSQ.png" /></figure><h3>Why this matters</h3><p>Most teams ask one question when building systems: <em>Does it work?</em> That question is internal and focuses on correctness, reliability, and implementation.</p><p>Clients ask a different question:</p><blockquote>Can I trust it? Can I safely retry? Can I understand failures? And can I make the right decision without guessing?</blockquote><p>This shift in perspective is where quality thinking changes the outcome.</p><p>In a <a href="https://medium.com/@squarenumbers/quality-mindset-as-part-of-the-product-solution-8ae83402a92d">previous article</a>, we explored how a quality mindset shapes internal systems and architecture. Here, the focus is different. This is about how those same decisions directly affect the client and the decisions they must make in the event of failure.</p><h3>The shift in perspective</h3><p>Internally, teams ask if the system is correct. Clients think differently. They need to know what they will see when things fail, what they can safely do next, and what guarantees the contract provides.</p><p>A system can be correct and still force clients into unsafe or guess-based behaviour.</p><p>Quality thinking shifts the design from internal correctness to <strong>client decision safety</strong>, where the client can always act without causing harm.</p><h3>Example: Designing for client decisions, not internal flow</h3><p>A fintech platform exposes a payment API. Internally, processing is reliable and consistent, and from an engineering perspective, the system is correct.</p><p>A client sends a payment request and receives no response due to a network issue. At this point, the client must decide what to do next.</p><ul><li>Retry and risk charging the customer twice</li><li>Do nothing and risk missing the payment</li><li>Build custom tracking to guess the system state</li></ul><p>This is the <strong>real</strong> failure. The system works, but the contract does not guarantee safe behaviour in the presence of failures.</p><p>A quality mindset reframes the problem. The question is no longer “<em>is the system correct?</em>”, but “<em>what can the client safely do next?</em>”.</p><p>That shift has a direct implication. If the client cannot make a safe decision, the system contract is incomplete. The solution must therefore change at <strong>the contract level</strong>, not just internally.</p><p>To mitigate this, the system has to do more than remain safe behind the scenes. It has to expose that safety in a way the client can understand and use.</p><p>That means giving the client two things.</p><ul><li>A clear way to identify a single business operation</li><li>A reliable way to resolve the final outcome</li></ul><p>This is how trust is built, externally. The client is not asked to assume that the platform behaved correctly. The contract gives them a safe and verifiable path.</p><p>One way to express that is through the API itself. Instead of assuming the client will manage retries and uncertainty on their own, or just ask the client to “trust the system”, the contract explicitly supports it.</p><p>The client is expected to attach an identifier to each operation. This identifier represents the intent of the action, not just the request.</p><pre>POST /payments<br>{<br>  &quot;client_request_id&quot;: &quot;abc-123&quot;,<br>  &quot;amount&quot;: 100.00,<br>  &quot;currency&quot;: &quot;USD&quot;,<br>  &quot;account_id&quot;: &quot;user-42&quot;<br>}</pre><p>Here, the <em>client_request_id</em> is introduced as part of the contract. It allows the client to define what a single payment means from their perspective. If the client needs to retry, they are not creating a new action. They are repeating the same intent. Their intent.</p><p>Response:</p><pre>{<br>  &quot;status&quot;: &quot;accepted&quot;,<br>  &quot;payment_id&quot;: &quot;pay-789&quot;<br>}</pre><p>The contract now guarantees:</p><ul><li>Repeating the same <em>client_request_id</em> will not execute the payment twice</li><li>The client can always resolve the final state</li></ul><pre>GET /payments?client_request_id=abc-123</pre><pre>{<br>  &quot;status&quot;: &quot;completed&quot;,<br>  &quot;payment_id&quot;: &quot;pay-789&quot;<br>}</pre><p>This is not an implementation detail. It is a client-facing contract. A real shift in how we think and a real positive impact on the client.</p><ul><li>Retry is safe</li><li>Outcome is deterministic</li><li>No guesswork or defensive logic is required</li></ul><p>Internally, the system was already safe. Externally, the client now has control and visibility.</p><p><strong>That is where quality thinking influences the solution.</strong></p><h3>What does this change for the client</h3><p>These decisions are small at design time but critical at integration time.</p><p>For clients, this means clear actions under failure, deterministic outcomes, no need for defensive or guess-based logic, and lower support and operational costs.</p><p>More importantly, it gives the client control. Even if the system is already safe internally, exposing that safety through the contract increases confidence and reduces friction. It’s about trust, not reliability.</p><h3>Why this matters to the product</h3><p>Client experience is part of the product. Friction and frustrations are a real pain. If integration is fragile or unpredictable, the product is harder to adopt and harder to trust.</p><p>Quality thinking ensures that systems are not only correct, but usable and reliable from the outside.</p><h3>What leaders need to know</h3><p>This shift is not theoretical. It affects how systems are designed, operated, and trusted.</p><ul><li>CTO: This is about enforcing guarantees at system boundaries. Without this, services may be correct in isolation but inconsistent overall.</li><li>CPO: This reduces customer-facing errors and support load. When clients can act safely, trust increases, and fewer issues reach users.</li><li>Solutions Architect: This clarifies contracts and responsibilities. It defines how systems behave under failure, not just under success.</li><li>Non-technical stakeholders: This makes integrations predictable. Clients do not need internal knowledge or support to operate safely.</li></ul><p>This is not additional complexity. It is making system behaviour explicit and usable.</p><h3>Closing thought</h3><p>Quality is not only about what happens inside the system. It is about how the system behaves when someone else depends on it.</p><p>A system can be correct yet hard to use. A strong solution is both correct and predictable from the outside.</p><p>Quality thinking does not add features. It defines guarantees.</p><p>That is what builds trust.</p><p>For more information <a href="https://squarenumbers.co.uk/">https://squarenumbers.co.uk/</a></p><h3>A message from our Founder</h3><p>Hey, <a href="https://linkedin.com/in/sunilsandhu">Sunil</a> here. I wanted to take a moment to thank you for reading until the end and for being a part of this community. Did you know that our team run these publications as a volunteer effort to over 3.5m monthly readers? We don’t receive any funding, we do this to support the community.</p><p>If you want to show some love, please take a moment to follow me on <a href="https://linkedin.com/in/sunilsandhu">LinkedIn</a>, <a href="https://tiktok.com/@messyfounder">TikTok</a>, <a href="https://instagram.com/sunilsandhu">Instagram</a>. You can also subscribe to our <a href="https://newsletter.plainenglish.io/">weekly newsletter</a>. And before you go, don’t forget to clap and follow the writer️!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=929565d4cc5f" width="1" height="1" alt=""><hr><p><a href="https://blog.stackademic.com/how-quality-thinking-shapes-client-solutions-929565d4cc5f">How Quality Thinking Shapes Client Solutions</a> was originally published in <a href="https://blog.stackademic.com/">Stackademic</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Quality Mindset as Part of the Product Solution]]></title>
            <link>https://blog.stackademic.com/quality-mindset-as-part-of-the-product-solution-8ae83402a92d?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/8ae83402a92d</guid>
            <category><![CDATA[product-development]]></category>
            <category><![CDATA[systems-thinking]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Fri, 27 Feb 2026 14:45:56 GMT</pubDate>
            <atom:updated>2026-03-31T09:20:28.881Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kCV7-vMaHK8SegopMQr5pg.png" /></figure><h3>Why this matters</h3><p>Most teams discover risk late. Late in integration. Late in staging. Late in production.</p><p>When that happens, the cost is not just technical.<br>It is roadmap disruption, reactive fixes, lost trust, and cross-team firefighting.</p><p>A strong quality mindset changes when and how those decisions are made.<br>It surfaces system-level risks early, influences architecture and contracts before they harden, and reduces the need for expensive redesign after launch.</p><p>This is not about catching more bugs.<br>It is about shaping stronger solutions before they become costly to change.</p><h3>What leaders often miss</h3><p>From a CTO perspective, system integrity and long-term maintainability matter.<br>From a CPO perspective, customer trust and delivery speed matter.<br>From a Solutions Architect perspective, cross-system contracts and failure handling matter.</p><p>A quality mindset operates at the intersection of all three.<br>It looks at the full system, not isolated components.</p><h3>What a quality mindset really means</h3><p>A quality mindset asks questions that affect design, not just tests.</p><ul><li><em>What assumptions are we making across services?</em></li><li><em>What happens under retry, delay, or partial failure?</em></li><li><em>How does this behave with real vendor data and real clients?</em></li><li><em>What would this cost to fix after release?</em></li></ul><p>These questions shape the boundaries of solutions and product guarantees.</p><h3>Example 1: Decimal precision across financial flows</h3><p>During system testing, inconsistent decimal precision was identified between internal services and external transaction vendors.<br>Each service was internally consistent, but when transactions were reconciled end to end, small differences appeared.</p><p>From a development perspective, nothing was broken locally.<br>From a system perspective, financial correctness was not guaranteed.</p><p>If released, this would have resulted in reconciliation gaps, manual investigations, and customer-facing discrepancies.</p><p>Raising this early forced a cross-team architectural decision.</p><ul><li>Define a single-precision and rounding policy</li><li>Align internal and vendor precision rules</li><li>Explicitly define how mismatches are handled</li></ul><p>This created a formal financial contract across services.<br>It reduced operational reconciliation effort and prevented production incidents.</p><h3>Example 2: Duplicate actions under retry</h3><p>A feature allowed users to trigger a sensitive action through an API.<br>Under network instability, clients retried requests.<br>Each component behaved correctly in isolation.</p><p>Quality asked.<br><em>What guarantees that the same action is not executed twice?</em></p><p>If ignored, this could have caused duplicate operations, financial corrections, and customer complaints.</p><p>The solution changed.</p><ul><li>Introduce idempotency keys at the API boundary</li><li>Persist request identifiers</li><li>Guarantee consistent responses for retries</li></ul><p>This was not a bug fix.<br>It changed the API contract and how clients integrate.<br>It reduced operational risk and post-release firefighting.</p><h3>Why this matters to leadership</h3><p>For a CTO, this reduces systemic fragility and cross-service drift.<br>For a CPO, this protects customer trust and reduces reactive roadmap work.<br>For a Solutions Architect, this clarifies contracts and strengthens the boundaries of failure.</p><p>Influencing these decisions early shortens feedback loops and avoids expensive redesign after launch.</p><h3>What this delivers</h3><p>When quality thinking influences design early, the impact is measurable.</p><ul><li>Fewer late-stage requirement reversals</li><li>Clearer cross-service contracts</li><li>Stronger failure handling before production</li><li>Reduced reactive work after release</li></ul><p>For leadership, this means less disruption to the roadmap and more predictable delivery.<br>For architecture, this means explicit system guarantees rather than implicit assumptions.<br>For customers, it means fewer surprises.</p><p>Quality does not replace solution roles.<br>It strengthens them by asking the questions that define durable, scalable solutions.</p><p>More on system-level quality and solution thinking at <a href="https://squarenumbers.co.uk/">https://squarenumbers.co.uk/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8ae83402a92d" width="1" height="1" alt=""><hr><p><a href="https://blog.stackademic.com/quality-mindset-as-part-of-the-product-solution-8ae83402a92d">Quality Mindset as Part of the Product Solution</a> was originally published in <a href="https://blog.stackademic.com/">Stackademic</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MCP Your Infrastructure: Intent-Driven Access to Testing Systems]]></title>
            <link>https://blog.stackademic.com/mcp-your-infrastructure-intent-driven-access-to-testing-systems-af806fd492c3?source=rss-cf715314fe0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/af806fd492c3</guid>
            <category><![CDATA[mcp-server]]></category>
            <category><![CDATA[infrastructure]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[qa]]></category>
            <dc:creator><![CDATA[Gil Avraham]]></dc:creator>
            <pubDate>Fri, 16 Jan 2026 15:24:44 GMT</pubDate>
            <atom:updated>2026-03-28T09:35:04.802Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Bugl0NX26PKs6ReotIVr8A.png" /></figure><h3>Why we did this</h3><p>We operate a large and complex system. As part of it, we built a similarly complex testing infrastructure.</p><p>This infrastructure supports manual testing, automation, and operational workflows. It is used by QA, developers, product, and management.</p><p>It already exposes powerful capabilities.</p><ul><li>Perform actions in the system</li><li>Retrieve system information</li><li>Retrieve and generate test data</li></ul><p>All of this is available via REST and GraphQL endpoints.<br>Even when designed carefully, using this infrastructure still requires knowledge of multiple endpoints, parameters, and internal concepts.</p><h3>The problem</h3><p>The problem was not missing functionality. The problem was access to it.</p><p>Technical and business knowledge acted as a barrier.<br>Many stakeholders did not know how to perform certain actions, or did not even know those actions existed.</p><p>Even simple tasks required</p><ul><li>Knowing which service to call</li><li>Knowing which endpoints to use and in which order</li><li>Knowing which parameters were required</li><li>Switching between multiple tools and dashboards</li></ul><p>As a result, only a small group of people could safely operate the infrastructure.<br>That group became an operational choke point.<br>As the system grew, delivery speed and test coverage degraded because access did not scale.</p><p>The cost showed up repeatedly in data preparation and test analysis.<br>Hours were spent creating users, accounts, and states just to validate small changes, and testers manually reviewed multiple reports daily to understand regressions.</p><p>Everyone else had to ask for help, wait, or avoid the task entirely.</p><h3>What changed with MCP</h3><p>We exposed large parts of our testing infrastructure as MCP tools.<br>This did not replace our APIs. It added a semantic layer on top of them.</p><p>Instead of interacting with endpoints, people interact through intent.<br>This shifts scalability from human knowledge and documentation to the system itself.</p><p>The agent resolves.</p><ul><li>Which underlying services to call</li><li>In which order</li><li>With which parameters</li></ul><p>The user no longer needs to understand the communication between systems.</p><h3>Example: generating a test user</h3><p>Before MCP, generating a usable test user was a multi step task.<br>A developer had to locate the correct service, call the right endpoint, supply a valid combination of parameters, and understand internal user and account models.<br>If the parameters were wrong or incomplete, the result was an unusable user and another iteration.</p><p>With MCP, the same intent is expressed in one sentence.</p><blockquote>Find me a user that has a savings account and a positive balance.</blockquote><p>The agent translates this intent into the required calls, validates the outcome, and returns a user that can log in and perform real actions.<br>No knowledge of internal structure is required.</p><p>Crucially, the workflow does not stop there.<br>The same conversation can continue with actions on that user, inspections, or further setup, without switching tools or losing context.</p><h3>Example: analysing test results</h3><p>Allure is our reporting system for automated tests.</p><p>Previously, analysis was fragmented.<br>A tester had to open multiple reports, correlate runs manually, and track regressions across services by hand.<br>This work was repetitive and easy to get wrong.</p><p>With MCP, the analysis becomes intent driven (a very simplified version of the prompt).</p><blockquote>Given this list of services, find regression status and generate an HTML report.</blockquote><p>The agent gathers results across runs, identifies regressions, find trends, analyze logs and and produces a single consolidated report.<br>What previously required daily manual effort is reduced to a single interaction, with consistent and repeatable output.</p><h3>What changed operationally</h3><p>Before MCP, critical knowledge lived with a small group of people.<br>Testers prepared environments and data, and developers depended on them even for small checks.</p><p>After MCP, this changed.<br>Work no longer depended on specific people or tribal knowledge.<br>Developers and other stakeholders could act independently without slowing delivery.</p><p>Developers can now generate test data, simulate flows, and validate changes themselves using a few prompts, without waiting on testers.</p><p>Non technical stakeholders can interact with parts of the system they previously could not.<br>They do not need to understand internal flows or system structure.<br>They only need to express what they want.</p><h3>What we gained</h3><p>The biggest gain is not automation. It is removal of handoffs.</p><p>Tasks that previously required coordination between people and tools now happen end to end in a single interaction.<br>This reduced waiting time, interruptions, and hidden dependencies.</p><h3>Security and access control</h3><p>Exposing infrastructure through MCP requires explicit guardrails.</p><p>For integrations that require specific users or elevated access, we use tools that rely on local secrets.<br>This limits sensitive capabilities to the people or environments that need them.</p><p>The MCP layer remains free of embedded secrets.<br>Permissions and access are enforced at the tool level, not in the agent logic.</p><h3>What this is and what it is not</h3><p>This is not about replacing existing systems.<br>It is not about letting agents run uncontrolled operations.</p><p>It is about providing a controlled, intent driven interface over existing infrastructure.</p><p>MCP does not remove complexity.<br>It relocates it to a place where it can be managed, audited, and evolved.</p><h3>Where this goes next</h3><p>This is not an optional optimization.<br>As systems and teams grow, intent based access becomes the only way to preserve velocity and safety.</p><p>At that point, infrastructure stops being something people learn.<br>It becomes something they operate through language, with explicit guardrails.</p><p>More at <a href="https://squarenumbers.co.uk/">https://squarenumbers.co.uk/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=af806fd492c3" width="1" height="1" alt=""><hr><p><a href="https://blog.stackademic.com/mcp-your-infrastructure-intent-driven-access-to-testing-systems-af806fd492c3">MCP Your Infrastructure: Intent-Driven Access to Testing Systems</a> was originally published in <a href="https://blog.stackademic.com/">Stackademic</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>