Update results.py
Browse files- results.py +4 -5
results.py
CHANGED
|
@@ -5,15 +5,14 @@ import json, csv
|
|
| 5 |
def results_agent(query, context):
|
| 6 |
|
| 7 |
system_prompt = """
|
| 8 |
-
You are an academic advisor helping students (user role) find classes for the next semester.
|
| 9 |
Relay information in a succinct way that fully answers their questions.
|
| 10 |
-
You will be given a user's query, as well as the chat history and finally, the rag responses in context.
|
| 11 |
-
|
| 12 |
-
Please add new lines, bolding/italicizing, formatting like "##" for headers to make it a pretty output as well.
|
| 13 |
"""
|
| 14 |
|
| 15 |
response = openai.ChatCompletion.create(
|
| 16 |
-
model="gpt-
|
| 17 |
messages=[
|
| 18 |
{"role": "system", "content": system_prompt},
|
| 19 |
{"role": "user", "content": query},
|
|
|
|
| 5 |
def results_agent(query, context):
|
| 6 |
|
| 7 |
system_prompt = """
|
| 8 |
+
You are an academic advisor helping students (user role) find classes for the next semester, based only on rag responses that are provided to you as context.
|
| 9 |
Relay information in a succinct way that fully answers their questions.
|
| 10 |
+
You will be given a user's query, as well as the chat history and finally, the rag responses in context. Respond in a way that keeps conversation flow.
|
| 11 |
+
You should only recommend classes when they are provided in RAG responses, otherwise, respond appropriately.
|
|
|
|
| 12 |
"""
|
| 13 |
|
| 14 |
response = openai.ChatCompletion.create(
|
| 15 |
+
model="gpt-4",
|
| 16 |
messages=[
|
| 17 |
{"role": "system", "content": system_prompt},
|
| 18 |
{"role": "user", "content": query},
|