Spaces:
Build error
Build error
Create mote_router.py
Browse files- mote_router.py +10 -0
mote_router.py
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
def compute_modality_weights(query):
|
| 2 |
+
query = query.lower()
|
| 3 |
+
|
| 4 |
+
if any(word in query for word in ["%", "percentage", "emission", "scope", "table"]):
|
| 5 |
+
return {"text": 0.3, "visual": 0.1, "tabular": 0.6}
|
| 6 |
+
|
| 7 |
+
if any(word in query for word in ["graph", "figure", "trend", "chart"]):
|
| 8 |
+
return {"text": 0.3, "visual": 0.6, "tabular": 0.1}
|
| 9 |
+
|
| 10 |
+
return {"text": 0.7, "visual": 0.15, "tabular": 0.15}
|