Update app.py
Browse files
app.py
CHANGED
@@ -11,7 +11,7 @@ from spacy import displacy
|
|
11 |
HTML_WRAPPER = """<div style="overflow-x: auto; border: 1px solid #e6e9ef; border-radius: 0.25rem; padding: 1rem; margin-bottom: 2.5rem">{}</div>"""
|
12 |
|
13 |
|
14 |
-
@st.
|
15 |
def load_models():
|
16 |
"""Load and cache NER4OPT models."""
|
17 |
lexical_ner_model = ner4opt.Ner4Opt("lexical")
|
|
|
11 |
HTML_WRAPPER = """<div style="overflow-x: auto; border: 1px solid #e6e9ef; border-radius: 0.25rem; padding: 1rem; margin-bottom: 2.5rem">{}</div>"""
|
12 |
|
13 |
|
14 |
+
@st.cache_resource
|
15 |
def load_models():
|
16 |
"""Load and cache NER4OPT models."""
|
17 |
lexical_ner_model = ner4opt.Ner4Opt("lexical")
|