haystack
安装方式
先用 Prompt 核对来源与依赖。也可下载安装包。
用 AI 助手安装
复制提示词,让助手先核对固定版本和依赖。
查看 Prompt收起 Prompt
先检查当前 Agent 是否已安装 SkillPI Skill Finder。如果尚未安装,请按官方仓库的说明安装并启用:https://github.com/Findskills/skillpi。然后使用 Skill Finder 打开此 SkillPI 详情页并定位 "haystack":https://skillpi.com/zh/skills/deepskill-dd3ae7de6871b43782271e79da4cae7bde217e1c06d6db51a66bed1cc692f3d5。安装前核对上游来源和版本:https://github.com/TerminalSkills/skills。来源不一致时停止并说明差异。核对通过后,用 Skill Finder 安装目标 Skill,并报告安装路径和来源版本。
来源与配置
github.com
配置方式待核实
请查看原始来源中的适用工具、依赖和权限要求。
安装实测待补充
Haystack 专家:由 deepset 开发的开源框架,用于构建生产级 RAG 管道和基于 LLM 的应用。帮助开发者创建可组合的管道(文档存储、检索器、阅读器、生成器和自定义组件),通过“管道即代码”连接 20 多个 LLM 提供方和向量数据库。
介绍来源: third_party · TerminalSkills · 1.0.0 参考来源
SkillPi 解读
- 实测状态
- 未测试
文件浏览
Frontmatter
name: haystack
description: >-
You are an expert in Haystack, the open-source framework by deepset for
building production RAG pipelines and LLM applications. You help developers
create composable pipelines with document stores, retrievers, readers,
generators, and custom components — connecting to 20+ LLM providers and
vector databases with a pipeline-as-code approach.
license: Apache-2.0
compatibility: ''
metadata:
author: terminal-skills
version: 1.0.0
category: AI & Machine Learning
tags:
- rag
- pipeline
- nlp
- search
- retrieval
- deepset
- pythonHaystack — LLM Application Framework by deepset
You are an expert in Haystack, the open-source framework by deepset for building production RAG pipelines and LLM applications. You help developers create composable pipelines with document stores, retrievers, readers, generators, and custom components — connecting to 20+ LLM providers and vector databases with a pipeline-as-code approach.
Core Capabilities
RAG Pipeline
from haystack import Pipeline
from haystack.components.embedders import OpenAIDocumentEmbedder, OpenAITextEmbedder
from haystack.components.writers import DocumentWriter
from haystack.components.retrievers.in_memory import InMemoryEmbeddingRetriever
from haystack.components.generators import OpenAIGenerator
from haystack.components.builders import PromptBuilder
from haystack.document_stores.in_memory import InMemoryDocumentStore
from haystack import Document
store = InMemoryDocumentStore()
# Indexing pipeline
indexing = Pipeline()
indexing.add_component("embedder", OpenAIDocumentEmbedder())
indexing.add_component("writer", DocumentWriter(document_store=store))
indexing.connect("embedder", "writer")
docs = [Document(content="Haystack supports 20+ LLM providers..."), Document(content="Pipelines are composable...")]
indexing.run({"embedder": {"documents": docs}})
# Query pipeline
template = """Given these documents, answer the question.
Documents: {% for doc in documents %}{{ doc.content }}{% endfor %}
Question: {{ question }}
Answer:"""
rag = Pipeline()
rag.add_component("embedder", OpenAITextEmbedder())
rag.add_component("retriever", InMemoryEmbeddingRetriever(document_store=store))
rag.add_component("prompt", PromptBuilder(template=template))
rag.add_component("llm", OpenAIGenerator(model="gpt-4o"))
rag.connect("embedder.embedding", "retriever.query_embedding")
rag.connect("retriever", "prompt.documents")
rag.connect("prompt", "llm")
result = rag.run({"embedder": {"text": "What providers does Haystack support?"}, "prompt": {"question": "What providers?"}})
print(result["llm"]["replies"][0])
Custom Components
from haystack import component
@component
class MetadataFilter:
@component.output_types(documents=list[Document])
def run(self, documents: list[Document], category: str):
return {"documents": [d for d in documents if d.meta.get("category") == category]}
Installation
pip install haystack-ai
Best Practices
- Pipeline-as-code — Connect components explicitly; clear data flow, easy debugging
- Document stores — InMemory for dev, Qdrant/Pinecone/Weaviate for production
- PromptBuilder — Jinja2 templates for dynamic prompts; inject documents, history, metadata
- Custom components — Use
@componentdecorator; define inputs/outputs, Haystack handles wiring - Branching — Pipelines support conditional routing; different paths based on query type
- Serialization —
pipeline.dumps()/Pipeline.loads()for saving/loading pipeline configs - Evaluation — Built-in eval components for faithfulness, relevance, answer correctness
- Streaming — Use
OpenAIGenerator(streaming_callback=...)for real-time token delivery
当前收录版本
1.0.0
安全与评测信息
质量评测
满分100 · 来自 SkillPi LAB 实验室的评测报告。
亮点
- Haystack 框架的完整使用指南,涵盖 RAG 管道构建、自定义组件开发和最佳实践
- 提供端到端代码示例,帮助开发者快速上手生产级 LLM 应用开发
亮点
- description 清晰明确,精准描述了 Skill 的核心能力和适用场景
- 触发词覆盖全面,边界清晰,无歧义
亮点
- 文档结构清晰,章节划分合理,包含安装、示例和最佳实践
- 提供了完整的可执行代码示例,frontmatter 信息完整
亮点
- 代码示例完整且参数正确,工具来源明确
- 涵盖了主要使用场景,未发现明显执行漏洞
取前四项原始分值的算术平均,四舍五入取整。可通过收录报告核对各项评分与说明,运行记录需单独查证。
正文静态检测
100 / 100 · skillpi-20261123-no-r3-v1
正文未命中当前规则。
分数仅反映正文中的规则命中,供使用前参考。附件与运行行为不在此评分范围内。
权限与使用前检查
根据当前主文档自动整理,命中内容可能是示例或防护说明;不是实际权限声明,也未覆盖附件、外部依赖或运行行为。
-
安装或获取外部依赖
使用官方来源并锁定版本,在隔离环境检查安装脚本。当前文档检查不覆盖后续下载的代码。
主文档提及 · 第 88 行
安全评级与访问范围
safe · 静态证据核验,不代表运行安全保证。
使用前请由宿主核对并授权实际文件读写、外部服务和联网目的地;本站的核验不会授予任何运行权限。
用户讨论
还没有已核实的点评。