Sasidhar commited on
Commit
ea2d98b
·
1 Parent(s): 8ae2f60

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -49,7 +49,7 @@ pipeline_ner =init_ner_pipeline()
49
  st.header("Intelligent Document Automation")
50
 
51
  def get_text_from_ocr_engine():
52
- return "This is a sample text for named entity recognition and other tasks"
53
 
54
  with st.sidebar:
55
  selected_menu = option_menu("Select Option",
@@ -67,6 +67,9 @@ elif selected_menu == "Extract Text":
67
  elif selected_menu == "Summarize Document":
68
  st.write(get_text_from_ocr_engine())
69
  elif selected_menu == "Extract Entities":
70
- st.write(get_text_from_ocr_engine())
 
 
 
71
  elif selected_menu == "Get Answers":
72
  st.write(get_text_from_ocr_engine())
 
49
  st.header("Intelligent Document Automation")
50
 
51
  def get_text_from_ocr_engine():
52
+ return "CASE: A 28-year-old previously healthy man presented with a 6-week history of palpitations. The symptoms occurred during rest, 2–3 times per week, lasted up to 30 minutes at a time and were associated with dyspnea. Except for a grade 2/6 holosystolic tricuspid regurgitation murmur (best heard at the left sternal border with inspiratory accentuation), physical examination yielded unremarkable findings."
53
 
54
  with st.sidebar:
55
  selected_menu = option_menu("Select Option",
 
67
  elif selected_menu == "Summarize Document":
68
  st.write(get_text_from_ocr_engine())
69
  elif selected_menu == "Extract Entities":
70
+ text = get_text_from_ocr_engine()
71
+ output = pipeline_ner (text)
72
+
73
+
74
  elif selected_menu == "Get Answers":
75
  st.write(get_text_from_ocr_engine())