Spaces:
Sleeping
Sleeping
add st.chace_resource
Browse files
app.py
CHANGED
@@ -9,7 +9,7 @@ import requests
|
|
9 |
from bs4 import BeautifulSoup
|
10 |
|
11 |
class NewsAnalytic():
|
12 |
-
@st.
|
13 |
def __init__(self):
|
14 |
self.model = T5ForZeroShotClassification.from_pretrained('knowledgator/comprehend_it-multilingual-t5-base')
|
15 |
self.tokenizer = T5Tokenizer.from_pretrained('knowledgator/comprehend_it-multilingual-t5-base')
|
|
|
9 |
from bs4 import BeautifulSoup
|
10 |
|
11 |
class NewsAnalytic():
|
12 |
+
@st.cache_resource
|
13 |
def __init__(self):
|
14 |
self.model = T5ForZeroShotClassification.from_pretrained('knowledgator/comprehend_it-multilingual-t5-base')
|
15 |
self.tokenizer = T5Tokenizer.from_pretrained('knowledgator/comprehend_it-multilingual-t5-base')
|