Go to file
zx2021 2d3ea9830e
Update requirements.txt
修复运行pip install -r requirements.txt提示ERROR: Invalid requirement: '"detectron2@git+https://github.com/facebookresearch/detectron2.git@v0.6#egg=detectron2"' (from line 4 of requirements.txt)
Hint: = is not a valid operator. Did you mean == ?的错误
2023-03-31 21:47:58 +08:00
README.md first commit 2023-03-31 20:23:49 +08:00
README_en.md first commit 2023-03-31 20:09:40 +08:00
chatglm_llm.py first commit 2023-03-31 20:09:40 +08:00
knowledge_based_chatglm.py first commit 2023-03-31 20:09:40 +08:00
requirements.txt Update requirements.txt 2023-03-31 21:47:58 +08:00

README_en.md

ChatGLM Application Based on Local Knowledge

Introduction

🌍 中文文档

🤖 A local knowledge based LLM Application with ChatGLM-6B and langchain.

💡 Inspired by document.ai by GanymedeNil and ChatGLM-6B Pull Request by AlexZhangji.

In this project, GanymedeNil/text2vec-large-chinese is used as Embedding Modeland ChatGLM-6B used as LLM。Based on those modelsthis project can be deployed offline with all open source models。

Usage

1. install python packages

pip install -r requirements

Attention: With langchain.document_loaders.UnstructuredFileLoader used to connect with local knowledge file, you may need some other dependencies as mentioned in langchain documentation

2. Run knowledge_based_chatglm.py script

python knowledge_based_chatglm.py

Roadmap

  • local knowledge based application with langchain + ChatGLM-6B
  • unstructured files loaded with langchain
  • more different file format loaded with langchain
  • implement web ui DEMO with gradio/streamlit
  • implement API with fastapiand web ui DEMO with API