Degenerate repetition loop: outputs "court" hundreds of times before tool calls

Status Open
Reported on v2.1.196
Maintainer reply None cached
Activity 0 comments · opened Jul 18, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

【不具合】応答が同一トークンの繰り返しループに陥る(degenerate repetition loop)

・症状: 応答の途中で、意味のない単語「court」が数百回連続して出力される。
・発生タイミング: ツール(Bashコマンド等)を呼び出す直前に前置き/説明文を
生成しようとした瞬間。前置きを書かず即ツール呼び出しした回では発生しない。
・頻度: 2026-07-18のセッションで、ツール実行を伴うターンで繰り返し発生。
1回の暴走で数百トークンを浪費。
・モデル: Opus 4.8 と Fable 5 の両方で確認(モデル切替後も再発)。
・環境: Claude Code。
・影響: トークン浪費・課金増・可読性の著しい低下。
・要望: 同一トークンがN回連続した時点で出力を打ち切る暴走検知
(repetition penalty / ウォッチドッグ)を推論層またはハーネス側に入れてほしい。

What Should Happen?

意味のない単語「court」は一切表示されないはず。

Error Messages/Logs

Steps to Reproduce

内容・作業は何でも良い。こちらからメッセージをして、考えて行動に移すときに発生する。

Claude Model

Sonnet (default)

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.196 (Claude Code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗