Step-by-step answer
Stretch 2 hours8 stepsDSPy: MIPROv2 versus GEPA
The searches summariser as a DSPy 3.4 program (a class-based signature and dspy.Predict), the claude -p optimiser's metric ported to return dspy.Prediction(score, feedback), a cost estimate built from the optimisers' own budget rules, MIPROv2 and GEPA at the light budget, and one five-row comparison on the frozen test split. Models come from .env, so the same code runs on any OpenRouter model or a local Ollama model, and a fake LM runs the whole pipeline in a free dry run.
Back to the exercise