cache-miss.sequence — Claude Code prompt: what it does, how to install
cache-miss.sequence drives the Archify skill to build a sequence diagram for a dashboard request that misses cache in Redis and falls through to PostgreSQL.
Apache-2.0 ★ 98,599 updated 2026-10-25
.claude/commands/cache-miss.sequence.mdWhat cache-miss.sequence does
The prompt lays out a scenario where a browser hits an API, the API checks a JWT and reads Redis. On a cache miss, the API queries PostgreSQL for profile and metric data, writes the result back to Redis, emits a trace, and sends JSON back to the browser. The agent has to pick its own internal IDs and layout rather than reusing any example already checked into the repository.
The output is a typed JSON diagram specification built for the showcase quality profile, keeping message direction intact and separating calls, returns, security checks, and the asynchronous trace emission. When shell access is available, the agent runs the bundled Archify CLI to validate and repair the draft before freezing it; an external harness checks the frozen candidate independently.
The prompt requires writing the result to exactly benchmark-candidate.json in the repository root and touching no other file, since that file counts as the submission, not the chat reply. It also tells the agent not to claim validation passed.
What it helps with
- model a request sequence that hits cache and falls through to a database
- diagram a Redis cache-miss path into PostgreSQL
- produce a typed diagram spec for the showcase quality profile
- validate and repair a diagram draft with the Archify CLI
- freeze a diagram candidate into a fixed file for external checking
Example prompts for the agent
- Use the Archify skill to build a sequence diagram for a dashboard request with a Redis cache miss
- Produce a showcase-profile JSON diagram spec and save it as benchmark-candidate.json
- Run the Archify CLI to validate and repair the diagram candidate before writing the file
How to install cache-miss.sequence
Manually: put the files in place
.claude/commands/cache-miss.sequence.mdHow to use
Paste the text at the start of a chat or into project instructions
Questions about cache-miss.sequence
How do I install cache-miss.sequence in Claude Code?
Drop the prompt file at .claude/commands/cache-miss.sequence.md.
What does cache-miss.sequence do?
It directs the agent to use the Archify skill for drawing a sequence diagram of a dashboard request that checks a JWT, misses Redis cache, and queries PostgreSQL, then save the result to benchmark-candidate.json.
Why can't the agent reuse a checked-in example diagram?
The prompt explicitly forbids copying an existing example from the repository; the agent must generate its own IDs and layout or the submission does not count.
Source text
cache-miss.sequence.md · Apache-2.0
# Cache-miss request sequence Use the Archify skill in this repository to create a sequence diagram for a dashboard request. A browser calls an API, the API validates the JWT, then reads Redis. Redis returns a cache miss, so the API queries PostgreSQL for profile and metric data, stores the result back in Redis, emits a trace, and returns JSON for the browser to render. Author a fresh typed JSON diagram specification targeting the `showcase` quality profile. Choose your own stable internal IDs and layout. Preserve message direction and distinguish calls, returns, security checks, and asynchronous trace emission. Use the bundled Archify CLI to validate and repair the candidate when shell access is available. The external harness will independently validate the frozen candidate. Write the final candidate to exactly `benchmark-candidate.json` in the repository root. Do not edit any other file. The candidate file, not the prose response, is the attempt 1 artifact. Do not copy a checked-in example. Do not claim that validation passed.
© tt-a1i · Apache-2.0 · tt-a1i/archify