Framework from Stanford for programming (not prompting) LLMs with optimizable modules.
DSPy is a framework for building LLM pipelines by writing declarative Python modules (signatures) instead of brittle hand-tuned prompts. Its optimizers (teleprompters) automatically compile and tune prompts and few-shot examples against a metric, enabling systematic, reproducible improvement of multi-stage agent and RAG systems.
Open-source (MIT). Free to use; model usage billed by the provider.