Add Weights & Biases Weave observability to any LLM project with minimal code changes.
Weave is W&B's observability toolkit for LLM applications. It automatically traces LLM calls, captures token usage, latency, and costs, and provides a powerful UI for debugging and evaluation.
- 🔄 Auto-patching - Automatic tracing for OpenAI, Anthropic, and 20+ providers
- 📊 Token tracking - Full visibility into input/output tokens and costs
- ⏱️ Latency metrics - TTFB and total response time
- 🔍 Debug UI - Visual trace explorer in W&B dashboard
- 📈 Evaluations - Built-in support for LLM evals
Works with Claude Code, Cursor, Codex, and other AI coding agents:
npx add-skill altryne/weavify-skillThis adds the skill to your project's .cursor/skills/ or agent config.
# Clone to your skills directory
git clone https://github.com/altryne/weavify-skill.git ~/clawd/skills/weave-integrationThe skill will be automatically available to your Clawdbot agent.
Copy SKILL.md to your project's agent instructions folder.
# TypeScript/Node.js
npm install weave
# Python
pip install weaveSet WANDB_API_KEY environment variable. Get key from wandb.ai/settings.
export WANDB_API_KEY="your-key-here"TypeScript:
import * as weave from 'weave';
import OpenAI from 'openai';
await weave.init('your-team/project-name');
const client = new OpenAI();
// All OpenAI calls are now automatically traced!Python:
import weave
import openai
weave.init('your-team/project-name')
client = openai.OpenAI()
# All OpenAI calls are now automatically traced!Weave auto-patches these providers (no code changes needed):
| Provider | TypeScript | Python |
|---|---|---|
| OpenAI | ✅ | ✅ |
| Anthropic | ✅ | ✅ |
| Google AI | ✅ | ✅ |
| Mistral | ✅ | ✅ |
| Cohere | ✅ | ✅ |
| Groq | ✅ | ✅ |
| Together | ✅ | ✅ |
| LiteLLM | ❌ | ✅ |
| LangChain | ❌ | ✅ |
For custom functions, use the @weave.op() decorator:
TypeScript:
const myFunction = weave.op(async (input: string) => {
// Your code here
return result;
}, { name: 'myFunction' });Python:
@weave.op()
def my_function(input: str) -> str:
# Your code here
return result- 📚 Weave Documentation
- 🚀 Quickstart Guide
- 🔧 TypeScript Integration
- 🐍 Python Integration
- 📊 Tracing Guide
- 📈 Evaluations
weavify-skill/
├── README.md # This file
├── SKILL.md # Agent instructions
└── references/
└── typescript.md # TypeScript-specific docs
MIT