cost-ledger
하는 일
이 스킬은 AI 코딩 도구가 컴퓨터에 이미 남겨 둔 사용 로그를 읽고, 제공자별 지출과 토큰, 캐시 사용량을 보여 줍니다. 여러 AI 도구를 쓰면서 한 화면에서 보고 싶은 사람을 위한 스킬입니다.
사용하는 경우
- ✓이번 주에 AI 도구에 얼마를 썼는지 묻고 싶을 때.
- ✓Codex와 Claude Code의 비용을 비교하고 싶을 때.
- ✓아직 가격이 없는 모델이 무엇인지 확인하고 싶을 때.
스킬 링크
https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-cost-tracker/skills/cost-ledger/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“이번 주에 모든 제공자에서 AI 코딩 도구에 얼마를 썼는지 알려 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
스킬은 로컬 로그를 읽고, 날짜가 적힌 가격표로 사용량에 값을 매겨 합계를 보여 줍니다. 가격이 없는 모델은 무료로 세지 않고 따로 나열합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
Cost Ledger
Reads the logs the agents already wrote (~/.claude/projects, $CODEX_HOME or ~/.codex) and prices them from data/prices.json (dated, editable).
Run
node ${CLAUDE_PLUGIN_ROOT}/scripts/ledger.mjs --since 7d
node ${CLAUDE_PLUGIN_ROOT}/scripts/ledger.mjs --provider codex --format json
One mission, or one project
--from and --to (ISO times) cut the window and --project <absolute path> keeps one project's rows; the console's mission page uses them for a mission's spend. An explicit --from/--to replaces the default 7-day look-back.
Read the result correctly
- USD and Codex credits are never added. GPT-6 Codex models are priced in credits; their cached-input rate is unpublished, so the figure is an upper bound.
- Estimates at list price, not bills. Subscriptions bill by window, not by token.
/usageis authoritative for the live Claude session; the Console or provider dashboard is authoritative for invoices. - Unpriced models are listed, never counted as $0. Say so, and offer to add them to
data/prices.json. - Counting rules (why numbers differ from naive sums): Claude messages are de-duplicated by
message.id + requestId; Codex uses deltas of the runningtotal_token_usage(never alsolast_token_usage), cached input is a subset of input, and forked rollouts are de-duplicated. - Claude transcript output tokens can under-count streamed output.
If the log directory is missing, say so; do not invent numbers.
자주 묻는 질문
데이터가 어디로 전송되나요?
스킬은 로컬 로그만 사용하며 아무것도 전송하지 않습니다. 비용은 청구서가 아니라 정가 기준의 추정치입니다.
달러와 크레딧 합계가 맞지 않는 이유는 무엇인가요?
Codex 크레딧과 미국 달러는 서로 다른 단위이므로 절대 합치지 않습니다.
한 프로젝트만 볼 수 있나요?
네. 프로젝트 설정으로 특정 프로젝트 폴더만 집계할 수 있고, 기간도 지정할 수 있습니다.
상세 정보
작성자의 원본 설명
One cost view across Claude Code, Codex and Grok on this machine — spend, tokens, cache hit ratio per provider and model, with unpriced models flagged. Use when asked "what did I spend", "how much did Codex cost", or to compare providers. Local logs only, nothing is sent.
repo: ruvnet/ruflo
인기도
- GitHub 스타
- 81k
- 순위
- #1603
- 라이선스
- MIT
- 업데이트
- 2026. 11. 2.
댓글
- …
이 저장소의 다른 스킬
agent-adaptive-coordinator
81k작업량이 바뀔 때 에이전트 무리를 나누고 재배치해, 작업에 맞는 배치를 고르도록 에이전트를 돕습니다.
agent-agent
81k큰 목표를 순서가 있는 행동 계획으로 나누고, 조건이 바뀌면 다시 계획하도록 에이전트를 가르칩니다.
agent-agentic-payments
81kAI 쇼핑을 위한 지출 위임장을 관리합니다. 지출 상한, 시간 창, 판매자 규칙, 서명된 승인을 포함합니다.
agent-analyze-code-quality
81k에이전트가 파일을 바꾸지 않고, 코드 품질 문제와 코드 냄새, 기술 부채, 리팩터링 아이디어를 찾아 검토하도록 돕습니다.