Rice Patrol: DSH Inference Loop Detection and Automatic Recovery
Rice Patrol is a DSH plugin (admin-security) maintained by LeeLizuoLiu. Version 0.2.11-desktopcompat.1 requires DSH ≥0.2.0-rc.2. It inspects the last 50 lines of inference text for median line length and 70% repetitive line detection; upon secondary confirmation, it halts generation and resumes within the original Agent session by excluding interrupted inference while preserving tool and edit results. Once enabled, no Stop/Observe/Recover modes are required; it supports configuration for model filtering, state directory, and resumeTimeoutMs (defaulting to 5 minutes). Installation and activation are performed on the Plugins page, and a DSH restart is required after upgrading. Licensed under MIT; source code available on GitHub.
Read More