In plain English
Instead of manually tweaking prompt wording over and over like trial-and-error, DSPy treats prompt engineering like writing software where an automated compiler optimizes prompts and few-shot examples for you.
Real-world example
Automatically optimizing multi-hop retrieval and reasoning pipelines for enterprise QA systems.
Technical definition
DSPy is a declarative Python framework designed for algorithmically optimizing prompts and weights in complex LLM pipelines. By separating program logic from prompt strings, DSPy compiles modular signatures into optimized few-shot examples and instruction sets through automated teleprompter optimization algorithms, maximizing task performance.