Shortening agent prompts broke semantic testing: keyword checks missed a P0-to-P1 rule change

Dinu_Dev · reddit · 2026-10-08

A developer shortened their coding-agent instructions and found their keyword-based coverage test passed four deliberately altered versions — one changed "stop only for P0" to "stop only for P1" — showing keyword checks can't catch meaning changes.

Their current fix: verify 15 required sentences verbatim and test intentionally corrupted copies, which caught those cases. But exact-text checks can't tell whether a shorter paraphrase preserves meaning.

They're asking the community for small behavior-based tests that catch a changed rule without rejecting every harmless rewording.

Original post →

More from coding & agent

coding & agent channel →