Optimize prompts, code, and more with AI-powered Reflective Text Evolution
5.6k
Stars
458
Forks
105
Open issues
30
Contributors
AI Analysis
GEPA is a framework for optimizing textual parameters (prompts, code, agent architectures, configurations) using LLM-based reflection and Pareto-efficient evolutionary search. It is specialized for teams building AI systems who need to iteratively improve their prompts and agent designs without the computational overhead of traditional reinforcement learning. It is not a general-purpose tool—it targets practitioners optimizing LLM-powered systems in production, particularly at enterprises lik...
Inferred from signals mentioned in the README (tests, CI, type safety) — not a review of the actual code.
AI's overall editorial judgment — not an average of the bars above, can weigh other factors too.
GEPA uses LLM-based reflection and evolutionary search to optimize prompts, code, and any textual artifact
GEPA (Genetic-Pareto) is a Python framework that treats prompt and artifact optimization as an evolutionary search problem: it feeds full execution traces back into an LLM to diagnose failures, mutate candidates, and select Pareto-efficient variants across multiple objectives. It targets ML engineers and researchers who need to optimize system prompts, agent architectures, or arbitrary text-defined configurations with far fewer evaluations than RL-based approaches. Documented production usage at Shopify, Databricks, Dropbox, and OpenAI, plus a native DSPy integration, give it credible real-world grounding for a project under a year old.
Created in August 2025, GEPA emerged as LLM-based prompt optimization gained traction. It has an accompanying arxiv paper (2507.19457) and was quickly integrated into DSPy as dspy.GEPA, suggesting early alignment with the research and engineering community around structured LLM program optimization.
The Shopify CEO public endorsement and a Databricks blog post citing a 90x cost reduction appear to have been major catalysts. Growing from zero to 5,290 stars in under 11 months, with 74 stars in the last 7 days, reflects steady but not explosive organic interest — likely driven by word-of-mouth in practitioner circles and the DSPy community, plus concrete benchmark claims.
README explicitly lists 50+ production uses at named organizations including Shopify, Databricks, Dropbox, and OpenAI. A Databricks blog post is directly cited. The Shopify CEO's public endorsement is verifiable. These are stronger-than-average adoption signals for a sub-one-year project, though independent auditing of the '50+ production uses' claim is not possible from available metadata.
Based on README, GEPA appears to implement a loop of: (1) candidate evaluation against a user-supplied metric, (2) LLM-based reflection over execution traces including errors and logs, (3) mutation/proposal of new candidates, and (4) Pareto-front selection to balance multiple objectives. The optimize_anything API appears to generalize beyond prompts to any string artifact. Integration with DSPy as a first-class optimizer suggests modular design compatible with existing LLM pipeline abstractions.
Not documented in README
Last push was 2026-06-22 — one day before the evaluation date — indicating active, ongoing development. The project has a documentation site, a blog, Discord and Slack communities, and a linked arxiv paper, all of which are positive maintenance signals for a project less than a year old.
ADOPT IF: you are building LLM pipelines in Python, already use DSPy, or need to optimize prompts or agent configurations with a limited evaluation budget and want interpretable iteration steps. AVOID IF: you need a simple, low-dependency one-shot prompt rewriting tool, or if your optimization target is not expressible as a text artifact with a measurable metric. MONITOR IF: you are interested in automated agent architecture search or non-prompt optimization (code, configs) but are not yet ready to invest in setting up custom evaluators.
Independent dimensions
Mainstream potential
6/10
Technical importance
8/10
Adoption evidence
6/10
- Reflection quality and mutation usefulness are heavily dependent on the capability of the chosen reflection_lm — using weaker models may produce low-quality proposals and waste evaluation budget.
- The framework requires users to define a reliable evaluation metric; poorly designed metrics will cause optimization to find unintended solutions, with no built-in safeguards visible in the README.
- At under one year old, the API surface may shift substantially; early adopters could face breaking changes as the project matures.
- The claimed benchmark results (90x cost reduction, 35x fewer evaluations) are compelling but originate from the project's own blog and paper — independent third-party reproduction has not been documented in available metadata.
- Community support infrastructure (Discord, Slack) is present but community size is unverified; if growth stalls, support responsiveness may decline.
Likely to establish itself as a go-to optimizer within the DSPy ecosystem and among ML practitioners running automated evaluation loops. Mainstream breakout beyond that community will depend on whether the optimize_anything abstraction lowers the barrier enough for non-research teams.
Newsletter
Get analyses like this every Monday
Free weekly digest of the most interesting open-source discoveries.
Languages
Information
- Website
- https://gepa-ai.github.io/gepa/
- Language
- Jupyter Notebook
- License
- MIT
- Last updated
- 3d ago
- Created
- 11mo ago
- Analyzed with
- anthropic/claude-haiku-4-5
Stars over time
Contributors over time
Top 100 contributors only — repos with more will plateau at 100.
Open issues
Add a run_dir admission manifest for candidate acceptance/rejection audits
Idea: Add Program Summarization Context to GEPA Instruction Proposer for Improved Module Role Alignment
GEPA doesn't remember rejected proposals — re-sampling the same parent repeats the same failed mutation
Top contributors
Similar repos
Wirasm/PRPs-agentic-eng
PRP (Product Requirement Prompts) is a specialized framework and collection of...
dair-ai/Prompt-Engineering-Guide
A comprehensive, community-maintained reference guide covering prompt...
| Repository | Stars | Week Δ | Language | Score | Updated |
|---|---|---|---|---|---|
|
|
5.6k | +96 | Jupyter Notebook | 8/10 | 3d ago |
|
|
8.9k | — | JavaScript | 8/10 | 21h ago |
|
|
2.2k | — | Python | 7/10 | 2w ago |
|
|
9.7k | — | Jupyter Notebook | 7/10 | 9mo ago |
|
|
76.3k | — | MDX | 8/10 | 4mo ago |
|
|
4.6k | — | Python | 7/10 | 3w ago |
DSPy's built-in optimizers also automate prompt optimization within structured pipelines, but GEPA is now integrated into DSPy as dspy.GEPA, positioning it as complementary rather than competing. GEPA's claimed advantage is richer trace feedback and fewer required evaluations compared to DSPy's Bayesian and bootstrap approaches.
Older and more popular by stars (9,661), gpt-prompt-engineer focuses on generating and ranking prompt candidates using tournament-style evaluation. It lacks GEPA's reflective trace analysis and Pareto-multi-objective framing, and appears less actively maintained.
A TypeScript/web-focused prompt optimizer (31,271 stars) aimed at interactive UI-driven prompt rewriting rather than programmatic, metric-driven evolutionary optimization. Targets a different user profile — non-developers or those wanting quick manual iteration rather than automated optimization loops.
TextGrad treats LLM pipelines as differentiable computation graphs and backpropagates text gradients. Conceptually similar in using LLMs to explain failures, but GEPA's evolutionary/Pareto framing differs from TextGrad's gradient metaphor. GEPA explicitly claims fewer evaluations than RL methods; comparison with TextGrad specifically is not documented in the README.
OPRO (Optimization by PROmpting) is a research method using LLMs to propose better prompts based on past results. GEPA extends this direction with Pareto selection, full trace reflection, and a production-ready Python package, whereas OPRO remains primarily a research artifact without a maintained open-source library.
Click to view full HotpotQA prompt
[HotpotQA Prompt Begin]