diff --git a/docs-website/docs/concepts/device-management.mdx b/docs-website/docs/concepts/device-management.mdx index 4f8b2b09f5..a50008c8f3 100644 --- a/docs-website/docs/concepts/device-management.mdx +++ b/docs-website/docs/concepts/device-management.mdx @@ -24,8 +24,7 @@ Haystack’s device management is built on the following abstractions: With the above abstractions, Haystack can fully address any supported device that’s part of your local machine and can support the usage of multiple devices at the same time. Every component that supports local inference will internally handle the conversion of these generic representations to their backend-specific representations. -:::info -Source Code +:::info Source Code Find the full code for the abstractions above in the Haystack GitHub [repo](https://github.com/deepset-ai/haystack/blob/6a776e672fb69cc4ee42df9039066200f1baf24e/haystack/utils/device.py). ::: @@ -82,14 +81,14 @@ class MyComponent(Component): self.model = AutoModel.from_pretrained("deepset/bert-base-cased-squad2", device=self.device.to_hf()) def to_dict(self): - # Serialize the policy like any other (custom) data. + # Serialize the policy like any other (custom) data. return default_to_dict(self, device=self.device.to_dict() if self.device else None, ...) - + @classmethod def from_dict(cls, data): - # Deserialize the device data inplace before passing + # Deserialize the device data inplace before passing # it to the generic from_dict function. init_params = data["init_parameters"] init_params["device"] = ComponentDevice.from_dict(init_params["device"]) @@ -120,4 +119,4 @@ generator = HuggingFaceLocalGenerator(model="llama2", huggingface_pipeline_kwarg }) ``` -In such cases, ensure that the parameter precedence and selection behavior is clearly documented. In the case of `HuggingFaceLocalGenerator`, the device map passed through the `huggingface_pipeline_kwargs` parameter overrides the explicit `device` parameter and is documented as such. \ No newline at end of file +In such cases, ensure that the parameter precedence and selection behavior is clearly documented. In the case of `HuggingFaceLocalGenerator`, the device map passed through the `huggingface_pipeline_kwargs` parameter overrides the explicit `device` parameter and is documented as such. diff --git a/docs-website/docs/concepts/document-store.mdx b/docs-website/docs/concepts/document-store.mdx index 88d1534e9f..2550f95607 100644 --- a/docs-website/docs/concepts/document-store.mdx +++ b/docs-website/docs/concepts/document-store.mdx @@ -9,16 +9,14 @@ description: "You can think of the Document Store as a database that stores your You can think of the Document Store as a database that stores your data and provides them to the Retriever at query time. Learn how to use Document Store in a pipeline or how to create your own. -Document Store is an object that stores your documents. In Haystack, a Document Store is different from a component, as it doesn’t have the `run()` method. You can think of it as an interface to your database – you put the information there, or you can look through it. This means that a Document Store is not a piece of a pipeline but rather a tool that the components of a pipeline have access to and can interact with. +Document Store is an object that stores your documents. In Haystack, a Document Store is different from a component, as it doesn't have the `run()` method. You can think of it as an interface to your database – you put the information there, or you can look through it. This means that a Document Store is not a piece of a pipeline but rather a tool that the components of a pipeline have access to and can interact with. -:::tip -Work with Retrievers +:::tip Work with Retrievers The most common way to use a Document Store in Haystack is to fetch documents using a Retriever. A Document Store will often have a corresponding Retriever to get the most out of specific technologies. See more information in our [Retriever](../pipeline-components/retrievers.mdx) documentation. ::: -:::info -How to choose a Document Store? +:::note How to choose a Document Store? To learn about different types of Document Stores and their strengths and disadvantages, head to the [Choosing a Document Store](document-store/choosing-a-document-store.mdx) page. ::: @@ -40,7 +38,7 @@ See the installation and initialization details for each Document Store in the " ### Work with Documents -Convert your data into `Document` objects before writing them into a Document Store along with its metadata and document ID. +Convert your data into `Document` objects before writing them into a Document Store along with its metadata and document ID. The ID field is mandatory, so if you don’t choose a specific ID yourself, Haystack will do its best to come up with a unique ID based on the document’s information and assign it automatically. However, since Haystack uses the document’s contents to create an ID, two identical documents might have identical IDs. Keep it in mind as you update your documents, as the ID will not be updated automatically. @@ -61,14 +59,13 @@ To write documents into the `InMemoryDocumentStore`, simply call the `.write_doc ```python document_store.write_documents([ - Document(content="My name is Jean and I live in Paris."), - Document(content="My name is Mark and I live in Berlin."), + Document(content="My name is Jean and I live in Paris."), + Document(content="My name is Mark and I live in Berlin."), Document(content="My name is Giorgio and I live in Rome.") ]) ``` -:::info -`DocumentWriter` +:::note `DocumentWriter` See `DocumentWriter` component [docs](../pipeline-components/writers/documentwriter.mdx) to write your documents into a Document Store in a pipeline. ::: @@ -100,4 +97,4 @@ The `init` function should indicate all the specifics for the chosen database or We also recommend having a custom corresponding Retriever to get the most out of a specific Document Store. -See [Creating Custom Document Stores](document-store/creating-custom-document-stores.mdx) page for more details. \ No newline at end of file +See [Creating Custom Document Stores](document-store/creating-custom-document-stores.mdx) page for more details. diff --git a/docs-website/docs/concepts/document-store/choosing-a-document-store.mdx b/docs-website/docs/concepts/document-store/choosing-a-document-store.mdx index 8b7af69085..59481cf620 100644 --- a/docs-website/docs/concepts/document-store/choosing-a-document-store.mdx +++ b/docs-website/docs/concepts/document-store/choosing-a-document-store.mdx @@ -56,9 +56,10 @@ Continue further down the article for a more complex explanation of the strength Vector libraries are often included in the “vector database” category improperly, as they are limited to handling only vectors, are designed to work in-memory, and normally don’t have a clean way to store data on disk. Still, they are the way to go every time performance and speed are the top requirements for your AI application, as these libraries can use hardware resources very effectively. -> 🚧 In progress -> -> We are currently developing the support for vector libraries in Haystack. +:::warning In progress + +We are currently developing the support for vector libraries in Haystack. +::: #### Pure vector databases diff --git a/docs-website/docs/concepts/pipelines.mdx b/docs-website/docs/concepts/pipelines.mdx index 089693c64f..6e66503876 100644 --- a/docs-website/docs/concepts/pipelines.mdx +++ b/docs-website/docs/concepts/pipelines.mdx @@ -100,8 +100,7 @@ Thanks to serialization, you can save and then load your pipelines. Serializatio Haystack pipelines delegate the serialization to its components, so serializing a pipeline simply means serializing each component in the pipeline one after the other, along with their connections. The pipeline is serialized into a dictionary format, which acts as an intermediate format that you can then convert into the final format you want. -:::info -Serialization formats +:::info Serialization formats Haystack only supports YAML format at this time. We'll be rolling out more formats gradually. ::: diff --git a/docs-website/docs/concepts/pipelines/serialization.mdx b/docs-website/docs/concepts/pipelines/serialization.mdx index 635a55b8bd..4bcf9e06f3 100644 --- a/docs-website/docs/concepts/pipelines/serialization.mdx +++ b/docs-website/docs/concepts/pipelines/serialization.mdx @@ -9,10 +9,9 @@ description: "Save your pipelines into a custom format and explore the serializa Save your pipelines into a custom format and explore the serialization options. -Serialization means converting a pipeline to a format that you can save on your disk and load later. +Serialization means converting a pipeline to a format that you can save on your disk and load later. -:::info -Serialization formats +:::info Serialization formats Haystack 2.0 only supports YAML format at this time. We will be rolling out more formats gradually. ::: @@ -28,7 +27,7 @@ pipe = Pipeline() print(pipe.dumps()) ## Prints: -## +## ## components: {} ## connections: [] ## max_loops_allowed: 100 @@ -131,7 +130,7 @@ from haystack import component, default_from_dict, default_to_dict class SetIntersector: def __init__(self, intersect_with: set): self.intersect_with = intersect_with - + @component.output_types(result=set) def run(self, data: set): return data.intersect(self.intersect_with) @@ -151,7 +150,7 @@ class SetIntersector: Once a pipeline is available in its dictionary format, the last step of serialization is to convert that dictionary into a format you can store or send over the wire. Haystack supports YAML out of the box, but if you need a different format, you can write a custom Marshaller. -A `Marshaller` is a Python class responsible for converting text to a dictionary and a dictionary to text according to a certain format. Marshallers must respect the `Marshaller` [protocol](https://github.com/deepset-ai/haystack/blob/main/haystack/marshal/protocol.py), providing the methods `marshal` and `unmarshal`. +A `Marshaller` is a Python class responsible for converting text to a dictionary and a dictionary to text according to a certain format. Marshallers must respect the `Marshaller` [protocol](https://github.com/deepset-ai/haystack/blob/main/haystack/marshal/protocol.py), providing the methods `marshal` and `unmarshal`. This is the code for a custom TOML marshaller that relies on the `rtoml` library: @@ -182,4 +181,4 @@ pipe.dumps(TomlMarshaller()) ## Additional References -:notebook: Tutorial: [Serializing LLM Pipelines](https://haystack.deepset.ai/tutorials/29_serializing_pipelines) \ No newline at end of file +:notebook: Tutorial: [Serializing LLM Pipelines](https://haystack.deepset.ai/tutorials/29_serializing_pipelines) diff --git a/docs-website/docs/concepts/pipelines/visualizing-pipelines.mdx b/docs-website/docs/concepts/pipelines/visualizing-pipelines.mdx index 04abf6df9b..adf2b8cdf2 100644 --- a/docs-website/docs/concepts/pipelines/visualizing-pipelines.mdx +++ b/docs-website/docs/concepts/pipelines/visualizing-pipelines.mdx @@ -13,8 +13,7 @@ You can visualize your pipelines as graphs to better understand how the componen Haystack pipelines have `draw()` and `show()` methods that enable you to visualize the pipeline as a graph using Mermaid graphs. -:::info -Data Privacy Notice +:::note Data Privacy Notice Exercise caution with sensitive data when using pipeline visualization. diff --git a/docs-website/docs/development/deployment.mdx b/docs-website/docs/development/deployment.mdx index 8cde258918..fdeebeb2ae 100644 --- a/docs-website/docs/development/deployment.mdx +++ b/docs-website/docs/development/deployment.mdx @@ -9,7 +9,7 @@ description: "Deploy your Haystack pipelines through various services such as Do Deploy your Haystack pipelines through various services such as Docker, Kubernetes, Ray, or a variety of Serverless options. -As a framework, Haystack is typically integrated into a variety of applications and environments, and there is no single, specific deployment strategy to follow. However, it is very common to make Haystack pipelines accessible through a service that can be easily called from other software systems. +As a framework, Haystack is typically integrated into a variety of applications and environments, and there is no single, specific deployment strategy to follow. However, it is very common to make Haystack pipelines accessible through a service that can be easily called from other software systems. These guides focus on tools and techniques that can be used to run Haystack pipelines in common scenarios. While these suggestions should not be considered the only way to do so, they should provide inspiration and the ability to customize them according to your needs. @@ -25,12 +25,11 @@ Here are the currently available guides on Haystack pipeline deployment: Haystack can be easily integrated into any HTTP application, but if you don’t have one, you can use Hayhooks, a ready-made application that serves Haystack pipelines as REST endpoints. We’ll be using Hayhooks throughout this guide to streamline the code examples. Refer to the Hayhooks [documentation](hayhooks.mdx) to get details about how to run the server and deploy your pipelines. -:::note -Looking to scale with confidence? +:::note Looking to scale with confidence? If your team needs **enterprise-grade support, best practices, and deployment guidance** to run Haystack in production, check out **Haystack Enterprise**. 📜 [Learn more about Haystack Enterprise](https://haystack.deepset.ai/blog/announcing-haystack-enterprise) 👉 [Get in touch with our team](https://www.deepset.ai/products-and-services/haystack-enterprise) -::: \ No newline at end of file +::: diff --git a/docs-website/docs/development/hayhooks.mdx b/docs-website/docs/development/hayhooks.mdx index 90d33003a5..424c81420c 100644 --- a/docs-website/docs/development/hayhooks.mdx +++ b/docs-website/docs/development/hayhooks.mdx @@ -9,8 +9,7 @@ description: "Hayhooks is a web application you can use to serve Haystack pipeli Hayhooks is a web application you can use to serve Haystack pipelines through HTTP endpoints. This page provides an overview of the main features of Hayhooks. -:::info -Hayhooks GitHub +:::info Hayhooks GitHub You can find the code and an in-depth explanation of the features in the [Hayhooks GitHub repository](https://github.com/deepset-ai/hayhooks). ::: @@ -238,10 +237,10 @@ To deploy a pipeline without listing it as an MCP Tool, set `skip_mcp = True` in class PipelineWrapper(BasePipelineWrapper): # This will skip the MCP Tool listing skip_mcp = True - + def setup(self) -> None: ... - + def run_api(self, urls: List[str], question: str) -> str: ... ``` @@ -298,4 +297,4 @@ async def custom_middleware(request: Request, call_next): if __name__ == "__main__": uvicorn.run("app:hayhooks", host=settings.host, port=settings.port) -``` \ No newline at end of file +``` diff --git a/docs-website/docs/development/logging.mdx b/docs-website/docs/development/logging.mdx index 97cfde1a00..03e37215d9 100644 --- a/docs-website/docs/development/logging.mdx +++ b/docs-website/docs/development/logging.mdx @@ -66,8 +66,7 @@ If Haystack detects a [structlog installation](https://www.structlog.org/en/stab To make development a more pleasurable experience, Haystack uses [structlog’s `ConsoleRender`](https://www.structlog.org/en/stable/console-output.html) by default to render structured logs as a nicely aligned and colorful output: -:::tip -Rich Formatting +:::tip Rich Formatting Install [_rich_](https://rich.readthedocs.io/en/stable/index.html) to beautify your logs even more! ::: diff --git a/docs-website/docs/document-stores/azureaisearchdocumentstore.mdx b/docs-website/docs/document-stores/azureaisearchdocumentstore.mdx index ed3f33c008..40237453d4 100644 --- a/docs-website/docs/document-stores/azureaisearchdocumentstore.mdx +++ b/docs-website/docs/document-stores/azureaisearchdocumentstore.mdx @@ -16,7 +16,7 @@ A Document Store for storing and retrieval from Azure AI Search Index. [Azure AI Search](https://learn.microsoft.com/en-us/azure/search/search-what-is-azure-search) is an enterprise-ready search and retrieval system to build RAG-based applications on Azure, with native LLM integrations. -`AzureAISearchDocumentStore` supports semantic reranking and metadata/content filtering. The Document Store is useful for various tasks such as generating knowledge base insights (catalog or document search), information discovery (data exploration), RAG, and automation. +`AzureAISearchDocumentStore` supports semantic reranking and metadata/content filtering. The Document Store is useful for various tasks such as generating knowledge base insights (catalog or document search), information discovery (data exploration), RAG, and automation. ### Initialization @@ -46,8 +46,7 @@ document_store.write_documents([ print(document_store.count_documents()) ``` -:::info -Latency Notice +:::info Latency Notice Due to Azure search index latency, the document count returned in the example might be zero if executed immediately. To ensure accurate results, be mindful of this latency when retrieving documents from the search index. ::: @@ -60,4 +59,4 @@ The Haystack Azure AI Search integration includes three Retriever components. Ea - [`AzureAISearchEmbeddingRetriever`](../pipeline-components/retrievers/azureaisearchembeddingretriever.mdx): This Retriever accepts the embeddings of a single query as input and returns a list of matching documents. The query must be embedded beforehand, which can be done using an [Embedder](../pipeline-components/embedders.mdx) component. - [`AzureAISearchBM25Retriever`](../pipeline-components/retrievers/azureaisearchbm25retriever.mdx): A keyword-based Retriever that retrieves documents matching a query from the Azure AI Search index. -- [`AzureAISearchHybridRetriever`](../pipeline-components/retrievers/azureaisearchhybridretriever.mdx): This Retriever combines embedding-based retrieval and keyword search to find matching documents in the search index to get more relevant results. \ No newline at end of file +- [`AzureAISearchHybridRetriever`](../pipeline-components/retrievers/azureaisearchhybridretriever.mdx): This Retriever combines embedding-based retrieval and keyword search to find matching documents in the search index to get more relevant results. diff --git a/docs-website/docs/document-stores/qdrant-document-store.mdx b/docs-website/docs/document-stores/qdrant-document-store.mdx index 67f4de2975..c7e3ef7855 100644 --- a/docs-website/docs/document-stores/qdrant-document-store.mdx +++ b/docs-website/docs/document-stores/qdrant-document-store.mdx @@ -14,7 +14,7 @@ Use the Qdrant vector database with Haystack. | API reference | [Qdrant](/reference/integrations-qdrant) | | GitHub link | https://github.com/deepset-ai/haystack-core-integrations/tree/main/integrations/qdrant | -Qdrant is a powerful high-performance, massive-scale vector database. The `QdrantDocumentStore` can be used with any Qdrant instance, in-memory, locally persisted, hosted, and the official Qdrant Cloud. +Qdrant is a powerful high-performance, massive-scale vector database. The `QdrantDocumentStore` can be used with any Qdrant instance, in-memory, locally persisted, hosted, and the official Qdrant Cloud. ### Installation @@ -39,15 +39,16 @@ document_store = QdrantDocumentStore( wait_result_from_api=True, ) document_store.write_documents([ - Document(content="This is first", embedding=[0.0]*5), + Document(content="This is first", embedding=[0.0]*5), Document(content="This is second", embedding=[0.1, 0.2, 0.3, 0.4, 0.5]) ]) print(document_store.count_documents()) ``` -> 🚧 Collections Created Outside Haystack -> -> When you create a `QdrantDocumentStore` instance, Haystack takes care of setting up the collection. In general, you cannot use a Qdrant collection created without Haystack with Haystack. If you want to migrate your existing collection, see the sample script at https://github.com/deepset-ai/haystack-core-integrations/blob/main/integrations/qdrant/src/haystack_integrations/document_stores/qdrant/migrate_to_sparse.py. +:::warning Collections Created Outside Haystack + +When you create a `QdrantDocumentStore` instance, Haystack takes care of setting up the collection. In general, you cannot use a Qdrant collection created without Haystack with Haystack. If you want to migrate your existing collection, see the sample script at https://github.com/deepset-ai/haystack-core-integrations/blob/main/integrations/qdrant/src/haystack_integrations/document_stores/qdrant/migrate_to_sparse.py. +::: You can also connect directly to [Qdrant Cloud](https://cloud.qdrant.io/login) directly. Once you have your API key and your cluster URL from the Qdrant dashboard, you can connect like this: @@ -65,14 +66,13 @@ document_store = QdrantDocumentStore( ) document_store.write_documents([ - Document(content="This is first", embedding=[0.0]*5), + Document(content="This is first", embedding=[0.0]*5), Document(content="This is second", embedding=[0.1, 0.2, 0.3, 0.4, 0.5]) ]) print(document_store.count_documents()) ``` -:::tip -More information +:::tip More information You can find more ways to initialize and use QdrantDocumentStore on our [integration page](https://haystack.deepset.ai/integrations/qdrant-document-store). ::: @@ -83,8 +83,7 @@ You can find more ways to initialize and use QdrantDocumentStore on our [integra - [`QdrantSparseEmbeddingRetriever`](../pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx): Retrieves documents from the `QdrantDocumentStore` based on their sparse embeddings. - [`QdrantHybridRetriever`](../pipeline-components/retrievers/qdranthybridretriever.mdx): Retrieves documents from the `QdrantDocumentStore` based on both dense and sparse embeddings. -:::info -Sparse Embedding Support +:::note Sparse Embedding Support To use Sparse Embedding support, you need to initialize the `QdrantDocumentStore` with `use_sparse_embeddings=True`, which is `False` by default. @@ -93,4 +92,4 @@ If you want to use Document Store or collection previously created with this fea ## Additional References -:cook: Cookbook: [Sparse Embedding Retrieval with Qdrant and FastEmbed](https://haystack.deepset.ai/cookbook/sparse_embedding_retrieval) \ No newline at end of file +:cook: Cookbook: [Sparse Embedding Retrieval with Qdrant and FastEmbed](https://haystack.deepset.ai/cookbook/sparse_embedding_retrieval) diff --git a/docs-website/docs/document-stores/weaviatedocumentstore.mdx b/docs-website/docs/document-stores/weaviatedocumentstore.mdx index 6e862cbbeb..97ae360c43 100644 --- a/docs-website/docs/document-stores/weaviatedocumentstore.mdx +++ b/docs-website/docs/document-stores/weaviatedocumentstore.mdx @@ -71,7 +71,10 @@ volumes: ... ``` -> 🚧 With this example, we explicitly enable access without authentication, so you don't need to set any username, password, or API key to connect to our local instance. That is strongly discouraged for production use. See the [authorization](#authorization) section for detailed information. +:::warning +With this example, we explicitly enable access without authentication, so you don't need to set any username, password, or API key to connect to our local instance. That is strongly discouraged for production use. See the [authorization](#authorization) section for detailed information. + +::: Start your container with `docker compose up -d` and then initialize the Document Store with: diff --git a/docs-website/docs/intro.mdx b/docs-website/docs/intro.mdx index ca50cdf836..a5f722f688 100644 --- a/docs-website/docs/intro.mdx +++ b/docs-website/docs/intro.mdx @@ -8,8 +8,7 @@ description: "Haystack is an **open-source AI framework** for building productio Haystack is an **open-source AI framework** for building production-ready **AI Agents**, **retrieval-augmented generative pipelines** and **state-of-the-art multimodal search systems**. Learn more about Haystack and how it works. -:::tip -Welcome to Haystack +:::tip Welcome to Haystack To skip the introductions and go directly to installing and creating a search app, see [Get Started](overview/get-started.mdx). ::: @@ -22,8 +21,7 @@ The core foundation of Haystack consists of components and pipelines, along with Supported by an engaged community of developers, Haystack has grown into a comprehensive and user-friendly framework for LLM-based development. -:::note -Looking to scale with confidence? +:::note Looking to scale with confidence? If your team needs **enterprise-grade support, best practices, and deployment guidance** to run Haystack in production, check out **Haystack Enterprise**. diff --git a/docs-website/docs/optimization/evaluation/model-based-evaluation.mdx b/docs-website/docs/optimization/evaluation/model-based-evaluation.mdx index c9bba02b44..60aa571003 100644 --- a/docs-website/docs/optimization/evaluation/model-based-evaluation.mdx +++ b/docs-website/docs/optimization/evaluation/model-based-evaluation.mdx @@ -65,7 +65,7 @@ result = evaluator.run(questions=questions, contexts=contexts, predicted_answers ### Using Small Cross-Encoder Models for Evaluation -Alongside LLMs for evaluation, we can also use small cross-encoder models. These models can calculate, for example, semantic answer similarity. In contrast to metrics based on LLMs, the metrics based on smaller models don’t require an API key of a model provider. +Alongside LLMs for evaluation, we can also use small cross-encoder models. These models can calculate, for example, semantic answer similarity. In contrast to metrics based on LLMs, the metrics based on smaller models don’t require an API key of a model provider. This method of using small cross-encoder models as evaluators is faster and cheaper to run but is less flexible in terms of what aspect you can evaluate. You can only evaluate what the small model was trained to evaluate. @@ -108,8 +108,7 @@ Currently, Haystack has integrations with [DeepEval](https://docs.confident-ai.c | Explanations of scores | ❌ | ✅ | | Monitoring dashboard | ❌ | ❌ | -:::info -Framework Documentation +:::info Framework Documentation You can find more information about the metrics in the documentation of the respective evaluation frameworks: @@ -119,4 +118,4 @@ You can find more information about the metrics in the documentation of the resp ## Additional References -:notebook: Tutorial: [Evaluating RAG Pipelines](https://haystack.deepset.ai/tutorials/35_evaluating_rag_pipelines) \ No newline at end of file +:notebook: Tutorial: [Evaluating RAG Pipelines](https://haystack.deepset.ai/tutorials/35_evaluating_rag_pipelines) diff --git a/docs-website/docs/overview/get-started.mdx b/docs-website/docs/overview/get-started.mdx index 66278901f9..ca8ff8c508 100644 --- a/docs-website/docs/overview/get-started.mdx +++ b/docs-website/docs/overview/get-started.mdx @@ -24,7 +24,6 @@ pip install haystack-ai Were you already using Haystack 1.x? :::warning -🚧 Installing `farm-haystack` and `haystack-ai` in the same Python environment (virtualenv, Colab, or system) causes problems. diff --git a/docs-website/docs/overview/installation.mdx b/docs-website/docs/overview/installation.mdx index 28d8d9d380..cd461e684b 100644 --- a/docs-website/docs/overview/installation.mdx +++ b/docs-website/docs/overview/installation.mdx @@ -31,7 +31,6 @@ conda install haystack-ai Were you already using Haystack 1.x? :::warning -🚧 Installing `farm-haystack` and `haystack-ai` in the same Python environment (virtualenv, Colab, or system) causes problems. @@ -49,8 +48,8 @@ If you have any questions, please reach out to us on the [GitHub Discussion](htt ### Optional Dependencies -Some components in Haystack rely on additional optional dependencies. -To keep the installation lightweight, these are not included by default – only the essentials are installed. +Some components in Haystack rely on additional optional dependencies. +To keep the installation lightweight, these are not included by default – only the essentials are installed. If you use a feature that requires an optional dependency that hasn't been installed, Haystack will raise an error that instructs you to install missing dependencies, for example: ```shell @@ -75,4 +74,4 @@ pip install --upgrade pip ## Install Haystack in editable mode pip install -e '.[dev]' -``` \ No newline at end of file +``` diff --git a/docs-website/docs/overview/migration.mdx b/docs-website/docs/overview/migration.mdx index ea85b98bd3..d981808168 100644 --- a/docs-website/docs/overview/migration.mdx +++ b/docs-website/docs/overview/migration.mdx @@ -19,8 +19,8 @@ Haystack 2.x represents a significant overhaul of Haystack 1.x, and it's importa Haystack 1.x was distributed with a package called `farm-haystack`. To migrate your application, you must uninstall `farm-haystack` and install the new `haystack-ai` package for Haystack 2.x. -:::note -🚧 that the two versions of the project cannot coexist in the same Python environment. +:::warning +Two versions of the project cannot coexist in the same Python environment. One of the options is to remove both packages if they are installed in the same environment, followed by installing only one of them: @@ -125,8 +125,7 @@ Haystack 1.x provided Agents, enabling the use of LLMs in a loop. Currently in Haystack 2.x, you can build Agents using three main elements in a pipeline: Chat Generators, ToolInvoker component, and Tools. A standalone Agent abstraction in Haystack 2.x is in an experimental phase. -:::info -Agents Documentation Page +:::note Agents Documentation Page Take a look at our 2.x [Agents](../concepts/agents.mdx) documentation page for more information and detailed examples. ::: diff --git a/docs-website/docs/pipeline-components/connectors/githubfileeditor.mdx b/docs-website/docs/pipeline-components/connectors/githubfileeditor.mdx index cbb56b72ad..3219c24dd9 100644 --- a/docs-website/docs/pipeline-components/connectors/githubfileeditor.mdx +++ b/docs-website/docs/pipeline-components/connectors/githubfileeditor.mdx @@ -45,8 +45,7 @@ pip install github-haystack ## Usage -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/docs/pipeline-components/connectors/githubissuecommenter.mdx b/docs-website/docs/pipeline-components/connectors/githubissuecommenter.mdx index a463d4f33b..2ea59eede2 100644 --- a/docs-website/docs/pipeline-components/connectors/githubissuecommenter.mdx +++ b/docs-website/docs/pipeline-components/connectors/githubissuecommenter.mdx @@ -40,8 +40,7 @@ pip install github-haystack ## Usage -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/docs/pipeline-components/connectors/githubissueviewer.mdx b/docs-website/docs/pipeline-components/connectors/githubissueviewer.mdx index 7e12d93123..5329968164 100644 --- a/docs-website/docs/pipeline-components/connectors/githubissueviewer.mdx +++ b/docs-website/docs/pipeline-components/connectors/githubissueviewer.mdx @@ -44,8 +44,7 @@ pip install github-haystack ## Usage -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/docs/pipeline-components/connectors/githubprcreator.mdx b/docs-website/docs/pipeline-components/connectors/githubprcreator.mdx index e10375b534..14b1535a57 100644 --- a/docs-website/docs/pipeline-components/connectors/githubprcreator.mdx +++ b/docs-website/docs/pipeline-components/connectors/githubprcreator.mdx @@ -47,8 +47,7 @@ pip install github-haystack ## Usage -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/docs/pipeline-components/connectors/githubrepoforker.mdx b/docs-website/docs/pipeline-components/connectors/githubrepoforker.mdx index 423edd5b97..e877d7e7b2 100644 --- a/docs-website/docs/pipeline-components/connectors/githubrepoforker.mdx +++ b/docs-website/docs/pipeline-components/connectors/githubrepoforker.mdx @@ -45,8 +45,7 @@ pip install github-haystack ## Usage -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/docs/pipeline-components/connectors/githubrepoviewer.mdx b/docs-website/docs/pipeline-components/connectors/githubrepoviewer.mdx index c3ecd89664..c3ce4a3934 100644 --- a/docs-website/docs/pipeline-components/connectors/githubrepoviewer.mdx +++ b/docs-website/docs/pipeline-components/connectors/githubrepoviewer.mdx @@ -44,8 +44,7 @@ pip install github-haystack ## Usage -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/docs/pipeline-components/connectors/langfuseconnector.mdx b/docs-website/docs/pipeline-components/connectors/langfuseconnector.mdx index baf5c72763..de895dc167 100644 --- a/docs-website/docs/pipeline-components/connectors/langfuseconnector.mdx +++ b/docs-website/docs/pipeline-components/connectors/langfuseconnector.mdx @@ -50,8 +50,7 @@ pip install langfuse-haystack
-:::info -Usage Notice +:::info Usage Notice To ensure proper tracing, always set environment variables before importing any Haystack components. This is crucial because Haystack initializes its internal tracing components during import. In the example below, we first set the environmental variables and then import the relevant Haystack components. @@ -127,8 +126,8 @@ weather_data = { return weather_data.get(city, f"Weather information for {city} not available") @tool -def calculate(operation: Annotated[str, "Mathematical operation: add, subtract, multiply, divide"], - a: Annotated[float, "First number"], +def calculate(operation: Annotated[str, "Mathematical operation: add, subtract, multiply, divide"], + a: Annotated[float, "First number"], b: Annotated[float, "Second number"]) -> str: """Perform basic mathematical calculations.""" if operation == "add": @@ -199,4 +198,4 @@ class CustomSpanHandler(DefaultSpanHandler): ## Add the custom handler to the LangfuseConnector connector = LangfuseConnector(span_handler=CustomSpanHandler()) -``` \ No newline at end of file +``` diff --git a/docs-website/docs/pipeline-components/downloaders/s3downloader.mdx b/docs-website/docs/pipeline-components/downloaders/s3downloader.mdx index cb53a2c5a3..4cd805eb41 100644 --- a/docs-website/docs/pipeline-components/downloaders/s3downloader.mdx +++ b/docs-website/docs/pipeline-components/downloaders/s3downloader.mdx @@ -38,8 +38,7 @@ downloader = S3Downloader( The component downloads multiple files in parallel using the `max_workers` parameter (default is 32 workers) to speed up processing of large document sets. Downloaded files are cached locally, and when the cache exceeds `max_cache_size` (default is 100 files), least recently accessed files are automatically removed. Already downloaded files are touched to update their access time without re-downloading. -:::info -Required Configuration +:::info Required Configuration The component requires two critical configurations: @@ -55,7 +54,7 @@ You can use the `file_extensions` parameter to download only specific file types ### Custom S3 Key Generation -By default, the component uses the `file_name` from Document metadata as the S3 key. If your S3 file structure doesn't match the file names in metadata, you can provide an optional `s3_key_generation_function` to customize how S3 keys are generated from Document metadata. +By default, the component uses the `file_name` from Document metadata as the S3 key. If your S3 file structure doesn't match the file names in metadata, you can provide an optional `s3_key_generation_function` to customize how S3 keys are generated from Document metadata. ## Usage @@ -173,7 +172,7 @@ pipe = Pipeline() ## Add S3Downloader to download files from S3 pipe.add_component( - "downloader", + "downloader", S3Downloader( file_root_path="/tmp/s3_downloads", file_extensions=[".pdf", ".txt"] @@ -182,7 +181,7 @@ pipe.add_component( ## Route documents by file type pipe.add_component( - "router", + "router", DocumentTypeRouter( file_path_meta_field="file_path", mime_types=["application/pdf", "text/plain"] @@ -278,4 +277,4 @@ result = pipe.run({ "downloader": {"documents": documents}, "prompt_builder": {"question": "What information is shown in the chart?"} }) -``` \ No newline at end of file +``` diff --git a/docs-website/docs/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx b/docs-website/docs/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx index 2c89726097..5d998a5aea 100644 --- a/docs-website/docs/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx +++ b/docs-website/docs/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx @@ -24,8 +24,7 @@ This component computes embeddings for documents using models through Amazon Bed Supported models are `amazon.titan-embed-text-v1`, `cohere.embed-english-v3`, `cohere.embed-multilingual-v3`, and `amazon.titan-embed-text-v2:0`. -:::info -Batch Inference +:::info Batch Inference Note that only Cohere models support batch inference – computing embeddings for more documents with the same request. ::: diff --git a/docs-website/docs/pipeline-components/embedders/vertexaidocumentembedder.mdx b/docs-website/docs/pipeline-components/embedders/vertexaidocumentembedder.mdx index 83ca9611f5..17d8a6e360 100644 --- a/docs-website/docs/pipeline-components/embedders/vertexaidocumentembedder.mdx +++ b/docs-website/docs/pipeline-components/embedders/vertexaidocumentembedder.mdx @@ -9,11 +9,12 @@ description: "This component computes embeddings for documents using models thro This component computes embeddings for documents using models through VertexAI Embeddings API. -> 🚧 Deprecation Notice -> -> This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. -> -> We recommend switching to the new [GoogleGenAIDocumentEmbedder](googlegenaidocumentembedder.mdx) integration instead. +:::warning Deprecation Notice + +This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. + +We recommend switching to the new [GoogleGenAIDocumentEmbedder](googlegenaidocumentembedder.mdx) integration instead. +::: | | | | --- | --- | @@ -99,4 +100,4 @@ result = query_pipeline.run({"text_embedder":{"text": query}}) print(result['retriever']['documents'][0]) ## Document(id=..., content: 'My name is Wolfgang and I live in Berlin') -``` \ No newline at end of file +``` diff --git a/docs-website/docs/pipeline-components/embedders/vertexaitextembedder.mdx b/docs-website/docs/pipeline-components/embedders/vertexaitextembedder.mdx index 06dbc94736..971b865768 100644 --- a/docs-website/docs/pipeline-components/embedders/vertexaitextembedder.mdx +++ b/docs-website/docs/pipeline-components/embedders/vertexaitextembedder.mdx @@ -9,11 +9,12 @@ description: "This component computes embeddings for text (such as a query) usin This component computes embeddings for text (such as a query) using models through VertexAI Embeddings API. -> 🚧 Deprecation Notice -> -> This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. -> -> We recommend switching to the new [GoogleGenAITextEmbedder](googlegenaitextembedder.mdx) integration instead. +:::warning Deprecation Notice + +This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. + +We recommend switching to the new [GoogleGenAITextEmbedder](googlegenaitextembedder.mdx) integration instead. +::: | | | | --- | --- | @@ -99,4 +100,4 @@ result = query_pipeline.run({"text_embedder":{"text": query}}) print(result['retriever']['documents'][0]) ## Document(id=..., content: 'My name is Wolfgang and I live in Berlin') -``` \ No newline at end of file +``` diff --git a/docs-website/docs/pipeline-components/generators/amazonbedrockchatgenerator.mdx b/docs-website/docs/pipeline-components/generators/amazonbedrockchatgenerator.mdx index 7b9e2d1407..778542cfd1 100644 --- a/docs-website/docs/pipeline-components/generators/amazonbedrockchatgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/amazonbedrockchatgenerator.mdx @@ -28,8 +28,7 @@ The models that we currently support are Anthropic's _Claude_, Meta's _Llama 2_, This component uses AWS for authentication. You can use the AWS CLI to authenticate through your IAM. For more information on setting up an IAM identity-based policy, see the [official documentation](https://docs.aws.amazon.com/bedrock/latest/userguide/security_iam_id-based-policy-examples.html). -:::info -Using AWS CLI +:::info Using AWS CLI Consider using AWS CLI as a more straightforward tool to manage your AWS services. With AWS CLI, you can quickly configure your [boto3 credentials](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html). This way, you won't need to provide detailed authentication parameters when initializing Amazon Bedrock Generator in Haystack. ::: diff --git a/docs-website/docs/pipeline-components/generators/amazonbedrockgenerator.mdx b/docs-website/docs/pipeline-components/generators/amazonbedrockgenerator.mdx index 0d2ff310db..6b0880aa69 100644 --- a/docs-website/docs/pipeline-components/generators/amazonbedrockgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/amazonbedrockgenerator.mdx @@ -28,8 +28,7 @@ The models that we currently support are Anthropic's Claude, AI21 Labs' Jurassic This component uses AWS for authentication. You can use the AWS CLI to authenticate through your IAM. For more information on setting up an IAM identity-based policy, see the [official documentation](https://docs.aws.amazon.com/bedrock/latest/userguide/security_iam_id-based-policy-examples.html). -:::info -Using AWS CLI +:::info Using AWS CLI Consider using AWS CLI as a more straightforward tool to manage your AWS services. With AWS CLI, you can quickly configure your [boto3 credentials](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html). This way, you won't need to provide detailed authentication parameters when initializing Amazon Bedrock Generator in Haystack. ::: diff --git a/docs-website/docs/pipeline-components/generators/azureopenaichatgenerator.mdx b/docs-website/docs/pipeline-components/generators/azureopenaichatgenerator.mdx index b35a2d0ff9..28fec1c219 100644 --- a/docs-website/docs/pipeline-components/generators/azureopenaichatgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/azureopenaichatgenerator.mdx @@ -83,8 +83,7 @@ print(response["replies"][0].text) >> pressure.","nationality":"American"} ``` -:::info -Model Compatibility and Limitations +:::info Model Compatibility and Limitations - Pydantic models and JSON schemas are supported for latest models starting from GPT-4o. - Older models only support basic JSON mode through `{"type": "json_object"}`. For details, see [OpenAI JSON mode documentation](https://platform.openai.com/docs/guides/structured-outputs#json-mode). diff --git a/docs-website/docs/pipeline-components/generators/googleaigeminichatgenerator.mdx b/docs-website/docs/pipeline-components/generators/googleaigeminichatgenerator.mdx index f385c2b519..033aa03149 100644 --- a/docs-website/docs/pipeline-components/generators/googleaigeminichatgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/googleaigeminichatgenerator.mdx @@ -9,11 +9,12 @@ description: "This component enables chat completion using Google Gemini models. This component enables chat completion using Google Gemini models. -> 🚧 Deprecation Notice -> -> This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. -> -> We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +:::warning Deprecation Notice + +This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. + +We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +::: | | | | --- | --- | diff --git a/docs-website/docs/pipeline-components/generators/googleaigeminigenerator.mdx b/docs-website/docs/pipeline-components/generators/googleaigeminigenerator.mdx index c237d49648..11fbc197ce 100644 --- a/docs-website/docs/pipeline-components/generators/googleaigeminigenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/googleaigeminigenerator.mdx @@ -9,11 +9,12 @@ description: "This component enables text generation using the Google Gemini mod This component enables text generation using the Google Gemini models. -> 🚧 Deprecation Notice -> -> This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. -> -> We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +:::warning Deprecation Notice + +This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. + +We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +::: | | | | --- | --- | @@ -124,7 +125,7 @@ docstore = InMemoryDocumentStore() template = """ Given the following information, answer the question. -Context: +Context: {% for document in documents %} {{ document.content }} {% endfor %} @@ -144,4 +145,4 @@ pipe.run({ "country": "France" } }) -``` \ No newline at end of file +``` diff --git a/docs-website/docs/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx b/docs-website/docs/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx index adfea274bf..703883825c 100644 --- a/docs-website/docs/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx +++ b/docs-website/docs/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx @@ -41,8 +41,7 @@ Only one of these fields appears per chunk. Use `chunk.start` and `chunk.finish_ For providers that support multiple candidates, set `n=1` to stream. -:::info -Parameter Details +:::info Parameter Details Check out the parameter details in our [API Reference for StreamingChunk](/reference/data-classes-api#streamingchunk). ::: @@ -103,8 +102,7 @@ We also support [Amazon Bedrock](../amazonbedrockgenerator.mdx): it provides acc When discussing open (weights) models, we're referring to models with public weights that anyone can deploy on their infrastructure. The datasets used for training are shared less frequently. One could choose to use an open model for several reasons, including more transparency and control of the model. -:::info -Commercial Use +:::info Commercial Use Not all open models are suitable for commercial use. We advise thoroughly reviewing the license, typically available on Hugging Face, before considering their adoption. ::: diff --git a/docs-website/docs/pipeline-components/generators/guides-to-generators/function-calling.mdx b/docs-website/docs/pipeline-components/generators/guides-to-generators/function-calling.mdx index 8d7eb1f12b..e7d3daa35b 100644 --- a/docs-website/docs/pipeline-components/generators/guides-to-generators/function-calling.mdx +++ b/docs-website/docs/pipeline-components/generators/guides-to-generators/function-calling.mdx @@ -18,8 +18,7 @@ Function calling is useful for a variety of purposes, but two main points are pa 1. **Enhanced LLM Functionality**: Function calling enhances the capabilities of LLMs beyond just text generation. It allows to convert human-generated prompts into precise function invocation descriptors. These descriptors can then be used by connected LLM frameworks to perform computations, manipulate data, and interact with external APIs. This expansion of functionality makes LLMs adaptable tools for a wide array of tasks and industries. 2. **Real-Time Data Access and Interaction**: Function calling lets LLMs create function calls that access and interact with real-time data. This is necessary for apps that need current data, like news, weather, or financial market updates. By giving access to the latest information, this feature greatly improves the usefulness and trustworthiness of LLMs in changing and time-critical situations. -:::note -🚧 Important to +:::note Important Note The model doesn't actually call the function. Function calling returns JSON with the name of a function and the arguments to invoke it. ::: diff --git a/docs-website/docs/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx b/docs-website/docs/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx index 1ae8211866..6524936837 100644 --- a/docs-website/docs/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx +++ b/docs-website/docs/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx @@ -26,8 +26,7 @@ The choice between Generators (or text Generators) and Chat Generators depends o As highlighted by the different input and output characteristics above, Generators and Chat Generators are distinct, often interacting with different models through calls to different APIs. Therefore, they are not automatically interchangeable. -:::tip -Multi-turn Interactions +:::tip Multi-turn Interactions If you anticipate a two-way interaction with the Language Model in a chat scenario, opting for a Chat Generator is generally better. This choice ensures a more structured and straightforward interaction with the Language Model. ::: @@ -72,8 +71,7 @@ Here’s an example for [argilla/notus-7b-v1](https://huggingface.co/argilla/not ## Different Types of Language Models -:::info -Topic Exploration +:::note Topic Exploration This field is young, constantly evolving, and distinctions are not always possible and precise. ::: @@ -122,9 +120,10 @@ It's worth noting that many recent Instruct models are equipped with a [chat tem Utilizing a Chat Generator is the optimal choice if the model features a Chat template and you intend to use it in chat scenarios. In these cases, you can expect out-of-the-box support for Chat Messages, and you don’t need to manually apply the aforementioned template. -> 🚧 Caution -> -> The distinction between Instruct and Chat models is not a strict dichotomy. -> -> - Following pre-training, Supervised Fine Tuning (SFT) and Alignment with Human Preferences can be executed multiple times using diverse datasets. In some cases, the differentiation between Instruct and Chat models may not be particularly meaningful. -> - Some open Language Models on Hugging Face lack explicit indications of their nature. +:::warning Caution + +The distinction between Instruct and Chat models is not a strict dichotomy. + +- Following pre-training, Supervised Fine Tuning (SFT) and Alignment with Human Preferences can be executed multiple times using diverse datasets. In some cases, the differentiation between Instruct and Chat models may not be particularly meaningful. +- Some open Language Models on Hugging Face lack explicit indications of their nature. +::: diff --git a/docs-website/docs/pipeline-components/generators/huggingfaceapigenerator.mdx b/docs-website/docs/pipeline-components/generators/huggingfaceapigenerator.mdx index 94d9561698..63706fedb6 100644 --- a/docs-website/docs/pipeline-components/generators/huggingfaceapigenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/huggingfaceapigenerator.mdx @@ -25,8 +25,7 @@ This generator enables text generation using various Hugging Face APIs. - [Paid Inference Endpoints](https://huggingface.co/inference-endpoints) - [Self-hosted Text Generation Inference](https://github.com/huggingface/text-generation-inference) -:::note -🚧 Important +:::note Important Note As of July 2025, the Hugging Face Inference API no longer offers generative models through the `text_generation` endpoint. Generative models are now only available through providers supporting the `chat_completion` endpoint. As a result, this component might no longer work with the Hugging Face Inference API. @@ -100,7 +99,10 @@ print(result) #### Using the Free Serverless Inference API (Not Recommended) -> 🚧 This example might not work as the Hugging Face Inference API no longer offers models that support the `text_generation` endpoint. Use the [`HuggingFaceAPIChatGenerator`](huggingfaceapichatgenerator.mdx) for generative models through the `chat_completion` endpoint. +:::warning +This example might not work as the Hugging Face Inference API no longer offers models that support the `text_generation` endpoint. Use the [`HuggingFaceAPIChatGenerator`](huggingfaceapichatgenerator.mdx) for generative models through the `chat_completion` endpoint. + +::: Formerly known as (free) Hugging Face Inference API, this API allows you to quickly experiment with many models hosted on the Hugging Face Hub, offloading the inference to Hugging Face servers. It's rate-limited and not meant for production. diff --git a/docs-website/docs/pipeline-components/generators/huggingfacelocalgenerator.mdx b/docs-website/docs/pipeline-components/generators/huggingfacelocalgenerator.mdx index 9758fb93bc..7770852d07 100644 --- a/docs-website/docs/pipeline-components/generators/huggingfacelocalgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/huggingfacelocalgenerator.mdx @@ -22,8 +22,7 @@ description: "`HuggingFaceLocalGenerator` provides an interface to generate text Keep in mind that if LLMs run locally, you may need a powerful machine to run them. This depends strongly on the model you select and its parameter count. -:::info -Looking for chat completion? +:::info Looking for chat completion? This component is designed for text generation, not for chat. If you want to use Hugging Face LLMs for chat, consider using [`HuggingFaceLocalChatGenerator`](huggingfacelocalchatgenerator.mdx) instead. ::: @@ -82,7 +81,7 @@ query = "What is the capital of France?" template = """ Given the following information, answer the question. -Context: +Context: {% for document in documents %} {{ document.content }} {% endfor %} @@ -116,4 +115,4 @@ print(res) - [Use Zephyr 7B Beta with Hugging Face for RAG](https://haystack.deepset.ai/cookbook/zephyr-7b-beta-for-rag) - [Information Extraction with Gorilla](https://haystack.deepset.ai/cookbook/information-extraction-gorilla) - [RAG on the Oscars using Llama 3.1 models](https://haystack.deepset.ai/cookbook/llama3_rag) -- [Agentic RAG with Llama 3.2 3B](https://haystack.deepset.ai/cookbook/llama32_agentic_rag) \ No newline at end of file +- [Agentic RAG with Llama 3.2 3B](https://haystack.deepset.ai/cookbook/llama32_agentic_rag) diff --git a/docs-website/docs/pipeline-components/generators/ollamachatgenerator.mdx b/docs-website/docs/pipeline-components/generators/ollamachatgenerator.mdx index d6344b9617..55447cd5ad 100644 --- a/docs-website/docs/pipeline-components/generators/ollamachatgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/ollamachatgenerator.mdx @@ -75,8 +75,7 @@ If you already installed Ollama in your system, you can execute: ollama pull zephyr ``` -:::tip -Choose a specific version of a model +:::tip Choose a specific version of a model You can also specify a tag to choose a specific (quantized) version of your model. The available tags are shown in the model card of the Ollama models library. This is an [example](https://ollama.ai/library/zephyr/tags) for Zephyr. In this case, simply run diff --git a/docs-website/docs/pipeline-components/generators/ollamagenerator.mdx b/docs-website/docs/pipeline-components/generators/ollamagenerator.mdx index 1ed6395a74..341ea98967 100644 --- a/docs-website/docs/pipeline-components/generators/ollamagenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/ollamagenerator.mdx @@ -51,8 +51,7 @@ If you have already installed Ollama in your system, you can execute: ollama pull zephyr ``` -:::tip -Choose a specific version of a model +:::tip Choose a specific version of a model You can also specify a tag to choose a specific (quantized) version of your model. The available tags are shown in the model card of the Ollama models library. This is an [example](https://ollama.ai/library/zephyr/tags) for Zephyr. In this case, simply run diff --git a/docs-website/docs/pipeline-components/generators/openaichatgenerator.mdx b/docs-website/docs/pipeline-components/generators/openaichatgenerator.mdx index d09ff51fd8..a81a5f7464 100644 --- a/docs-website/docs/pipeline-components/generators/openaichatgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/openaichatgenerator.mdx @@ -74,8 +74,7 @@ print(response["replies"][0].text) >> pressure.","nationality":"American"} ``` -:::info -Model Compatibility and Limitations +:::info Model Compatibility and Limitations - Pydantic models and JSON schemas are supported for latest models starting from `gpt-4o-2024-08-06`. - Older models only support basic JSON mode through `{"type": "json_object"}`. For details, see [OpenAI JSON mode documentation](https://platform.openai.com/docs/guides/structured-outputs#json-mode). diff --git a/docs-website/docs/pipeline-components/generators/vertexaigeminichatgenerator.mdx b/docs-website/docs/pipeline-components/generators/vertexaigeminichatgenerator.mdx index 308205495f..4963ca0609 100644 --- a/docs-website/docs/pipeline-components/generators/vertexaigeminichatgenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/vertexaigeminichatgenerator.mdx @@ -9,11 +9,12 @@ description: "`VertexAIGeminiChatGenerator` enables chat completion using Google `VertexAIGeminiChatGenerator` enables chat completion using Google Gemini models. -> 🚧 Deprecation Notice -> -> This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. -> -> We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +:::warning Deprecation Notice + +This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. + +We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +::: | | | | --- | --- | diff --git a/docs-website/docs/pipeline-components/generators/vertexaigeminigenerator.mdx b/docs-website/docs/pipeline-components/generators/vertexaigeminigenerator.mdx index 1d693493ee..8fdb5dc624 100644 --- a/docs-website/docs/pipeline-components/generators/vertexaigeminigenerator.mdx +++ b/docs-website/docs/pipeline-components/generators/vertexaigeminigenerator.mdx @@ -9,11 +9,12 @@ description: "`VertexAIGeminiGenerator` enables text generation using Google Gem `VertexAIGeminiGenerator` enables text generation using Google Gemini models. -> 🚧 Deprecation Notice -> -> This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. -> -> We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +:::warning Deprecation Notice + +This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. + +We recommend switching to the new [GoogleGenAIChatGenerator](googlegenaichatgenerator.mdx) integration instead. +::: | | | | --- | --- | @@ -122,7 +123,7 @@ query = "What is the capital of France?" template = """ Given the following information, answer the question. -Context: +Context: {% for document in documents %} {{ document.content }} {% endfor %} @@ -151,4 +152,4 @@ print(res) ## Additional References -:cook: Cookbook: [Function Calling and Multimodal QA with Gemini](https://haystack.deepset.ai/cookbook/vertexai-gemini-examples) \ No newline at end of file +:cook: Cookbook: [Function Calling and Multimodal QA with Gemini](https://haystack.deepset.ai/cookbook/vertexai-gemini-examples) diff --git a/docs-website/docs/pipeline-components/rankers/amazonbedrockranker.mdx b/docs-website/docs/pipeline-components/rankers/amazonbedrockranker.mdx index d0c60f11d5..a8c3e4de5e 100644 --- a/docs-website/docs/pipeline-components/rankers/amazonbedrockranker.mdx +++ b/docs-website/docs/pipeline-components/rankers/amazonbedrockranker.mdx @@ -36,8 +36,7 @@ pip install amazon-bedrock-haystack This component uses AWS for authentication. You can use the AWS CLI to authenticate through your IAM. For more information on setting up an IAM identity-based policy, see the [official documentation](https://docs.aws.amazon.com/bedrock/latest/userguide/security_iam_id-based-policy-examples.html). -:::info -Using AWS CLI +:::info Using AWS CLI Consider using AWS CLI as a more straightforward tool to manage your AWS services. With AWS CLI, you can quickly configure your [boto3 credentials](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html). This way, you won't need to provide detailed authentication parameters when initializing Amazon Bedrock in Haystack. ::: diff --git a/docs-website/docs/pipeline-components/rankers/cohereranker.mdx b/docs-website/docs/pipeline-components/rankers/cohereranker.mdx index 79499eb20a..23886f1c30 100644 --- a/docs-website/docs/pipeline-components/rankers/cohereranker.mdx +++ b/docs-website/docs/pipeline-components/rankers/cohereranker.mdx @@ -84,8 +84,7 @@ query = "Cities in France" res = document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, "ranker": {"query": query, "top_k": 2}}) ``` -:::tip -`top_k` parameter +:::note `top_k` parameter In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/docs/pipeline-components/rankers/nvidiaranker.mdx b/docs-website/docs/pipeline-components/rankers/nvidiaranker.mdx index dce5592049..0d2d858af5 100644 --- a/docs-website/docs/pipeline-components/rankers/nvidiaranker.mdx +++ b/docs-website/docs/pipeline-components/rankers/nvidiaranker.mdx @@ -97,8 +97,7 @@ query = "Cities in France" res = document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, "ranker": {"query": query, "top_k": 2}}) ``` -:::tip -`top_k` parameter +:::note `top_k` parameter In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/docs/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx b/docs-website/docs/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx index f483c77c62..c9072f0bc5 100644 --- a/docs-website/docs/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx +++ b/docs-website/docs/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx @@ -93,8 +93,7 @@ document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, ``` -:::info -Ranker top_k +:::note Ranker top_k In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/docs/pipeline-components/rankers/transformerssimilarityranker.mdx b/docs-website/docs/pipeline-components/rankers/transformerssimilarityranker.mdx index 5f715b4147..1aa46d73f3 100644 --- a/docs-website/docs/pipeline-components/rankers/transformerssimilarityranker.mdx +++ b/docs-website/docs/pipeline-components/rankers/transformerssimilarityranker.mdx @@ -9,10 +9,11 @@ description: "Use this component to rank documents based on their similarity to Use this component to rank documents based on their similarity to the query. The `TransformersSimilarityRanker` is a powerful, model-based Ranker that uses a cross-encoder model to produce document and query embeddings. -> 🚧 Legacy Component -> -> This component is considered legacy and will no longer receive updates. It may be deprecated in a future release, followed by removal after a deprecation period. -> Consider using SentenceTransformersSimilarityRanker instead, as it provides the same functionality and additional features. +:::warning Legacy Component + +This component is considered legacy and will no longer receive updates. It may be deprecated in a future release, followed by removal after a deprecation period. +Consider using SentenceTransformersSimilarityRanker instead, as it provides the same functionality and additional features. +::: | | | | --- | --- | @@ -94,8 +95,7 @@ document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, "ranker": {"query": query, "top_k": 2}}) ``` -:::info -Ranker `top_k` +:::note Ranker `top_k` In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/docs/pipeline-components/retrievers.mdx b/docs-website/docs/pipeline-components/retrievers.mdx index b82ca7cd44..d8adabd71a 100644 --- a/docs-website/docs/pipeline-components/retrievers.mdx +++ b/docs-website/docs/pipeline-components/retrievers.mdx @@ -11,7 +11,7 @@ Retrievers go through all the documents in a Document Store and select the ones ## How Do Retrievers Work? -Retrievers are the basic components of the majority of search systems. They’re used in the retrieval part of the retrieval-augmented generation (RAG) pipelines, they’re at the core of document retrieval pipelines, and they’re paired up with a Reader in extractive question answering pipelines. +Retrievers are the basic components of the majority of search systems. They’re used in the retrieval part of the retrieval-augmented generation (RAG) pipelines, they’re at the core of document retrieval pipelines, and they’re paired up with a Reader in extractive question answering pipelines. When given a query, the Retriever sifts through the documents in the Document Store, assigns a score to each document to indicate how relevant it is to the query, and returns top candidates. It then passes the selected documents on to the next component in the pipeline or returns them as answers to the query. @@ -69,7 +69,7 @@ For more information, read this Retriever's [documentation page](retrievers/filt #### Combining Retrievers -You can use different types of Retrievers in one pipeline to take advantage of the strengths and mitigate the weaknesses of each of them. There are two most common strategies to do this: combining a sparse and dense Retriever (hybrid retrieval) and using two dense Retrievers, each with a different model (multi-embedding retrieval). +You can use different types of Retrievers in one pipeline to take advantage of the strengths and mitigate the weaknesses of each of them. There are two most common strategies to do this: combining a sparse and dense Retriever (hybrid retrieval) and using two dense Retrievers, each with a different model (multi-embedding retrieval). ##### Hybrid Retrieval @@ -77,14 +77,12 @@ You can use different Retriever types, sparse and dense, in one pipeline to take See an example of this approach in our [`DocumentJoiner` docs](joiners/documentjoiner.mdx#in-a-pipeline). -:::tip -Metadata Filtering +:::tip Metadata Filtering When talking about hybrid retrieval, some database providers mean _metadata filtering_ on dense embedding retrieval. While this is different from combining different Retrievers, it is usually supported by Haystack Retrievers. For more information, check the [Metadata Filtering page](../concepts/metadata-filtering.mdx). ::: -:::info -Hybrid Retrievers +:::info Hybrid Retrievers Some Document Stores offer hybrid retrieval on the database side. In general, these solutions can be performant, but they offer fewer customization options (for instance, on how to merge results from different retrieval techniques). @@ -98,7 +96,7 @@ In this strategy, you use two embedding-based Retrievers, each with a different ## Retrievers and Document Stores -Retrievers are tightly coupled with [Document Stores](../concepts/document-store.mdx). Most Document Stores can work both with a sparse or a dense Retriever or both Retriever types combined. See the documentation of a specific Document Store to check which Retrievers it supports. +Retrievers are tightly coupled with [Document Stores](../concepts/document-store.mdx). Most Document Stores can work both with a sparse or a dense Retriever or both Retriever types combined. See the documentation of a specific Document Store to check which Retrievers it supports. ### Naming Conventions @@ -158,4 +156,4 @@ For details on how to initialize and use a Retriever in a pipeline, see the docu | [SnowflakeTableRetriever](retrievers/snowflaketableretriever.mdx) | Connects to a Snowflake database to execute an SQL query. | | [WeaviateBM25Retriever](retrievers/weaviatebm25retriever.mdx) | A keyword-based Retriever that fetches Documents matching a query from the Weaviate Document Store. | | [WeaviateEmbeddingRetriever](retrievers/weaviateembeddingretriever.mdx) | An embedding Retriever compatible with the Weaviate Document Store. | -| [WeaviateHybridRetriever](retrievers/weaviatehybridretriever.mdx) | Combines BM25 keyword search and vector similarity to fetch documents from the Weaviate Document Store. | \ No newline at end of file +| [WeaviateHybridRetriever](retrievers/weaviatehybridretriever.mdx) | Combines BM25 keyword search and vector similarity to fetch documents from the Weaviate Document Store. | diff --git a/docs-website/docs/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx b/docs-website/docs/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx index b289b97e07..524cd4bb42 100644 --- a/docs-website/docs/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx +++ b/docs-website/docs/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx @@ -9,7 +9,7 @@ description: "An embedding Retriever compatible with the Azure AI Search Documen An embedding Retriever compatible with the Azure AI Search Document Store. -This Retriever accepts the embeddings of a single query as input and returns a list of matching documents. +This Retriever accepts the embeddings of a single query as input and returns a list of matching documents. | | | | --- | --- | @@ -30,8 +30,7 @@ By default, the `AzureAISearchDocumentStore` uses the [HNSW algorithm](https://l In addition to the `query_embedding`, the `AzureAISearchEmbeddingRetriever` accepts other optional parameters, including `top_k` (the maximum number of documents to retrieve) and `filters` to narrow down the search space. -:::info -Semantic Ranking +:::info Semantic Ranking The semantic ranking capability of Azure AI Search is not available for vector retrieval. To include semantic ranking in your retrieval process, use the [`AzureAISearchBM25Retriever`](azureaisearchbm25retriever.mdx) or [`AzureAISearchHybridRetriever`](azureaisearchhybridretriever.mdx). For more details, see [Azure AI documentation](https://learn.microsoft.com/en-us/azure/search/semantic-how-to-query-request?tabs=portal-query#set-up-the-query). ::: @@ -119,4 +118,4 @@ result = query_pipeline.run({"text_embedder": {"text": query}}) print(result["retriever"]["documents"][0]) -``` \ No newline at end of file +``` diff --git a/docs-website/docs/pipeline-components/retrievers/qdranthybridretriever.mdx b/docs-website/docs/pipeline-components/retrievers/qdranthybridretriever.mdx index 7630d68018..cc1b9d8399 100644 --- a/docs-website/docs/pipeline-components/retrievers/qdranthybridretriever.mdx +++ b/docs-website/docs/pipeline-components/retrievers/qdranthybridretriever.mdx @@ -24,8 +24,7 @@ The `QdrantHybridRetriever` is a Retriever based both on dense and sparse embedd It compares the query and document’s dense and sparse embeddings and fetches the documents most relevant to the query from the `QdrantDocumentStore`, fusing the scores with Reciprocal Rank Fusion. -:::tip -Hybrid Retrieval Pipeline +:::tip Hybrid Retrieval Pipeline If you want additional customization for merging or fusing results, consider creating a hybrid retrieval pipeline with [`DocumentJoiner`](../joiners/documentjoiner.mdx). @@ -37,10 +36,9 @@ When using the `QdrantHybridRetriever`, make sure it has the query and document - Adding a (dense) document Embedder and a sparse document Embedder to your indexing pipeline, - Adding a (dense) text Embedder and a sparse text Embedder to your query pipeline. -In addition to `query_embedding` and `query_sparse_embedding`, the `QdrantHybridRetriever` accepts other optional parameters, including `top_k` (the maximum number of documents to retrieve) and `filters` to narrow down the search space. +In addition to `query_embedding` and `query_sparse_embedding`, the `QdrantHybridRetriever` accepts other optional parameters, including `top_k` (the maximum number of documents to retrieve) and `filters` to narrow down the search space. -:::info -Sparse Embedding Support +:::note Sparse Embedding Support To use Sparse Embedding support, you need to initialize the `QdrantDocumentStore` with `use_sparse_embeddings=True`, which is `False` by default. diff --git a/docs-website/docs/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx b/docs-website/docs/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx index dbba4871e7..933588c094 100644 --- a/docs-website/docs/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx +++ b/docs-website/docs/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx @@ -28,8 +28,7 @@ When using the `QdrantSparseEmbeddingRetriever`, make sure it has the query and In addition to the `query_sparse_embedding`, the `QdrantSparseEmbeddingRetriever` accepts other optional parameters, including `top_k` (the maximum number of documents to retrieve) and `filters` to narrow down the search space. -:::info -Sparse Embedding Support +:::note Sparse Embedding Support To use Sparse Embedding support, you need to initialize the `QdrantDocumentStore` with `use_sparse_embeddings=True`, which is `False` by default. diff --git a/docs-website/docs/pipeline-components/tools/toolinvoker.mdx b/docs-website/docs/pipeline-components/tools/toolinvoker.mdx index e420585a4b..c78fcf9a60 100644 --- a/docs-website/docs/pipeline-components/tools/toolinvoker.mdx +++ b/docs-website/docs/pipeline-components/tools/toolinvoker.mdx @@ -29,8 +29,7 @@ The `ToolInvoker` has two additionally helpful parameters: - `convert_result_to_json_string`: Use `json.dumps` (when True) or `str` (when False) to convert the result into a string. - `raise_on_failure`: If True, it will raise an exception in case of errors. If False, it will return a `ChatMessage` object with `error=True` and a description of the error in `result`. Use this, for example, when you want to keep the Language Model running in a loop and fixing its errors. -:::info -ChatMessage and Tool Data Classes +:::info ChatMessage and Tool Data Classes Follow the links to learn more about [ChatMessage](../../concepts/data-classes/chatmessage.mdx) and [Tool](../../tools/tool.mdx) data classes. ::: @@ -54,7 +53,7 @@ tool = Tool(name="weather_tool", description="A tool to get the weather", function=dummy_weather_function, parameters=parameters) - + ## Usually, the ChatMessage with tool_calls is generated by a Language Model ## Here, we create it manually for demonstration purposes tool_call = ToolCall( @@ -183,7 +182,7 @@ print(result) ], "_name=None", "_meta="{ - + }")" ] } @@ -196,4 +195,4 @@ print(result) - [Define & Run Tools](https://haystack.deepset.ai/cookbook/tools_support) - [Newsletter Sending Agent with Haystack Tools](https://haystack.deepset.ai/cookbook/newsletter-agent) -- [Create a Swarm of Agents](https://haystack.deepset.ai/cookbook/swarm) \ No newline at end of file +- [Create a Swarm of Agents](https://haystack.deepset.ai/cookbook/swarm) diff --git a/docs-website/docs/pipeline-components/websearch/searchapiwebsearch.mdx b/docs-website/docs/pipeline-components/websearch/searchapiwebsearch.mdx index d5b4b75247..423e59cea0 100644 --- a/docs-website/docs/pipeline-components/websearch/searchapiwebsearch.mdx +++ b/docs-website/docs/pipeline-components/websearch/searchapiwebsearch.mdx @@ -26,8 +26,7 @@ To search the content of the web pages, use the [`LinkContentFetcher`](../fetche `SearchApiWebSearch` requires a [SearchApi](https://www.searchapi.io) key to work. It uses a `SEARCHAPI_API_KEY` environment variable by default. Otherwise, you can pass an `api_key` at initialization – see code examples below. -:::info -Alternative search +:::info Alternative search To use [Serper Dev](https://serper.dev/?gclid=Cj0KCQiAgqGrBhDtARIsAM5s0_kPElllv3M59UPok1Ad-ZNudLaY21zDvbt5qw-b78OcUoqqvplVHRwaAgRgEALw_wcB) as an alternative, see its respective [documentation page](serperdevwebsearch.mdx). ::: diff --git a/docs-website/docs/pipeline-components/websearch/serperdevwebsearch.mdx b/docs-website/docs/pipeline-components/websearch/serperdevwebsearch.mdx index f0a49f9555..66fcb2b007 100644 --- a/docs-website/docs/pipeline-components/websearch/serperdevwebsearch.mdx +++ b/docs-website/docs/pipeline-components/websearch/serperdevwebsearch.mdx @@ -26,8 +26,7 @@ To search the content of the web pages, use the [`LinkContentFetcher`](../fetche `SerperDevWebSearch` requires a [SerperDev](https://serper.dev/) key to work. It uses a `SERPERDEV_API_KEY` environment variable by default. Otherwise, you can pass an `api_key` at initialization – see code examples below. -:::info -Alternative search +:::info Alternative search To use [Search API](https://www.searchapi.io/) as an alternative, see its respective [documentation page](searchapiwebsearch.mdx). ::: diff --git a/docs-website/docs/tools/ready-made-tools/githubfileeditortool.mdx b/docs-website/docs/tools/ready-made-tools/githubfileeditortool.mdx index 798f9c092f..91f32929cd 100644 --- a/docs-website/docs/tools/ready-made-tools/githubfileeditortool.mdx +++ b/docs-website/docs/tools/ready-made-tools/githubfileeditortool.mdx @@ -22,7 +22,7 @@ A Tool that allows Agents and ToolInvokers to edit files in GitHub repositories. The tool supports multiple file operations including editing existing files, creating new files, deleting files, and undoing recent changes. It supports four main commands: - **EDIT**: Edit an existing file by replacing specific content -- **CREATE**: Create a new file with specified content +- **CREATE**: Create a new file with specified content - **DELETE**: Delete an existing file - **UNDO**: Revert the last commit if made by the same user @@ -43,8 +43,7 @@ Install the GitHub integration to use the `GitHubFileEditorTool`: pip install github-haystack ``` -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: @@ -104,4 +103,4 @@ print(response["last_message"].text) ```bash The file `README.md` has been successfully edited to correct the spelling of 'tpyo' to 'typo'. -``` \ No newline at end of file +``` diff --git a/docs-website/docs/tools/ready-made-tools/githubissuecommentertool.mdx b/docs-website/docs/tools/ready-made-tools/githubissuecommentertool.mdx index b67a714d2e..706e4bce35 100644 --- a/docs-website/docs/tools/ready-made-tools/githubissuecommentertool.mdx +++ b/docs-website/docs/tools/ready-made-tools/githubissuecommentertool.mdx @@ -37,8 +37,7 @@ Install the GitHub integration to use the `GitHubIssueCommenterTool`: pip install github-haystack ``` -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: @@ -91,4 +90,4 @@ print(response["last_message"].text) ```bash I have posted the comment on the GitHub issue, acknowledging the bug report and mentioning that the team is investigating the problem. If you need anything else, feel free to ask! -``` \ No newline at end of file +``` diff --git a/docs-website/docs/tools/ready-made-tools/githubissueviewertool.mdx b/docs-website/docs/tools/ready-made-tools/githubissueviewertool.mdx index e797ed21fd..ef6496d502 100644 --- a/docs-website/docs/tools/ready-made-tools/githubissueviewertool.mdx +++ b/docs-website/docs/tools/ready-made-tools/githubissueviewertool.mdx @@ -41,8 +41,7 @@ Install the GitHub integration to use the `GitHubIssueViewerTool`: pip install github-haystack ``` -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: @@ -99,4 +98,4 @@ The GitHub issue titled "SentenceTransformer no longer accepts 'gpu' as argument The user indicates that this change is problematic since it prevents users from instantiating the embedding model with GPU support, forcing them to default to using only the CPU for model execution. The issue was later closed with a comment indicating it was fixed in another pull request (#124). -``` \ No newline at end of file +``` diff --git a/docs-website/docs/tools/ready-made-tools/githubprcreatortool.mdx b/docs-website/docs/tools/ready-made-tools/githubprcreatortool.mdx index 12465f704f..49fa4a7198 100644 --- a/docs-website/docs/tools/ready-made-tools/githubprcreatortool.mdx +++ b/docs-website/docs/tools/ready-made-tools/githubprcreatortool.mdx @@ -36,8 +36,7 @@ Install the GitHub integration to use the `GitHubPRCreatorTool`: pip install github-haystack ``` -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: @@ -93,4 +92,4 @@ print(response["last_message"].text) ```bash The pull request titled "Fix authentication bug" has been created successfully and linked to issue [#123](https://github.com/owner/repo/issues/4). -``` \ No newline at end of file +``` diff --git a/docs-website/docs/tools/ready-made-tools/githubrepoviewertool.mdx b/docs-website/docs/tools/ready-made-tools/githubrepoviewertool.mdx index 8142c95ddf..a31af15929 100644 --- a/docs-website/docs/tools/ready-made-tools/githubrepoviewertool.mdx +++ b/docs-website/docs/tools/ready-made-tools/githubrepoviewertool.mdx @@ -43,8 +43,7 @@ Install the GitHub integration to use the `GitHubRepoViewerTool`: pip install github-haystack ``` -:::info -Repository Placeholder +:::info Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: @@ -127,4 +126,4 @@ The `deepset-ai/haystack` repository has a structured layout that includes sever - **`SECURITY.md`**: Contains information about the security policy of the repository. This structure indicates a well-organized repository that follows common conventions in open-source projects, with a focus on documentation, contribution guidelines, and testing. The core functionalities are likely housed in the `haystack` directory, with additional resources provided in the other directories. -``` \ No newline at end of file +``` diff --git a/docs-website/docs/tools/tool.mdx b/docs-website/docs/tools/tool.mdx index 959a5f67c7..e70918191a 100644 --- a/docs-website/docs/tools/tool.mdx +++ b/docs-website/docs/tools/tool.mdx @@ -173,8 +173,7 @@ To better understand this section, make sure you are also familiar with Haystack Using the `tools` parameter, you can pass tools as a list of Tool instances or a single Toolset during initialization or in the `run` method. Tools passed at runtime override those set at initialization. -:::info -Chat Generators support +:::info Chat Generators support Not all Chat Generators currently support tools, but we are actively expanding tool support across more models. diff --git a/docs-website/versioned_docs/version-2.18/overview/get-started.mdx b/docs-website/versioned_docs/version-2.18/overview/get-started.mdx index 0fb35e9372..ca8ff8c508 100644 --- a/docs-website/versioned_docs/version-2.18/overview/get-started.mdx +++ b/docs-website/versioned_docs/version-2.18/overview/get-started.mdx @@ -24,7 +24,6 @@ pip install haystack-ai Were you already using Haystack 1.x? :::warning -Warning Installing `farm-haystack` and `haystack-ai` in the same Python environment (virtualenv, Colab, or system) causes problems. diff --git a/docs-website/versioned_docs/version-2.18/overview/migration.mdx b/docs-website/versioned_docs/version-2.18/overview/migration.mdx index 5579963c01..a1a338d221 100644 --- a/docs-website/versioned_docs/version-2.18/overview/migration.mdx +++ b/docs-website/versioned_docs/version-2.18/overview/migration.mdx @@ -20,7 +20,7 @@ Haystack 2.x represents a significant overhaul of Haystack 1.x, and it's importa Haystack 1.x was distributed with a package called `farm-haystack`. To migrate your application, you must uninstall `farm-haystack` and install the new `haystack-ai` package for Haystack 2.x. :::warning -Note that the two versions of the project cannot coexist in the same Python environment. +Two versions of the project cannot coexist in the same Python environment. One of the options is to remove both packages if they are installed in the same environment, followed by installing only one of them: diff --git a/docs-website/versioned_docs/version-2.19/concepts/device-management.mdx b/docs-website/versioned_docs/version-2.19/concepts/device-management.mdx index a7bc31fcf0..65fde6267a 100644 --- a/docs-website/versioned_docs/version-2.19/concepts/device-management.mdx +++ b/docs-website/versioned_docs/version-2.19/concepts/device-management.mdx @@ -24,8 +24,7 @@ Haystack’s device management is built on the following abstractions: With the above abstractions, Haystack can fully address any supported device that’s part of your local machine and can support the usage of multiple devices at the same time. Every component that supports local inference will internally handle the conversion of these generic representations to their backend-specific representations. -:::note -Source Code +:::note Source Code Find the full code for the abstractions above in the Haystack GitHub [repo](https://github.com/deepset-ai/haystack/blob/6a776e672fb69cc4ee42df9039066200f1baf24e/haystack/utils/device.py). ::: diff --git a/docs-website/versioned_docs/version-2.19/concepts/document-store.mdx b/docs-website/versioned_docs/version-2.19/concepts/document-store.mdx index 4d5511125e..bb1ef3fa68 100644 --- a/docs-website/versioned_docs/version-2.19/concepts/document-store.mdx +++ b/docs-website/versioned_docs/version-2.19/concepts/document-store.mdx @@ -11,14 +11,12 @@ You can think of the Document Store as a database that stores your data and prov Document Store is an object that stores your documents. In Haystack, a Document Store is different from a component, as it doesn’t have the `run()` method. You can think of it as an interface to your database – you put the information there, or you can look through it. This means that a Document Store is not a piece of a pipeline but rather a tool that the components of a pipeline have access to and can interact with. -:::tip -Work with Retrievers +:::tip Work with Retrievers The most common way to use a Document Store in Haystack is to fetch documents using a Retriever. A Document Store will often have a corresponding Retriever to get the most out of specific technologies. See more information in our [Retriever](../pipeline-components/retrievers.mdx) documentation. ::: -:::note -How to choose a Document Store? +:::note How to choose a Document Store? To learn about different types of Document Stores and their strengths and disadvantages, head to the [Choosing a Document Store](document-store/choosing-a-document-store.mdx) page. ::: @@ -67,8 +65,7 @@ document_store.write_documents([ ]) ``` -:::note -`DocumentWriter` +:::note `DocumentWriter` See `DocumentWriter` component [docs](../pipeline-components/writers/documentwriter.mdx) to write your documents into a Document Store in a pipeline. ::: diff --git a/docs-website/versioned_docs/version-2.19/concepts/document-store/choosing-a-document-store.mdx b/docs-website/versioned_docs/version-2.19/concepts/document-store/choosing-a-document-store.mdx index 9094c09285..2f79b6b29f 100644 --- a/docs-website/versioned_docs/version-2.19/concepts/document-store/choosing-a-document-store.mdx +++ b/docs-website/versioned_docs/version-2.19/concepts/document-store/choosing-a-document-store.mdx @@ -56,8 +56,7 @@ Continue further down the article for a more complex explanation of the strength Vector libraries are often included in the “vector database” category improperly, as they are limited to handling only vectors, are designed to work in-memory, and normally don’t have a clean way to store data on disk. Still, they are the way to go every time performance and speed are the top requirements for your AI application, as these libraries can use hardware resources very effectively. -:::warning -In progress +:::warning In progress We are currently developing the support for vector libraries in Haystack. ::: diff --git a/docs-website/versioned_docs/version-2.19/concepts/document-store/creating-custom-document-stores.mdx b/docs-website/versioned_docs/version-2.19/concepts/document-store/creating-custom-document-stores.mdx index d937671526..c4740ea97f 100644 --- a/docs-website/versioned_docs/version-2.19/concepts/document-store/creating-custom-document-stores.mdx +++ b/docs-website/versioned_docs/version-2.19/concepts/document-store/creating-custom-document-stores.mdx @@ -48,8 +48,6 @@ pip install example-haystack ``` :::tip -Tip - Our [GitHub template](https://github.com/deepset-ai/document-store) ships a GitHub workflow that will automatically publish the Document Store package on PyPI. ::: diff --git a/docs-website/versioned_docs/version-2.19/concepts/pipelines.mdx b/docs-website/versioned_docs/version-2.19/concepts/pipelines.mdx index 0b05a3a472..9ddf76a185 100644 --- a/docs-website/versioned_docs/version-2.19/concepts/pipelines.mdx +++ b/docs-website/versioned_docs/version-2.19/concepts/pipelines.mdx @@ -98,8 +98,7 @@ Thanks to serialization, you can save and then load your pipelines. Serializatio Haystack pipelines delegate the serialization to its components, so serializing a pipeline simply means serializing each component in the pipeline one after the other, along with their connections. The pipeline is serialized into a dictionary format, which acts as an intermediate format that you can then convert into the final format you want. -:::note -Serialization formats +:::note Serialization formats Haystack only supports YAML format at this time. We'll be rolling out more formats gradually. ::: diff --git a/docs-website/versioned_docs/version-2.19/concepts/pipelines/serialization.mdx b/docs-website/versioned_docs/version-2.19/concepts/pipelines/serialization.mdx index feeb9a473c..d216de815d 100644 --- a/docs-website/versioned_docs/version-2.19/concepts/pipelines/serialization.mdx +++ b/docs-website/versioned_docs/version-2.19/concepts/pipelines/serialization.mdx @@ -11,8 +11,7 @@ Save your pipelines into a custom format and explore the serialization options. Serialization means converting a pipeline to a format that you can save on your disk and load later. -:::note -Serialization formats +:::note Serialization formats Haystack 2.0 only supports YAML format at this time. We will be rolling out more formats gradually. ::: diff --git a/docs-website/versioned_docs/version-2.19/concepts/pipelines/visualizing-pipelines.mdx b/docs-website/versioned_docs/version-2.19/concepts/pipelines/visualizing-pipelines.mdx index 5d3637e312..98256d292a 100644 --- a/docs-website/versioned_docs/version-2.19/concepts/pipelines/visualizing-pipelines.mdx +++ b/docs-website/versioned_docs/version-2.19/concepts/pipelines/visualizing-pipelines.mdx @@ -13,8 +13,7 @@ You can visualize your pipelines as graphs to better understand how the componen Haystack pipelines have `draw()` and `show()` methods that enable you to visualize the pipeline as a graph using Mermaid graphs. -:::note -Data Privacy Notice +:::note Data Privacy Notice Exercise caution with sensitive data when using pipeline visualization. diff --git a/docs-website/versioned_docs/version-2.19/development/deployment.mdx b/docs-website/versioned_docs/version-2.19/development/deployment.mdx index 50458dc6e5..fdeebeb2ae 100644 --- a/docs-website/versioned_docs/version-2.19/development/deployment.mdx +++ b/docs-website/versioned_docs/version-2.19/development/deployment.mdx @@ -25,8 +25,7 @@ Here are the currently available guides on Haystack pipeline deployment: Haystack can be easily integrated into any HTTP application, but if you don’t have one, you can use Hayhooks, a ready-made application that serves Haystack pipelines as REST endpoints. We’ll be using Hayhooks throughout this guide to streamline the code examples. Refer to the Hayhooks [documentation](hayhooks.mdx) to get details about how to run the server and deploy your pipelines. -:::note -Looking to scale with confidence? +:::note Looking to scale with confidence? If your team needs **enterprise-grade support, best practices, and deployment guidance** to run Haystack in production, check out **Haystack Enterprise**. diff --git a/docs-website/versioned_docs/version-2.19/development/hayhooks.mdx b/docs-website/versioned_docs/version-2.19/development/hayhooks.mdx index 1582b3f170..83b1aa0463 100644 --- a/docs-website/versioned_docs/version-2.19/development/hayhooks.mdx +++ b/docs-website/versioned_docs/version-2.19/development/hayhooks.mdx @@ -9,8 +9,7 @@ description: "Hayhooks is a web application you can use to serve Haystack pipeli Hayhooks is a web application you can use to serve Haystack pipelines through HTTP endpoints. This page provides an overview of the main features of Hayhooks. -:::note -Hayhooks GitHub +:::note Hayhooks GitHub You can find the code and an in-depth explanation of the features in the [Hayhooks GitHub repository](https://github.com/deepset-ai/hayhooks). ::: diff --git a/docs-website/versioned_docs/version-2.19/development/logging.mdx b/docs-website/versioned_docs/version-2.19/development/logging.mdx index bb9d148cb0..a7f3d94a5f 100644 --- a/docs-website/versioned_docs/version-2.19/development/logging.mdx +++ b/docs-website/versioned_docs/version-2.19/development/logging.mdx @@ -68,8 +68,7 @@ To make development a more pleasurable experience, Haystack uses [structlog’s -:::tip -Rich Formatting +:::tip Rich Formatting Install [_rich_](https://rich.readthedocs.io/en/stable/index.html) to beautify your logs even more! ::: diff --git a/docs-website/versioned_docs/version-2.19/document-stores/azureaisearchdocumentstore.mdx b/docs-website/versioned_docs/version-2.19/document-stores/azureaisearchdocumentstore.mdx index 83034b81e1..bc6c28f783 100644 --- a/docs-website/versioned_docs/version-2.19/document-stores/azureaisearchdocumentstore.mdx +++ b/docs-website/versioned_docs/version-2.19/document-stores/azureaisearchdocumentstore.mdx @@ -46,8 +46,7 @@ document_store.write_documents([ print(document_store.count_documents()) ``` -:::note -Latency Notice +:::note Latency Notice Due to Azure search index latency, the document count returned in the example might be zero if executed immediately. To ensure accurate results, be mindful of this latency when retrieving documents from the search index. ::: diff --git a/docs-website/versioned_docs/version-2.19/document-stores/qdrant-document-store.mdx b/docs-website/versioned_docs/version-2.19/document-stores/qdrant-document-store.mdx index 598f0a302f..553091c74e 100644 --- a/docs-website/versioned_docs/version-2.19/document-stores/qdrant-document-store.mdx +++ b/docs-website/versioned_docs/version-2.19/document-stores/qdrant-document-store.mdx @@ -45,8 +45,7 @@ document_store.write_documents([ print(document_store.count_documents()) ``` -:::warning -Collections Created Outside Haystack +:::warning Collections Created Outside Haystack When you create a `QdrantDocumentStore` instance, Haystack takes care of setting up the collection. In general, you cannot use a Qdrant collection created without Haystack with Haystack. If you want to migrate your existing collection, see the sample script at https://github.com/deepset-ai/haystack-core-integrations/blob/main/integrations/qdrant/src/haystack_integrations/document_stores/qdrant/migrate_to_sparse.py. ::: @@ -73,8 +72,7 @@ document_store.write_documents([ print(document_store.count_documents()) ``` -:::tip -More information +:::tip More information You can find more ways to initialize and use QdrantDocumentStore on our [integration page](https://haystack.deepset.ai/integrations/qdrant-document-store). ::: @@ -85,8 +83,7 @@ You can find more ways to initialize and use QdrantDocumentStore on our [integra - [`QdrantSparseEmbeddingRetriever`](../pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx): Retrieves documents from the `QdrantDocumentStore` based on their sparse embeddings. - [`QdrantHybridRetriever`](../pipeline-components/retrievers/qdranthybridretriever.mdx): Retrieves documents from the `QdrantDocumentStore` based on both dense and sparse embeddings. -:::note -Sparse Embedding Support +:::note Sparse Embedding Support To use Sparse Embedding support, you need to initialize the `QdrantDocumentStore` with `use_sparse_embeddings=True`, which is `False` by default. diff --git a/docs-website/versioned_docs/version-2.19/intro.mdx b/docs-website/versioned_docs/version-2.19/intro.mdx index ca50cdf836..a5f722f688 100644 --- a/docs-website/versioned_docs/version-2.19/intro.mdx +++ b/docs-website/versioned_docs/version-2.19/intro.mdx @@ -8,8 +8,7 @@ description: "Haystack is an **open-source AI framework** for building productio Haystack is an **open-source AI framework** for building production-ready **AI Agents**, **retrieval-augmented generative pipelines** and **state-of-the-art multimodal search systems**. Learn more about Haystack and how it works. -:::tip -Welcome to Haystack +:::tip Welcome to Haystack To skip the introductions and go directly to installing and creating a search app, see [Get Started](overview/get-started.mdx). ::: @@ -22,8 +21,7 @@ The core foundation of Haystack consists of components and pipelines, along with Supported by an engaged community of developers, Haystack has grown into a comprehensive and user-friendly framework for LLM-based development. -:::note -Looking to scale with confidence? +:::note Looking to scale with confidence? If your team needs **enterprise-grade support, best practices, and deployment guidance** to run Haystack in production, check out **Haystack Enterprise**. diff --git a/docs-website/versioned_docs/version-2.19/optimization/evaluation/model-based-evaluation.mdx b/docs-website/versioned_docs/version-2.19/optimization/evaluation/model-based-evaluation.mdx index f6ed8c6a0e..f9f583af7d 100644 --- a/docs-website/versioned_docs/version-2.19/optimization/evaluation/model-based-evaluation.mdx +++ b/docs-website/versioned_docs/version-2.19/optimization/evaluation/model-based-evaluation.mdx @@ -107,8 +107,7 @@ Currently, Haystack has integrations with [DeepEval](https://docs.confident-ai.c | Explanations of scores | ❌ | | Monitoring dashboard | ❌ | -:::note -Framework Documentation +:::note Framework Documentation You can find more information about the metrics in the documentation of the respective evaluation frameworks: diff --git a/docs-website/versioned_docs/version-2.19/overview/get-started.mdx b/docs-website/versioned_docs/version-2.19/overview/get-started.mdx index 0fb35e9372..ca8ff8c508 100644 --- a/docs-website/versioned_docs/version-2.19/overview/get-started.mdx +++ b/docs-website/versioned_docs/version-2.19/overview/get-started.mdx @@ -24,7 +24,6 @@ pip install haystack-ai Were you already using Haystack 1.x? :::warning -Warning Installing `farm-haystack` and `haystack-ai` in the same Python environment (virtualenv, Colab, or system) causes problems. diff --git a/docs-website/versioned_docs/version-2.19/overview/installation.mdx b/docs-website/versioned_docs/version-2.19/overview/installation.mdx index e1f7e51315..cd461e684b 100644 --- a/docs-website/versioned_docs/version-2.19/overview/installation.mdx +++ b/docs-website/versioned_docs/version-2.19/overview/installation.mdx @@ -31,7 +31,6 @@ conda install haystack-ai Were you already using Haystack 1.x? :::warning -Warning Installing `farm-haystack` and `haystack-ai` in the same Python environment (virtualenv, Colab, or system) causes problems. diff --git a/docs-website/versioned_docs/version-2.19/overview/migration.mdx b/docs-website/versioned_docs/version-2.19/overview/migration.mdx index 5579963c01..1ae8b07050 100644 --- a/docs-website/versioned_docs/version-2.19/overview/migration.mdx +++ b/docs-website/versioned_docs/version-2.19/overview/migration.mdx @@ -20,7 +20,7 @@ Haystack 2.x represents a significant overhaul of Haystack 1.x, and it's importa Haystack 1.x was distributed with a package called `farm-haystack`. To migrate your application, you must uninstall `farm-haystack` and install the new `haystack-ai` package for Haystack 2.x. :::warning -Note that the two versions of the project cannot coexist in the same Python environment. +Two versions of the project cannot coexist in the same Python environment. One of the options is to remove both packages if they are installed in the same environment, followed by installing only one of them: @@ -126,8 +126,7 @@ Haystack 1.x provided Agents, enabling the use of LLMs in a loop. Currently in Haystack 2.x, you can build Agents using three main elements in a pipeline: Chat Generators, ToolInvoker component, and Tools. A standalone Agent abstraction in Haystack 2.x is in an experimental phase. -:::note -Agents Documentation Page +:::note Agents Documentation Page Take a look at our 2.x [Agents](../concepts/agents.mdx) documentation page for more information and detailed examples. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubfileeditor.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubfileeditor.mdx index d0b7d75ec5..e9f9d2b280 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubfileeditor.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubfileeditor.mdx @@ -45,8 +45,7 @@ pip install github-haystack ## Usage -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissuecommenter.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissuecommenter.mdx index 84e13f04e2..d032ac36c8 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissuecommenter.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissuecommenter.mdx @@ -40,8 +40,7 @@ pip install github-haystack ## Usage -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissueviewer.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissueviewer.mdx index 06f4ee01d9..e4aec8aa31 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissueviewer.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubissueviewer.mdx @@ -44,8 +44,7 @@ pip install github-haystack ## Usage -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubprcreator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubprcreator.mdx index 8c80f6e609..5cc6f453f9 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubprcreator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubprcreator.mdx @@ -47,8 +47,7 @@ pip install github-haystack ## Usage -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoforker.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoforker.mdx index bef0304cfc..551c7874b7 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoforker.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoforker.mdx @@ -45,8 +45,7 @@ pip install github-haystack ## Usage -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoviewer.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoviewer.mdx index 023f63fb0d..60cc30a704 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoviewer.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/githubrepoviewer.mdx @@ -44,8 +44,7 @@ pip install github-haystack ## Usage -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/langfuseconnector.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/langfuseconnector.mdx index 64bd2f048a..469d4a167f 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/langfuseconnector.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/connectors/langfuseconnector.mdx @@ -50,8 +50,7 @@ pip install langfuse-haystack
-:::note -Usage Notice +:::note Usage Notice To ensure proper tracing, always set environment variables before importing any Haystack components. This is crucial because Haystack initializes its internal tracing components during import. In the example below, we first set the environmental variables and then import the relevant Haystack components. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/downloaders/s3downloader.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/downloaders/s3downloader.mdx index 2d082eb067..6d6cbef30b 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/downloaders/s3downloader.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/downloaders/s3downloader.mdx @@ -38,8 +38,7 @@ downloader = S3Downloader( The component downloads multiple files in parallel using the `max_workers` parameter (default is 32 workers) to speed up processing of large document sets. Downloaded files are cached locally, and when the cache exceeds `max_cache_size` (default is 100 files), least recently accessed files are automatically removed. Already downloaded files are touched to update their access time without re-downloading. -:::note -Required Configuration +:::note Required Configuration The component requires two critical configurations: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx index d5cac90888..8f93ec4dcd 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/amazonbedrockdocumentembedder.mdx @@ -24,8 +24,7 @@ This component computes embeddings for documents using models through Amazon Bed Supported models are `amazon.titan-embed-text-v1`, `cohere.embed-english-v3`, `cohere.embed-multilingual-v3`, and `amazon.titan-embed-text-v2:0`. -:::note -Batch Inference +:::note Batch Inference Note that only Cohere models support batch inference – computing embeddings for more documents with the same request. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaidocumentembedder.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaidocumentembedder.mdx index f852047b7b..bb8bc81974 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaidocumentembedder.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaidocumentembedder.mdx @@ -9,8 +9,7 @@ description: "This component computes embeddings for documents using models thro This component computes embeddings for documents using models through VertexAI Embeddings API. -:::warning -Deprecation Notice +:::warning Deprecation Notice This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaitextembedder.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaitextembedder.mdx index ce09cd1c72..94bd5935a3 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaitextembedder.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/embedders/vertexaitextembedder.mdx @@ -9,8 +9,7 @@ description: "This component computes embeddings for text (such as a query) usin This component computes embeddings for text (such as a query) using models through VertexAI Embeddings API. -:::warning -Deprecation Notice +:::warning Deprecation Notice This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockchatgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockchatgenerator.mdx index 3fd208a99a..706ab99213 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockchatgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockchatgenerator.mdx @@ -28,8 +28,7 @@ The models that we currently support are Anthropic's _Claude_, Meta's _Llama 2_, This component uses AWS for authentication. You can use the AWS CLI to authenticate through your IAM. For more information on setting up an IAM identity-based policy, see the [official documentation](https://docs.aws.amazon.com/bedrock/latest/userguide/security_iam_id-based-policy-examples.html). -:::note -Using AWS CLI +:::note Using AWS CLI Consider using AWS CLI as a more straightforward tool to manage your AWS services. With AWS CLI, you can quickly configure your [boto3 credentials](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html). This way, you won't need to provide detailed authentication parameters when initializing Amazon Bedrock Generator in Haystack. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockgenerator.mdx index bbbf7a3408..026af2bd3f 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/amazonbedrockgenerator.mdx @@ -28,8 +28,7 @@ The models that we currently support are Anthropic's Claude, AI21 Labs' Jurassic This component uses AWS for authentication. You can use the AWS CLI to authenticate through your IAM. For more information on setting up an IAM identity-based policy, see the [official documentation](https://docs.aws.amazon.com/bedrock/latest/userguide/security_iam_id-based-policy-examples.html). -:::note -Using AWS CLI +:::note Using AWS CLI Consider using AWS CLI as a more straightforward tool to manage your AWS services. With AWS CLI, you can quickly configure your [boto3 credentials](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html). This way, you won't need to provide detailed authentication parameters when initializing Amazon Bedrock Generator in Haystack. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/azureopenaichatgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/azureopenaichatgenerator.mdx index 7573bfa78e..d3b40273c3 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/azureopenaichatgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/azureopenaichatgenerator.mdx @@ -78,8 +78,7 @@ print(response["replies"][0].text) ``` -:::note -Model Compatibility and Limitations +:::note Model Compatibility and Limitations - Pydantic models and JSON schemas are supported for latest models starting from GPT-4o. - Older models only support basic JSON mode through `{"type": "json_object"}`. For details, see [OpenAI JSON mode documentation](https://platform.openai.com/docs/guides/structured-outputs#json-mode). diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminichatgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminichatgenerator.mdx index 07b4be2f7f..79fec10635 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminichatgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminichatgenerator.mdx @@ -9,8 +9,7 @@ description: "This component enables chat completion using Google Gemini models. This component enables chat completion using Google Gemini models. -:::warning -Deprecation Notice +:::warning Deprecation Notice This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminigenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminigenerator.mdx index 2c3feba239..318b32ce84 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminigenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/googleaigeminigenerator.mdx @@ -9,8 +9,7 @@ description: "This component enables text generation using the Google Gemini mod This component enables text generation using the Google Gemini models. -:::warning -Deprecation Notice +:::warning Deprecation Notice This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx index a4043a3541..3adbd3e151 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/choosing-the-right-generator.mdx @@ -42,8 +42,7 @@ Only one of these fields appears per chunk. Use `chunk.start` and `chunk.finish_ For providers that support multiple candidates, set `n=1` to stream. -:::note -Parameter Details +:::note Parameter Details Check out the parameter details in our [API Reference for StreamingChunk](/reference/data-classes-api#streamingchunk). ::: @@ -104,8 +103,7 @@ We also support [Amazon Bedrock](../amazonbedrockgenerator.mdx): it provides acc When discussing open (weights) models, we're referring to models with public weights that anyone can deploy on their infrastructure. The datasets used for training are shared less frequently. One could choose to use an open model for several reasons, including more transparency and control of the model. -:::note -Commercial Use +:::note Commercial Use Not all open models are suitable for commercial use. We advise thoroughly reviewing the license, typically available on Hugging Face, before considering their adoption. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/function-calling.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/function-calling.mdx index 0d7f7da76b..d3e7a6a853 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/function-calling.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/function-calling.mdx @@ -18,8 +18,7 @@ Function calling is useful for a variety of purposes, but two main points are pa 1. **Enhanced LLM Functionality**: Function calling enhances the capabilities of LLMs beyond just text generation. It allows to convert human-generated prompts into precise function invocation descriptors. These descriptors can then be used by connected LLM frameworks to perform computations, manipulate data, and interact with external APIs. This expansion of functionality makes LLMs adaptable tools for a wide array of tasks and industries. 2. **Real-Time Data Access and Interaction**: Function calling lets LLMs create function calls that access and interact with real-time data. This is necessary for apps that need current data, like news, weather, or financial market updates. By giving access to the latest information, this feature greatly improves the usefulness and trustworthiness of LLMs in changing and time-critical situations. -:::warning -Important to Note +:::warning Important to Note The model doesn't actually call the function. Function calling returns JSON with the name of a function and the arguments to invoke it. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx index 0e992c3c4e..3304fb63a1 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/guides-to-generators/generators-vs-chat-generators.mdx @@ -25,8 +25,7 @@ The choice between Generators (or text Generators) and Chat Generators depends o As highlighted by the different input and output characteristics above, Generators and Chat Generators are distinct, often interacting with different models through calls to different APIs. Therefore, they are not automatically interchangeable. -:::tip -Multi-turn Interactions +:::tip Multi-turn Interactions If you anticipate a two-way interaction with the Language Model in a chat scenario, opting for a Chat Generator is generally better. This choice ensures a more structured and straightforward interaction with the Language Model. ::: @@ -71,8 +70,7 @@ Here’s an example for [argilla/notus-7b-v1](https://huggingface.co/argilla/not ## Different Types of Language Models -:::note -Topic Exploration +:::note Topic Exploration This field is young, constantly evolving, and distinctions are not always possible and precise. ::: @@ -121,8 +119,7 @@ It's worth noting that many recent Instruct models are equipped with a [chat tem Utilizing a Chat Generator is the optimal choice if the model features a Chat template and you intend to use it in chat scenarios. In these cases, you can expect out-of-the-box support for Chat Messages, and you don’t need to manually apply the aforementioned template. -:::warning -Caution +:::warning Caution The distinction between Instruct and Chat models is not a strict dichotomy. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfaceapigenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfaceapigenerator.mdx index c5137c5fce..f10b30b38f 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfaceapigenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfaceapigenerator.mdx @@ -25,8 +25,7 @@ This generator enables text generation using various Hugging Face APIs. - [Paid Inference Endpoints](https://huggingface.co/inference-endpoints) - [Self-hosted Text Generation Inference](https://github.com/huggingface/text-generation-inference) -:::warning -Important Note +:::warning Important Note As of July 2025, the Hugging Face Inference API no longer offers generative models through the `text_generation` endpoint. Generative models are now only available through providers supporting the `chat_completion` endpoint. As a result, this component might no longer work with the Hugging Face Inference API. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfacelocalgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfacelocalgenerator.mdx index 174c452fe8..918a7b380f 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfacelocalgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/huggingfacelocalgenerator.mdx @@ -22,8 +22,7 @@ description: "`HuggingFaceLocalGenerator` provides an interface to generate text Keep in mind that if LLMs run locally, you may need a powerful machine to run them. This depends strongly on the model you select and its parameter count. -:::note -Looking for chat completion? +:::note Looking for chat completion? This component is designed for text generation, not for chat. If you want to use Hugging Face LLMs for chat, consider using [`HuggingFaceLocalChatGenerator`](huggingfacelocalchatgenerator.mdx) instead. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamachatgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamachatgenerator.mdx index 525031061b..f135791c73 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamachatgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamachatgenerator.mdx @@ -76,8 +76,7 @@ If you already installed Ollama in your system, you can execute: ollama pull zephyr ``` -:::tip -Choose a specific version of a model +:::tip Choose a specific version of a model You can also specify a tag to choose a specific (quantized) version of your model. The available tags are shown in the model card of the Ollama models library. This is an [example](https://ollama.ai/library/zephyr/tags) for Zephyr. In this case, simply run diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamagenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamagenerator.mdx index dd23cb8f1c..80dbfecf4a 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamagenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/ollamagenerator.mdx @@ -51,8 +51,7 @@ If you have already installed Ollama in your system, you can execute: ollama pull zephyr ``` -:::tip -Choose a specific version of a model +:::tip Choose a specific version of a model You can also specify a tag to choose a specific (quantized) version of your model. The available tags are shown in the model card of the Ollama models library. This is an [example](https://ollama.ai/library/zephyr/tags) for Zephyr. In this case, simply run diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/openaichatgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/openaichatgenerator.mdx index bc6d61ef36..4cd41bd2fe 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/openaichatgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/openaichatgenerator.mdx @@ -68,8 +68,7 @@ print(response["replies"][0].text) ``` -:::note -Model Compatibility and Limitations +:::note Model Compatibility and Limitations - Pydantic models and JSON schemas are supported for latest models starting from `gpt-4o-2024-08-06`. - Older models only support basic JSON mode through `{"type": "json_object"}`. For details, see [OpenAI JSON mode documentation](https://platform.openai.com/docs/guides/structured-outputs#json-mode). diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminichatgenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminichatgenerator.mdx index ab578b5f5d..13a5f6bb73 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminichatgenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminichatgenerator.mdx @@ -9,8 +9,7 @@ description: "`VertexAIGeminiChatGenerator` enables chat completion using Google `VertexAIGeminiChatGenerator` enables chat completion using Google Gemini models. -:::warning -Deprecation Notice +:::warning Deprecation Notice This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminigenerator.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminigenerator.mdx index e58e759d1c..3f89c2309e 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminigenerator.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/generators/vertexaigeminigenerator.mdx @@ -9,8 +9,7 @@ description: "`VertexAIGeminiGenerator` enables text generation using Google Gem `VertexAIGeminiGenerator` enables text generation using Google Gemini models. -:::warning -Deprecation Notice +:::warning Deprecation Notice This integration uses the deprecated google-generativeai SDK, which will lose support after August 2025. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/amazonbedrockranker.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/amazonbedrockranker.mdx index 85bd978444..3aab895502 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/amazonbedrockranker.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/amazonbedrockranker.mdx @@ -36,8 +36,7 @@ pip install amazon-bedrock-haystack This component uses AWS for authentication. You can use the AWS CLI to authenticate through your IAM. For more information on setting up an IAM identity-based policy, see the [official documentation](https://docs.aws.amazon.com/bedrock/latest/userguide/security_iam_id-based-policy-examples.html). -:::note -Using AWS CLI +:::note Using AWS CLI Consider using AWS CLI as a more straightforward tool to manage your AWS services. With AWS CLI, you can quickly configure your [boto3 credentials](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html). This way, you won't need to provide detailed authentication parameters when initializing Amazon Bedrock in Haystack. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/cohereranker.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/cohereranker.mdx index f7515c7096..6be755cbaa 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/cohereranker.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/cohereranker.mdx @@ -84,8 +84,7 @@ query = "Cities in France" res = document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, "ranker": {"query": query, "top_k": 2}}) ``` -:::tip -`top_k` parameter +:::note `top_k` parameter In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/nvidiaranker.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/nvidiaranker.mdx index 1e4aa04cba..572250ab33 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/nvidiaranker.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/nvidiaranker.mdx @@ -97,8 +97,7 @@ query = "Cities in France" res = document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, "ranker": {"query": query, "top_k": 2}}) ``` -:::tip -`top_k` parameter +:::note `top_k` parameter In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx index 7497fd4635..15b5d55787 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/sentencetransformerssimilarityranker.mdx @@ -93,8 +93,7 @@ document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, ``` -:::note -Ranker top_k +:::note Ranker top_k In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/transformerssimilarityranker.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/transformerssimilarityranker.mdx index 3c1524a051..23cd7491b6 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/transformerssimilarityranker.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/rankers/transformerssimilarityranker.mdx @@ -9,8 +9,7 @@ description: "Use this component to rank documents based on their similarity to Use this component to rank documents based on their similarity to the query. The `TransformersSimilarityRanker` is a powerful, model-based Ranker that uses a cross-encoder model to produce document and query embeddings. -:::warning -Legacy Component +:::warning Legacy Component This component is considered legacy and will no longer receive updates. It may be deprecated in a future release, followed by removal after a deprecation period. Consider using SentenceTransformersSimilarityRanker instead, as it provides the same functionality and additional features. @@ -96,8 +95,7 @@ document_ranker_pipeline.run(data={"retriever": {"query": query, "top_k": 3}, "ranker": {"query": query, "top_k": 2}}) ``` -:::note -Ranker `top_k` +:::note Ranker `top_k` In the example above, the `top_k` values for the Retriever and the Ranker are different. The Retriever's `top_k` specifies how many documents it returns. The Ranker then orders these documents. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers.mdx index 6c0d460778..b07d47c697 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers.mdx @@ -77,14 +77,12 @@ You can use different Retriever types, sparse and dense, in one pipeline to take See an example of this approach in our [`DocumentJoiner` docs](joiners/documentjoiner.mdx#in-a-pipeline). -:::tip -Metadata Filtering +:::tip Metadata Filtering When talking about hybrid retrieval, some database providers mean _metadata filtering_ on dense embedding retrieval. While this is different from combining different Retrievers, it is usually supported by Haystack Retrievers. For more information, check the [Metadata Filtering page](../concepts/metadata-filtering.mdx). ::: -:::note -Hybrid Retrievers +:::note Hybrid Retrievers Some Document Stores offer hybrid retrieval on the database side. In general, these solutions can be performant, but they offer fewer customization options (for instance, on how to merge results from different retrieval techniques). diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx index 135ce4f263..bf74f8d153 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/azureaisearchembeddingretriever.mdx @@ -30,8 +30,7 @@ By default, the `AzureAISearchDocumentStore` uses the [HNSW algorithm](https://l In addition to the `query_embedding`, the `AzureAISearchEmbeddingRetriever` accepts other optional parameters, including `top_k` (the maximum number of documents to retrieve) and `filters` to narrow down the search space. -:::note -Semantic Ranking +:::note Semantic Ranking The semantic ranking capability of Azure AI Search is not available for vector retrieval. To include semantic ranking in your retrieval process, use the [`AzureAISearchBM25Retriever`](azureaisearchbm25retriever.mdx) or [`AzureAISearchHybridRetriever`](azureaisearchhybridretriever.mdx). For more details, see [Azure AI documentation](https://learn.microsoft.com/en-us/azure/search/semantic-how-to-query-request?tabs=portal-query#set-up-the-query). ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdranthybridretriever.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdranthybridretriever.mdx index f4d7f65e03..755b096e13 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdranthybridretriever.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdranthybridretriever.mdx @@ -24,8 +24,7 @@ The `QdrantHybridRetriever` is a Retriever based both on dense and sparse embedd It compares the query and document’s dense and sparse embeddings and fetches the documents most relevant to the query from the `QdrantDocumentStore`, fusing the scores with Reciprocal Rank Fusion. -:::tip -Hybrid Retrieval Pipeline +:::tip Hybrid Retrieval Pipeline If you want additional customization for merging or fusing results, consider creating a hybrid retrieval pipeline with [`DocumentJoiner`](../joiners/documentjoiner.mdx). @@ -39,8 +38,7 @@ When using the `QdrantHybridRetriever`, make sure it has the query and document In addition to `query_embedding` and `query_sparse_embedding`, the `QdrantHybridRetriever` accepts other optional parameters, including `top_k` (the maximum number of documents to retrieve) and `filters` to narrow down the search space. -:::note -Sparse Embedding Support +:::note Sparse Embedding Support To use Sparse Embedding support, you need to initialize the `QdrantDocumentStore` with `use_sparse_embeddings=True`, which is `False` by default. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx index d11d77cf62..31604dcad7 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/retrievers/qdrantsparseembeddingretriever.mdx @@ -28,8 +28,7 @@ When using the `QdrantSparseEmbeddingRetriever`, make sure it has the query and In addition to the `query_sparse_embedding`, the `QdrantSparseEmbeddingRetriever` accepts other optional parameters, including `top_k` (the maximum number of documents to retrieve) and `filters` to narrow down the search space. -:::note -Sparse Embedding Support +:::note Sparse Embedding Support To use Sparse Embedding support, you need to initialize the `QdrantDocumentStore` with `use_sparse_embeddings=True`, which is `False` by default. diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/tools/toolinvoker.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/tools/toolinvoker.mdx index 28d49aaa8c..aa361103b0 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/tools/toolinvoker.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/tools/toolinvoker.mdx @@ -29,8 +29,7 @@ The `ToolInvoker` has two additionally helpful parameters: - `convert_result_to_json_string`: Use `json.dumps` (when True) or `str` (when False) to convert the result into a string. - `raise_on_failure`: If True, it will raise an exception in case of errors. If False, it will return a `ChatMessage` object with `error=True` and a description of the error in `result`. Use this, for example, when you want to keep the Language Model running in a loop and fixing its errors. -:::note -ChatMessage and Tool Data Classes +:::note ChatMessage and Tool Data Classes Follow the links to learn more about [ChatMessage](../../concepts/data-classes/chatmessage.mdx) and [Tool](../../tools/tool.mdx) data classes. ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/searchapiwebsearch.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/searchapiwebsearch.mdx index 54846cd891..5d8b8bbd3a 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/searchapiwebsearch.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/searchapiwebsearch.mdx @@ -26,8 +26,7 @@ To search the content of the web pages, use the [`LinkContentFetcher`](../fetche `SearchApiWebSearch` requires a [SearchApi](https://www.searchapi.io) key to work. It uses a `SEARCHAPI_API_KEY` environment variable by default. Otherwise, you can pass an `api_key` at initialization – see code examples below. -:::note -Alternative search +:::note Alternative search To use [Serper Dev](https://serper.dev/?gclid=Cj0KCQiAgqGrBhDtARIsAM5s0_kPElllv3M59UPok1Ad-ZNudLaY21zDvbt5qw-b78OcUoqqvplVHRwaAgRgEALw_wcB) as an alternative, see its respective [documentation page](serperdevwebsearch.mdx). ::: diff --git a/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/serperdevwebsearch.mdx b/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/serperdevwebsearch.mdx index 11e6fcae27..232b2dbee0 100644 --- a/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/serperdevwebsearch.mdx +++ b/docs-website/versioned_docs/version-2.19/pipeline-components/websearch/serperdevwebsearch.mdx @@ -26,8 +26,7 @@ To search the content of the web pages, use the [`LinkContentFetcher`](../fetche `SerperDevWebSearch` requires a [SerperDev](https://serper.dev/) key to work. It uses a `SERPERDEV_API_KEY` environment variable by default. Otherwise, you can pass an `api_key` at initialization – see code examples below. -:::note -Alternative search +:::note Alternative search To use [Search API](https://www.searchapi.io/) as an alternative, see its respective [documentation page](searchapiwebsearch.mdx). ::: diff --git a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubfileeditortool.mdx b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubfileeditortool.mdx index e75baa6648..ff4b62cd2b 100644 --- a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubfileeditortool.mdx +++ b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubfileeditortool.mdx @@ -43,8 +43,7 @@ Install the GitHub integration to use the `GitHubFileEditorTool`: pip install github-haystack ``` -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissuecommentertool.mdx b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissuecommentertool.mdx index 756c0d3fff..2dbf47ff37 100644 --- a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissuecommentertool.mdx +++ b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissuecommentertool.mdx @@ -37,8 +37,7 @@ Install the GitHub integration to use the `GitHubIssueCommenterTool`: pip install github-haystack ``` -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissueviewertool.mdx b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissueviewertool.mdx index c9d0c9f0ff..f7e41ae401 100644 --- a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissueviewertool.mdx +++ b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubissueviewertool.mdx @@ -41,8 +41,7 @@ Install the GitHub integration to use the `GitHubIssueViewerTool`: pip install github-haystack ``` -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubprcreatortool.mdx b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubprcreatortool.mdx index 66110b94df..4de51f7d22 100644 --- a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubprcreatortool.mdx +++ b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubprcreatortool.mdx @@ -36,8 +36,7 @@ Install the GitHub integration to use the `GitHubPRCreatorTool`: pip install github-haystack ``` -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubrepoviewertool.mdx b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubrepoviewertool.mdx index db4b69a68e..a2419e639b 100644 --- a/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubrepoviewertool.mdx +++ b/docs-website/versioned_docs/version-2.19/tools/ready-made-tools/githubrepoviewertool.mdx @@ -43,8 +43,7 @@ Install the GitHub integration to use the `GitHubRepoViewerTool`: pip install github-haystack ``` -:::note -Repository Placeholder +:::note Repository Placeholder To run the following code snippets, you need to replace the `owner/repo` with your own GitHub repository name. ::: diff --git a/docs-website/versioned_docs/version-2.19/tools/tool.mdx b/docs-website/versioned_docs/version-2.19/tools/tool.mdx index 0e847598e7..6a755d6fa1 100644 --- a/docs-website/versioned_docs/version-2.19/tools/tool.mdx +++ b/docs-website/versioned_docs/version-2.19/tools/tool.mdx @@ -173,8 +173,7 @@ To better understand this section, make sure you are also familiar with Haystack Using the `tools` parameter, you can pass tools as a list of Tool instances or a single Toolset during initialization or in the `run` method. Tools passed at runtime override those set at initialization. -:::note -Chat Generators support +:::note Chat Generators support Not all Chat Generators currently support tools, but we are actively expanding tool support across more models.