test(config-audit): add Opus 4.7 pattern fixtures (cache, redundant, imports, sonnet-era)
This commit is contained in:
parent
350cebc39c
commit
94ce70186c
11 changed files with 255 additions and 0 deletions
47
plugins/config-audit/tests/fixtures/opus-47/cache-breaking/CLAUDE.md
vendored
Normal file
47
plugins/config-audit/tests/fixtures/opus-47/cache-breaking/CLAUDE.md
vendored
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
# Cache-Breaking Volatile Top
|
||||
|
||||
> Last Run: {timestamp} — volatile placeholder that changes on every invocation
|
||||
> Session: {uuid} — another volatile field
|
||||
> Now: {date}
|
||||
|
||||
## Recent Activity
|
||||
|
||||
- 2026-04-19T12:00:00Z — User A edited file X
|
||||
- 2026-04-19T11:45:00Z — User B pushed commit Y
|
||||
- 2026-04-19T11:30:00Z — CI run Z completed
|
||||
- 2026-04-19T11:15:00Z — Review comment added
|
||||
- 2026-04-19T11:00:00Z — Deployment triggered
|
||||
- 2026-04-19T10:45:00Z — Log rotation ran
|
||||
- 2026-04-19T10:30:00Z — Backup verified
|
||||
- 2026-04-19T10:15:00Z — Cache cleared
|
||||
- 2026-04-19T10:00:00Z — Session started
|
||||
|
||||
## Current State
|
||||
|
||||
The status widget above renews on every turn, pushing the stable-prefix
|
||||
content further down the file. Under Opus 4.7 prompt caching, any change
|
||||
within the first block invalidates the cache-prefix, forcing a full
|
||||
recomputation each turn and inflating token cost per session.
|
||||
|
||||
## Stable Content (cache target)
|
||||
|
||||
Below this line is content that rarely changes — the project overview,
|
||||
conventions, and shared rules. But because the volatile header sits ABOVE
|
||||
this stable section, it cannot benefit from caching.
|
||||
|
||||
## Project Overview
|
||||
|
||||
A fixture designed to trip the Opus 4.7 TOK scanner's cache-breaking
|
||||
detector (CA-TOK-001). The first 30 lines contain volatile-looking
|
||||
patterns (timestamps, session ids, running activity logs) that would
|
||||
break prompt-cache reuse on every turn.
|
||||
|
||||
## Commands
|
||||
|
||||
- `npm run build`
|
||||
- `npm test`
|
||||
|
||||
## Conventions
|
||||
|
||||
- Conventional Commits
|
||||
- TypeScript strict
|
||||
Loading…
Add table
Add a link
Reference in a new issue