julien-c HF staff commited on
Commit
5605919
1 Parent(s): 35237ea

`languages:` => `language:`

Browse files
Files changed (2) hide show
  1. apputils.py +1 -1
  2. tagging_app.py +2 -2
apputils.py CHANGED
@@ -6,7 +6,7 @@ def new_state() -> Dict[str, List]:
6
  "task_categories": [],
7
  "task_ids": [],
8
  "multilinguality": [],
9
- "languages": [],
10
  "language_creators": [],
11
  "annotations_creators": [],
12
  "source_datasets": [],
 
6
  "task_categories": [],
7
  "task_ids": [],
8
  "multilinguality": [],
9
+ "language": [],
10
  "language_creators": [],
11
  "annotations_creators": [],
12
  "source_datasets": [],
tagging_app.py CHANGED
@@ -258,7 +258,7 @@ if "other" in state["multilinguality"]:
258
  state["multilinguality"][state["multilinguality"].index("other")] = f"other-{other_multilinguality}"
259
 
260
  valid_values, invalid_values = list(), list()
261
- for langtag in state["languages"]:
262
  try:
263
  lc.get(langtag)
264
  valid_values.append(langtag)
@@ -273,7 +273,7 @@ langtags = leftcol.text_area(
273
  "What languages are represented in the dataset? expected format is BCP47 tags separated for ';' e.g. 'en;fr'",
274
  value=";".join(valid_values),
275
  )
276
- state["languages"] = langtags.strip().split(";") if langtags.strip() != "" else []
277
 
278
 
279
  #
 
258
  state["multilinguality"][state["multilinguality"].index("other")] = f"other-{other_multilinguality}"
259
 
260
  valid_values, invalid_values = list(), list()
261
+ for langtag in state["language"]:
262
  try:
263
  lc.get(langtag)
264
  valid_values.append(langtag)
 
273
  "What languages are represented in the dataset? expected format is BCP47 tags separated for ';' e.g. 'en;fr'",
274
  value=";".join(valid_values),
275
  )
276
+ state["language"] = langtags.strip().split(";") if langtags.strip() != "" else []
277
 
278
 
279
  #