Caveman Stats

作者 juliusbrussee2e08b9177c07無授權條款110K 個星標收錄於 2026年10月8日更新於 2026年10月8日儲存庫今天更新

Show recorded output and cache-read token usage and mode attribution for the current Claude Code session, or locate the host's native usage report. Trigger: /caveman-stats.

僅含說明Data & Analytics
AI 產生的概覽

回報目前 Claude Code 工作階段中記錄的 token 用量與模式歸屬,或指向宿主原生的用量報告。

功能
此技能會將 Claude Code 的 caveman-mode-tracker 鉤子所提供的用量報告,原樣輸出在圍欄程式碼區塊中,不會自行重新計算數字。報告涵蓋已記錄的輸出 token 與快取讀取 token、回應次數,以及可用時的模式歸屬。在 Gemini CLI 中,它會引導使用者改用內建的 /stats 指令;在其他宿主中則指向原生用量報告,或說明目前工作階段的用量無法取得。它也說明了彙總參數,並指出無法據此推論節省量。
適用情境
當使用者想查看目前 Claude Code 工作階段的 token 用量或模式歸屬時使用。當 Gemini CLI 或其他宿主的使用者詢問工作階段用量統計、需要被指引到原生報告時,也同樣適用。
執行需求
需在已安裝 caveman-mode-tracker 鉤子及其統計指令稿的 Claude Code 中執行;此技能本身不隨附指令稿。Gemini CLI 使用者需要內建的 /stats 指令。未說明需要憑證或網路存取。

In Claude Code, src/hooks/caveman-mode-tracker.js runs src/hooks/caveman-stats.js on /caveman-stats and supplies its report through hookSpecificOutput.additionalContext. Print that report verbatim inside a fenced code block, as the hook instructs. Do not calculate or add numbers yourself.

In Gemini CLI, direct the user to /stats model for current session token usage or /stats session for session statistics. Gemini custom commands are prompts; they cannot invoke the built-in command or read its live session metrics. Never read Claude Code transcripts as Gemini usage. In other hosts, use a native usage report if one is available; otherwise say that current session usage is unavailable. The Claude reader and its lifetime history apply only to Claude Code. Savings remain unknown in every host without a measured comparison.

The report shows recorded output and cache-read tokens, response counts, and mode attribution where available. Savings are unknown: the transcript has no measured comparison without Caveman. Do not infer saved tokens, percentages, dollars, rule overhead, or a net result from output counts or the current mode.

--all and --since 7d aggregate the latest recorded output count per session. --share reports observed usage with savings unknown. Historical est_saved_* fields are ignored; their original history rows remain on disk. The statusline shows the active mode without the retired savings badge.

Original/current memory-file pairs are reported by their measured byte sizes. Those file-size differences do not establish provider token or billing savings. See docs/HONEST-NUMBERS.md.

來源與署名

來源:juliusbrussee/caveman位於plugins/caveman/skills/caveman-stats提交2e08b91

授權條款: 無授權條款

內容歸原作者所有。SourceWeft 從公開儲存庫中收錄這些內容。

檢舉或申請下架