Python SDK for PromptLayer, logging, versioning, tracing and evaluating prompts and LLM requests across OpenAI, Anthropic and other providers.
wandb/weave
Python toolkit from Weights & Biases for tracing and evaluating AI agents and LLM applications.
Open-source alternative to:LangSmith
- Stars
- 1,144
- Forks
- 183
- Open issues
- 164
- Last commit
- 12 hours ago
What is it?
Weave is a toolkit for tracing and evaluating AI agents, built by Weights & Biases. It records conversations, turns, LLM calls and tool calls, and shows them in a dedicated Agents tab in the W&B web interface. Plain function tracing with the @weave.op decorator is also supported, with results shown in the Calls tab.
After calling weave.init(), Weave autopatches supported agent SDKs such as the OpenAI Agents SDK, Claude Agent SDK and Google ADK, and auto-traces plain openai client calls. For agents built without a supported SDK, a Conversation API with start_conversation, start_turn and start_llm context managers lets you record your own loop.
The project requires Python 3.10 or higher and a Weights & Biases account with an API key. Traces are stored in W&B projects, so you need to sign in to the hosted service to view them.
Key features
- 01Traces agent conversations, turns, LLM calls and tool calls in the Agents tab.
- 02Autopatches the OpenAI Agents SDK, Claude Agent SDK and Google ADK after weave.init().
- 03Traces ordinary Python functions with the @weave.op decorator.
- 04Provides a Conversation API for tracing custom agent loops.
- 05Auto-traces calls made with the openai Python client.
Use cases
- Debugging multi-turn agents built with a supported SDK by inspecting their tool calls and LLM requests.
- Tracing a custom agent loop that does not use a supported framework.
- Running evaluations and scorers on LLM application outputs.
- Recording token usage and model responses from LLM calls.
Quick start
- 1
Install Weave and the OpenAI Agents SDK
pip install weave openai-agents requests - 2
Set WANDB_API_KEY and OPENAI_API_KEY environment variables
- 3
Run the example agent code, then open the Agents tab in the printed project URL
Things to know
- Requires a Weights & Biases account and API key to view traces.
- The advanced Weave engine and boards code is paused and not actively developed.
In collections
Topics
FAQ
- What is weave?
- Python toolkit from Weights & Biases for tracing and evaluating AI agents and LLM applications. Weave is a toolkit for tracing and evaluating AI agents, built by Weights & Biases. It records conversations, turns, LLM calls and tool calls, and shows them in a dedicated Agents tab in the W&B web interface. Plain function tracing with the @weave.op decorator is also supported, with results shown in the Calls tab.
- Is weave free to use? What license does it have?
- weave is open source under the Apache-2.0 license. Check the license terms before using it in commercial products.
- Is weave still maintained?
- Actively maintained. The last commit to weave was on Nov 6, 2026.
- What can I use weave for?
- Debugging multi-turn agents built with a supported SDK by inspecting their tool calls and LLM requests. Tracing a custom agent loop that does not use a supported framework. Running evaluations and scorers on LLM application outputs. Recording token usage and model responses from LLM calls.
- How do I install weave?
- Install Weave and the OpenAI Agents SDK: pip install weave openai-agents requests Set WANDB_API_KEY and OPENAI_API_KEY environment variables Run the example agent code, then open the Agents tab in the printed project URL
- Where can I get weave?
- The source code and installation instructions are on GitHub: https://github.com/wandb/weave
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
Open source LLM engineering platform for tracing, evaluating, managing prompts, and debugging LLM applications, self-hostable.
Open-source LLM observability and evaluation platform for tracing AI agents, scoring LLM outputs, managing prompts, and monitoring production.
Official OpenClaw plugin that exports agent traces, tool calls, token usage and costs to Opik for observability.
Open-source engine for guardrails, tracing, evaluation and monitoring of LLM and agentic AI applications, plus ML model monitoring.
Open-source platform for tracing, testing, routing and governing LLM calls, agents and coding assistants across a company.