Installation
Setup
Basic Example
What Gets Traced
Phoenix automatically captures:- Chains: Input/output, intermediate steps, latency
- Agents: Tool selection, reasoning, execution
- Retrievers: Query, retrieved documents, scores
- LLM Calls: Model, prompts, tokens, parameters
- Tools: Function calls, inputs, outputs
- Errors: Exceptions, retries, failures
Advanced Examples
RAG Chain with Retriever
Agent with Tools
Streaming Chains
Observability in Phoenix
Once instrumented, you can:- Visualize chain execution graphs with all intermediate steps
- Debug agent reasoning and tool selection
- Inspect retrieved documents and relevance scores
- Monitor token usage across all LLM calls
- Track latency for each chain component
- Analyze errors and retry behavior
Resources
Python Example Notebook
Complete LangChain tutorial
Python Package
View Python source
TypeScript Package
View TypeScript source
LangChain Docs
LangChain documentation