openlegaldata / README.md
harshildarji's picture
update extraction process
c7ae48b
metadata
license: mit
task_categories:
  - text-classification
  - text-generation
language:
  - de
tags:
  - legal
pretty_name: Clean Open Legal Data
size_categories:
  - 100K<n<1M
configs:
  - config_name: cases
    data_files:
      - split: main
        path: data/cases.jsonl.gz

Clean Open Legal Data

Overview | Dataset Structure | Key Fields | Example Entry | Using the Dataset with Python | License

Overview

This dataset is a comprehensive collection of open legal case records in JSONL format. It comprises 251,038 cases extracted and processed from the Open Legal Data dump (as of 2022-10-18). The dataset is designed for legal research, data science, and natural language processing applications. Each decision is segmented into three main sections of judicial writing: Tenor, Tatbestand, and Entscheidungsgründe. In addition, the Rechtsmittelbelehrung is extracted as a separate field, since it is part of the published decision but not considered a substantive section of it. In references, law references and case references are also separated, as shown in the example entry.

Dataset Structure

├── README.md
├── data
│   └── cases.jsonl.gz
└── problematic_case_slugs.txt
  • Language: German
  • Format: JSONL
  • Total Cases: 251,038

Key Fields

  • id: Unique identifier for the record.
  • file_number: Identifier for the case (e.g., "1 A 2639/20").
  • slug: URL-friendly unique identifier (e.g., "ovgnrw-2022-03-25-1-a-263920").
  • ecli: European Case Law Identifier.
  • date: Date of the decision in YYYY-MM-DD format.
  • court: JSON object with court details (e.g., name, city, state, jurisdiction).
  • type: Type of legal decision (e.g., "Beschluss").
  • tenor: List of summary statements of the decision.
  • tatbestand: List of factual background details.
  • entscheidungsgründe: Detailed decision reasons.
  • references: Contains references to laws and related cases.
  • rechtsmittelbelehrung: Instructions on how and when to appeal a legal decision.

Example Entry

Below is an example entry from the JSONL file:

{
    "id": 344319,
    "file_number": "1 A 2639/20",
    "slug": "ovgnrw-2022-03-25-1-a-263920",
    "ecli": "ECLI:DE:OVGNRW:2022:0325.1A2639.20.00",
    "date": "2022-03-25",
    "court": {
        "id": 823,
        "name": "Oberverwaltungsgericht Nordrhein-Westfalen",
        "slug": "ovgnrw",
        "city": "Unspecified",
        "state": "Nordrhein-Westfalen",
        "jurisdiction": "Verwaltungsgerichtsbarkeit",
        "level_of_appeal": null
    },
    "type": "Beschluss",
    "tenor": [
        "Der Antrag wird abgelehnt.",
        "..."
    ],
    "tatbestand": [],
    "entscheidungsgründe": [
        "Der Antrag des Klägers auf Zulassung der Berufung hat keinen Erfolg.",
        "..."
    ],
    "references": {
        "law": [
            "§ 27a Abs. 3 Satz 1 2. Halbsatz SGB V",
            "..."
        ],
        "case": [
            "1 A 2251/16",
            "..."
        ]
    },
    "rechtsmittelbelehrung": []
}

Using the Dataset with Python

Below is an example of how to load and explore the dataset using Python with the 🤗 Datasets library:

import json

from datasets import load_dataset

# Load cases
cases = load_dataset("harshildarji/openlegaldata", "cases", split="main")

# Total cases
print(len(cases))

# View first case
print(json.dumps(cases[0], indent=4, default=str, ensure_ascii=False))

License

This dataset is released under the MIT license, same license as the Open Legal Data platform.