// event · framework
DSPy 3.3.1: managed Python sandbox, GEPA 0.1.4 multi-proposal, MCP v2 structured results
frameworkvendor: stanfordnlppublished: 7d agoconfidence: 0.90id: 19d961dc-73da-4c7a-a239-1b18fddfa550
DSPy 3.3.1 hardens the PythonInterpreter with an optional managed Deno/Pyodide runtime (`pip install dspy[deno]`), stronger sandbox isolation, and full callback lifecycle observability. It upgrades to GEPA 0.1.4 with multi-proposal sampling and objective-aware frontiers, adds MCP SDK v2 compatibility with opt-in `result_mode=\"structured\"`, applies default fallbacks for missing adapter fields, and deprecates CodeAct/ProgramOfThought in favor of `dspy.RLM`.
capability delta
an agent can now run sandboxed Python via a managed Deno/Pyodide runtime with full lifecycle callbacks, use GEPA 0.1.4 multi-proposal optimization, get structured MCP tool results, and rely on adapter default fallbacks for missing output fields.
// install
pip install "dspy[deno]"==3.3.1pypi · dspy @ 3.3.1
// example
python
import dspy
from gepa.strategies.proposal_sampling import IndependentSampling
from gepa.strategies.proposal_selection import BestImprovement
# Managed Python sandbox (Deno/Pyodide)
interp = dspy.PythonInterpreter()
result = interp("x = 2 + 2; x")
# Multi-proposal GEPA optimization
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",
},
)
# MCP structured tool results
tool = dspy.Tool.from_mcp_tool(client, mcp_tool, result_mode="structured")// links