CoolFace
Apppublic

hmb/rtl-test

sourceHugging Faceupdated 3y agoView on Hugging Face
0likes
app.py33 linesDownload Raw Back to root
1import random2 3import gradio as gr4 5CSS = """6@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@500&display=swap');7 8"""9 10def random_response(message, history):11    return random.choice(["الثالث بلديهما مواقعها", "بلا مع. وقد الخاسر"])12 13 14demo = gr.ChatInterface(15    random_response,16    title="ArabicGPT",17    chatbot=gr.Chatbot(18        rtl=True,19    ),20    textbox=gr.Textbox(21        lines=1, placeholder="اكتب رسالتك هنا...", rtl=True, scale=7, autofocus=True22    ),23    theme=gr.themes.Soft(),24    css=CSS,25    submit_btn="ارسل",26    stop_btn="توقف",27    retry_btn="أعد المحاولة 🔄",28    clear_btn="أمسح النقاش 🗑️",29    undo_btn=None,30)31 32demo.queue().launch()33