Spaces:
Sleeping
Sleeping
fschwartzer
commited on
Commit
•
4fd0504
1
Parent(s):
2598bbd
Update app.py
Browse files
app.py
CHANGED
@@ -30,14 +30,8 @@ model = genai.GenerativeModel(model_name="gemini-pro",
|
|
30 |
safety_settings=safety_settings)
|
31 |
|
32 |
def interpretar_e_refinar_busca(query):
|
33 |
-
|
34 |
-
|
35 |
-
"output: ",
|
36 |
-
f"input: {query}",
|
37 |
-
"output: ",
|
38 |
-
]
|
39 |
-
|
40 |
-
response = model.generate_content(prompt_parts)
|
41 |
refined_query = response.text.strip()
|
42 |
return refined_query
|
43 |
|
|
|
30 |
safety_settings=safety_settings)
|
31 |
|
32 |
def interpretar_e_refinar_busca(query):
|
33 |
+
prompt = f"Corrigir e refinar a busca: '{query}' para uma consulta mais precisa."
|
34 |
+
response = model.generate_content(prompt)
|
|
|
|
|
|
|
|
|
|
|
|
|
35 |
refined_query = response.text.strip()
|
36 |
return refined_query
|
37 |
|