mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-28 00:14:21 +00:00
debug: 请求时debug输出api_key
This commit is contained in:
@@ -1,3 +1,5 @@
|
|||||||
|
import logging
|
||||||
|
|
||||||
import openai
|
import openai
|
||||||
|
|
||||||
import config
|
import config
|
||||||
@@ -26,6 +28,7 @@ class OpenAIInteract:
|
|||||||
|
|
||||||
# 请求OpenAI Completion
|
# 请求OpenAI Completion
|
||||||
def request_completion(self, prompt, stop):
|
def request_completion(self, prompt, stop):
|
||||||
|
logging.debug("请求OpenAI Completion, key:"+openai.api_key)
|
||||||
response = openai.Completion.create(
|
response = openai.Completion.create(
|
||||||
prompt=prompt,
|
prompt=prompt,
|
||||||
stop=stop,
|
stop=stop,
|
||||||
|
|||||||
Reference in New Issue
Block a user