VyLala commited on
Commit
c7298d0
Β·
verified Β·
1 Parent(s): f7fbadb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +14 -13
app.py CHANGED
@@ -63,15 +63,16 @@ with gr.Blocks() as interface:
63
  with gr.Tab("🧬 Classifier"):
64
  gr.Markdown("# 🧬 mtDNA Location Classifier (MVP)")
65
  #inputMode = gr.Radio(choices=["Single Accession", "Batch Input"], value="Single Accession", label="Choose Input Mode")
66
- #user_email = gr.Textbox(label="πŸ“§ Your email (used to track free quota)")
 
67
 
68
- sign_in_button = gr.Button("Sign in to Download")
69
- user_email = gr.Textbox(
70
- label="πŸ“§ Your email (used to track free quota)",
71
- visible=False
72
- )
73
- # The output will be used to display a message to the user
74
- output_message = gr.Textbox(visible=False, interactive=False)
75
  usage_display = gr.Markdown("", visible=False)
76
 
77
  # with gr.Group() as single_input_group:
@@ -85,8 +86,8 @@ with gr.Blocks() as interface:
85
  # file_upload = gr.File(label="πŸ“ Or Upload CSV/Excel File", file_types=[".csv", ".xlsx"], interactive=True, elem_id="file-upload-box")
86
  raw_text = gr.Textbox(label="🧚 Input Accession Number(s) (single (KU131308) or comma-separated (e.g., MF362736.1,MF362738.1,KU131308,MW291678))")
87
  #resume_file = gr.File(label="πŸ—ƒοΈ Previously saved Excel output (optional)", file_types=[".xlsx"], interactive=True)
88
- gr.HTML("""<a href="https://docs.google.com/spreadsheets/d/1lKqPp17EfHsshJGZRWEpcNOZlGo3F5qU/edit?usp=sharing" download target="_blank">Example Excel Batch Input Format</a>""")
89
- file_upload = gr.File(label="πŸ“ Or Upload CSV/Excel File", file_types=[".csv", ".xlsx"], interactive=True)
90
  processed_info = gr.Markdown(visible=False) # new placeholder for processed list
91
 
92
  with gr.Row():
@@ -112,20 +113,20 @@ with gr.Blocks() as interface:
112
 
113
  # gr.Markdown("---")
114
 
115
- with gr.Accordion("Open to See the Output Table", open=False) as table_accordion:
116
  output_table = gr.HTML(render=True)
117
  #with gr.Row():
118
  #output_type = gr.Dropdown(choices=["Excel", "JSON", "TXT"], label="Select Output Format", value="Excel")
119
  #download_button = gr.Button("⬇️ Download Output")
120
  #download_file = gr.File(label="Download File Here",visible=False)
121
 
122
- report_button = gr.Button("Report the bad output to get back one more free sample query")
123
  report_textbox = gr.Textbox(
124
  label="Describe the issue",
125
  lines=4,
126
  placeholder="e.g. DQ981467: it gives me unknown when I can in fact search it on NCBI \n DQ981467: cannot find the result in batch output when the live processing did show already processed",
127
  visible=False)
128
- submit_report_button = gr.Button("Submit", visible=False)
129
  status_report = gr.Markdown(visible=False)
130
 
131
  with gr.Group(visible=True, elem_id="nps-overlay") as nps_modal:
 
63
  with gr.Tab("🧬 Classifier"):
64
  gr.Markdown("# 🧬 mtDNA Location Classifier (MVP)")
65
  #inputMode = gr.Radio(choices=["Single Accession", "Batch Input"], value="Single Accession", label="Choose Input Mode")
66
+ user_email = gr.Textbox(label="πŸ“§ Your email (used to track free quota). ",
67
+ placeholder="Enter your email and click Submit and Classify button below to run accessions.\nYou'll get +20 extra free queries and Excel-formatted results.")
68
 
69
+ # sign_in_button = gr.Button("Sign in to Download")
70
+ # user_email = gr.Textbox(
71
+ # label="πŸ“§ Your email (used to track free quota)",
72
+ # visible=False
73
+ # )
74
+ # # The output will be used to display a message to the user
75
+ # output_message = gr.Textbox(visible=False, interactive=False)
76
  usage_display = gr.Markdown("", visible=False)
77
 
78
  # with gr.Group() as single_input_group:
 
86
  # file_upload = gr.File(label="πŸ“ Or Upload CSV/Excel File", file_types=[".csv", ".xlsx"], interactive=True, elem_id="file-upload-box")
87
  raw_text = gr.Textbox(label="🧚 Input Accession Number(s) (single (KU131308) or comma-separated (e.g., MF362736.1,MF362738.1,KU131308,MW291678))")
88
  #resume_file = gr.File(label="πŸ—ƒοΈ Previously saved Excel output (optional)", file_types=[".xlsx"], interactive=True)
89
+ gr.HTML("""<a href="https://docs.google.com/spreadsheets/d/1lKqPp17EfHsshJGZRWEpcNOZlGo3F5qU/edit?usp=sharing" download target="_blank">Example Excel Input Template</a>""")
90
+ file_upload = gr.File(label="πŸ“ Or Upload Excel File", file_types=[".xlsx"], interactive=True)
91
  processed_info = gr.Markdown(visible=False) # new placeholder for processed list
92
 
93
  with gr.Row():
 
113
 
114
  # gr.Markdown("---")
115
 
116
+ with gr.Accordion("Open to See the Output Table", open=True) as table_accordion:
117
  output_table = gr.HTML(render=True)
118
  #with gr.Row():
119
  #output_type = gr.Dropdown(choices=["Excel", "JSON", "TXT"], label="Select Output Format", value="Excel")
120
  #download_button = gr.Button("⬇️ Download Output")
121
  #download_file = gr.File(label="Download File Here",visible=False)
122
 
123
+ report_button = gr.Button("Report inaccurate output to receive 1 extra free query",elem_id="run-btn")
124
  report_textbox = gr.Textbox(
125
  label="Describe the issue",
126
  lines=4,
127
  placeholder="e.g. DQ981467: it gives me unknown when I can in fact search it on NCBI \n DQ981467: cannot find the result in batch output when the live processing did show already processed",
128
  visible=False)
129
+ submit_report_button = gr.Button("Submit", visible=False, elem_id="run-btn")
130
  status_report = gr.Markdown(visible=False)
131
 
132
  with gr.Group(visible=True, elem_id="nps-overlay") as nps_modal: