Spaces:
Sleeping
Sleeping
import streamlit as st | |
from transformers import pipeline | |
prompt = st.text_area("Enter text to translate to Spanish:") | |
if prompt: | |
translator = pipeline("translation", model="Helsinki-NLP/opus-mt-en-es") | |
out = translator(prompt) | |
st.json(out) |