Set credentials
Find these in Lemma project settings, or in the project get-started flow.LEMMA_API_KEY server-side. Never commit it. Never put it in browser or client-side code. The SDK sends to https://api.uselemma.ai by default. Pass baseUrl / base_url only for a custom endpoint.
What a ready trace is
Creating an API key, adding an SDK dependency, or seeing an ingest attempt does not prove observability. Observability is proven when a real production-like path produces a ready trace you can open in the dashboard: inspectable, with a root, nested work, and input and output you recognize. A key, an SDK install, or a failed or empty ingest is not a ready trace.What you are building
You send one support-agent trace with a nested generation and tool call.Instrument the agent
Pick one path. Framework adapters live on the integration pages: Vercel AI SDK, OpenAI Agents, LangChain, and LangGraph.- Coding agent
- Direct SDK
Use a coding agent to instrument the production agent.Ask the coding agent to use that skill to instrument the production agent.
1
Open the project get-started flow
In the Lemma dashboard, select or create the organization and project, then open that project’s get-started flow.
2
Install the tracing skill
3
Exercise a real path
Run a production-like request through the instrumented agent.
Verify a ready trace
Open Traces in the Lemma dashboard. You should see:- One trace for the whole execution
- The root trace with input and output
- A nested generation with model metadata
- A nested tool call with arguments and result
Stamp a release
Tag every ingest payload with the stable identifier your deployment process assigns to the running app, such as an app version, commit SHA, or container tag. Change it with each deployment. Passrelease on the client, or set LEMMA_RELEASE. Most continuous integration systems expose the current commit SHA as an environment variable. Set LEMMA_RELEASE to that value during deployment.
An explicit constructor value wins over the environment variable. Lemma omits empty, whitespace-only, longer-than-200-character, or newline, tab, or carriage-return values. It does not guess a git SHA.
Adapters (vercelAI, openAIAgents, langChain, langGraph, mastra) accept the same release field and forward it to the client they construct.
- TypeScript
- Python
Next steps
Use these pages after the first ready trace lands.Instrument an agent
Add spans, tools, generations, and errors to a real agent.
Runnable examples
The same docs chat agent, instrumented once per stack.
Traces in the dashboard
Search and inspect the trace you sent.
Overview
Issues, Inspect, Artifacts, and Analytics after ingest.