Spaces:
Sleeping
Sleeping
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +6 -11
src/streamlit_app.py
CHANGED
@@ -120,6 +120,7 @@ if not comet_initialized:
|
|
120 |
# --- Label Definitions ---
|
121 |
|
122 |
|
|
|
123 |
labels = [
|
124 |
'person',
|
125 |
'organization',
|
@@ -141,19 +142,13 @@ labels = [
|
|
141 |
'temporal expression',
|
142 |
]
|
143 |
|
144 |
-
|
145 |
-
|
146 |
# Create a mapping dictionary for labels to categories
|
147 |
category_mapping = {
|
148 |
-
|
149 |
-
"
|
150 |
-
"
|
151 |
-
"
|
152 |
-
"
|
153 |
-
"Quantitative & Contextual": ["Number", "Cause of death"]
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
}
|
158 |
|
159 |
# --- Model Loading ---
|
|
|
120 |
# --- Label Definitions ---
|
121 |
|
122 |
|
123 |
+
# --- Label Definitions ---
|
124 |
labels = [
|
125 |
'person',
|
126 |
'organization',
|
|
|
142 |
'temporal expression',
|
143 |
]
|
144 |
|
|
|
|
|
145 |
# Create a mapping dictionary for labels to categories
|
146 |
category_mapping = {
|
147 |
+
"People & Groups": ["person", "organization", "title"],
|
148 |
+
"Topics & Objects": ["event", "product", "law", "policy", "work of art", "weapon", "vehicle"],
|
149 |
+
"Temporal": ["date", "time", "temporal expression"],
|
150 |
+
"Locations": ["location", "geopolitical entity", "facility"],
|
151 |
+
"Quantitative & Contextual": ["number", "cause of death"]
|
|
|
|
|
|
|
|
|
152 |
}
|
153 |
|
154 |
# --- Model Loading ---
|