Hysen Labs
Open-source project
chatchat-space/Langchain-Chatchat avatar
chatchat-space

Langchain-Chatchat

GitHub describes it as Langchain-Chatchat(原Langchain-ChatGLM)基于 Langchain 与 ChatGLM, Qwen 与 Llama 等语言模型的 RAG 与 Agent 应用 | Langchain-Chatchat (formerly langchain-ChatGLM), local knowledge based LLM (like ChatGLM, Qwen and Llama) RAG and Agent app with langchain. The repository metadata lists Python as its primary language. The metadata lists the Apache-2.0 license. This article stays within the project description and details documented in the GitHub repository README.

38,544 stars6,260 forksPythonApache-2.0
01
DEEP OPEN-SOURCE ANALYSIS

chatchat-space/Langchain-Chatchat: 概述

GitHub describes it as Langchain-Chatchat(原Langchain-ChatGLM)基于 Langchain 与 ChatGLM, Qwen 与 Llama 等语言模型的 RAG 与 Agent 应用 | Langchain-Chatchat (formerly langchain-ChatGLM), local knowledge based LLM (like ChatGLM, Qwen and Llama) RAG and Agent app with langchain. The repository metadata lists Python as its primary language. The metadata lists the Apache-2.0 license. This article stays within the project description and details documented in the GitHub repository README.

02
DEEP OPEN-SOURCE ANALYSIS

Repository scope

GitHub describes it as Langchain-Chatchat(原Langchain-ChatGLM)基于 Langchain 与 ChatGLM, Qwen 与 Llama 等语言模型的 RAG 与 Agent 应用 | Langchain-Chatchat (formerly langchain-ChatGLM), local knowledge based LLM (like ChatGLM, Qwen and Llama) RAG and Agent app with langchain. The repository metadata lists Python as its primary language. The metadata lists the Apache-2.0 license. The README describes the project this way: 💡 受 GanymedeNil 的项目 document.ai 和 AlexZhangji 创建的 ChatGLM-6B Pull Request 启发,建立了全流程可使用开源模型实现的本地知识库问答应用。本项目的最新版本中可使用 Xinference、Ollama 等框架接入 GLM-4-Chat、 Qwen2-Instruct、 Llama3 等模型,依托于 langchain 框架支持通过基于 FastAPI 提供的 API 调用服务,或使用基于 Streamlit 的 WebUI 进行操作。

03
DEEP OPEN-SOURCE ANALYSIS

概述

The README section "概述" states: ✅ 本项目支持市面上主流的开源 LLM、 Embedding 模型与向量数据库,可实现全部使用 开源 模型 离线私有部署 。与此同时,本项目也支持 OpenAI GPT API 的调用,并将在后续持续扩充对各类模型及模型 API 的接入。

04
DEEP OPEN-SOURCE ANALYSIS

概述

The README section "概述" states: ⛓️ 本项目实现原理如下图所示,过程包括加载文件 - 读取文本 - 文本分割 - 文本向量化 - 问句向量化 - 在文本向量中匹配出与问句向量最相似的 top k 个 - 匹配出的文本作为上下文和问题一起添加到 prompt 中 - 提交给 LLM 生成回答。

05
DEEP OPEN-SOURCE ANALYSIS

0.3.x 版本功能一览

The README section "0.3.x 版本功能一览" states: | 功能 | 0.2.x | 0.3.x | |-----------|----------------------------------|---------------------------------------------------------------------| | 模型接入 | 本地:fastchat 在线:XXXModelWorker | 本地:model provider,支持大部分主流模型加载框架 在线:oneapi 所有模型接入均兼容openai sdk | | Agent | ❌不稳定 | ✅针对ChatGLM3和Qwen进行优化,Agent能力显著提升 || | LLM对话 | ✅ | ✅ || | 知识库对话 | ✅ | ✅ || | 搜索引擎对话 | ✅ | ✅ || | 文件对话 | ✅仅向量检索 | ✅统一为File RAG功能,支持BM25+KNN等多种检索方式 || | 数据库对话 | ❌ | ✅ || | 多模态图片对话 | ❌ | ✅ 推荐使用 qwen-vl-chat || | ARXIV文献对话 | ❌ | ✅ || | Wolfram对话 | ❌ | ✅ || | 文生图 | ❌ | ✅ || | 本地知识库管理 | ✅ | ✅ || | WEBUI | ✅ | ✅更好的多会话支持,自定义系统提示词... |

06
DEEP OPEN-SOURCE ANALYSIS

Editorial conclusion

The repository README is the source for this review. It does not replace a local installation or an independent test.

07
DEEP OPEN-SOURCE ANALYSIS

Official sources

08
Community notes

Community notes