Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -737,15 +737,15 @@ def ask(question: str) -> str:
|
|
| 737 |
if chunks:
|
| 738 |
dlog("CLEAN", "Post-clean applied")
|
| 739 |
answer = _answer_from_chunks(chunks, q)
|
| 740 |
-
return _ensure_min_answer(_post_clean(answer)) or
|
| 741 |
-
return
|
| 742 |
|
| 743 |
chunks = retrieve_context(q, top_k=5)
|
| 744 |
if not chunks:
|
| 745 |
-
return
|
| 746 |
dlog("CLEAN", "Post-clean applied")
|
| 747 |
answer = _answer_from_chunks(chunks, q)
|
| 748 |
-
return _ensure_min_answer(_post_clean(answer))
|
| 749 |
|
| 750 |
# ================== UI: NAME GATE + PER-ANSWER FEEDBACK ==================
|
| 751 |
def _now_iso():
|
|
|
|
| 737 |
if chunks:
|
| 738 |
dlog("CLEAN", "Post-clean applied")
|
| 739 |
answer = _answer_from_chunks(chunks, q)
|
| 740 |
+
return _ensure_min_answer(_post_clean(answer)) or direct_llm_fallback(q)
|
| 741 |
+
return direct_llm_fallback(q)
|
| 742 |
|
| 743 |
chunks = retrieve_context(q, top_k=5)
|
| 744 |
if not chunks:
|
| 745 |
+
return direct_llm_fallback(q)
|
| 746 |
dlog("CLEAN", "Post-clean applied")
|
| 747 |
answer = _answer_from_chunks(chunks, q)
|
| 748 |
+
return _ensure_min_answer(_post_clean(answer)) or direct_llm_fallback(q)
|
| 749 |
|
| 750 |
# ================== UI: NAME GATE + PER-ANSWER FEEDBACK ==================
|
| 751 |
def _now_iso():
|