본문으로 건너뛰기
Skillpedia
기타81k · #1607

cost-projection

하는 일

이 스킬은 최근 하루 평균 지출을 바탕으로 앞으로의 AI 지출을 예측합니다. 예산을 세우면서 언제 돈이 떨어질지 미리 알고 싶은 사람을 위한 스킬입니다.

사용하는 경우

  • ✓다음 달이나 내년 AI 지출이 얼마일지 알고 싶을 때.
  • ✓예산이 얼마나 오래 갈지 계획할 때.
  • ✓예산이 다 쓰이기 전에 미리 경고를 받고 싶을 때.

스킬 링크

https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-cost-tracker/skills/cost-projection/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-cost-tracker/skills/cost-projection/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“지금 속도라면 AI 예산이 언제 바닥나는지 알려 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

스킬은 최근 기간의 일평균 지출을 계산하고, 이를 각 기간까지 일정하게 늘려 봅니다. 예산이 설정되어 있으면 예산의 각 비율이 소진되기까지 남은 일수도 보여 줍니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Forward-looking cost projection that pairs with cost-budget-check:

  • cost-budget-check answers "have we crossed the line?" — reactive
  • cost-projection answers "when will we cross the line?" — predictive

Algorithm

  1. Read all session-* records from the cost-tracking namespace (same source cost-budget-check uses).
  2. Filter to a measurement window (default last 7 days on capturedAt/startedAt).
  3. Compute the per-day burn rate: windowSpend / windowDays.
  4. Linear-extrapolate to each requested horizon (default 7d/30d/90d/365d).
  5. If a budget is configured (budget-config key set by cost-budget set):
    • Compute "days until 75% / 90% / 100% consumed" at the current rate.
    • Surface as a separate table block with ALREADY REACHED markers for thresholds already exceeded.

Flags

--window <duration> Measurement window. Nh|Nd|Nw|Nm. Default 7d. --horizons <csv> Projection horizons. Default 7d,30d,90d,365d. --format table|json Default table (markdown).

Env: PROJECTION_NAMESPACE override (default cost-tracking), PROJECTION_QUIET=1 (alias for --format json).

Smoke transcript (3 sessions × $1 over 7d, $20 budget)

| Sessions in window | 3 |
| Window spend | $3.000000 |
| **USD per day** | **$0.428571** |
| All-time spend | $3.000000 across 3 sessions |

## Projected spend (linear extrapolation)
| Horizon | Days | Projected spend |
|---|---:|---:|
| 7d | 7 | $3.0000 |
| 30d | 30 | $12.8571 |

## Budget exhaustion ($20.00 configured)
| Threshold | Target | Remaining | Time at current rate |
|---|---:|---:|---|
| 75% | $15.00 | $12.00 | 28.0 days |
| 90% | $18.00 | $15.00 | 35.0 days |
| 100% | $20.00 | $17.00 | 39.7 days |

When to use

  • Finance / SRE planning: hand the JSON output to a budget dashboard for "are we on track for the quarter?".
  • CI gates: cost-projection --format json | jq '.budget.exhaustion[2].daysUntilReached < 7' → fail builds when 100% exhaustion is < 1 week away.
  • Post-workload-shift sanity check: after a big feature lands, re-run to verify the rate hasn't accelerated past expectations.

Stationarity assumption

Linear extrapolation assumes the current rate holds. The footer reminds operators to re-run after workload shifts. For drift detection over MULTIPLE windows, pair with cost-trend (which already covers benchmark-drift).

자주 묻는 질문

예측이 정확한가요?

아닙니다. 최근 사용량을 바탕으로 한 단순한 직선 추정이므로 사용량이 바뀌면 결과도 달라집니다.

어떤 기간을 볼 수 있나요?

기본값은 7일, 30일, 90일, 365일이며, 다른 기간도 고를 수 있습니다.

이미 도달했다는 뜻은 무엇인가요?

현재 데이터가 이미 넘어선 예산 기준점을 나타냅니다.

상세 정보

작성자의 원본 설명

Forward-looking spend extrapolation. Computes a USD-per-day rate from the recent measurement window, projects to 7d/30d/90d/365d horizons, and surfaces "days until budget exhausted" when a budget is configured. Predictive counterpart to `cost-budget-check` (reactive).

repo: ruvnet/ruflo

인기도

GitHub 스타
81k
순위
#1607
라이선스
MIT
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬