Model Meter — AI cost tracking

Architecture

Why LLM Proxies Break Cost Attribution

Proxy-based tools like Helicone sit in the critical path of your AI calls. Here's what that costs you, and why OpenTelemetry instrumentation is a better approach for cost tracking.

All posts
Model Meter Team8 min read
architecture, helicone, proxy, opentelemetry, cost-attribution

The proxy model

Helicone, Portkey, and similar tools work by sitting between your application and the LLM provider. Every API call is routed through their servers, logged, and forwarded. This gives them request/response visibility — but at a cost.

When a proxy sits in the call path, it becomes a single point of failure, adds latency, and stores your prompts and completions on infrastructure you don't control.

Why proxies break attribution

Cost attribution requires knowing which internal feature or project generated each request. A proxy sees the raw API call. It sees tokens, model name, and latency, but it doesn't know if that call came from your billing service, your support bot, or your dev environment.

Proxies solve this by requiring you to tag requests manually with headers or metadata. It works, but it's brittle. Change a header name, forget to tag a call, or route through a different client, and the attribution silently breaks.

And if your AI calls must go through a third-party proxy to be tracked, you've introduced a hard dependency in your most critical path.

The OpenTelemetry alternative

Model Meter uses OpenTelemetry instrumentation instead of a proxy. The SDK hooks into gen_ai.* spans emitted by the Vercel AI SDK (or any OTel-compatible provider) and sends telemetry to Model Meter asynchronously — completely separate from the AI call itself.

The key differences:

  • No proxy in the call path. Your AI requests go directly to the provider, so tracking adds no latency and introduces no new failure point.
  • No prompts stored. We only capture metadata: model, tokens, latency, cost estimate, project, and operation label. Prompt and completion text never leave your infrastructure.
  • Attribution by code, not config. projectId and operation are set in the SDK init() call or the modelMeter option on individual calls. They live in your codebase, not a routing configuration.

When a proxy is still the right call

Proxies make sense when you need features Model Meter doesn't provide: request/response logging and inspection, semantic caching, prompt routing, or PII redaction at the network layer. If those are your requirements, Helicone or LiteLLM may be the right tool.

Model Meter is deliberately focused: cost visibility and attribution without the proxy tradeoff. If you need full observability (prompt inspection, trace debugging), use a proxy or LangSmith alongside Model Meter.

The bottom line

If your primary need is knowing which project or feature is spending your AI budget, a proxy is unnecessary overhead. OpenTelemetry instrumentation gets you the same attribution data without the critical-path dependency.

Model Meter on GitHub → · Read the architecture docs →

Launch offer

Lock in the best launch pricing.

Join the Waitlist