
Write HTML. Render video. Built for agents.
Haystack is a Python framework for building LLM applications with modular pipelines and agent workflows. It organizes retrieval, routing, memory, tools, and generation as explicit components, so you can customize how context is prepared before it reaches the model. It includes built-in pieces for retrieval, indexing, evaluation, tracing, and async execution, plus hooks for agent lifecycle events. The same framework can be used for semantic search, RAG, multimodal apps, and conversational systems.

Builders who want to build production LLM apps with pipelines, retrieval, and agent workflows.
You can build search- and tool-driven LLM systems with clear control over context, routing, and generation.
Build workflows from reusable components and connect them with loops, branches, and conditional logic.
Use agents with concurrent tool calls, lifecycle hooks, and built-in tracking for step count, token usage, and tool calls.
Control how information is retrieved, ranked, filtered, combined, structured, and routed before it reaches the model.
Run pipelines synchronously or asynchronously and stream token by token.
Connect to OpenAI, Anthropic, Cohere, Hugging Face, Google, Azure OpenAI, AWS Bedrock, local models, and more.
Create custom components through a consistent interface and mix them with built-in retrieval, indexing, memory, and evaluation pieces.
pip install haystack-ai
pip install --pre haystack-ai
Haystack is an open-source AI orchestration framework for building production-ready LLM applications in Python.
Design modular pipelines and agent workflows with explicit control over retrieval, routing, memory, and generation. Build scalable RAG systems, multimodal applications, semantic search, question answering, and autonomous agents, all in a transparent architecture that lets you experiment, customize deeply, and deploy with confidence.
The simplest way to get Haystack is via pip:
pip install haystack-ai
Install nightly pre-releases to try the newest features:
pip install --pre haystack-ai
Haystack supports multiple installation methods, including Docker images. For a comprehensive guide, please refer to the documentation.
If you're new to the project, check out "What is Haystack?" then go through the "Get Started Guide" and build your first LLM application in a matter of minutes. Keep learning with the tutorials. For more advanced use cases, or just to get some inspiration, you can browse our Haystack recipes in the Cookbook.
At any given point, hit the documentation to learn more about Haystack, what it can do for you, and the technology behind.
Agents built for production
Extend agent behavior with lifecycle hooks (before_llm, before_tool, on_exit, …) for guardrails and custom logic, and track step_count, token_usage, and tool calls out of the box for monitoring and cost control. Get started fast with ready-made agents from Agent Pack (e.g., a deep research agent, or an advanced RAG agent) or give your own agents progressive skill discovery via SkillToolset, so skill descriptions only enter context when needed.
Built for context engineering
Design flexible systems with explicit control over how information is retrieved, ranked, filtered, combined, structured, and routed before it reaches the model. Define pipelines and agent workflows where retrieval, memory, tools, and generation are transparent and traceable.
Native Async Support
One Pipeline runs synchronously or asynchronously and streams token by token. Agent can run concurrent tool calls.
Modular and customizable
Use built-in components for retrieval, indexing, tool calling, memory, and evaluation, or create your own. Add loops, branches, and conditional logic to precisely control how context moves through your pipelines and agent workflows.
Model- and vendor-agnostic
Integrate with OpenAI, Mistral, Anthropic, Cohere, Hugging Face, Google, Azure OpenAI, AWS Bedrock, local models, and many others. Swap models or infrastructure components without rewriting your system.
Extensible ecosystem
Build and share custom components through a consistent interface that makes it easy for the community and third parties to extend Haystack and contribute to an open ecosystem.
[!TIP]
Would you like to deploy and serve Haystack pipelines as REST APIs or MCP servers? Hayhooks provides a simple way for you to wrap pipelines and agents with custom logic and expose them through HTTP endpoints or MCP. It also supports OpenAI-compatible chat completion endpoints and works with chat UIs like open-webui.
Get expert support from the Haystack team, build faster with enterprise-grade templates, and scale securely with deployment guides for cloud and on-prem environments with Haystack Enterprise Starter. Read more about it in the announcement post.
👉 Get Haystack Enterprise Starter
Need a managed production setup for Haystack? The Haystack Enterprise Platform helps you build, test, deploy and operate Haystack pipelines with built-in observability, collaboration, governance, and access controls. It’s available as a managed cloud service or as a self-hosted solution.
👉 Learn more about Haystack Enterprise Platform or try it free
Haystack collects anonymous usage statistics of pipeline components. We receive an event every time these components are initialized. This way, we know which components are most relevant to our community.
Read more about telemetry in Haystack or how you can opt out in Haystack docs.
If you have a feature request or a bug report, feel free to open an issue in GitHub. We regularly check these, so you can expect a quick response. If you'd like to discuss a topic or get more general advice on how to make Haystack work for your project, you can start a thread in Github Discussions or our Discord channel. We also check 𝕏 (Twitter) and Stack Overflow.
We are very open to the community's contributions - be it a quick fix of a typo, or a completely new feature! You don't need to be a Haystack expert to provide meaningful improvements. To learn how to get started, check out our Contributor Guidelines first.
There are several ways you can contribute to Haystack:
[!TIP] 👉 Check out the full list of issues that are open to contributions
Haystack is used by thousands of teams building production AI systems across industries, including:
Are you also using Haystack? Open a PR or tell us your story
Sign in to join the discussion.
No comments yet. Be the first to say what this is good for.

Write HTML. Render video. Built for agents.
Ultra-lightweight, open-source, self-hosted personal AI agent framework in Python with WebUI, tools, memory, MCP, multi-agent workflows, automation, and chat apps
SkillOpt is a text-space optimizer that trains reusable natural-language skills for frozen LLM agents through trajectory-driven edits, validation-gated updates, and deployable best_skill.md artifacts.

Omnigent is an open-source AI agent framework and meta-harness: orchestrate Claude Code, Codex, Cursor, Pi, and custom agents — swap harnesses without rewriting, enforce policies and sandboxing, and collaborate in real time from any device.
A theoretical reconstruction of the Claude Mythos architecture, built from first principles using the available research literature.
🕷️ An adaptive Web Scraping framework that handles everything from a single request to a full-scale crawl!