TiberiuCristianLeon commited on
Commit
fc95630
·
verified ·
1 Parent(s): 1ca7970

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -1,8 +1,6 @@
1
  import streamlit as st
2
  from transformers import T5Tokenizer, T5ForConditionalGeneration
3
 
4
-
5
- # model = T5ForTranslation.from_pretrained("Helsinki-NLP/opus-mt-en-ro")
6
  # tokenizer = T5Tokenizer.from_pretrained("Helsinki-NLP/opus-mt-en-ro")
7
 
8
  # Create the app layout
@@ -10,7 +8,7 @@ st.title("Text Translation")
10
  input_text = st.text_input("Enter text to translate:")
11
  # Create a list of options for the select box
12
  options = ["English", "Romanian", "German", "French", "Spanish"]
13
- models = ["t5-base", "t5-small"]
14
  # Create the select box
15
  slanguage_selector = st.selectbox("Select a source language:", options)
16
  tlanguage_selector = st.selectbox("Select a target language:", options)
 
1
  import streamlit as st
2
  from transformers import T5Tokenizer, T5ForConditionalGeneration
3
 
 
 
4
  # tokenizer = T5Tokenizer.from_pretrained("Helsinki-NLP/opus-mt-en-ro")
5
 
6
  # Create the app layout
 
8
  input_text = st.text_input("Enter text to translate:")
9
  # Create a list of options for the select box
10
  options = ["English", "Romanian", "German", "French", "Spanish"]
11
+ models = ["t5-base", "t5-small", "opus-mt-en-ro"]
12
  # Create the select box
13
  slanguage_selector = st.selectbox("Select a source language:", options)
14
  tlanguage_selector = st.selectbox("Select a target language:", options)