The Hidden Failure Mode in AI Agent Loops
Dan Mercede · 2026-06-29 · 9м 51с · 14 просмотров · YouTube ↗
Топики: ai-loop-engineering
🎧 Аудио
📝 Summary
model=deepseek-v4-flash · prompt=summary-v7 · 4 202→2 710 tokens · 2026-07-20 12:06:24
🎯 Главная суть
Самокорректирующиеся агентные циклы страдают от скрытого режима отказа: когда верификатор не может выполнить проверку (из-за тайм-аута, rate limit или падения), система интерпретирует отсутствие ответа как «опровергнуто», а не как «не проверено». Это приводит к тому, что агент выдаёт уверенные, но полностью ложные вердикты, разрушая доверие к собственным результатам. Решение — внедрение трёхсостоянийных ворот (подтверждено / опровергнуто / воздержалось) и жёстких правил классификации, чтобы пустота не превращалась в лже-опровержение.
Анатомия агентного цикла: три роли
Любой серьёзный агентный цикл строится вокруг трёх ролей: reasoner (генератор кандидатов-ответов), verifier (оценщик, который выносит вердикт) и refiner (исправляет ответ на основе обратной связи). Технически все три могут быть одной моделью, но критически важным звеном оказывается этап verify. Если сломан reasoner — выдача очевидный мусор, который видно сразу. Если сломан verifier — он производит чистые, правдоподобные и абсолютно неверные заключения. Исследование Self-Correction Bench показало: у 14 разных моделей слепая зона самоисправления составляет 64,5% — модели исправляют ошибку, если её явно указать в промпте, но систематически не замечают ту же ошибку в собственном предыдущем выводе. Генерация легко обгоняет суждение. Интересный факт: простое добавление слова «wait» в промпт снижало слепые зоны на 89% — способность к самопроверке есть, но она не срабатывает без внешнего триггера.
Невидимый сбой: как rate limit превращается в лже-опровержение
В реальном кейсе использовались двухсостоянийные ворота: утверждение выживает, если получает не менее двух действительных голосов «за» и менее двух «против». Звучит разумно, но логика неявно предполагает, что голоса существуют. Когда API rate limit дал сбой, каждый вызов верификатора вернул пустой ответ. Формально было ноль опровержений, но и ноль действительных голосов. Утверждение не прошло. Это классический fail-closed (безопасное падение в закрытое состояние), но цена высока: система сбросила всю тишину в корзину «опровергнуто». Слой суммаризации превратил инфраструктурный сбой в уверенное «исследование не дало результата» — хотя на самом деле все 25 утверждений были истинными, с цитатами из реальных недавних статей. Проверка фактически не выполнялась ни разу.
Трёхсостоянийные ворота: новая ментальная модель
Верификационная логика должна немедленно перейти на три состояния. Подтверждено — есть кворум действительных голосов (например, три независимых веб-поиска успешно подтвердили дату). Действие: сохранить. Опровергнуто — достигнут порог опровержений (например, верификатор нашёл первоисточник, прямо противоречащий утверждению). Действие: отбросить, потому что доказательства говорят «нет». Воздержалось — кворум не набран из-за сбоя, тайм-аута, null-возврата или rate limit. Действие: не знаем — нужно перезапустить, эскалировать или вывести как ожидающее. Аналогия с CI/CD: если автоматический ревью кода упал, это не «одобрено» и не «отклонено» — это просто падение. Тишина — не вердикт.
Три золотых правила против ложных отрицаний
Правило 1. Классифицировать по действительным голосам в первую очередь. Прежде чем смотреть на сравнение количества опровержений, нужно подсчитать, сколько голосов реально выполнилось и успешно распарсилось. Если меньше кворума — это воздержание, ветка опровержений не достигается.
Правило 2. Ошибки, тайм-ауты и null — это воздержания, и точка. Их нельзя трактовать как чистый проход и никогда — как опровержение. Всегда помечать как ожидающие повторной попытки.
Правило 3. Охранять слой суммаризации. «Неопределённо» нельзя транскрибировать как результат без проверки, работали ли верификаторы. Встроить крошечный классификатор, который просто читает итоги прогона: если прогон доминируется нулевыми abstain, суммаризация должна говорить «проверка не завершена», а не «утверждения ложны».
Восстановление после сбоя: resume, а не rerun
Худшее, что можно сделать при падении прогона — выбросить всё и начать заново. Это тратит время и токены, а часто повторно натыкается на тот же rate limit. Стратегия: возобновить, а не перезапускать. Трёхшаговый план восстановления:
- Переклассифицировать — прогнать скрипт, который разделит опровергнутые на действительно опровергнутые и те, что просто воздержались.
- Продолжить из кэша — хороший цикл кэширует завершённые стадии. Перезапускаются только воздержавшиеся вызовы верификатора, оплачивается «пробел», а не весь конвейер.
- Догрузить хвост последовательно и аккуратно — тот общий rate limiter, который вызвал сбой, со временем ослабляется. Последовательная догрузка остаётся незаметной.
Практический совет во время восстановления: проверяй существование, прежде чем опровергать. Очень соблазнительно автоматически отклонить цитату, которая выглядит неправдоподобно — например, дата публикации на несколько месяцев в будущем. Но в описанном сбое несколько таких подозрительных цитат оказались реальными early access-статьями при фактической проверке. Не используй молоток, пока не убедился, что объект существует.
Аудит существующих циклов: поиск коррелированных сбоев
Три чек-пункта для быстрой диагностики живых систем. Первый: всё ли упало одновременно? Если да — это коррелированное воздержание (например, единый rate limit), а не реальное массовое отклонение. Второй: если ужесточить rate limit или уменьшить размер батча, падает ли доля сбоев? Если падает — вы измеряете ограничения инфраструктуры, а не корректность агента. Третий: посмотри на корзину «не прошло» — есть ли у каждого элемента доказательства отказа (цитаты опровержения, причина)? Если нет — эти элементы никогда не проверялись. Золотое правило: настоящий отказ может указать, почему он говорит «нет» — противоречащий источник, провал утверждения, явный контрпример. Воздержание не может этого сделать, потому что ничего не произошло. Если ваше «нет» не может показать свою работу — это не «нет». Тишина — недостающие данные, а не опровержение.
Широкий принцип: тратьте inference-бюджет на верификацию
Проблема abst-сбоя вскрывает общий архитектурный принцип. Простое повторение (дать агенту думать дольше или семплировать больше траекторий) — слабый рычаг. Генерация легко обгоняет суждение, и правильный ответ часто уже есть в сэмплах — агент просто не может его выбрать. Верификация — истинное узкое место масштабирования агентов. Вывод: направляйте бюджет inference на разнообразную генерацию плюс сильную независимую внешнюю верификацию. И стройте эту верификацию так, чтобы при неизбежном сбое она честно сказала: «я не проверила», вместо того чтобы врать: «ответ — нет». Этап verify — самое слабое звено во всём цикле, поэтому он заслуживает самого оборонительного дизайна, а не самого слабого.
📜 Transcript
en · 1 775 слов · 22 сегментов · clean
Показать текст транскрипта
All right, pull up a chair. I want to share a bit of a war story with you today. A truly nasty bug that cost me a ton of time, way too many tokens, and honestly, a little bit of trust in my own system design. If you're out there building agent loops that are supposed to check their own work, listen up because you absolutely need to hear this. Welcome to The Explainer. Today, we're diving into the hard-won lessons of building self-correcting agent loops that fail honestly, and even more importantly, how they can actually recover. So look at the sheer confidence of this output. No, seriously, look at it. I had just run a multi-agent research loop over a genuinely difficult question, and it came back with this super clean authoritative verdict. All 25 claims refuted by adversarial verification. Research inconclusive. It sounded exactly like what you'd want a rigorous, skeptical agent to say, right? Well, there was just one massive problem. Every single one of those 25 claims was completely true. Several of them even cited real recent papers that I could easily pull up in another tab. Literally nothing had actually been checked. Here's the kicker. The verifier hadn't actually disagreed with the research at all. It had just crashed. Every single verification call we made had hit a transient API rate limit and returned absolutely nothing. But my loop? It scored that returned nothing as refuted. This is exactly what we call a fail closed gate that simply cannot tell the difference between refuted by evidence and never adjudicated. It'll lie straight to your face with total unearned confidence and dress that lie up as due diligence. I learned this one the hard way, so you don't have to. Here's our postmortem for today. We'll quickly cover the anatomy of agent loops, dive into the rate limit crash itself, introduce the three-state gate, lay out some hard rules for false negatives, talk about how to resume a crashed run, and finally, how to audit your existing loops. Okay, part one, the anatomy of agent loops. Let's make sure we're all speaking the same language here. Regardless of whatever specific framework you're using right now, pretty much every serious agent loop relies on three core roles. First step, the reasoner. This generates your candidate answers. That's your policy. Then you've got one or more verifiers that evaluate those answers, basically acting as the judge or the reward signal. And finally, a refiner that revises everything based on that verifier feedback. Now, sure, all three of these can technically be the exact same model, just wearing different hats, right? But the verify stage... That is your load-bearing component. It's where the loop decides what's actually true enough to keep. And crucially, it is where the invisible failures happen. Think about it. A broken reasoner produces obvious garbage. You'll spot it instantly. But a broken verifier? It produces clean, plausible, and totally wrong verdicts. To put some numbers to this, look at the research from the self-correction bench. They measured a massive 64.5% blind spot rate across 14 different models. What this means is that, yeah, while models can totally fix an error if you manually point it out in the prompt, they systematically fail to notice and fix that exact same error in their own prior output. Agents are just structurally terrible at noticing their own mistakes. Generation easily outruns judgment. Actually, fun fact from that research, just appending the word wait to the prompt cut those blind spots by over 89%. So the capability is in there. It just doesn't fire on its own. you absolutely need strong independent verification all right moving to part two the rate limit crash let's really unpack these invisible failures so the gate that i actually shipped in my failed loop was a two-state gate and you know the rule seemed perfectly reasonable at the time a claim survives if it gets at least two valid votes and fewer than two refutations makes sense right well it quietly assumed that votes actually exist when that api rate limit hit every single vote came back empty. We had zero refutations, sure, but we also had zero valid votes. So the claim didn't survive. Now, refusing to pass an unverified claim with a genuinely good safety instinct. It's classic failing closed, but here is the trap. By safely denying unverified claims, I accidentally dumped all of that silence into the refuted bucket. The summary layer then just laundered that air, turning an infrastructure crash into a confident, research inconclusive. We have completely collapsed a complex three-state world into just two states. Which brings us to part three, the three-state gate. It is time for a new mental model. We need to update our verifier logic to three states immediately so we stop feeding our refiner absolute garbage. First state, confirmed. This means you have a quorum of valid votes. For example, three independent web searches successfully verify a specific date. The action, you keep it. Second state, refuted. you've hit your refute threshold. Say the verifier finds a primary source that directly contradicts the reasoner's claim. The action? You drop it because the evidence actually says no. And third, this is the state everyone forgets, abstained. This means you are below your quorum of valid votes because of a crash, a timeout, a null return, or a rate limit. The action here? You don't know yet. You must rerun, escalate, or surface it as pending. Look, think of it exactly like a CICD pipeline. If your automated code reviewer sub-agent crashes, it hasn't approved or denied your code diff. It just crashed. Silence is not a verdict. Okay, part four, rules to prevent false negatives. Let's lay down some system design laws. I've got three golden rules for you. Rule number one, classify on valid votes first. Before you ever even look at comparing refutations, count how many votes actually ran and parsed successfully. If it's below your quorum, It's an abstention. You never even reach the refute branch of your logic. Rule two. Errors, timeouts, and nulls are abstentions. Period. They are pending retries. Never treat them as a clean pass. And never, ever treat them as refuted. And rule three. Guard the summary layer. You can never transcribe inconclusive as a finding without mathematically checking if the verifiers actually ran. Enforce this with a tiny report-only reclassifier that just reads the tallies of a run. If your run is dominated by zero zero abstentions, your summary needs to say verification did not complete, not the claims are false. Part 5. Resuming crashed agent runs. Listen to me. Whatever you do, do not start over. The absolute worst thing you can possibly do when a run crashes is throw away the whole thing and start from scratch. You're going to waste massive amounts of time, burn through tokens, and honestly, you'll probably just re-trip the exact same rate limit. Your mantra has to be, resume, don't rerun. Here is your three-step recovery plan. Step one, reclassify. Run that tiny script we just talked about to split your refuted pile into what's genuinely refuted versus what just abstained. Step two, resume from cache. A good loop harness caches completed stages. You only rerun the abstained verifier calls. You pay for the gap, not the whole pipeline. Step three, top up the tail manually and gently. Do it sequentially. That shared rate limiter that caused the crash in the first place? It eases up over time. A gentle, serial top-up slips right under the radar. Oh, and a quick piece of advice from the trenches while you're in that recovery phase. Existence check before you refute. When you're manually re-verifying the tail end of a run, it is incredibly tempting to just auto-reject a citation because it looks totally improbable. Like, say, a paper with a publication date a few months in the future. Resist that urge. In my busted run, several of those suspicious future-dated citations resolved to entirely real early access papers when I actually inspected them. So check that the thing exists before you swing the gavel. Finally, part six, auditing your existing loops. Let's go hunting for correlated failures. I want you to run through this quick audit checklist for the loops you're running right now. Check item one. Did everything fail at once? That's a correlated abstention, like hitting a shared rate limit. That is not a real mass rejection. Check item two. If you tighten a rate limit or shrink a batch size, does your failure rate magically drop? If so, you are measuring your infrastructure limits. You're not measuring the correctness of your agent. Check item three. Take a look at your failed bucket. Does it have zero per item evidence? No refuting quote? No reason attached? That means those items were never actually adjudicated. Nothing ran. Let me just reiterate the golden rule of this explainer. An absence of votes is not a vote. A genuine refutation can point at exactly why it's saying no. It'll show you a contradicting source, a failing assertion, a clear counter example. An abstention can't do any of that because nothing actually happened. If your no can't show its work, it isn't a no. Silence is missing data, not a refutation. Zooming all the way out here, this abstention bug reveals a much broader architectural principle about where we should actually be spending our inference budget. Brute repetition, you know, just letting an agent think longer or sampling more trajectories, it's a weak lever. The research clearly shows that generation easily outruns judgment. The right answer is often already sitting right there in your samples. The agent just can't pick it out. Verification is the true binding constraint of agent scaling. So your design conclusion is this. Spend your inference budget on diverse generation plus stronger, independent external verification. And built that verification so that when it inevitably fails, it honestly says, hey, I didn't check, instead of lying to you and saying the answer is no. The verification step is the absolute weakest link in your entire loop, so it deserves the absolute most defensive design, not the least. So I'll leave you with this question to take back to your own code bases today. Is your agent loop actively confirming reality, or is it just silently agreeing with an infrastructure crash? Ensure your systems fail honestly, guys, because honestly, That's the only kind of failure you can actually recover from. Thanks for joining me on this explainer. See you next time.
⚙️ Pipeline jobs
| Stage | Status | Att. | Updated | Error |
|---|---|---|---|---|
| download | done | 1/3 | 2026-07-20 12:05:00 | |
| transcribe | done | 1/3 | 2026-07-20 12:05:56 | |
| summarize | done | 1/3 | 2026-07-20 12:06:24 | |
| embed | done | 1/3 | 2026-07-20 12:06:26 |
📄 Описание YouTube
Показать
A crashed verifier is not a refutation. In this video, I recap my guide on a subtle but dangerous failure mode in self-checking AI agents: when rate limits, timeouts, null responses, or crashed verifier calls get mislabeled as “refuted.” That mistake makes an agent loop look rigorous while it quietly throws away valid results. The fix is simple but load-bearing: Every verification gate needs three states: CONFIRMED REFUTED ABSTAINED If the verifier did not run, did not return evidence, or failed below quorum, the honest result is not “false.” It is “not adjudicated.” This matters for research agents, code-review agents, multi-agent verification loops, AI governance systems, and any generate → verify → refine pipeline. Read the full guide: https://www.danmercede.com/guides/verifier-abstention-not-refutation #AIAgents #LLMEngineering #aigovernance