Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -15,6 +15,7 @@ openai.api_key = os.getenv("OPENAI_API_KEY")
|
|
15 |
openai.api_base = "https://tensora-oai.openai.azure.com/"
|
16 |
openai.api_type = "azure"
|
17 |
openai.api_version = "2023-05-15"
|
|
|
18 |
os_connection_string = os.getenv("CONNECTION")
|
19 |
os_mail_password = os.getenv("MAIL_PASSWORD")
|
20 |
|
@@ -231,7 +232,7 @@ def bot(history, job, resume, job_params):
|
|
231 |
messages.append({"role": "assistant", "content": assistant})
|
232 |
|
233 |
response = openai.ChatCompletion.create(
|
234 |
-
|
235 |
messages=messages,
|
236 |
temperature=0.0,
|
237 |
stream=True,
|
@@ -284,13 +285,9 @@ def send_evaluation(history, job, resume, job_params):
|
|
284 |
# E-Mail-Nachricht erstellen
|
285 |
subject = "Evaluation for the job: "+job_params[0]
|
286 |
message = f"""Dear Recruiter,
|
287 |
-
|
288 |
Please find attached the complete chat history for this evaluation, resume and summary.
|
289 |
-
|
290 |
The evaluation AI-supported summarized:
|
291 |
-
|
292 |
{ai_summary}
|
293 |
-
|
294 |
Sincerely,
|
295 |
Your Evaluation Tool
|
296 |
"""
|
|
|
15 |
openai.api_base = "https://tensora-oai.openai.azure.com/"
|
16 |
openai.api_type = "azure"
|
17 |
openai.api_version = "2023-05-15"
|
18 |
+
|
19 |
os_connection_string = os.getenv("CONNECTION")
|
20 |
os_mail_password = os.getenv("MAIL_PASSWORD")
|
21 |
|
|
|
232 |
messages.append({"role": "assistant", "content": assistant})
|
233 |
|
234 |
response = openai.ChatCompletion.create(
|
235 |
+
engine="gpt-4",
|
236 |
messages=messages,
|
237 |
temperature=0.0,
|
238 |
stream=True,
|
|
|
285 |
# E-Mail-Nachricht erstellen
|
286 |
subject = "Evaluation for the job: "+job_params[0]
|
287 |
message = f"""Dear Recruiter,
|
|
|
288 |
Please find attached the complete chat history for this evaluation, resume and summary.
|
|
|
289 |
The evaluation AI-supported summarized:
|
|
|
290 |
{ai_summary}
|
|
|
291 |
Sincerely,
|
292 |
Your Evaluation Tool
|
293 |
"""
|