0
点赞
收藏
分享

微信扫一扫

240831-Gradio之RAG文档对话工具Kotaemon的安装与配置


A. 用户界面

240831-Gradio之RAG文档对话工具Kotaemon的安装与配置_RAG

该项目既可以作为功能性 RAG UI,既可以用于对文档进行 QA 的最终用户,也可以用作想要构建自己的 RAG 管道的开发人员。

对于最终用户:
- 一个干净且简约的用户界面,用于基于RAG的QA。
- 支持 LLM API 提供程序(OpenAI、AzureOpenAI、Cohere 等)和本地 LLMs(通过 ollama 和 llama-cpp-python)。
- 简单的安装脚本。
- 
For developers:  对于开发人员:
- 用于构建您自己的基于 RAG 的文档 QA 管道的框架。
- 使用提供的 UI(使用 Gradio 构建)自定义并查看 RAG 管道的运行情况。

This project serves as a functional RAG UI for both end users who want to do QA on their documents and developers who want to build their own RAG pipeline.

For end users:  
A clean & minimalistic UI for RAG-based QA.
Supports LLM API providers (OpenAI, AzureOpenAI, Cohere, etc) and local LLMs (via ollama and llama-cpp-python).

Easy installation scripts.
A framework for building your own RAG-based document QA pipeline.
Customize and see your RAG pipeline in action with the provided UI (built with Gradio).

B. 环境安装

参考这个:

  • Cinnamon/kotaemon: An open-source RAG-based tool for chatting with your documents.

240831-Gradio之RAG文档对话工具Kotaemon的安装与配置_UI_02

C. 本地模型

参考这个:

  • kotaemon/docs/local_model.md at main · Cinnamon/kotaemon

240831-Gradio之RAG文档对话工具Kotaemon的安装与配置_GUI_03

设置Model (勾选set default)

240831-Gradio之RAG文档对话工具Kotaemon的安装与配置_GUI_04

设置Embedding (勾选set default)

240831-Gradio之RAG文档对话工具Kotaemon的安装与配置_Kotaemon_05

D. 视频教程

D.1 Bilibili视频1


Kotaemon - Easy Local RAG UI - GraphRAG with Ollama - Tutorial


D.1 Bilibili视频2


Kotaemon


E. 问题处理

E.1 无法下载NLTK数据集

  • 手动下载:python - How do I download NLTK data? - Stack Overflow
  • 放置到有户名所在目录,例如:/home/<your_user_name/nltk_data

240831-Gradio之RAG文档对话工具Kotaemon的安装与配置_UI_06

E.2 无法链接HuggingFace的theme主题

解决方法1:
  • 设置代理
解决方法2:
  • 取消选择的主题
解决方法3:
  • 手动配置:
  • 从一台可访问HuggingFace的主机上下载好主题文件包
  • 将其复制到对应的路径

Windows: C:\Users\<your_user_name>\.cache\huggingface\hub\spaces--lone17--kotaemon

Linux: 
\\wsl.localhost\Ubuntu-22.04\home\<your_user_name>\.cache\huggingface\hub\spaces--lone17--kotaemon

- 修改对应的文件内容:

\wsl.localhost\Ubuntu-22.04\home\<your_user_name>\.conda\envs\kotaemon\lib\python3.10\site-packages\gradio\themes\basepy

F. 参考文献

  • Cinnamon/kotaemon: An open-source RAG-based tool for chatting with your documents.
  • kotaemon/docs/local_model.md at main · Cinnamon/kotaemon
  • Kotaemon: Making Advanced RAG Technology Accessible to Everyone | by Lakshmi narayana .U | Aug, 2024 | Medium
  • lone17/kotaemon-gradio-theme: A clean Gradio theme with dark and light variants.
  • Quick Start - kotaemon Docs
  • Development - kotaemon Docs
  • ollama-library


举报

相关推荐

0 条评论