plugmyagent

DSPy

Frameworks Open source (MIT)

GitHub stars38.7k
Forks3.4k
LicenseMIT
Last activityOct 20, 2026
Open issues809

Repository: stanfordnlp/dspy ยท Data checked Oct 2026

About

DSPy is Stanford's framework for programming language-model software declaratively instead of hand-tuning prompts. You define your agent as Python modules like ChainOfThought and ReAct, then DSPy's optimizers compile better prompts and few-shot examples automatically from your data. It flips the usual workflow: you declare what good looks like, and the framework figures out the wording. MIT licensed, pip install, and the closest thing to a compiler for agent behavior.

Details

Open source. You run it yourself.

Auth: Open source (MIT)

Rate limit: None, runs locally (uses your model API)

Verified: 2026-09-19

Best for: developer

Setup

  1. Run pip install dspy
  2. Define your task as a DSPy signature: inputs in, outputs out
  3. Build a small training set of example input-output pairs
  4. Run an optimizer and let it compile the best prompt for your task