Skip to content

Commit

Permalink
fixed some hard-coded values
Browse files Browse the repository at this point in the history
  • Loading branch information
Yusuf Kaka committed Oct 3, 2023
1 parent 9e42b69 commit 9885cc6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions conversation.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,9 @@ def __init__(self, user_id=None):

def get_answer(self, tg_user=None):
# Initialise OpenAI
openai.api_type = "azure"
openai.api_base = "https://jarvis-openai.openai.azure.com/"
openai.api_version = "2022-12-01"
openai.api_type = os.getenv("OPENAI_API_TYPE","azure")
openai.api_base = os.getenv("OPENAI_API_BASE")
openai.api_version = os.getenv("OPENAI_API_VERSION","2022-12-01")
openai.api_key = os.getenv("OPENAI_API_KEY")
try:
response = openai.Completion.create(
Expand Down

0 comments on commit 9885cc6

Please sign in to comment.