eurlex / README.md
darrinka's picture
Upload dataset
ec5c834 verified
|
raw
history blame
1.48 kB
---
dataset_info:
features:
- name: utterance
dtype: string
- name: label
sequence: int64
splits:
- name: train
num_bytes: 396298199
num_examples: 55000
download_size: 165889261
dataset_size: 396298199
configs:
- config_name: default
data_files:
- split: train
path: data/train-*
task_categories:
- text-classification
language:
- en
---
# eurlex
This is a text classification dataset. It is intended for machine learning research and experimentation.
This dataset is obtained via formatting another publicly available data to be compatible with our [AutoIntent Library](https://deeppavlov.github.io/AutoIntent/index.html).
## Usage
It is intended to be used with our [AutoIntent Library](https://deeppavlov.github.io/AutoIntent/index.html):
```python
from autointent import Dataset
eurlex = Dataset.from_datasets("AutoIntent/eurlex")
```
## Source
This dataset is taken from `coastalcph/multi_eurlex` and formatted with our [AutoIntent Library](https://deeppavlov.github.io/AutoIntent/index.html):
```python
from datasets import load_dataset
from autointent import Dataset
eurlex = load_dataset("coastalcph/multi_eurlex", "en", trust_remote_code=True)
def transform(example: dict):
return {"utterance": example["text"], "label": example["labels"]}
multilabel_eurlex = eurlex["train"].map(transform, remove_columns=eurlex["train"].features.keys())
eurlex_converted = Dataset.from_dict({"train": multilabel_eurlex.to_list()})
```