HumanSignal / HumanSignal/label-studio
labels field of the annotations got dropped or mangled
- Dominant language
- TypeScript
- Stars
- 28.3k
- Forks
- 3.7k
- Avg merge
- 14h
- Merged PRs (30d)
- 15
Description
**Describe the bug**
Somehow the labels field of the annotations got dropped. I noticed the problem when running the attached JSON file export ([_bad-annotation.json.txt](https://github.com/heartexlabs/label-studio/files/7333787/_bad-annotation.json.txt)) through the CONLL2003 converter.
Here's the problematic section from the JSON file:
```
{
"value" : {
"end" : 2180,
"text" : " ^identified i ",
"start" : 2145
},
"from_name" : "label",
"type" : "labels",
"id" : "ZNgZKDPsmk",
"to_name" : "text"
}
```
By the way, a related problem was that an invalid label got used in the annotations (e.g., b instead of block):
```
{
"value" : {
"start" : 2145,
"end" : 2180,
"text" : " ^identified i\n ",
"labels" : [
"b"
]
},
"type" : "labels",
"from_name" : "label",
"to_name" : "text"
}
```
**To Reproduce**
I'm not sure how to reproduce the problem: I just noticed the problem downstream when doing the conversion. See https://github.com/heartexlabs/label-studio-converter/issues/61#issue-1024620914.
**Environment (please complete the following information):**
- OS: Ubuntu 18.04
- Label Studio Version 1.2
**Additional context**
I created two separate tickets because there are two issues:
1. Task DB getting corrupted
2. Converted not handling annotation spans with missing fields.
Contributor guide
Assessment
This issue has not been assessed yet.