Spaces:
Sleeping
Sleeping
fschwartzer
commited on
Commit
•
7c67564
1
Parent(s):
59e4db6
Update app.py
Browse files
app.py
CHANGED
@@ -121,7 +121,8 @@ def search_with_fallback(query, df, limit=50):
|
|
121 |
|
122 |
for i in range(len(query_parts), 0, -1):
|
123 |
simplified_query = " ".join(query_parts[:i])
|
124 |
-
|
|
|
125 |
df_filtrado = filtrar_itens_similares(df_refinado, simplified_query, limit=limit)
|
126 |
|
127 |
if not df_filtrado.empty:
|
@@ -129,6 +130,7 @@ def search_with_fallback(query, df, limit=50):
|
|
129 |
|
130 |
return pd.DataFrame()
|
131 |
|
|
|
132 |
def integrated_app(query, titulo, EC, PU):
|
133 |
include_conjunto = "conjunto" in query.lower()
|
134 |
df_mercadolibre = fetch_data_to_dataframe(query, 50, "mercadolibre")
|
|
|
121 |
|
122 |
for i in range(len(query_parts), 0, -1):
|
123 |
simplified_query = " ".join(query_parts[:i])
|
124 |
+
include_word = ["conjunto"] if include_conjunto else [] # Ensure include_word is a list
|
125 |
+
df_refinado = refinar_resultados(df, include_word=include_word)
|
126 |
df_filtrado = filtrar_itens_similares(df_refinado, simplified_query, limit=limit)
|
127 |
|
128 |
if not df_filtrado.empty:
|
|
|
130 |
|
131 |
return pd.DataFrame()
|
132 |
|
133 |
+
|
134 |
def integrated_app(query, titulo, EC, PU):
|
135 |
include_conjunto = "conjunto" in query.lower()
|
136 |
df_mercadolibre = fetch_data_to_dataframe(query, 50, "mercadolibre")
|