liunux4odoo
|
ec85cd1954
|
move wrap_done & get_ChatOpenAI from server.chat.utils to server.utils (#1506)
|
2023-09-17 16:19:50 +08:00 |
liunux4odoo
|
a65bc4a63c
|
添加configs/prompt_config.py,允许用户自定义prompt模板: (#1504)
1、 默认包含2个模板,分别用于LLM对话,知识库和搜索引擎对话
2、 server/utils.py提供函数get_prompt_template,获取指定的prompt模板内容(支持热加载)
3、 api.py中chat/knowledge_base_chat/search_engine_chat接口支持prompt_name参数
|
2023-09-17 13:27:11 +08:00 |
liunux4odoo
|
3dde02be28
|
优化LLM模型列表获取、切换的逻辑: (#1497)
1、更准确的获取未运行的可用模型
2、优化WEBUI模型列表显示与切换的控制逻辑
|
2023-09-16 07:15:08 +08:00 |
liunux4odoo
|
f7c73b842a
|
优化configs (#1474)
* remove llm_model_dict
* optimize configs
* fix get_model_path
* 更改一些默认参数,添加千帆的默认配置
* Update server_config.py.example
|
2023-09-15 17:52:22 +08:00 |
liunux4odoo
|
60f88ae92e
|
fix: 由于server.utils导入model_workers时,导入fastchat model_worker,导致startup启动延迟明显 (#1436)
|
2023-09-12 08:52:00 +08:00 |
liunux4odoo
|
22ff073309
|
修改Embeddings和FAISS缓存加载方式,知识库相关API接口支持多线程并发 (#1434)
* 修改Embeddings和FAISS缓存加载方式,支持多线程,支持内存FAISS
* 知识库相关API接口支持多线程并发
* 根据新的API接口调整ApiRequest和测试用例
* 删除webui.py失效的启动说明
|
2023-09-11 20:41:41 +08:00 |
glide-the
|
5550e3c1a9
|
增加显示详细日志开关
|
2023-09-08 20:48:31 +08:00 |
liunux4odoo
|
1195eb75eb
|
merge pr1413
|
2023-09-08 10:30:07 +08:00 |
liunux4odoo
|
93b133f9ac
|
将KnowledgeFile的file2text拆分成file2docs、docs2texts和file2text三个部分,在保持接口不变的情况下,实现:
1、支持chunk_size和chunk_overlap参数
2、支持自定义text_splitter
3、支持自定义docs
修复:csv文件不使用text_splitter
|
2023-09-04 21:00:16 +08:00 |
liunux4odoo
|
0bc9d5c8ee
|
Merge branch 'dev' into opt_add_doc
|
2023-09-03 21:38:45 +08:00 |
imClumsyPanda
|
8a73673d6b
|
update model_config.py.example
|
2023-09-03 15:57:44 +08:00 |
imClumsyPanda
|
25880ebd52
|
fix bug when config["device"]="auto"
|
2023-09-02 22:11:54 +08:00 |
liunux4odoo
|
6cb1bdf623
|
添加切换模型功能,支持智谱AI在线模型 (#1342)
* 添加LLM模型切换功能,需要在server_config中设置可切换的模型
* add tests for api.py/llm_model/*
* - 支持模型切换
- 支持智普AI线上模型
- startup.py增加参数`--api-worker`,自动运行所有的线上API模型。使用`-a
(--all-webui), --all-api`时默认开启该选项
* 修复被fastchat覆盖的标准输出
* 对fastchat日志进行更细致的控制,startup.py中增加-q(--quiet)开关,可以减少无用的fastchat日志输出
* 修正chatglm api的对话模板
Co-authored-by: liunux4odoo <liunu@qq.com>
|
2023-09-01 23:58:09 +08:00 |
liunux4odoo
|
55e417a263
|
升级注意
数据库表发生变化,需要重建知识库
新功能
- 增加FileDocModel库表,存储知识文件与向量库Document ID对应关系以及元数据,便于检索向量库
- 增加FileDocModel对应的数据库操作函数(这些函数主要是给KBService调用,用户一般无需使用):
- list_docs_from_db: 根据知识库名称、文件名称、元数据检索对应的Document IDs
- delete_docs_from_db: 根据知识库名称、文件名称删除对应的file-doc映射
- add_docs_to_db: 添加对应的file-doc映射
- KBService增加list_docs方法,可以根据文件名、元数据检索Document。当前仅支持FAISS,待milvus/pg实现get_doc_by_id方法后即自动支持。
- 去除server.utils对torch的依赖
待完善
- milvus/pg kb_service需要实现get_doc_by_id方法
|
2023-09-01 22:54:57 +08:00 |
liunux4odoo
|
b1201a5f23
|
优化LLM和Embedding模型运行设备配置,可设为auto自动检测;修复:重建知识库时FAISS未保存 (#1330)
* 避免configs对torch的依赖;
* webui自动从configs获取api地址(close #1319)
* bug fix: 重建知识库时FAISS未保存
* 优化LLM和Embedding模型运行设备配置,可设为auto自动检测
|
2023-08-31 17:44:48 +08:00 |
liunux4odoo
|
16fb19d2c3
|
优化LLM和Embedding模型运行设备配置,可设为auto自动检测
|
2023-08-31 17:41:09 +08:00 |
liunux4odoo
|
34a416b941
|
优化server_config配置项 (#1293)
* update server_config.py:
- 在model_config中增加HISTORY_LEN配置参数
- 将server_config中helper function移动到server.utils中
- 统一set_httpx_timeout的定义和调用
* update webui.py:
应用model_config中的配置项:HISTORY_LEN,VECTOR_SEARCH_TOP_K,SEARCH_ENGINE_TOP_K
---------
Co-authored-by: liunux4odoo <liunu@qq.com>
|
2023-08-29 10:06:09 +08:00 |
liunux4odoo
|
69627a2fa3
|
update chat and knowledge base api: unify exception processing and return types
|
2023-08-19 15:14:45 +08:00 |
liunux4odoo
|
f64affc930
|
update llm_api and api server:
1. fastchat's controller/model_worker/api_server use swagger UI offline.
2. add custom title and icon.
3. remove fastapi-offline dependence
|
2023-08-16 14:20:09 +08:00 |
liunux4odoo
|
a08fe994c2
|
更新API与ApiReuest:
1. 重新整理webui_pages/utils与server/knowledge_base间的工具依赖
2.
将delete_knowledge_base与delete_doc接口从delete改为post.delete不支持body参数
3. 修复update_doc
4. 修复部分bug
|
2023-08-11 08:45:26 +08:00 |
imClumsyPanda
|
8a4d9168fa
|
update import pkgs and format
|
2023-08-10 21:26:05 +08:00 |
liunux4odoo
|
18e7e7307b
|
patch fastapi-offline to use local swagger-ui assests
|
2023-08-10 17:00:39 +08:00 |
imClumsyPanda
|
dcf49a59ef
|
v0.2.0 first commit
|
2023-07-27 23:22:07 +08:00 |