一键导入
cache-report
Use when the user asks about cache hit rate, token usage, or prompt-caching stats. Do NOT use for runtime cache configuration.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when the user asks about cache hit rate, token usage, or prompt-caching stats. Do NOT use for runtime cache configuration.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | cache-report |
| author | christina |
| skill-type | technique-skill |
| description | Use when the user asks about cache hit rate, token usage, or prompt-caching stats. Do NOT use for runtime cache configuration. |
| disable-model-invocation | true |
Display the prompt-cache hit-rate and token-usage report for the current or a specified session. The slash-command body is the technique; the contract data below routes user phrasing to it.
technique_skill:
_schema_version: "1"
trigger_model: user-only
identity: Display the prompt-cache hit-rate report for the current or a specified session.
scope:
covers:
- cache hit rate questions
- token usage questions
- prompt-caching stats requests
- per-request cost breakdown requests
excludes:
- runtime cache configuration changes
- cache invalidation policy decisions
techniques:
- id: show_cache_report
name: Show cache report
keywords: [cache hit rate, cache report, token usage, prompt caching stats, session cache, cache breakdown, cache costs, /cache-report]
goal: Render the cache_report.py output verbatim, in the user's chat.
arguments:
- name: SESSION_ID
required: false
description: Specific session to report on; omit for current.
- name: "--all"
required: false
description: Report across all sessions.
- name: "--detailed"
required: false
description: Include per-request breakdown.
steps:
- n: 1
action: Invoke ${CLAUDE_PLUGIN_ROOT}/scripts/cache_report.py with $ARGUMENTS.
tool: uv run python
expected: stdout containing the cache hit-rate, token usage, and (if --detailed) per-request breakdown.
on_failure: If the script is missing at ${CLAUDE_PLUGIN_ROOT}/scripts/cache_report.py, surface the error to the user verbatim. Do not improvise the script path.
- n: 2
action: Display the script's stdout verbatim in the user's chat. Do not summarize, paraphrase, or omit any lines.
output_template: |
Display the script's stdout verbatim. Do not summarize, paraphrase, or omit any lines.
gotchas:
- The slash command resolves the script via ${CLAUDE_PLUGIN_ROOT}, which Claude Code expands to the plugin's install path at runtime. If the script is missing there, the invocation fails -- surface the error to the user, do not improvise the path.
Display the report output below verbatim. Do not summarize, paraphrase, or omit any lines. Show the complete report exactly as produced by the script.
!uv run python "${CLAUDE_PLUGIN_ROOT}/scripts/cache_report.py" $ARGUMENTS
To see all sessions: run uv run python "${CLAUDE_PLUGIN_ROOT}/scripts/cache_report.py" --all
To see a specific session: run uv run python "${CLAUDE_PLUGIN_ROOT}/scripts/cache_report.py" SESSION_ID
To include per-request breakdown: run uv run python "${CLAUDE_PLUGIN_ROOT}/scripts/cache_report.py" --detailed
Use when creating, listing, working, closing, archiving, or moving task folders and task_list refs. Do NOT use for native TaskCreate/TodoWrite or code review.
Use when interpreting SessionStart bootstrap messages or configuring user/project dependency manifests. Do NOT use for non-bootstrap debugging.
Use when md-audit dispatches a CLAUDE.md audit against the cohesion framework; fans multi-file runs via the Workflow tool. Do NOT use for SKILL.md.
Use when md-authoring dispatches authoring a CLAUDE.md -- a valid claude_md block (scope, insights). Do NOT use for SKILL.md (use skill-authoring).
Use when deciding where a fact should live across CLAUDE.md / SKILL.md / references (placement). Do NOT use for content shape (use md-authoring).
Use when authoring or refining an md artifact -- a SKILL.md or a CLAUDE.md -- or via /md-authoring. Do NOT use for auditing (use md-audit).