qitongwei commited on
Commit
51a8cda
1 Parent(s): d52c4f4

Update bot/chatgpt/chat_gpt_bot.py

Browse files
Files changed (1) hide show
  1. bot/chatgpt/chat_gpt_bot.py +2 -2
bot/chatgpt/chat_gpt_bot.py CHANGED
@@ -12,7 +12,7 @@ user_session = dict()
12
  class ChatGPTBot(Bot):
13
  def __init__(self):
14
  openai.api_key = conf().get('open_ai_api_key')
15
- openai.api_base="https://api.mandrillai.tech/v1"
16
 
17
  def reply(self, query, context=None):
18
  # acquire reply content
@@ -42,7 +42,7 @@ class ChatGPTBot(Bot):
42
  def reply_text(self, query, user_id, retry_count=0):
43
  try:
44
  response = openai.ChatCompletion.create(
45
- model="gpt-4", # 对话模型的名称
46
  messages=query,
47
  temperature=0.5, # 值在[0,1]之间,越大表示回复越具有不确定性
48
  max_tokens=1500, # 回复最大的字符数
 
12
  class ChatGPTBot(Bot):
13
  def __init__(self):
14
  openai.api_key = conf().get('open_ai_api_key')
15
+ openai.api_base="https://zen-ai.top/v1"
16
 
17
  def reply(self, query, context=None):
18
  # acquire reply content
 
42
  def reply_text(self, query, user_id, retry_count=0):
43
  try:
44
  response = openai.ChatCompletion.create(
45
+ model="gpt-4-1106-preview", # 对话模型的名称
46
  messages=query,
47
  temperature=0.5, # 值在[0,1]之间,越大表示回复越具有不确定性
48
  max_tokens=1500, # 回复最大的字符数