Spaces:
Sleeping
Sleeping
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +1 -1
src/streamlit_app.py
CHANGED
|
@@ -171,7 +171,7 @@ category_mapping = {
|
|
| 171 |
def load_ner_model():
|
| 172 |
"""Loads the GLiNER model and caches it."""
|
| 173 |
try:
|
| 174 |
-
return GLiNER.from_pretrained("
|
| 175 |
except Exception as e:
|
| 176 |
st.error(f"Failed to load NER model. Please check your internet connection or model availability: {e}")
|
| 177 |
st.stop()
|
|
|
|
| 171 |
def load_ner_model():
|
| 172 |
"""Loads the GLiNER model and caches it."""
|
| 173 |
try:
|
| 174 |
+
return GLiNER.from_pretrained("urchade/gliner_multi", nested_ner=True, num_gen_sequences=2, gen_constraints= labels)
|
| 175 |
except Exception as e:
|
| 176 |
st.error(f"Failed to load NER model. Please check your internet connection or model availability: {e}")
|
| 177 |
st.stop()
|