Skip to content

Commit 163e59c

Browse files
committed
minor bug fix
1 parent 07ece29 commit 163e59c

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

config.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@
8181

8282
# 多线程函数插件中,默认允许多少路线程同时访问OpenAI。Free trial users的限制是每分钟3次,Pay-as-you-go users的限制是每分钟3500次
8383
# 一言以蔽之:免费(5刀)用户填3,OpenAI绑了信用卡的用户可以填 16 或者更高。提高限制请查询:https://platform.openai.com/docs/guides/rate-limits/overview
84-
DEFAULT_WORKER_NUM = 3
84+
DEFAULT_WORKER_NUM = 8
8585

8686

8787
# 色彩主题, 可选 ["Default", "Chuanhu-Small-and-Beautiful", "High-Contrast"]
@@ -103,6 +103,7 @@
103103
"华文中宋(STZhongsong)",
104104
"华文新魏(STXinwei)",
105105
"华文隶书(STLiti)",
106+
# 备注:以下字体需要网络支持,您可以自定义任意您喜欢的字体,如下所示,需要满足的格式为 "字体昵称(字体英文真名@字体css下载链接)"
106107
"思源宋体(Source Han Serif CN VF@https://chinese-fonts-cdn.deno.dev/packages/syst/dist/SourceHanSerifCN/result.css)",
107108
"月星楷(Moon Stars Kai HW@https://chinese-fonts-cdn.deno.dev/packages/moon-stars-kai/dist/MoonStarsKaiHW-Regular/result.css)",
108109
"珠圆体(MaokenZhuyuanTi@https://chinese-fonts-cdn.deno.dev/packages/mkzyt/dist/猫啃珠圆体/result.css)",

request_llms/bridge_deepseekcoder.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
from request_llms.local_llm_class import LocalLLMHandle, get_local_llm_predict_fns
77
from threading import Thread
88
from loguru import logger
9-
import torch
109
import os
1110

1211
def download_huggingface_model(model_name, max_retry, local_dir):
@@ -29,6 +28,7 @@ def load_model_info(self):
2928
self.cmd_to_install = cmd_to_install
3029

3130
def load_model_and_tokenizer(self):
31+
import torch
3232
# 🏃‍♂️🏃‍♂️🏃‍♂️ 子进程执行
3333
with ProxyNetworkActivate('Download_LLM'):
3434
from transformers import AutoTokenizer, AutoModelForCausalLM, TextIteratorStreamer

0 commit comments

Comments
 (0)