Skip to content

Commit

Permalink
Merge pull request #1563 from malsony/master
Browse files Browse the repository at this point in the history
Update xunfei_spark_bot.py
  • Loading branch information
zhayujie authored Dec 5, 2023
2 parents cc0be22 + 65424c7 commit c010549
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions bot/xunfei/xunfei_spark_bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,13 @@ def __init__(self):
self.app_id = conf().get("xunfei_app_id")
self.api_key = conf().get("xunfei_api_key")
self.api_secret = conf().get("xunfei_api_secret")
# 默认使用v3.0版本,2.0版本可设置为generalv2, 1.5版本可设置为 general
self.domain = "generalv2"
# 默认使用v3.0版本,1.5版本可设置为 "ws://spark-api.xf-yun.com/v1.1/chat",
# 2.0版本可设置为 "ws://spark-api.xf-yun.com/v2.1/chat"
# 默认使用v2.0版本: "generalv2"
# v1.5版本为 "general"
# v3.0版本为: "generalv3"
self.domain = "generalv3"
# 默认使用v2.0版本: "ws://spark-api.xf-yun.com/v2.1/chat"
# v1.5版本为: "ws://spark-api.xf-yun.com/v1.1/chat"
# v3.0版本为: "ws://spark-api.xf-yun.com/v3.1/chat"
self.spark_url = "ws://spark-api.xf-yun.com/v3.1/chat"
self.host = urlparse(self.spark_url).netloc
self.path = urlparse(self.spark_url).path
Expand Down

0 comments on commit c010549

Please sign in to comment.