This is the multi-page printable view of this section. Click here to print.

Return to the regular view of this page.

快速入门指南

快速开始使用 NodeRAG 本指南将帮助您在几分钟内设置并运行您的第一个 NodeRAG 项目。

1 - 从 PyPI 安装

学习如何使用 pip 安装 NodeRAG。 本指南提供了从 PyPI 安装 NodeRAG 的简单说明。

Conda 环境设置

为 NodeRAG 创建并激活虚拟环境:

conda create -n NodeRAG python=3.10
conda activate NodeRAG

安装 uv(可选:更快的包安装)

要加速包安装,可以使用 uv

pip install uv

安装 NodeRAG

使用 uv 安装 NodeRAG 以获得优化的性能:

uv pip install NodeRAG

下一步,请查看构建文档以索引您的语料库。

2 - 从源码安装

学习如何从源代码安装 NodeRAG。 本指南为希望从源代码构建的开发者提供了分步说明。

前提条件

在从源码安装 NodeRAG 之前,请确保您具备以下要求:

  • Python 3.10 或更高版本
  • Git
  • Miniconda
  • 在以下文件中列出的其他依赖项:
    • requirements.txt - 核心依赖项
    • requirements.in - 开发依赖项

开始

环境

从源码克隆

git clone https://github.com/Terry-Xu-666/NodeRAG.git
cd NodeRAG

Conda

conda create -n NodeRAG python=3.10
conda activate NodeRAG

安装

pip install uv
uv pip install requirements.txt
pip install requirements.txt

下一步,请参阅构建文档以索引您的语料库。