Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -31,7 +31,8 @@ def run_chatnt(dna_text, fasta_file, custom_question):
31
  if dna_text and dna_text.strip():
32
  dna_sequence = dna_text.strip().replace("\n", "")
33
  elif fasta_file is not None:
34
- file_content = fasta_file.read().decode("utf-8")
 
35
  lines = file_content.splitlines()
36
  sequence = ""
37
  for line in lines:
@@ -131,7 +132,7 @@ with gr.Blocks(css=css) as demo:
131
  **Note:**
132
  ✅ You must use **exactly one DNA sequence** (either paste it or upload a file).
133
  ✅ Your question must include the `<DNA>` token **exactly once** at the position where the DNA will be inserted.
134
- Example: *"Does this sequence <DNA> contain a donor splice site?"*
135
  """)
136
 
137
  with gr.Accordion("Logs", open=True):
 
31
  if dna_text and dna_text.strip():
32
  dna_sequence = dna_text.strip().replace("\n", "")
33
  elif fasta_file is not None:
34
+ with open(fasta_file.name, "r") as f:
35
+ file_content = f.read()
36
  lines = file_content.splitlines()
37
  sequence = ""
38
  for line in lines:
 
132
  **Note:**
133
  ✅ You must use **exactly one DNA sequence** (either paste it or upload a file).
134
  ✅ Your question must include the `<DNA>` token **exactly once** at the position where the DNA will be inserted.
135
+ Example: *"Does this sequence `<DNA>` contain a donor splice site?"*
136
  """)
137
 
138
  with gr.Accordion("Logs", open=True):