C.W.K.
Stream
Lesson 08 of 10 · published

Pricing과 rate limit — 진짜 숫자

~12 min · providers, pricing

Level 0수련생
0 XP0/100 lessons0/14 achievements
0/120 XP to next level120 XP to go0% complete

숫자 움직이고; 구조 stable

Pricing 변화; rate limit 변화; category 안 변해. 각 provider 갖춰: input 토큰, output 토큰, cached input 토큰, image 토큰, audio 토큰, reasoning 토큰 — 각자 자기 청구서. Rate limit이 RPM (requests per minute), TPM (tokens per minute), 모델당 concurrency cap으로 존재.

Cost intuition (quote 전 라이브 숫자 체크)

  • Top-tier (Opus / GPT-5.5 / Gemini 2.5 Pro)가 input에 output보다 약 5–15× cheaper, reasoning 토큰 별도 billed.
  • Mid-tier (Sonnet / GPT-5.5-mini / Gemini Flash)가 비슷한 throughput에 top-tier보다 보통 3–10× cheaper.
  • Cached input이 normal input의 5–25%.
  • Open-source per-call이 amortized compute; 청구서가 utilization에서, per-token rate 아니라.

Rate limit trap

  • Burst pattern이 TPM 다 쓰기 전에 RPM limit hit. Traffic smooth.
  • Long-context call이 throughput 제시하는 것보다 빨리 TPM budget 먹어.
  • 일부 provider가 top-tier 모델을 tier-up requirement 뒤에 gate.

Code

Cost monitor (sketch)·python
from collections import defaultdict

buckets = defaultdict(int)
for resp in stream_recent_responses():
    buckets[(resp.provider, resp.model, "input")] += resp.usage.input_tokens
    buckets[(resp.provider, resp.model, "output")] += resp.usage.output_tokens
    if resp.usage.cache_read_input_tokens:
        buckets[(resp.provider, resp.model, "cache_read")] += resp.usage.cache_read_input_tokens
    if resp.usage.thinking_tokens:
        buckets[(resp.provider, resp.model, "thinking")] += resp.usage.thinking_tokens

External links

Exercise

한 prompt의 지난주 traffic pull. category (input, output, cached, thinking)로 토큰 break out. 가장 큰 bucket과 줄일 실험 하나 식별.

Progress

Progress is local-only — sign in to sync across devices.
이 페이지에서 버그를 발견하셨거나 피드백이 있으세요?문제 신고

댓글 0

🔔 답글 알림 (로그인 필요)
로그인댓글을 남기려면 로그인해 주세요.

아직 댓글이 없어요. 첫 댓글을 남겨보세요.