从网站填充松果矢量数据库#
¥Populate a Pinecone vector database from a website
使用 n8n 抓取网站,将数据加载到 Pinecone,然后使用聊天工作流进行查询。此工作流使用 HTTP 节点 获取网站数据,使用 HTML 节点 提取相关内容,然后使用 Pinecone 矢量存储节点 将其发送到 Pinecone。
¥Use n8n to scrape a website, load the data into Pinecone, then query it using a chat workflow. This workflow uses the HTTP node to get website data, extracts the relevant content using the HTML node, then uses the Pinecone Vector Store node to send it to Pinecone.
Workflow preview placeholder.
主要功能#
¥Key features
此工作流程使用:
¥This workflow uses:
- HTTP 节点:获取网站数据。
¥HTTP node: fetches website data.
- HTML 节点:通过提取页面的主要内容来简化数据。
¥HTML node: simplifies the data by extracting the main content from the page.
- Pinecone 矢量存储节点 和 OpenAI 嵌入:将数据转换为向量并将其存储在 Pinecone 中。
¥Pinecone Vector Store node and Embeddings OpenAI: transform the data into vectors and store it in Pinecone.
- 查询向量数据库所需的 聊天触发器 和 Question and Answer 链。
¥Chat Trigger and Question and Answer Chain to query the vector database.
使用示例#
¥Using the example
To load the template into your n8n instance:
- Download the workflow JSON file.
- Open a new workflow in your n8n instance.
- Copy in the JSON, or select Workflow menu
> Import from file....
The example workflows use Sticky Notes to guide you:
- Yellow: notes and information.
- Green: instructions to run the workflow.
- Orange: you need to change something to make the workflow work.
- Blue: draws attention to a key feature of the example.