dspy

Build AI systems with declarative programming and automated prompt optimization.

6|3|Updated Jan 29, 2026
One-click install
npx skills add https://github.com/jonnabio/ace-framework --skill dspy-jonnabio
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dspy
Source: https://github.com/jonnabio/ace-framework/tree/main/.ace/packs/ai-research/dspy
Command: npx skills add https://github.com/jonnabio/ace-framework --skill dspy-jonnabio

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires dspy, openai, anthropic, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill provides a framework for building complex AI systems with declarative programming, optimizing prompts automatically, and creating modular RAG systems and agents.

Core Features & Use Cases

  • Declarative Programming: Build complex AI systems with multiple components and workflows using a structured programming language.
  • Prompt Optimization: Automatically optimize prompts for better model performance.
  • RAG Systems: Create modular RAG systems and agents that can retrieve and generate information from external sources.
  • Use Case: Imagine you are developing a chatbot that needs to retrieve information from a database and generate responses. Use this Skill to create a modular chatbot system with DSPy.

Quick Start

Create a new project using the dspy framework with the following command:

npx create-ace-framework my-project --adapter claude-code

Frequently Asked Questions about dspy

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How does automated prompt optimization work for AI systems?

Automated prompt optimization systematically tunes language model instructions using declarative programming to improve performance, replacing manual prompt engineering with programmatic parameter adjustments.

What is declarative programming for language models?

Declarative programming for language models structures AI systems by defining modular components and workflows programmatically, enabling systematic development of complex behaviors without manual prompt tuning.

How do I build modular RAG systems with automated prompt optimization?

You build modular RAG systems by using a declarative framework to connect retrieval and generation components, allowing automatic prompt optimization to enhance the generation pipeline.

Can I use DSPy with OpenAI and Anthropic models?

Yes, this declarative AI development framework integrates with both OpenAI and Anthropic, allowing you to apply systematic programming and automated prompt optimization across different language model providers.

Do I need Python to develop AI systems with automated prompt optimization?

Yes, Python is required to execute the declarative programming framework, build modular RAG systems, and run automated prompt optimization for your language model workflows.

Why use declarative programming instead of manual prompt engineering?

Declarative programming replaces manual prompt engineering by automatically optimizing prompts and structuring complex AI systems into modular components, reducing fragility and improving model performance systematically.