Developer Tools

deepset releases Haystack v3.1.0-rc1 with breaking changes

Breaking changes in Haystack v3.1.0-rc1 affect Agents, pipelines, and evaluators

Deep Dive

deepset has pushed Haystack v3.1.0-rc1, a pre-release for its open-source LLM orchestration framework, introducing several breaking changes that require immediate attention from users. The update affects core components like Agents, pipelines, and evaluators, with modifications to reserved state keys (e.g., `exit_reason`), schema handling, and input/output formats. For instance, `Agent.state_schema` now exposes the user-provided schema directly, while `resolved_state_schema` handles the runtime schema. Pipeline snapshots have also undergone a structural shift, with inputs now stored as lists of sender-value pairs, complicating backward compatibility.

Additionally, the release enforces stricter validation for unsafe deserialization in `OutputAdapter` and `ConditionalRouter`, requiring explicit `unsafe=True` flags during pipeline loading. Runtime behaviors have tightened as well, including stricter handling of `window_size=0` in `SentenceWindowRetriever` and case-sensitive metadata matching in `InMemoryDocumentStore`. The changes aim to improve consistency and security but demand updates to existing pipelines and custom components to avoid runtime errors.

Key Points
  • Haystack v3.1.0-rc1 introduces breaking changes to Agents, pipelines, and evaluators, including renamed state keys and updated schema handling.
  • Pipeline snapshots now store inputs as lists of sender-value pairs, and unsafe deserialization requires explicit flags.
  • Users must adapt pipelines or risk errors due to stricter validation and modified runtime behaviors.

Why It Matters

Professionals using Haystack must update pipelines to avoid runtime errors and leverage improved consistency and security in v3.1.0-rc1.

📬 Get the top 10 AI stories daily