Update app.py
Browse files
app.py
CHANGED
@@ -42,7 +42,7 @@ def get_relevant_context(pdf_text, query, num_contexts=3):
|
|
42 |
def generate_response(context, question):
|
43 |
prompt = f"The following is an excerpt from a research paper on GPT-4. Please answer the question based on this context:\n\nContext: {context}\n\nQuestion: {question}\nAnswer:"
|
44 |
response = openai.Completion.create(
|
45 |
-
model="gpt-
|
46 |
prompt=prompt,
|
47 |
max_tokens=200,
|
48 |
temperature=0.7,
|
|
|
42 |
def generate_response(context, question):
|
43 |
prompt = f"The following is an excerpt from a research paper on GPT-4. Please answer the question based on this context:\n\nContext: {context}\n\nQuestion: {question}\nAnswer:"
|
44 |
response = openai.Completion.create(
|
45 |
+
model="gpt-4o-mini", # Replace with the appropriate model identifier
|
46 |
prompt=prompt,
|
47 |
max_tokens=200,
|
48 |
temperature=0.7,
|