Sasidhar commited on
Commit
d744208
·
1 Parent(s): 9a8ea25

Update text_annotatator.py

Browse files
Files changed (1) hide show
  1. text_annotatator.py +17 -16
text_annotatator.py CHANGED
@@ -1,22 +1,23 @@
1
  def get_display_only_data():
2
- data1 = {
3
- "tokens": [
4
- {"text": "He", "labels": ["Person"]},
5
- {"text": "loves"},
6
- {"text": "his"},
7
- {"text": "dog", "labels": ["Animal", "Pet"]},
8
- ],
9
- "labels": [
10
- {"text": "Person"},
11
- {"text": "Action"},
12
- {"text": "Animal"},
13
- ]
14
- }
15
- return data1
 
16
 
17
  def get_editable_data():
18
 
19
- data2 = {
20
  "allowEditing": True,
21
  "tokens": [
22
  {"text": "He", "labels": ["Pronoun", "Person"]},
@@ -46,4 +47,4 @@ def get_editable_data():
46
  {"text": "Animal"},
47
  ]
48
  }
49
- return data 2
 
1
  def get_display_only_data():
2
+ data1 = {
3
+ "tokens": [
4
+ {"text": "He", "labels": ["Person"]},
5
+ {"text": "loves"},
6
+ {"text": "his"},
7
+ {"text": "dog", "labels": ["Animal", "Pet"]},
8
+ ],
9
+ "labels": [
10
+ {"text": "Person"},
11
+ {"text": "Action"},
12
+ {"text": "Animal"},
13
+ ]
14
+ }
15
+
16
+ return data1
17
 
18
  def get_editable_data():
19
 
20
+ data2 = {
21
  "allowEditing": True,
22
  "tokens": [
23
  {"text": "He", "labels": ["Pronoun", "Person"]},
 
47
  {"text": "Animal"},
48
  ]
49
  }
50
+ return data 2