DSPy
Trace DSPy programs and optimizers with Respan.
Set up Respan
- Sign up — Create an account at platform.respan.ai
- Create an API key — Generate one on the API keys page
- Add credits or a provider key — Add credits on the Credits page or connect your own provider key on the Integrations page
Use AI
Add the Docs MCP to your AI coding tool to get help building with Respan. No API key needed.
What is DSPy?
DSPy is a framework from Stanford NLP for programming — not prompting — language models. It provides composable modules and automatic prompt optimization, replacing hand-crafted prompts with learnable programs.
Setup
View your trace
Open the Traces page to see your DSPy program with module forward passes, chain-of-thought steps, and LLM calls.
What gets traced
All DSPy operations are auto-instrumented:
- Module forward passes
- LLM calls with model, tokens, and input/output
- Optimizer steps and prompt mutations
- Retrieval operations
- Chain-of-thought reasoning steps
Traces appear in the Traces dashboard.
Learn more
- OpenTelemetry integration - How Respan processes OTel spans
- Respan Python SDK - Full SDK reference