Spaces:
Runtime error
Runtime error
File size: 346 Bytes
55bcb27 578d533 28f75ea |
1 2 3 4 5 6 7 8 9 10 11 12 |
import streamlit as st
from transformers import pipeline
pipeline = pipeline(task="translation", model="guymorlan/Shami2English")
st.title("Translate Levantine Arabic to English")
text = st.text_input("Enter text to translate:")
if text:
result = pipeline(text, max_length=1024)
st.write("Translation:", result[0]['translation_text']) |