From bcc414a3890f31edba4b6dd5dc2cbf3c6ad4e1f3 Mon Sep 17 00:00:00 2001 From: Silvano Cerza <3314350+silvanocerza@users.noreply.github.com> Date: Thu, 5 Sep 2024 11:57:21 +0200 Subject: [PATCH] Update 2.5 release notes (#362) * Remove async stuff release note * Fix formatting * Remove unnecessary point in list --- content/release-notes/2.5.0.md | 31 ++++++++++++++----------------- 1 file changed, 14 insertions(+), 17 deletions(-) diff --git a/content/release-notes/2.5.0.md b/content/release-notes/2.5.0.md index c8d6ff04..5bf87aa6 100644 --- a/content/release-notes/2.5.0.md +++ b/content/release-notes/2.5.0.md @@ -3,30 +3,28 @@ title: Haystack 2.5.0 description: Release notes for Haystack 2.5.0 toc: True date: 2024-09-04 -last_updated: 2024-09-04 +last_updated: 2024-09-04 tags: ["Release Notes"] link: https://github.com/deepset-ai/haystack/releases/tag/v2.5.0 --- ### ⬆️ Upgrade Notes -- Removed `ChatMessage.to_openai_format` method. Use `haystack.components.generators.openai_utils._convert_message_to_openai_format` instead. -- Removed unused `debug` parameter from `Pipeline.run` method. -- Removed deprecated `SentenceWindowRetrieval`. Use `SentenceWindowRetriever` instead. +- Removed `ChatMessage.to_openai_format` method. Use `haystack.components.generators.openai_utils._convert_message_to_openai_format` instead. +- Removed unused `debug` parameter from `Pipeline.run` method. +- Removed deprecated `SentenceWindowRetrieval`. Use `SentenceWindowRetriever` instead. ### 🚀 New Features -- Extended core component machinery to support an optional asynchronous `async_run` method in components. If it's present, it should have the same parameters (and output types) as the run method and must be implemented as a coroutine. - Added the unsafe argument to enable behavior that could lead to remote code execution in `ConditionalRouter` and `OutputAdapter`. By default, unsafe behavior is disabled, and users must explicitly set `unsafe=True` to enable it. When unsafe is enabled, types such as `ChatMessage`, `Document`, and `Answer` can be used as output types. We recommend enabling unsafe behavior only when the Jinja template source is trusted. For more information, see the documentation for [`ConditionalRouter`](https://docs.haystack.deepset.ai/docs/conditionalrouter#unsafe-behaviour) and [`OutputAdapter`](https://docs.haystack.deepset.ai/docs/outputadapter#unsafe-behaviour). -- ### ⚡️ Enhancement Notes -- Adapts how `ChatPromptBuilder` creates `ChatMessages`. Messages are deep copied to ensure all meta fields are copied correctly. -- The parameter, `min_top_k`, has been added to the `TopPSampler`. This parameter sets the minimum number of documents to be returned when the top-p sampling algorithm selects fewer documents than desired. Documents with the next highest scores are added to meet the minimum. This is useful when guaranteeing a set number of documents to pass through while still allowing the Top-P algorithm to determine if more documents should be sent based on scores. -- Introduced a utility function to deserialize a generic Document Store from the `init_parameters` of a serialized component. -- Refactor `deserialize_document_store_in_init_parameters` to clarify that the function operates in place and does not return a value. -- The `SentenceWindowRetriever` has now an extra output key containing all the documents belonging to the context window. +- Adapts how `ChatPromptBuilder` creates `ChatMessages`. Messages are deep copied to ensure all meta fields are copied correctly. +- The parameter, `min_top_k`, has been added to the `TopPSampler`. This parameter sets the minimum number of documents to be returned when the top-p sampling algorithm selects fewer documents than desired. Documents with the next highest scores are added to meet the minimum. This is useful when guaranteeing a set number of documents to pass through while still allowing the Top-P algorithm to determine if more documents should be sent based on scores. +- Introduced a utility function to deserialize a generic Document Store from the `init_parameters` of a serialized component. +- Refactor `deserialize_document_store_in_init_parameters` to clarify that the function operates in place and does not return a value. +- The `SentenceWindowRetriever` has now an extra output key containing all the documents belonging to the context window. ### ⚠️ Deprecation Notes @@ -34,9 +32,8 @@ link: https://github.com/deepset-ai/haystack/releases/tag/v2.5.0 ### 🐛 Bug Fixes -- Fixed an issue where page breaks were not being extracted from DOCX files. -- Used a forward reference for the `Paragraph` class in the `DOCXToDocument` converter to prevent import errors. -- The metadata produced by `DOCXToDocument` component is now JSON serializable. Previously, it contained `datetime` objects automatically extracted from DOCX files, which are not JSON serializable. These `datetime` objects are now converted to strings. -- Starting from `haystack-ai==2.4.0`, Haystack is compatible with `sentence-transformers>=3.0.0`; earlier versions of `sentence-transformers` are not supported. We have updated the test dependencies and LazyImport messages to reflect this change. -- For components that support multiple Document Stores, prioritize using the specific `from_dict` class method for deserialization when available. Otherwise, fall back to the generic `default_from_dict` method. This impacts the following generic components: `CacheChecker`, `DocumentWriter`, `FilterRetriever`, and `SentenceWindowRetriever`. - +- Fixed an issue where page breaks were not being extracted from DOCX files. +- Used a forward reference for the `Paragraph` class in the `DOCXToDocument` converter to prevent import errors. +- The metadata produced by `DOCXToDocument` component is now JSON serializable. Previously, it contained `datetime` objects automatically extracted from DOCX files, which are not JSON serializable. These `datetime` objects are now converted to strings. +- Starting from `haystack-ai==2.4.0`, Haystack is compatible with `sentence-transformers>=3.0.0`; earlier versions of `sentence-transformers` are not supported. We have updated the test dependencies and LazyImport messages to reflect this change. +- For components that support multiple Document Stores, prioritize using the specific `from_dict` class method for deserialization when available. Otherwise, fall back to the generic `default_from_dict` method. This impacts the following generic components: `CacheChecker`, `DocumentWriter`, `FilterRetriever`, and `SentenceWindowRetriever`.