Products

LensAI

See latency, cost, tokens, errors, and volume across models and agents. LensAI is the observe layer of the control plane — fleet SLOs and cost attribution, not a replacement for your APM.

When to use

  • You need p50/p95/p99 and $/task by tenant, agent, and model
  • Finance and platform must share one cost number
  • You want anomaly feeds that jump to TraceForge via trace_id

Ingest path

eBPF tracer  or  HTTP/SDK events
        ↓
  streaming ingest :8080
        ↓
     Redpanda
        ↓
    ClickHouse
        ↓
  Grafana :3000   ← dashboards
  Inferix :4000   ← /v1/observe/metrics query

Control plane API stays on :4000. Do not point chat clients at ingest or Grafana ports. Streaming stack: infra-ai-streaming; eBPF: ebpf-llm-tracer.

Required labels

LabelWhy
tenant_idCost attribution; reject if missing
model_idModel mix and SLO by revision
trace_idJoin spike → TraceForge waterfall
agent_idPer-agent burn and errors
envKeep chaos/shadow out of prod SLO

Core metrics

  • lensai.latency.p50/p95/p99 — inference latency (ms)
  • lensai.tokens.input/output — finalize streams or under-count
  • lensai.cost.usd / cost.per_successful_task
  • lensai.errors.timeout, provider_5xx, rate_limit.429s
  • lensai.ingest.lag_ms, cardinality.active_series

Operator failure modes

IDProblemNext action
L08Missing tenant_id → unattributed costReject unlabeled at ingest
L09Token under-count on streamsHook stream-end events
L12HTTP 200 with empty bodyTreat empty as error class
L13429 thrash burns retry costRespect Retry-After; jitter
L20Fallback to strong model spikes billBudget caps in RouteIQ
L23Cannot jump spike → traceRequire trace_id on events
L01Cardinality explosionDrop high-churn labels; aggregate
L18Sampling hides rare errorsAlways sample errors + slow

Config knobs

observe:
  lensai: true
  sample_rate: 1.0          # spans only; metrics stay full
  require_tenant_id: true
  redact_pii: true

Source

https://github.com/AkshantVats/lensai-integration

Spans, tool taxonomy, business success.

TraceForge →