Choosing LLM development tools: Promptfoo, DSPy, LangSmith, Guidance, and Outlines
When building an LLM application, testing, prompt optimization, execution tracing, and constrained output solve different problems. Promptfoo focuses on configuration-based evaluation and red-team testing; DSPy on modularizing tasks and optimizing programs against metrics; LangSmith on traces and offline/online evaluation; Guidance and Outlines on constraining generation and output formats. Choose based on the problem you need to solve and fit with your language, model hosting, and data policies. Using all five is not the default.
Choosing LLM development tools: Promptfoo, DSPy, LangSmith, Guidance, and Outlines
When building an LLM application, testing, prompt optimization, execution tracing, and constrained output solve different problems. Promptfoo focuses on configuration-based evaluation and red-team testing; DSPy on modularizing tasks and optimizing programs against metrics; LangSmith on traces and offline/online evaluation; Guidance and Outlines on constraining generation and output formats. Choose based on the problem you need to solve and fit with your language, model hosting, and data policies. Using all five is not the default.
Documentation checked: November 23, 2026. APIs, model support, hosting options, and licenses change; recheck official documentation before adoption.
What problem are you trying to solve?
To check whether a prompt still works after a model update, you need reproducible evaluation cases and comparisons. To find which step fails in production, you need traces and visibility into data flow. Constrained schema output or assembling and optimizing prompts by task call for different capabilities. Treating all of these as generic “LLM support” obscures their different responsibilities.
How do the five tools differ?
| Tool | Main role | Who might start here | Check before adopting |
|---|---|---|---|
| Promptfoo | Configure prompts, models, and cases in YAML/code; evaluate and compare results; documents red teaming too | Teams building prompt regression evaluations and CI checks | Case and assertion quality, cost/provider calls, data handling for sharing or remote features |
| DSPy | Build structured-input/output language-model programs and modules; optimize them against a metric and data | Python developers composing and tuning multi-step LLM programs | Whether data and metric are representative, a held-out evaluation set, supported models/adapters |
| LangSmith | Application traces, datasets, offline experiments, production evaluation and monitoring | Teams needing failure analysis and quality checks before and after release | Sensitivity of traced inputs/outputs, hosting, region/access policy, retention and cost |
| Guidance | Combine generation constraints such as regex/grammar with code and control flow | Developers needing fine control over output format or generation flow | Constraint support in the chosen runtime, backend compatibility, and that format does not guarantee truth |
| Outlines | Python workflows for text and structured generation such as JSON; documents integrations with open-model runtimes | Python teams working with open models or structured output | Feature and performance support for the desired model/runtime, API differences by project version |
This table summarizes documented core capabilities; it is not a performance ranking or a hands-on product test. Support can vary by provider, model, configuration, and version.
When is Promptfoo a good starting point?
Promptfoo’s getting-started guide configures prompts, model providers, and test cases, then runs evaluations and compares results. It can be a starting point when you need repeatable CLI/config-driven runs or want to compare prompt and model combinations on the same inputs. Its documentation covers assertions, model/RAG/agent evaluation, and red-team tests. Assertions may be rule-based checks or rubric scoring, so validate the criteria themselves. Cost and latency assertions are not a substitute for an overall spending limit. Promptfoo getting started
What is different about DSPy?
DSPy’s guide describes declaring task input/output structures and composing them into modules and multi-step programs instead of directly managing prompt strings. With evaluation metrics and data, an optimizer can adjust program configuration. This can suit reusable multi-step programs tuned against an evaluation criterion. An optimizer cannot supply a sound criterion or representative data; keep a separate held-out evaluation set to detect overfitting. Check the official guide for current installation, Python, and model-connection requirements. DSPy: Program, don’t prompt
How does LangSmith relate to a framework?
LangSmith documentation describes using traces to inspect model calls, tools, processing steps, and latency, and distinguishes offline evaluation on curated datasets from online evaluation of production traces. A trace does not judge answer quality by itself; evaluators and human review may still be needed. Trace collection can send prompts, outputs, and retrieved documents to an external observability system, so decide what to record first. For OpenTelemetry or an existing model stack, verify current integrations, hosting, and data options against policy. LangSmith evaluation types
When should you consider Guidance or Outlines?
Consider them when you need code-controlled generation formats. Guidance’s official repository demonstrates constraints such as regex, context-free grammars, and JSON, as well as combining generation with conditions, loops, or tool use. Outlines documents Python workflows for output formats and lists several open-model runtimes. Exact backend and model compatibility changes by release, so prototype on the intended stack and inspect performance and failure handling. Guidance official repository, Outlines documentation
Format constraints can help produce syntactically valid output, but do not establish that values are true, properly sourced, or compliant with business rules. A constrained model can still choose a wrong value within the allowed format, or lack a way to express the right answer. Separate parsing/schema checks from factual and policy checks.
How can you narrow the choice?
**Need to rerun an evaluation set and compare prompt/model results:** consider Promptfoo. Compare with LangSmith if you want evaluation closely integrated with an existing harness.
**Want to compose multi-step LLM programs in Python and optimize against data:** consider DSPy, after defining metrics and a data-splitting plan.
**Need to trace production requests and compare before/after release:** examine LangSmith tracing and evaluation. Privacy-aware logging is central.
**Need to constrain JSON, regex, or grammar generation on open models:** shortlist Guidance and Outlines, then check compatibility, token handling, and performance on the actual model/backend.
**Provider API already offers reliable JSON Schema output:** first check whether that capability plus a validation library is enough before adding a generation framework.
Start with a small comparison using the same task cases, reference answers, evaluation criteria, and deployment conditions. Review initial cost and latency, data transmission and retention, reproducibility, upgrades, and recovery. Adding tools can make responsibility boundaries harder to manage; require a tool to solve a demonstrated problem before adding it.
Sources
[Promptfoo getting-started guide](https://www.promptfoo.dev/docs/getting-started/)
[DSPy: Program, don’t prompt](https://dspy.ai/current/getting-started/program-dont-prompt/)
[LangSmith evaluation types](https://docs.langchain.com/langsmith/evaluation-types)
[Guidance official GitHub repository](https://github.com/guidance-ai/guidance)
[Outlines documentation](https://dottxt-ai.github.io/outlines/welcome/)