chatgpt-bot
b653c25fbc
Fix device detection and fallback logic and add 'xpu' ( #2570 )
...
Co-authored-by: zR <2448370773@qq.com>
2024-01-11 18:36:38 +08:00
高厉害
e7bba6bd0a
fix: automatically replace unsupported torch device ( #2514 )
2024-01-11 18:16:31 +08:00
liunux4odoo
448c99f969
fix: 过滤 sse_starlette 返回的 ping 包,避免 `JSON Decoder error : ping -...` ( #2585 )
2024-01-09 09:14:29 +08:00
liunux4odoo
17e8bc072b
fix: make_text_splitter use wrong chunk_* parameters when exception. ( close #2561 ) ( #2564 )
2024-01-05 15:06:59 +08:00
imClumsyPanda
719e2713ed
fix typos
2023-12-31 20:13:14 +08:00
liunux4odoo
c179230ce0
remove /chat/fastchat API endpoint ( #2506 )
2023-12-29 09:44:37 +08:00
liunux4odoo
5cccd5e7aa
merge from master
2023-12-29 09:10:01 +08:00
liunux4odoo
9ff7bef2c2
新功能:知识库管理界面支持查看、编辑、删除向量库文档 ( #2471 )
...
* 新功能:
- 知识库管理界面支持查看、编辑、删除向量库文档。暂不支持增加(aggrid添加新行比较麻烦,需要另外实现)
- 去除知识库管理界面中重建知识库和删除知识库按钮,建议用户到终端命令操作
修复:
- 所有与知识库名称、文件名称有关的数据库操作函数都改成大小写不敏感,所有路径统一为 posix 风格,避免因路径文本不一致导致数据重复和操作失效 (close #2232)
开发者:
- 添加 update_docs_by_id 函数与 API 接口。当前仅支持 FAISS,暂时未用到,未将来对知识库做更细致的修改做准备
- 统一 DocumentWithScore 与 DocumentWithVsId
- FAISS 返回的 Document.metadata 中包含 ID, 方便后续查找比对
- /knowledge_base/search_docs 接口支持 file_name, metadata 参数,可以据此检索文档
* fix bug
2023-12-26 13:44:36 +08:00
zR
2e1442a5c1
修复 Langchain 更新之后OpenAI在线embed无法正常使用问题
2023-12-23 11:36:11 +08:00
liunux4odoo
4e5bc8b399
修复: zhipu-api 请求出错时返回准确的错误信息
2023-12-22 10:17:00 +08:00
hzg0601
129c765a74
新增特性:reranker对向量召回文本进行重排
2023-12-21 19:05:11 +08:00
hzg0601
5891f94c88
temporarily add reranker
2023-12-21 16:05:16 +08:00
Funkeke
c1a32d9f1a
fix:使用在线embedding模型时 报错 There is no current event loop in thread 'Any… ( #2393 )
...
* fix:使用在线embedding模型时 报错 There is no current event loop in thread 'AnyIO worker thread'
* 动态配置在线embbding模型
---------
Co-authored-by: fangkeke <3339698829@qq.com>
2023-12-20 08:40:53 +08:00
Astlvk
7e01e82470
fixed 迭代器参数传递错误,知识库问答报错TypeError: unhashable type: 'list' ( #2383 )
...
Co-authored-by: liunux4odoo <41217877+liunux4odoo@users.noreply.github.com>
2023-12-15 07:54:36 +08:00
xldistance
7e8391eb55
修复knowledge_base_chat_iterator传参错误 ( #2386 )
2023-12-15 07:53:36 +08:00
xldistance
332e1ccfaa
更新self.dims_length赋值错误 ( #2380 )
2023-12-14 19:56:39 +08:00
liunux4odoo
472a97a616
所有 chat 接口都改为 EventSourceResponse;ApiRequest 作对应修改
2023-12-13 16:53:24 +08:00
liunux4odoo
c8fef3380c
merge from dev
2023-12-13 16:52:40 +08:00
hzg0601
db008c1af8
为milvus增加额外索引与搜索配置
2023-12-13 15:52:11 +08:00
liunux4odoo
2604c9e761
fix: prompt template name error in file_chat ( #2366 )
2023-12-12 21:12:33 +08:00
hzg0601
db1c1e2ee4
解决多次调用es创建索引失败的问题
2023-12-11 10:39:59 +08:00
liunux4odoo
2e9319846e
support .xls files
2023-12-08 15:04:08 +08:00
liunux4odoo
7b70776810
fix: doc ext name error in LOADER_DICT
2023-12-08 13:59:55 +08:00
hzg0601
4c2fda7200
Merge branch 'dev' of https://github.com/chatchat-space/Langchain-Chatchat into dev
2023-12-06 20:42:32 +08:00
hzg0601
d1f94c2846
temporarily add reranker
2023-12-06 20:42:27 +08:00
hzg0601
1fac51fe35
temporarily save faiss_cache
2023-12-06 09:45:56 +00:00
liunux4odoo
67b7c99d03
ocr 支持 GPU 加速(需要手动安装 rapidocr_paddle[gpu]);知识库支持 MHTML 和 Evernote 文件。 ( #2265 )
...
在 requirements 和 Wiki 中增加对可选文档加载器 SDK 的说明 ( close #2264 )
2023-12-04 09:39:56 +08:00
liunux4odoo
7d2de47bcf
文件对话和知识库对话 API 接口实现全异步操作,防止阻塞 ( #2256 )
...
* EmbeddingFunAdapter 支持异步操作;文件对话和知识库对话 API 接口实现全异步操作,防止阻塞
* 修复: 使 list_files_from_folder 返回相对路径
2023-12-02 19:22:44 +08:00
zR
dcb76984bc
修复Azure 不设置Max token的bug ( #2254 )
2023-12-02 16:50:56 +08:00
liunux4odoo
4fa28c71b1
修复:chat 接口默认使用 memory获取10条历史消息,导致最终拼接的prompt出错 ( #2247 )
...
修改后默认使用用户传入的history,只有同时传入conversation_id和history_len时才从数据库读取历史消息
使用memory还有一个问题,对话角色是固定的,不能适配不同的模型。
其它:注释一些无用的 print
2023-12-01 11:35:43 +08:00
zR
0cc1be224d
依赖升级 ( #2246 )
...
大量依赖升级到最新版
测试环境:Ubuntu 22.04 LTS kernel 6.6.3 Python 3.10.12,Cuda12.3 update1
2023-12-01 11:34:41 +08:00
imClumsyPanda
c34b4136c0
update file format
2023-11-30 23:33:48 +08:00
imClumsyPanda
072e0a2a32
update reqs and server/utils
2023-11-30 22:23:15 +08:00
zty
5ac77e5089
修复: MiniMax和千帆在线embedding模型分批请求的bug ( #2208 )
...
* 修复: MiniMax和千帆在线embedding模型分批请求的bug
* 修改了一处typo
2023-11-30 17:28:22 +08:00
zR
40918c21de
bug修复和提示词修改 ( #2230 )
...
* 更新Langchain依赖到0.0.343以上版本
* 更改了一些提示词和依赖,修改了openai异常的问题
* 注释data的打印日志
2023-11-30 12:09:53 +08:00
zR
b7a50daa0f
更新Langchain依赖到0.0.342以上版本 ( #2212 )
2023-11-29 15:08:13 +08:00
liunux4odoo
509dee0425
fix: empty docs error in KnowledgeFile
2023-11-29 11:33:43 +08:00
liunux4odoo
7d580d9a47
修复:*_chat 接口中重设 max_tokens 时导致 `local variable 'max_tokens' referenced before assignment` 错误
2023-11-28 21:00:00 +08:00
liunux4odoo
8b695dba03
*_chat 接口中,当 max_tokens=0时,将其设为 None,避免 swagger ui 中默认值为0时访问出错
2023-11-26 16:47:58 +08:00
glide-the
279ffdf117
单个知识库根据doc_ids摘要
2023-11-25 23:31:13 +08:00
glide-the
248db46187
Merge branch 'dev_summary' into dev_command_summary
...
实现summary_chunk 文档分段总结业务实现
使用 MapReduceDocumentsChain 生成摘要
# Conflicts:
# server/api.py
# server/knowledge_base/kb_doc_api.py
# server/knowledge_base/kb_service/base.py
# server/knowledge_base/migrate.py
2023-11-25 22:30:41 +08:00
glide-the
f57837c07a
Merge branch 'dev_summary' into dev_tmp
...
# Conflicts:
# server/api.py
# server/knowledge_base/kb_doc_api.py
# server/knowledge_base/kb_service/base.py
# server/knowledge_base/migrate.py
2023-11-25 21:02:46 +08:00
liunux4odoo
1de4258aa0
给 ApiModelWorker 添加 logger 成员变量,API请求出错时输出有意义的错误信息。 ( #2169 )
...
* 给 ApiModelWorker 添加 logger 成员变量,API请求出错时输出有意义的错误信息。
/chat/chat 接口 conversation_id参数改为默认 "",避免 swagger 页面默认值错误导致历史消息失效
* 修复在线模型一些bug
2023-11-25 13:51:07 +08:00
zR
1b0cf67a57
支持软连接的知识库 ( #2167 )
...
* GLM3支持传入提示词
支持传入提示词的Agent ChatGLM3-6B
* 软连接处理
1. 有效的软连接处理,参考了 #2125
2. 更新了依赖,现在fschat原生支持GLM3的全功能
* 更新了支持的模型列表和依赖
1. 推荐用户使用GLM3-6B取代2代GLM模型
2. 推荐用户使用性能更强的bge模型
3 推荐使用vllm和torch的最新稳定版本
2023-11-24 22:47:55 +08:00
Eden
dfcebf7bc3
支持昆仑万维天工大模型 ( #2166 )
...
---------
Co-authored-by: Eden <chuangqi.huang@ubtrobot.com>
Co-authored-by: liunux4odoo <liunux@qq.com>
2023-11-24 22:25:35 +08:00
liunux4odoo
824c29a6d2
将 MiniMax 和 千帆 在线 Embedding 改为 10 个文本一批,防止接口数量限制 ( #2161 )
2023-11-24 16:42:20 +08:00
liunux4odoo
1b9b777eaf
使 MessageModel 中 conversation_id 为非必填项,避免前端请求错误
2023-11-23 21:42:27 +08:00
liunux4odoo
aae4144476
数据库和向量库中文档 metadata["source"] 改为相对路径,便于向量库迁移 ( #2153 )
...
修复:
- 上传知识库文件名称包括子目录时,自动创建子目录
2023-11-23 19:54:00 +08:00
qiankunli
1c97673d41
feat: add db memory ( #2046 )
...
* feat: add db memory
* WEBUI 添加多会话功能
---------
Co-authored-by: liqiankun.1111 <liqiankun.1111@bytedance.com>
Co-authored-by: liunux4odoo <liunux@qq.com>
2023-11-22 18:38:26 +08:00
glide-the
17c9632942
统一在线模型异常报文、增加详细日志
2023-11-21 21:47:02 +08:00