47 model fiyatı
  1. Ana sayfa
  2. Sürümler
  3. DSPy
  4. 3.3.1

DSPy 3.3.1 sürüm notları

DSPy 3.3.1 sürümünün yayın tarihi 21 Ağustos 2026. En güncel sürüm 3.5.0.

· 64 değişiklik maddesi

Orijinal sürüm notları

DSPy 3.3.1

DSPy 3.3.1 contains many interpreter fixes and improvements. It makes PythonInterpreter easier to install, substantially strengthens sandbox isolation and request handling, and adds end-to-end visibility into interpreter execution. The release also improves optimizer throughput, adapter correctness, and MCP compatibility.

Highlights

PythonInterpreter: Managed Runtime, Hardening, and Lifecycle Visibility
Installation, isolation, and execution integrity

PythonInterpreter now has an optional managed runtime installation:

pip install "dspy[deno]"

DSPy prefers that managed binary when present, while continuing to support system Deno 2.x and an explicit custom deno_command. The default path pins Pyodide, validates Deno >=2.0.0,<3.0.0, and ignores ambient Node and Deno project configuration so nearby application files cannot change sandbox startup.

The interpreter also closes several execution-integrity and isolation gaps:

Observability and agent integration

DSPy's callback API now exposes the complete interpreter lifecycle:

Events retain callback ancestry across modules, interpreters, tools, and LM calls. End callbacks receive terminating BaseException values such as cancellation and interruption instead of incorrectly reporting those operations as successful. Optimizer compile() runs receive the same start/end coverage.

PythonInterpreter.execution_instructions now gives RLM an accurate description of the Pyodide environment, including state persistence and unavailable native process capabilities. This helps generated code use the sandbox correctly.

Typing, serialization, and compatibility details

PRs: #10119, #10120, #10134, #10135, #10136, #10186, #10190, #10194, #10205, #10206, #10208, and #10255

Faster Multi-Proposal GEPA Optimization

DSPy now uses GEPA 0.1.4 and supports its multi-proposal sampling, selection, acceptance, tracking, and checkpoint-state contracts through gepa_kwargs. DSPy's adapter saves and restores its random-number-generator state, making resumed proposal sampling consistent with uninterrupted optimization.

When a sampling strategy produces multiple candidates, DSPy can evaluate those candidates concurrently. Candidate-level and example-level concurrency share the existing num_threads budget rather than multiplying it. For example, four candidates evaluated with num_threads=8 receive two example workers each; total DSPy-controlled concurrency remains eight.

import dspy
from gepa.strategies.proposal_sampling import IndependentSampling
from gepa.strategies.proposal_selection import BestImprovement

optimizer = dspy.GEPA(
    metric=metric,
    max_metric_calls=2_000,
    reflection_lm=dspy.LM("openai/gpt-5", temperature=1.0, max_tokens=32_000),
    num_threads=8,
    gepa_kwargs={
        "sampling_strategy": IndependentSampling(4),
        "selection_strategy": BestImprovement(),
        "acceptance_criterion": "strict_improvement",
    },
)

The default single-proposal strategy retains its previous execution shape. max_reflection_cost is not yet supported by DSPy's GEPA adapter and now raises clearly when set instead of silently providing an ineffective budget.

Metrics can also report named objective_scores and select an objective-aware frontier through gepa_kwargs. Objective, hybrid, and cartesian frontiers let GEPA use dimensions such as quality, privacy, or cost when selecting parents and merges, while the scalar metric continues to gate acceptance and select the final program. Tracked results expose aggregate objective scores, best candidates per objective, and each objective's independently achieved maximum.

GEPA 0.1.4 has a known upstream limitation: it requests traces while evaluating accepted candidates on the full validation set. For programs whose traced and ordinary evaluation paths differ after a runtime failure, this can cause missing or misaligned validation results. The upstream correction is targeted for GEPA 0.1.5.

PRs: #10209, #10210, #10259

More Reliable Structured Adapter Outputs

When an LM omits an output field with a declared default, default factory, or None-allowing annotation, ChatAdapter, JSONAdapter, XMLAdapter, and adapters built on them now apply the declared fallback. Missing required outputs continue to raise AdapterParseError.

This also prevents adapter fallback merely because a provider omitted a native optional output.

XMLAdapter now formats and parses nested Pydantic models, typed dictionaries, lists, mappings, nullable fields, and unions as nested XML. It continues to accept the previous JSON-inside-an-outer-XML-field representation for backward compatibility.

PRs: #10148, #10239

MCP SDK v2 Compatibility and Structured Results

DSPy's MCP bridge supports both MCP SDK v1 and v2 field names, v1 ClientSession, and the v2 high-level Client. The default tool-result semantics are unchanged: historical text and non-text content remains authoritative rather than being replaced by v2 structured content.

Applications can now opt into machine-readable MCP results:

tool = dspy.Tool.from_mcp_tool(client, mcp_tool, result_mode="structured")

Structured mode returns structuredContent exactly when the server supplies it, including arrays, scalar values, empty values, and explicit JSON null. It falls back to the existing content conversion when structured content is absent. DSPy does not infer, parse, or unwrap the returned value.

PRs: #10188, #10235

API and Compatibility Changes

CodeAct and ProgramOfThought Deprecation

dspy.CodeAct and dspy.ProgramOfThought now emit DeprecationWarning when constructed. They are scheduled for removal in DSPy 3.5; use dspy.RLM for new code.

PR: #10198

Resource Download Timeouts

Image.from_url() and Audio.from_url() now default to a 30-second request timeout instead of potentially waiting forever:

image = dspy.Image.from_url(url, timeout=60)
audio = dspy.Audio.from_url(url, timeout=60)

Pass timeout=None to retain the previous unbounded behavior.

PR: #10149

Typed Interpreter and ReAct Errors

CodeInterpreterError is now also a DSPyError while retaining RuntimeError compatibility. ReAct preserves ContextWindowExceededError after trajectory truncation is exhausted, and LM-facing execution errors now use one consistent formatter.

PRs: #10134, #10132, #10135, #10139

Additional Fixes

Full PR List

GEPA and Optimizers
Callbacks and Parallel Execution
Adapters, Tools, and MCP
Agents, Errors, and Code Execution
Datasets
Documentation
Testing, CI, Dependencies, and Release Engineering

Contributors

Thank you to @alvinttang, @daleselaji-dev, @immu4989, @isaacbmiller, @katherineahn, @michaelisaac-dev, @saime428, and @yzxcj797 for contributing to this release.

Full Changelog: https://github.com/stanfordnlp/dspy/compare/3.3.0...3.3.1

Kaynak: GitHub sürümü 3.3.1

Daha yeni: 3.4.0Daha eski: 3.3.0DSPy