File size: 5,265 Bytes
afeb989
 
4445a4a
afeb989
 
4445a4a
afeb989
4445a4a
 
afeb989
4445a4a
5f7a97f
afeb989
4445a4a
 
 
 
89ce44b
 
 
 
 
 
 
 
 
afeb989
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5f7a97f
afeb989
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5f7a97f
afeb989
 
 
5f7a97f
 
 
 
 
 
 
 
 
afeb989
 
 
 
 
 
 
 
5f7a97f
afeb989
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5f7a97f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
---
language:
- en
pretty_name: CoNLL-2003
task_categories:
- token-classification
task_ids:
- named-entity-recognition
- part-of-speech
size_categories:
- 10K<n<100K
license: mit
tags:
- ner
- pos
- chunking
- conll
configs:
  - config_name: default
    data_files:
      - split: train
        path: data/train-*
      - split: validation
        path: data/validation-*
      - split: test
        path: data/test-*
---

# Dataset Card for CoNLL-2003

## Dataset Summary

CoNLL-2003 is the English dataset from the CoNLL-2003 shared task on language-independent named entity recognition. It contains newswire sentences from the Reuters corpus, annotated with part-of-speech tags, syntactic chunk tags, and named entity tags. This repository stores the data in Parquet format.

## Supported Tasks

- **Named entity recognition (NER):** predict `ner_tags` for each token.
- **Part-of-speech tagging:** predict `pos_tags`.
- **Chunking:** predict `chunk_tags`.

## Languages

English (`en`).

## Dataset Structure

### Data Splits

| Split      | Examples |
|------------|----------|
| train      | 14,041   |
| validation | 3,250    |
| test       | 3,453    |
| **total**  | 20,744   |

### Data Fields

- `id` (string): example identifier.
- `tokens` (list of string): the words of the sentence.
- `pos_tags` (list of int): part-of-speech tag per token.
- `chunk_tags` (list of int): syntactic chunk tag per token.
- `ner_tags` (list of `ClassLabel`): named entity tag per token. Values are stored as integers, and the label names are available through the dataset features (see Usage).

All three tag lists have the same length as `tokens`.

### Example

```json
{
  "id": "0",
  "tokens": ["EU", "rejects", "German", "call", "to", "boycott", "British", "lamb", "."],
  "pos_tags": [22, 42, 16, 21, 35, 37, 16, 21, 7],
  "chunk_tags": [11, 21, 11, 12, 21, 22, 11, 12, 0],
  "ner_tags": [3, 0, 7, 0, 0, 0, 7, 0, 0]
}
```

### Label Mappings

**`ner_tags`** (BIO scheme; entity types are person, organization, location, miscellaneous)

| id | tag    | id | tag    |
|----|--------|----|--------|
| 0  | O      | 5  | B-LOC  |
| 1  | B-PER  | 6  | I-LOC  |
| 2  | I-PER  | 7  | B-MISC |
| 3  | B-ORG  | 8  | I-MISC |
| 4  | I-ORG  |    |        |

**`chunk_tags`**

0: O, 1: B-ADJP, 2: I-ADJP, 3: B-ADVP, 4: I-ADVP, 5: B-CONJP, 6: I-CONJP, 7: B-INTJ, 8: I-INTJ, 9: B-LST, 10: I-LST, 11: B-NP, 12: I-NP, 13: B-PP, 14: I-PP, 15: B-PRT, 16: I-PRT, 17: B-SBAR, 18: I-SBAR, 19: B-UCP, 20: I-UCP, 21: B-VP, 22: I-VP

**`pos_tags`** (Penn Treebank tags)

0: `"`, 1: `''`, 2: `#`, 3: `$`, 4: `(`, 5: `)`, 6: `,`, 7: `.`, 8: `:`, 9: ` `` `, 10: CC, 11: CD, 12: DT, 13: EX, 14: FW, 15: IN, 16: JJ, 17: JJR, 18: JJS, 19: LS, 20: MD, 21: NN, 22: NNP, 23: NNPS, 24: NNS, 25: NN|SYM, 26: PDT, 27: POS, 28: PRP, 29: PRP$, 30: RB, 31: RBR, 32: RBS, 33: RP, 34: SYM, 35: TO, 36: UH, 37: VB, 38: VBD, 39: VBG, 40: VBN, 41: VBP, 42: VBZ, 43: WDT, 44: WP, 45: WP$, 46: WRB

## Usage

```python
from datasets import load_dataset

ds = load_dataset("moh-pezeshki/conll2003")
print(ds["train"][0])
```

To convert the NER integers to label names:

```python
names = ds["train"].features["ner_tags"].feature.names
row = ds["train"][0]
print([names[i] for i in row["ner_tags"]])
# ['B-ORG', 'O', 'B-MISC', 'O', 'O', 'O', 'B-MISC', 'O', 'O']
```

## Dataset Creation

### Source Data

The text comes from the Reuters Corpus Volume 1 (RCV1), news stories from August 1996 to August 1997. Annotations were produced for the CoNLL-2003 shared task (Tjong Kim Sang and De Meulder, 2003).

### Provenance of This Copy

This is a Parquet copy of [`lhoestq/conll2003`](https://huggingface.co/datasets/lhoestq/conll2003), maintained by [moh-pezeshki](https://huggingface.co/moh-pezeshki). The only change is that the `ner_tags` column was cast to `ClassLabel`, so label names appear in the viewer and are available via `ds.features["ner_tags"].feature.names`. The stored values are still integers and are identical to the source. The split sizes match the source (14,041 / 3,250 / 3,453).

## Considerations

- The data is newswire from 1996-1997, so entity types, topics, and writing style may not transfer well to modern or non-news text.
- Some sentences are headlines, datelines (e.g. "LONDON 1996-08-22"), or table-like fragments rather than ordinary prose.
- The text is derived from Reuters RCV1, which has its own usage terms. Check those terms before redistributing or using the data commercially.

## Licensing Information

The `license: other` field in the metadata is a placeholder. The underlying text comes from Reuters RCV1, so users should review the RCV1 and CoNLL-2003 terms before use.

## Citation

```bibtex
@inproceedings{tjong-kim-sang-de-meulder-2003-introduction,
    title = "Introduction to the {C}o{NLL}-2003 Shared Task: Language-Independent Named Entity Recognition",
    author = "Tjong Kim Sang, Erik F. and De Meulder, Fien",
    booktitle = "Proceedings of the Seventh Conference on Natural Language Learning at {HLT}-{NAACL} 2003",
    year = "2003",
    pages = "142--147",
    url = "https://www.aclweb.org/anthology/W03-0419"
}
```

## Contact

Maintained by [moh-pezeshki](https://huggingface.co/moh-pezeshki). For issues with this copy, use the Community tab.