Spaces:
Runtime error
Runtime error
Add PSFT Model
Browse files
app.py
CHANGED
@@ -1,6 +1,10 @@
|
|
1 |
import streamlit as st
|
2 |
-
from transformers import (T5ForConditionalGeneration, AutoTokenizer, pipeline)
|
3 |
-
import
|
|
|
|
|
|
|
|
|
4 |
|
5 |
model_path = 'erfan226/persian-t5-formality-transfer'
|
6 |
model = T5ForConditionalGeneration.from_pretrained(model_path)
|
|
|
1 |
import streamlit as st
|
2 |
+
# from transformers import (T5ForConditionalGeneration, AutoTokenizer, pipeline)
|
3 |
+
from transformers import pipeline
|
4 |
+
|
5 |
+
# import torch
|
6 |
+
|
7 |
+
st.set_page_config(layout="wide", page_title="تبدیل متون محاورهای به فارسی")
|
8 |
|
9 |
model_path = 'erfan226/persian-t5-formality-transfer'
|
10 |
model = T5ForConditionalGeneration.from_pretrained(model_path)
|