A trace explains what happened. An evaluation tells you whether it met the expectation. Lens keeps both connected so production evidence can inform the next release.

The feedback loop for
production agents.

Operational signals, repeatable evaluation, and release decisions stay connected to the runs that produced them.

End-to-end traces

Follow model calls, tools, errors, latency, and usage through the complete run that produced them.

Comparable evaluation

Keep suite, case, metric, release, dataset version, and trace identity together as one evaluation run.

Evidence-backed gates

Compare a candidate with its baseline and make regressions visible before they reach production.

Self-hosted control

Send native Anvia telemetry or supported OTLP traces to infrastructure and storage your team operates.

Turn one run into
the next decision.

Start with what happened in production, diagnose the behavior, measure the candidate on stable cases, then let an explicit gate carry the evidence into release review.

  1. 01

    Trace

    Capture the agent, model, tool, release, latency, and usage involved in one production run.

  2. 02

    Diagnose

    Move from an alert or regression into the exact span, input boundary, and failure that changed.

  3. 03

    Evaluate

    Replay stable cases against a published dataset version and correlate every result to its trace.

  4. 04

    Gate

    Compare the candidate with its baseline, apply thresholds, and ship only with evidence.

Overview, trace detail,
and the release gate.

Move between the operating picture, a failed production trace, and its candidate comparison. The preview keeps the evidence connected just as the real workflow does.

https://lens.local/production-agents

Production AgentsOverview

Overview

448 spans · 4 active users in this window

Total tokens205K+1,342.3% vs previous period
Total cost$0.6174+1,283.3% vs previous period
Tokens / generation1,066+32.4% vs previous period
Active models4+33.3% vs previous period
Traces64+2,033.3% vs previous period
Error rate10.9%+30.9% vs previous period
P95 generation duration1.78s+10.8% vs previous period
Active sessions22+1,000.0% vs previous period

Token usage

  • Input tokens
  • Output tokens
07 PM11 PM03 AM07 AM11 AM03 PM06 PM

Throughput and errors

  • Generations
  • Traces
  • Errors
07 PM11 PM03 AM07 AM11 AM03 PM06 PM

Generation duration

  • P50
  • P95
07 PM11 PM03 AM07 AM11 AM03 PM06 PM

Tokens by model

  • Total tokens

Model efficiency

ModelGensShareInputOutputTotalTok/genP95Err
gemini-2.0-flash9241%47.1K37K84.1K9140.84s4.2%
gpt-4o3829%33.3K26.2K59.5K1,5642.41s8.1%
gpt-4o-mini5018%20.7K16.2K36.9K7381.12s12.4%
claude-3-sonnet-41212%13.8K10.8K24.6K2,0502.88s16.7%

Services

ServiceTracesGensTokensP95Err
customer-support-agent288694.3K3.12s9.4%
billing-copilot144059.4K1.96s6.1%
research-agent113330.8K4.80s14.2%
docs-qa113320.5K1.44s13.0%

A score describes a case.
A gate informs a release.

Lens groups the suite, immutable dataset version, metric direction, usage, outcomes, and trace references as one candidate that can be compared and gated.

Candidate 2026.08.18Blocked
Candidate

support-agent@1.4.0-candidate.2

Dataset support-regression@v12 · 48 cases · 192 metric results

Passed
46
Failed
2
Eval usage
184k
MetricBaselineCandidateDelta
Answer relevancyHigher is better0.910.94+0.03pass
FaithfulnessHigher is better0.960.90−0.06fail
HallucinationLower is better0.040.07+0.03fail
Turn relevancyHigher is better0.880.90+0.02pass

Observe the agent.
Flush the evidence.

@anvia/lens creates isolated telemetry providers, attaches to the runtime you already own, and exports correlated traces over OTLP HTTP with project-scoped credentials.

Read the Lens adapter guide
agent.ts
1import { Agent } from '@anvia/core'2import { LensClient } from '@anvia/lens'34const lens = new LensClient()5const tracing = lens.observer({ captureMode: 'safe' })67const agent = new Agent({8  id: 'support',9  model,10  observability: { observers: { tracing } },11})1213await agent.generate({ prompt: 'Summarize this ticket.' })14await lens.flush()15await lens.close()

Useful by default.
Explicit when sensitive.

Safe capture exports operational metadata without input or output bodies. Full payloads remain opt-in; redaction and size limits are configurable and governed by your application.

01 / APPLICATION

Your runtime

Defines the agent, release policy, credentials, and which environments or data classes may include payloads.

AUTHORIZE + CONFIGURE
02 / @ANVIA/LENS

Isolated adapter

No global provider takeover. Payload capture is off until explicitly enabled.

metadata onlyredactionsize limits

Operational traces

Agent, model, tool, environment, release, latency, usage, and errors.

Evaluation evidence

Run lifecycle, cases, metrics, outcomes, usage, and direct trace references.

Storage you operate

Project-scoped ingestion into the self-hosted Lens control plane.

Start with the signal.
End with the cause.

Three repeatable paths from an operational or quality signal to the run-level evidence needed to act.

01 / LATENCY

Find a latency regression

Compare P95 by release and service, open the slow cohort, then inspect the model and tool spans consuming the budget.

P95 alert → release cohort → slow trace → span timing
release contexttrace timing
Investigate traces
02 / TOOLS

Explain a tool-failure cluster

Group errors by service and tool, follow one representative run, and separate bad input from permissions, retries, or provider failure.

error cluster → tool span → run context → root cause
tool eventserror context
Explore observability
03 / QUALITY

Resolve a failed quality gate

Open the candidate comparison, inspect the failing cases, jump to their traces, then rerun the same published dataset version.

blocked gate → failed case → linked trace → rerun
managed datasetrelease gate
Build a quality gate

Debug locally.
Learn in production.

Studio helps you understand an agent before it ships. Lens keeps the same runtime concepts visible after deployment and feeds the evidence into the next candidate.

DEVELOP / STUDIO

Prompt, inspect, intervene

Exercise the real local agent, resolve approvals, inspect context, and replay the workflow.

Explore Studio
OPERATE / LENS

Observe, evaluate, gate

Investigate deployed runs, compare stable evaluation suites, and carry evidence into release review.

Open the Lens guide

Run Lens on your
own infrastructure.

Download the Compose and environment templates, configure unique secrets, then start the stack. The first account becomes the workspace owner.

Read the install guide
  1. 01
    Prepare the deployment

    Download the official templates, pin a Lens release, and configure unique secrets.

  2. 02
    Start the workspace

    Launch the stack. The first account created becomes the workspace owner.

  3. 03
    Connect a project

    Create a project and ingestion key, then send native Anvia telemetry or supported Langfuse v5 OTLP traces.

Make the evidence
part of the release.

Connect one agent in safe-capture mode, investigate its traces, then promote a stable evaluation suite into an explicit quality gate.