File size: 8,048 Bytes
fed2be6
 
 
 
 
bee9742
fed2be6
bee9742
fed2be6
bee9742
fed2be6
 
 
bee9742
fed2be6
bee9742
fed2be6
bee9742
fed2be6
 
 
bee9742
fed2be6
bee9742
fed2be6
bee9742
fed2be6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
---
configs:
  - config_name: law_level
    data_files:
      - split: train
        path: law_level/train.parquet
      - split: validation
        path: law_level/val.parquet
      - split: test
        path: law_level/test.parquet
  - config_name: article_level
    data_files:
      - split: train
        path: article_level/train.parquet
      - split: validation
        path: article_level/val.parquet
      - split: test
        path: article_level/test.parquet
  - config_name: paragraph_level
    data_files:
      - split: train
        path: paragraph_level/train.parquet
      - split: validation
        path: paragraph_level/val.parquet
      - split: test
        path: paragraph_level/test.parquet
task_categories:
- translation
language:
- de
- fr
- it
- rm
- en
tags:
- legal
pretty_name: Swiss Law Translations
size_categories:
- 10K<n<100K
---

# Dataset Card for Swiss Law Translations

This dataset card describes a collection of Swiss legal translations extracted from the Swiss federal law platform, [Fedlex](https://www.fedlex.admin.ch). It is a parallel dataset that offers translations at three different levels: the law level, the article level, and the paragraph level. The dataset includes five languages: German (de), French (fr), Italian (it), Rumantsch (rm), and English (en).

## Dataset Details

### Dataset Description

This dataset consists of Swiss federal law and its translations into multiple languages. The data is available at three distinct levels:
- **law_level**: Entire legal text at the law level.
- **article_level**: Text at the individual article level.
- **paragraph_level**: Text at the paragraph level within each article.

The dataset supports multilingual tasks and can be used for machine translation, text alignment, or legal document processing and analysis.

- **Curated by:** Joel Niklaus
- **Funded by [optional]:** Swiss Federal Supreme Court
- **Source:** Swiss Federal Law (Fedlex)
- **Language(s) (NLP):** German (de), French (fr), Italian (it), Rumantsch (rm), English (en)
- **License:** [More Information Needed]

### Dataset Sources

- **Repository:** https://github.com/JoelNiklaus/SwissLegalTranslations
- **Paper [optional]:** [More Information Needed]
- **Demo [optional]:** [More Information Needed]

## Uses

### Direct Use

This dataset can be used for:
- Multilingual text alignment and translation tasks across five languages.
- Legal text analysis at different levels of granularity (law, article, paragraph).
- Language model training or fine-tuning in the legal domain.

### Out-of-Scope Use

The dataset may not be suitable for tasks outside the legal domain, or those that do not take the multilingual legal context into account.

## Dataset Structure

The dataset is divided into three levels:
1. **law_level**: Contains entire laws in all five languages.
    - Fields:
        - `abbreviation`: The abbreviation of the law.
        - `url`: URL linking to the legal text on Fedlex.
        - `dateApplicability`: Date of applicability of the law.
        - `rsNr`: Swiss federal register number.
        - `de_lawTitle`: Law title in German.
        - `fr_lawTitle`: Law title in French.
        - `it_lawTitle`: Law title in Italian.
        - `rm_lawTitle`: Law title in Rumantsch.
        - `en_lawTitle`: Law title in English.
        - `de_lawText`: Full legal text in German.
        - `fr_lawText`: Full legal text in French.
        - `it_lawText`: Full legal text in Italian.
        - `rm_lawText`: Full legal text in Rumantsch.
        - `en_lawText`: Full legal text in English.
        - `de_lawHtml`: Legal text in HTML format in German.
        - `fr_lawHtml`: Legal text in HTML format in French.
        - `it_lawHtml`: Legal text in HTML format in Italian.
        - `rm_lawHtml`: Legal text in HTML format in Rumantsch.
        - `en_lawHtml`: Legal text in HTML format in English.

2. **article_level**: Contains individual articles of laws.
    - Fields:
        - `abbreviation`: Law abbreviation.
        - `artNr`: Article number.
        - `lawTitle`: Law title in the relevant language.
        - `de_artTitle`: Article title in German.
        - `fr_artTitle`: Article title in French.
        - `it_artTitle`: Article title in Italian.
        - `rm_artTitle`: Article title in Rumantsch.
        - `en_artTitle`: Article title in English.
        - `de_artText`: Article text in German.
        - `fr_artText`: Article text in French.
        - `it_artText`: Article text in Italian.
        - `rm_artText`: Article text in Rumantsch.
        - `en_artText`: Article text in English.
        - `de_artHtml`: Article HTML in German.
        - `fr_artHtml`: Article HTML in French.
        - `it_artHtml`: Article HTML in Italian.
        - `rm_artHtml`: Article HTML in Rumantsch.
        - `en_artHtml`: Article HTML in English.

3. **paragraph_level**: Contains individual paragraphs within articles.
    - Fields:
        - `abbreviation`: Law abbreviation.
        - `artNr`: Article number.
        - `parNr`: Paragraph number.
        - `lawTitle`: Law title in the relevant language.
        - `de_parText`: Paragraph text in German.
        - `fr_parText`: Paragraph text in French.
        - `it_parText`: Paragraph text in Italian.
        - `rm_parText`: Paragraph text in Rumantsch.
        - `en_parText`: Paragraph text in English.
        - `de_parHtml`: Paragraph HTML in German.
        - `fr_parHtml`: Paragraph HTML in French.
        - `it_parHtml`: Paragraph HTML in Italian.
        - `rm_parHtml`: Paragraph HTML in Rumantsch.
        - `en_parHtml`: Paragraph HTML in English.

### Example Code

```python
from datasets import load_dataset

# Load the datasets for each level
law_dataset = load_dataset('fedlex/SwissLawTranslations', name='law_level', trust_remote_code=True)
article_dataset = load_dataset('fedlex/SwissLawTranslations', name='article_level', trust_remote_code=True)
paragraph_dataset = load_dataset('fedlex/SwissLawTranslations', name='paragraph_level', trust_remote_code=True)

# Print datasets for inspection
print(law_dataset, article_dataset, paragraph_dataset)
```
## Dataset Creation

### Curation Rationale

The dataset was created to support multilingual legal research and legal text processing. The structured nature of the dataset enables use cases ranging from full law analysis to paragraph-level translation tasks.

### Source Data

The dataset is derived from public Swiss federal legal texts on the Fedlex platform, which provides multilingual legal content.

#### Data Collection and Processing

The legal texts were extracted, normalized, and structured into law, article, and paragraph levels. The dataset includes HTML versions for advanced formatting analysis.

#### Who are the source data producers?

The source data is produced and maintained by the Swiss federal government, published on [Fedlex](https://www.fedlex.admin.ch).

### Annotations [optional]

No additional annotations have been added beyond the official translations provided by Swiss authorities.

#### Personal and Sensitive Information

The dataset does not contain any personal, sensitive, or private information. It consists solely of publicly available legal texts.

## Bias, Risks, and Limitations

The dataset may reflect the specific legal framework of Swiss federal law and does not represent legal systems outside Switzerland. Users should consider the limitations when applying it to international legal tasks.

### Recommendations

This dataset is best used for tasks within the legal domain, particularly focusing on multilingual legal text processing, translation, and analysis.

## Citation [optional]

**BibTeX:**

[More Information Needed]

**APA:**

[More Information Needed]

## Glossary [optional]

- **RS**: The Swiss official register number for federal laws.
- **Fedlex**: The official Swiss federal law platform.

## More Information [optional]

[More Information Needed]

## Dataset Card Authors

Joel Niklaus

## Dataset Card Contact

[Joel Niklaus](mailto:joel@niklaus.ai)