What problem does it solve? Manual prompt engineering is fragile and hard to maintain when building multi-stage AI systems like RAG pipelines, agents, and classifiers. This Skill provides expert guidance for DSPy, Stanford NLP's framework that replaces hand-tuned prompts with declarative signatures and data-driven automatic optimization. ## Core Features & Use Cases - Declarative Signatures & Modules: Define tasks as input-output signatures and compose them with Predict, ChainOfThought, ReAct, and ProgramOfThought modules. - Automatic Prompt Optimization: Use teleprompters like BootstrapFewShot, MIPRO, and BootstrapFinetune to improve prompts and generate fine-tuning data from training examples. - Complex System Patterns: Build multi-hop RAG, reranking pipelines, multi-agent routers, and typed structured extraction with Pydantic models. - Use Case: You need a question-answering system over your documents. Define a RAG module with retrieval and generation stages, then compile it with BootstrapFewShot against 50 labeled examples to automatically learn effective few-shot demonstrations. ## Quick Start Use the dspy skill to build a chain-of-thought question answering module and optimize it with BootstrapFewShot on my training examples.