Spaces:
Running
Running
kargaranamir
commited on
Commit
•
f4b2839
1
Parent(s):
0b63d31
update emoji.
Browse files
README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
---
|
2 |
-
title: GlotLID
|
3 |
-
emoji:
|
4 |
colorFrom: yellow
|
5 |
colorTo: red
|
6 |
sdk: streamlit
|
@@ -10,4 +10,3 @@ pinned: true
|
|
10 |
tags: [multilingual]
|
11 |
---
|
12 |
|
13 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
1 |
---
|
2 |
+
title: GlotLID (Language Identification)
|
3 |
+
emoji: 🕵️
|
4 |
colorFrom: yellow
|
5 |
colorTo: red
|
6 |
sdk: streamlit
|
|
|
10 |
tags: [multilingual]
|
11 |
---
|
12 |
|
|
app.py
CHANGED
@@ -208,7 +208,7 @@ def compute(sentences, version = 'v3'):
|
|
208 |
if output_label_script not in all_scripts:
|
209 |
output_label_script = main_script
|
210 |
output_label = f"und_{output_label_script}"
|
211 |
-
output_prob = 0
|
212 |
|
213 |
|
214 |
labels = labels + [output_label]
|
@@ -227,18 +227,13 @@ render_svg(open("assets/glotlid_logo.svg").read())
|
|
227 |
|
228 |
render_metadata()
|
229 |
|
230 |
-
st.markdown("**GlotLID** is an open-source language identification model with support for more than **2000
|
231 |
|
232 |
|
233 |
tab1, tab2 = st.tabs(["Input a Sentence", "Upload a File"])
|
234 |
|
235 |
with tab1:
|
236 |
|
237 |
-
# choice = st.radio(
|
238 |
-
# "Set granularity level",
|
239 |
-
# ["default", "merge", "individual"],
|
240 |
-
# captions=["enable both macrolanguage and its varieties (default)", "merge macrolanguage and its varieties into one label", "remove macrolanguages - only shows individual langauges"],
|
241 |
-
# )
|
242 |
|
243 |
version = st.radio(
|
244 |
"Choose model",
|
|
|
208 |
if output_label_script not in all_scripts:
|
209 |
output_label_script = main_script
|
210 |
output_label = f"und_{output_label_script}"
|
211 |
+
output_prob = 1.0
|
212 |
|
213 |
|
214 |
labels = labels + [output_label]
|
|
|
227 |
|
228 |
render_metadata()
|
229 |
|
230 |
+
st.markdown("**GlotLID** is an open-source language identification model with support for more than **2000 labels (V3)**.")
|
231 |
|
232 |
|
233 |
tab1, tab2 = st.tabs(["Input a Sentence", "Upload a File"])
|
234 |
|
235 |
with tab1:
|
236 |
|
|
|
|
|
|
|
|
|
|
|
237 |
|
238 |
version = st.radio(
|
239 |
"Choose model",
|