Update app.py
Browse files
app.py
CHANGED
@@ -39,10 +39,9 @@ def get_web_context(prompt: str) -> dict:
|
|
39 |
|
40 |
@app.post("/api/search")
|
41 |
async def search(q: Query):
|
42 |
-
web_data = get_web_context(q.query)
|
43 |
messages = [
|
44 |
{"role": "system", "content": "You are a helpful search assistant that reads from the following web sources to answer user questions."},
|
45 |
-
{"role": "user", "content": f"{q.query}
|
46 |
]
|
47 |
try:
|
48 |
response = client.chat.completions.create(
|
|
|
39 |
|
40 |
@app.post("/api/search")
|
41 |
async def search(q: Query):
|
|
|
42 |
messages = [
|
43 |
{"role": "system", "content": "You are a helpful search assistant that reads from the following web sources to answer user questions."},
|
44 |
+
{"role": "user", "content": f"{q.query}"}
|
45 |
]
|
46 |
try:
|
47 |
response = client.chat.completions.create(
|