Coder Social home page Coder Social logo

chinese-langchain's Introduction

license title sdk emoji colorFrom colorTo pinned app_file
openrail
Chinese-LangChain
gradio
🚀
yellow
yellow
true
app.py

Chinese-LangChain

Chinese-LangChain:中文langchain项目,基于ChatGLM-6b+langchain实现本地化知识库检索与智能答案生成

https://github.com/yanqiangmiffy/Chinese-LangChain

俗称:小必应,Q.Talk,强聊,QiangTalk

🔥 效果演示

🚋 使用教程

  • 选择知识库询问相关领域的问题

🏗️ 部署教程

运行配置

  • 显存:12g,实际运行9g够了
  • 运行内存:32g

运行环境

langchain
gradio
transformers
sentence_transformers
faiss-cpu
unstructured
duckduckgo_search
mdtex2html
chardet
cchardet

启动Gradio

python main.py

🚀 特性

  • 🚀 2023/05/19 yanlijun573提供streamlit分支
  • 🚀 2023/04/22 支持模型多机多卡推理
  • 🔭 2023/04/20 支持模型问答与检索问答模式切换
  • 💻 2023/04/20 感谢HF官方提供免费算力,添加HuggingFace Spaces在线体验[🤗 DEMO
  • 🧫 2023/04/19 发布45万Wikipedia的文本预处理语料以及FAISS索引向量
  • 🐯 2023/04/19 引入ChuanhuChatGPT皮肤
  • 📱 2023/04/19 增加web search功能,需要确保网络畅通!(感谢@wanghao07456,提供的idea)
  • 📚 2023/04/18 webui增加知识库选择功能
  • 🚀 2023/04/18 修复推理预测超时5s报错问题
  • 🎉 2023/04/17 支持多种文档上传与内容解析:pdf、docx,ppt等
  • 🎉 2023/04/17 支持知识增量更新

🧰 知识库

构建知识库

  • Wikipedia-zh

详情见:corpus/zh_wikipedia/README.md

知识库向量索引

知识库数据 FAISS向量
中文维基百科截止4月份数据,45万 链接:https://pan.baidu.com/s/1VQeA_dq92fxKOtLL3u3Zpg?pwd=l3pn 提取码:l3pn
截止去年九月的130w条中文维基百科处理结果和对应faiss向量文件 @yubuyuabc 链接:https://pan.baidu.com/s/1Yls_Qtg15W1gneNuFP9O_w?pwd=exij 提取码:exij
💹 大规模金融研报知识图谱 链接:https://pan.baidu.com/s/1FcIH5Fi3EfpS346DnDu51Q?pwd=ujjv 提取码:ujjv

🔨 TODO

  • 支持上下文
  • 支持知识增量更新
  • 支持加载不同知识库
  • 支持检索结果与LLM生成结果对比
  • 支持检索生成结果与原始LLM生成结果对比
  • 支持模型问答与检索问答
  • 检索结果过滤与排序
  • 互联网检索结果接入
  • 模型初始化有问题
  • 增加非LangChain策略
  • 显示当前对话策略
  • 构建一个垂直业务场景知识库,非通用性

交流

欢迎多提建议、Bad cases,目前尚不完善,欢迎进群及时交流,也欢迎大家多提PR

合作交流可以联系:

❤️引用

⭐️ Star History

Star History Chart

chinese-langchain's People

Contributors

yanqiangmiffy avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.