Spaces:
Runtime error
Runtime error
Update app/rag.py
Browse files- app/rag.py +3 -1
app/rag.py
CHANGED
|
@@ -32,11 +32,13 @@ def find_top_5_ayahs_qdrant(question: str):
|
|
| 32 |
|
| 33 |
match = normalized_df[normalized_df['normalized'] == normalized_english_ayah]
|
| 34 |
arabic_ayah = match.iloc[0]['arabic'] if not match.empty else "❌ Not found"
|
|
|
|
| 35 |
|
| 36 |
results.append({
|
| 37 |
"question": question,
|
| 38 |
"answer": english_ayah,
|
| 39 |
-
"arabic": arabic_ayah
|
|
|
|
| 40 |
})
|
| 41 |
|
| 42 |
print("results size:", asizeof.asizeof(results))
|
|
|
|
| 32 |
|
| 33 |
match = normalized_df[normalized_df['normalized'] == normalized_english_ayah]
|
| 34 |
arabic_ayah = match.iloc[0]['arabic'] if not match.empty else "❌ Not found"
|
| 35 |
+
link = match.iloc[0]['link'] if not match.empty else "https://quran.com"
|
| 36 |
|
| 37 |
results.append({
|
| 38 |
"question": question,
|
| 39 |
"answer": english_ayah,
|
| 40 |
+
"arabic": arabic_ayah,
|
| 41 |
+
"link": link
|
| 42 |
})
|
| 43 |
|
| 44 |
print("results size:", asizeof.asizeof(results))
|