TEZv commited on
Commit
fbb0103
·
verified ·
1 Parent(s): 57b7d63

Update chatbot.py

Browse files
Files changed (1) hide show
  1. chatbot.py +4 -15
chatbot.py CHANGED
@@ -581,13 +581,8 @@ def rag_query(question: str, top_k: int = 3) -> str:
581
  def build_chatbot_tab():
582
  """Called from app.py to inject the chatbot into Tab A6."""
583
 
584
- # Pre-build index in background
585
- status_msg = "Initializing RAG index..."
586
- ok, build_msg = _build_index()
587
- status_msg = build_msg if ok else f"⚠️ {build_msg}"
588
-
589
  gr.Markdown(
590
- f"**Status:** {status_msg}\n\n"
591
  "Ask questions about LNP delivery, protein corona, cancer variants, or liquid biopsy. "
592
  "Answers are grounded in 20 indexed papers — never fabricated."
593
  )
@@ -621,19 +616,14 @@ def build_chatbot_tab():
621
  "**Protein Corona**\n"
622
  "- Hard vs soft corona\n"
623
  "- Vroman effect kinetics\n"
624
- "- ApoE/LDLR targeting\n"
625
- "- Corona engineering\n\n"
626
  "**Cancer Variants**\n"
627
  "- TP53 mutation spectrum\n"
628
  "- KRAS G12C resistance\n"
629
- "- ClinVar classification\n"
630
- "- gnomAD population AF\n\n"
631
  "**Liquid Biopsy**\n"
632
  "- ctDNA methylation\n"
633
- "- cfRNA biomarkers\n\n"
634
- "**Cancer Vaccines**\n"
635
- "- mRNA neoantigen vaccines\n"
636
- "- siRNA tumor delivery"
637
  )
638
  gr.Markdown(
639
  "### 🔑 Confidence Flags\n"
@@ -655,7 +645,6 @@ def build_chatbot_tab():
655
  user_input.submit(respond, inputs=[user_input, chatbox], outputs=[chatbox, user_input])
656
  clear_btn.click(lambda: ([], ""), outputs=[chatbox, user_input])
657
 
658
-
659
  # ─────────────────────────────────────────────
660
  # STANDALONE MODE
661
  # ─────────────────────────────────────────────
 
581
  def build_chatbot_tab():
582
  """Called from app.py to inject the chatbot into Tab A6."""
583
 
 
 
 
 
 
584
  gr.Markdown(
585
+ "**Status:** Model loads on first query (~30s)...\n\n"
586
  "Ask questions about LNP delivery, protein corona, cancer variants, or liquid biopsy. "
587
  "Answers are grounded in 20 indexed papers — never fabricated."
588
  )
 
616
  "**Protein Corona**\n"
617
  "- Hard vs soft corona\n"
618
  "- Vroman effect kinetics\n"
619
+ "- ApoE/LDLR targeting\n\n"
 
620
  "**Cancer Variants**\n"
621
  "- TP53 mutation spectrum\n"
622
  "- KRAS G12C resistance\n"
623
+ "- ClinVar classification\n\n"
 
624
  "**Liquid Biopsy**\n"
625
  "- ctDNA methylation\n"
626
+ "- cfRNA biomarkers"
 
 
 
627
  )
628
  gr.Markdown(
629
  "### 🔑 Confidence Flags\n"
 
645
  user_input.submit(respond, inputs=[user_input, chatbox], outputs=[chatbox, user_input])
646
  clear_btn.click(lambda: ([], ""), outputs=[chatbox, user_input])
647
 
 
648
  # ─────────────────────────────────────────────
649
  # STANDALONE MODE
650
  # ─────────────────────────────────────────────