Replies: 1 comment
|
Measured this report against the harness, and there is a real gap here — plus one thing that now fires on it. What the harness does today for shape A/BYour suggestion #1 (detect repetition while generating) maps onto exactly one extension point in this codebase: the I maintain the community plugin that uses that seam (
The breaker counted identical deltas against a threshold of 60, and a cycle resets that counter on every phase change. Under no chunking did it reach the threshold. That is the bug you found, expressed precisely: a delta-level rule cannot see a period-k cycle, and your shape B (with What now fires on itReleased today as # cordis.patch.yml — or mount it in your profile
- insert:
- id: thinking-loop-guard
name: '@argszero/cordis-plugin-thinking-loop-guard'On your two shapes it fires after ~256–270 characters instead of never — i.e. after ~20 cycles, not after the screen has filled. Your periods are short (12 and 26 characters), and because the period is measured in characters it does not matter whether the bleed arrives with line breaks or not: a provider that streams it as one blob is caught identically. Why not an n-gram repeat rateYou proposed "n-gram repetition rate over the generated text"; I built that first, measured it, and dropped it. This plugin already has that measure (fixed-length gram coverage, language-agnostic, written for CJK) and here is what it reads on a 512-character tail:
The separation between "degenerate" and "legitimately repetitive" is ~0.06, which is not a margin I am willing to truncate someone's call over — a model legitimately dumping a table or a JSON array is in that band. Exact verbatim periodicity instead reads 0 for all six healthy samples and non-zero only for the loop. One extra guard: the period must contain at least two distinct characters, so a long What you can run on your own sessionThe plugin ships an offline analyzer that replays a session file through the same detector, so you can answer "would the breaker have cut this call?" on the session that produced this report instead of reproducing the failure: npm install @argszero/cordis-plugin-thinking-loop-guard@0.1.8 # next to your dsh packages: it uses their types at runtime
node node_modules/@argszero/cordis-plugin-thinking-loop-guard/tools/analyze-session.mjs <session.jsonl>Both durable attempt formats are read (v1
What is still not covered
For the record, two of your observations are independently confirmed by the harness sources: degeneration is a long-context phenomenon rather than input-triggered (both this and discussion #2848, a ~420,000-character single-call bleed, appeared under large contexts), and your "it looks like it stopped" reading is the expected user-visible symptom — the model keeps generating, so the failure surfaces as a turn that neither finishes nor calls a tool. Disclosure: I am the author of that plugin — it is a community package (independent repo and npm scope), not part of the harness, so treat the claims above as mine to defend; the measurements are reproducible from the plugin's test suite. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
摘要
在长会话中,助手输出会突然开始重复同一段无意义短文本,持续数十行,把真正的回答(通常是工具调用)完全挤掉。用户侧看到的表现是「卡住」或「无故停止」。官方仓库关闭了 Issues,所以按 Ideas 分类发在这里。
现象(完整记录)
重复的形态
同一段文本在一轮内被连续输出几十次。观察到的两种形态:
形态 A(纯中文短句):
形态 B(中英混合,说明重复会跨越语言/段落边界):
这些内容没有任何语义 —— 正常情况下,那个位置应该是一个直接的工具调用(读文件 / 改文件 / 跑命令)。
出现频率(本次会话的观察)
明显的正相关:会话越长,越容易触发,且一旦开始就很难在同一轮内自行恢复。
伴随的输出质量下降
出现退化之后,工具调用的参数不再可靠。具体一次:
用户侧的实际感受
用户的原话(按时间顺序):
即:在用户看来助手是在任务中途停止响应。实际上助手一直在生成,只是生成的全是重复片段,真实输出被挤没了。
环境
0.1.5-rc.2(Windows 10/11)deepseek-flash我观察到的可能相关因素
只陈述相关性,不下结论:
不是由某个具体输入触发的:同一类操作在前期完全正常,后期同一种操作开始退化。所以给不出最小复现步骤。
建议(如果 harness 层有余地)
现在每次都要"等它把重复刷满"才停,浪费了大量 token 和时间 —— 这是最实际的改进点。
对"整体替换文件"这类高风险操作做一层内容长度/结构突变检测会有帮助。
我们这边的规避方法(供遇到同样问题的人参考)
说明:本报告由助手根据一次真实会话整理。发布前已剔除一切与现象无关的私人信息(账户余额、含用户名的绝对路径、身份标识、密钥与配置片段)。
All reactions