Dataset Viewer
Auto-converted to Parquet Duplicate
Search is not available for this dataset

Bangladesh Supreme Court Case Studies (bd-case-studies)

8,493 Bangladesh Supreme Court judgment PDFs plus a machine-readable layer built for legal research: per-page triage, cleaned text, case metadata, and in-progress VLM transcription of every non-digital page. Built as the retrieval corpus for an agentic legal assistant for lawyers and law students (paired Qdrant collections: statutes + case studies, matched by case type).

Repository layout

Path Contents
*.pdf (repo root, 8,493 files) Source judgment PDFs (mixed Bangla/English; digital, scanned, and broken-glyph pages)
processed/cases.jsonl One JSON record per judgment: cleaned page texts, per-page route, extracted metadata
processed/manifest.json SHA-256 resumability manifest for the parsing pass
processed/ocr_queue/<stem>/p<page>.png Rendered page images for every non-digital page (1,376 total)
processed/ocr_queue/<stem>/p<page>.txt Muse Glimmer 30B transcriptions, one per page (landing in batches; 1,376 target)
processed/cases_with_ocr.jsonl cases.jsonl with OCR pages merged in (published when transcription completes)

How the machine-readable layer was built

  1. Triage per page, worst page decides the file. Each page is routed to digital (parse + clean), scanned_image (OCR from pixels), or bangla_needs_ocr (glyphs present but fragmented — re-read from pixels, never trust the extracted text). Page rule: < 200 chars + embedded images = scan; Bangla with isolated vowel signs or majority stub tokens = broken glyphs.
  2. Clean without collapsing. NFKC normalization (recomposes decomposed Bangla), hyphen-wrap joining, single newlines folded to spaces while blank-line paragraph breaks are kept, Page # N footers and lone page numbers stripped.
  3. OCR with Muse Glimmer 30B (meta-models/Muse-Glimmer-30B). Image-text-to-text transcription per page with a strict transcribe-only prompt; echo/stub text stripped after generation.
  4. Regex metadata, best effort. Case number, court (division preferred over the bare apex name), decision date, parties, year, case type — coverage varies (see stats); deeper fields ride the structuring pass.

Corpus stats (parsing pass)

  • Records: 8,052 judgments, 64,309 pages
  • Routes: 7,160 digital / 832 scanned_image / 60 bangla_needs_ocr
  • Metadata coverage: case_number 5,979 · court 4,005 · decision_date 6,673 · case_year 8,027 · case_type 6,180 · parties 0 (front-matter rarely states parties cleanly)

cases.jsonl record schema

{
  "source_file": "100174_CR_1359_2002.pdf",
  "file_hash": "sha256…",
  "n_pages": 9,
  "route": "digital",
  "metadata": {"case_number": "…", "court": "…", "decision_date": "…",
               "case_year": "…", "case_type": "…", "parties": ""},
  "pages": [{"page": 1, "route": "digital", "chars": 2313,
             "cleaned": "…", "origin": "text"}],
  "ocr_pngs": ["ocr_queue/<stem>/p3.png"]
}

origin is text for parser output and glimmer_ocr for merged transcriptions. Downstream chunking splits on judgment headings and numbered reasoning paragraphs (~2,800 chars, 320 overlap) with deterministic IDs, and embeds with voyage-4 dense + BM25 sparse vectors for hybrid retrieval filtered by case_type / court / year.

Usage

from datasets import load_dataset
ds = load_dataset("istiaqfuad/bd-case-studies", streaming=True)
# JSONL lives under processed/; PDFs at repo root

Direct download of one record file:

from huggingface_hub import hf_hub_download
p = hf_hub_download("istiaqfuad/bd-case-studies",
                    "processed/cases.jsonl", repo_type="dataset")

Intended use and limitations

  • Research corpus for legal RAG: case-study retrieval alongside statute retrieval, not a substitute for reading the judgment.
  • Metadata is regex best-effort; verify citations against the source PDF before relying on them.
  • Transcription is model output — spot-check Bengali passages that matter to your argument.
  • Source judgments are public court records shared for education and research. If you are a rights holder with a concern, open a discussion on this repo.

Provenance

Parsed and transcribed with the open pipeline in src/legalbuddy/case_parsing.py (procedure documented in docs/case-studies-pipeline.md of the legalbuddy-cv project). Transcription model: meta-models/Muse-Glimmer-30B (Meta).

Downloads last month
183