Datasets:
Add Ukrainian court decisions judgment prediction subset
Add a new SLTC subset: ukrainian_court_decisions_judgment — case outcome prediction for Ukrainian court decisions.
Dataset details
- Source: overthelex/ukrainian-court-decisions
- Language: Ukrainian (uk)
- Task: Single-label text classification (SLTC)
- Labels:
approved,dismissed,partial - Size: 10,268 samples (8,214 train / 1,027 val / 1,027 test)
- Input: Facts section only (ВСТАНОВИВ marker to ВИРІШИВ marker)
- Source registry: State Court Decisions Registry of Ukraine (ЄДРСР, reyestr.court.gov.ua)
- Jurisdiction: Civil and commercial courts, 2010–2014
Why facts only?
Following the approach from Swiss Judgment Prediction and Brazilian Court Decisions subsets, we provide only the facts section to avoid trivially solvable classification (the ruling section contains the answer directly).
Changes
- Added
_UKRAINIAN_COURT_DECISIONS_JUDGMENTconfig dict inlextreme.py - Added
LextremeConfigentry inBUILDER_CONFIGS
This is the first Cyrillic-script / Ukrainian language subset in LexTreme.
Update: New case_outcome_temporal config added
Hi Joel! Following your suggestion, I've significantly expanded the Ukrainian subset. In addition to the original ukrainian_court_decisions_judgment config (150K, 3 labels, civil+commercial), there's now a second config in the source dataset:
load_dataset('overthelex/ukrainian-court-decisions', 'case_outcome_temporal')
What's new
| Original config | New case_outcome_temporal |
|
|---|---|---|
| Records | 150,000 | 14,452 |
| Years | 2010-2014 | 2008-2026 (15 years) |
| Jurisdictions | Civil + commercial | All 5 (civil, criminal, commercial, admin, admin offense) |
| Labels | 3 (approved/dismissed/partial) | 7 (granted/guilty/partial/closed/denied/plea_deal/other) |
| Temporal epochs | — | 3 (pre_war 2008-2013, hybrid_war 2014-2021, full_scale 2022-2026) |
Why temporal epochs matter
Ukraine's judiciary went through two major disruptions:
- 2014: Crimea annexation + Donbas conflict — courts in occupied territories ceased operating
- 2022: Full-scale invasion — martial law, surge in military criminal cases (AWOL, desertion), new Criminal Code articles (collaborationism)
This enables cross-temporal generalization research — train on one epoch, evaluate on another.
Fields
facts (model input), dispositive (for label verification), outcome (label), epoch, year, justice_kind, court_code, judge, category_code, adjudication_date
Happy to add a second LextremeConfig entry for this config if you'd like it in the benchmark. Also fixed the LEXTREME citation in my paper — thanks again for catching that!
Why three epochs — more detail on the distribution shifts
The three-epoch split isn't arbitrary — each boundary marks a structural change in the Ukrainian court system that creates genuine distribution shift in both case types and outcomes:
Pre-war (2008–2013): Baseline. All 832 courts operational across all 25 oblasts + Crimea. Criminal docket dominated by property crimes (theft, fraud), drug offenses. Administrative courts handle tax disputes, pension cases. Outcome distribution relatively stable year-to-year.
Hybrid war (2014–2021): In 2014, Ukraine lost ~40 courts in Crimea and parts of Donetsk/Luhansk — those courts simply disappear from the registry. New case categories emerge: internally displaced persons' property rights, ATO veteran benefits, anti-terrorist operation proceedings. Criminal code amended with new articles on terrorism (258), separatism (110). The case-type mix shifts measurably — but the fundamental court procedure stays the same.
Full-scale (2022–2026): Martial law declared — this changes procedural timelines, appeal rules, and judge availability. Military criminal cases explode: AWOL (art. 407 KK), desertion (art. 408), draft evasion (art. 336), insubordination (art. 402). New Criminal Code articles added: collaborationism (111-1), aiding the aggressor state (111-2). Administrative offense courts now handle mass mobilization-related cases (art. 210-1 KUpAP). Several more courts in newly occupied territories go offline. The guilty and plea_deal labels see a significant frequency increase compared to earlier epochs.
For a benchmark, this means a model trained on pre-war civil cases may fail on full-scale military criminal cases — not because of language difficulty, but because the legal concepts, outcome distributions, and even the vocabulary are different. This is a real-world temporal robustness challenge that most legal NLP benchmarks don't capture.
Thanks for the PR!
It looks like you have a random split for the original dataset, right? We usually advise for the temporal split for a more realistic measurement as you mention in the discussion. In this case the different epochs seem to differ substantially, I wonder whether it makes sense to have three separate configs (one for each epoch) and to have the train, val and test splits temporally separated there.
Thanks for the feedback, Joel!
I've updated the PR with three separate configs as you suggested:
ukrainian_court_decisions_judgment_pre_war(2008-2013): 128K samplesukrainian_court_decisions_judgment_hybrid_war(2014-2021): 150K samplesukrainian_court_decisions_judgment_full_scale(2022-2026): 150K samples
Each config now has temporal train/val/test splits (chronological, not random):
| Config | Train | Val | Test | Train period | Test period |
|---|---|---|---|---|---|
| pre_war | 102K | 12.8K | 12.8K | 2008-01 -- 2012-08 | 2013-09 -- 2013-12 |
| hybrid_war | 120K | 15K | 15K | 2014-01 -- 2020-05 | 2021-03 -- 2021-12 |
| full_scale | 120K | 15K | 15K | 2022-01 -- 2025-09 | 2025-12 -- 2026-05 |
The three epochs differ substantially in judicial practice (stable pre-war baseline vs. partial martial law vs. full-scale invasion with nationwide martial law), so separate configs allow measuring generalization within and across regimes.
The source dataset has been updated at overthelex/ukrainian-court-decisions with the three configs.
Usage:
load_dataset('joelniklaus/lextreme', 'ukrainian_court_decisions_judgment_hybrid_war')
Let me know if anything else needs adjusting!
Also, once this is merged, I'm planning to add a companion baselines repo with:
- Cross-epoch evaluation -- train on pre_war, test on full_scale (and vice versa) to measure temporal generalization
- Fine-tuned baselines -- XLM-RoBERTa-base and mBERT on each epoch, plus a zero-shot multilingual baseline
- Epoch drift analysis -- how class distributions and decision language shift across war/peace regimes (the approved/dismissed ratio changes substantially between epochs)
The source registry (ЄДРСР) has 100M+ decisions going back to 2005, so we can also expand to:
- Criminal and administrative jurisdictions (currently civil + commercial only)
- Multi-label tasks (e.g., legal area prediction from facts)
- Longer time horizons for finer-grained temporal analysis
Happy to prioritize any of these if they'd be useful for the benchmark.
Thanks for the update. I see some discrepancies regarding the sizes of the datasets:
You say that the original dataset has around 10k samples: https://huggingface.co/datasets/joelniklaus/lextreme/discussions/16#6a0499f20bc13155e1c410d7
Then you say the original has actually 150k samples and the new one has ~14k (with three periods): https://huggingface.co/datasets/joelniklaus/lextreme/discussions/16#6a052cc0e846e75a79d2b87f
And now suddenly the new config has three periods with around 150k each: https://huggingface.co/datasets/joelniklaus/lextreme/discussions/16#6a0a1deaa129a1d96ea48a99
Can you please clarify ?
Good catch, Joel — sorry for the confusion. The numbers changed because I iterated on the source dataset between comments:
Comment 1 (10K): Initial small proof-of-concept sample — 10,268 decisions from civil+commercial courts (2010–2014), 3 labels, random split. This was a minimal submission to validate the config format.
Comment 2 (150K default + 14K temporal): After your initial feedback, I went back to the full ЄДРСР registry and expanded significantly. The default config grew to 150K (50K per class, balanced). The case_outcome_temporal config (14,452 samples) was a separate, smaller curated subset covering all 5 jurisdictions and 7 fine-grained labels across 3 epochs — intended as a richer research config, not a replacement.
Comment 5 (128–150K per epoch): Following your suggestion to split by epoch with temporal train/val/test, I pulled the full available data for each period directly from the registry. This replaced the small 14K temporal config with three large epoch configs:
| Config | Train | Val | Test | Total |
|---|---|---|---|---|
pre_war |
102,460 | 12,807 | 12,808 | 128,075 |
hybrid_war |
120,000 | 15,000 | 15,000 | 150,000 |
full_scale |
120,000 | 15,000 | 15,000 | 150,000 |
pre_war is smaller (128K vs 150K) because the registry has fewer digitized decisions before 2008. hybrid_war and full_scale are capped at 150K each (50K per class) for balance.
All splits are temporal (chronological by adjudication_date), not random. The source dataset at overthelex/ukrainian-court-decisions now has all four configs (default + 3 epochs) and the numbers match.
For the LEXTREME PR, I'm proposing the three epoch configs only (not default) — the temporal splits are more realistic for benchmarking. Let me know if you'd prefer to also include the default config as a simpler baseline.
Thanks for the clarification.
Are you truncating the texts? I think it would be good to not truncate since we don't have the same context length restrictions anymore that we used to have in the past.
Also, I think it would be great if you have a complete dataset with all the cases and then a smaller one that is used for lextreme so that the evaluation is faster. I would suggest no more than 1000 examples in validation and test each.
Great points!
Truncation — you're right, I was capping facts at 10K characters. Will remove that and keep the full text.
Sizing — makes total sense. Here's what I'll do:
- Source dataset (overthelex/ukrainian-court-decisions) — full untruncated data, all available cases per epoch, large splits
- LEXTREME configs — separate configs in the source repo with ≤1000 val / ≤1000 test so evaluation runs fast
Will re-extract everything without the length cap, set up the LEXTREME-sized configs, and push an update to this PR.
Done! Here's what changed:
Truncation removed — texts are now full length. The distribution across epochs:
| Epoch | Records | Median chars | Max chars | >10K chars |
|---|---|---|---|---|
| pre_war | 128,075 | 4,607 | 150,194 | 18% |
| hybrid_war | 150,000 | 7,575 | 150,890 | 36% |
| full_scale | 150,000 | 13,790 | 194,480 | 65% |
Dataset restructured — the source dataset now has 6 configs:
pre_war,hybrid_war,full_scale— full configs with 12K-15K val/testpre_war_lextreme,hybrid_war_lextreme,full_scale_lextreme— benchmark configs with 999 val / 999 test (333 per class, balanced, temporally split)
The LEXTREME PR now points to the *_lextreme configs. Train sets are shared between full and lextreme configs (102K-120K samples).
The source registry (ЄДРСР) has 100M+ decisions total; the published dataset covers ~6.6M valid extracted records across all three epochs, from which we sample balanced subsets.
Let me know if anything else needs adjusting!
One question on the "complete dataset" side — the current source configs have 128-150K balanced samples per epoch (50K per class). But the full extraction pipeline yields ~6.6M valid records across all three epochs (543K pre-war, 4.1M hybrid war, 1.96M full-scale), and the underlying registry has 100M+ court decisions total.
Is the current 428K balanced subset enough for the source dataset, or would you prefer the full 6.6M unbalanced extraction? Happy to upload either way — just want to check before pushing tens of GB to HF.
There are more than 100M court decisions in less than 20 years? This doesn't sound very realistic.
It's real — Ukraine's Unified State Register of Court Decisions (EDRSR, reyestr.court.gov.ua) is one of the largest open judicial databases in the world. By law ("On Access to Court Decisions", 2005), every court decision must be published in the registry (with narrow national security exceptions). The registry has been operational since 2006.
Ukraine has ~750 courts across 5 jurisdictions (civil, criminal, commercial, administrative, constitutional). With mandatory publication and high caseload volume, the registry crossed 100M decisions around 2024. You can verify the count via the public API — or see our citation graph dataset (overthelex/ua-court-citation-graph) which extracted 2.3M co-citation edges from 99.5M of those decisions.
For reference, the annual volume is roughly 5–8M decisions/year in recent years.
Fair point to clarify — the 100M figure includes all judicial documents in the registry, not just substantive judgments. The breakdown from our local mirror of the full EDRSR:
| Document type | Count | % |
|---|---|---|
| Ухвала (procedural ruling) | 67.4M | 66.7% |
| Постанова (appellate/cassation resolution) | 17.1M | 16.9% |
| Рішення (substantive decision) | 12.6M | 12.5% |
| Судовий наказ (court order) | 2.8M | 2.8% |
| Вирок (criminal verdict) | 1.1M | 1.1% |
| Other (separate opinions, additional decisions) | ~35K | <0.1% |
So in the narrow sense of "decisions on the merits" (рішення + вироки + постанови) it's ~31M. The bulk are procedural rulings (ухвали) — scheduling hearings, accepting cases, granting motions, etc. The registry mandates publication of all document types.
For the judgment prediction subset contributed here, we filter to substantive decisions only (judgment_code=3, Рішення).
I see, interesting. Thanks for the clarification.
I think the current number of cases is more than enough. Could you please also adapt the dataset card accordingly?
Updated the dataset card. Here's the final structure:
6 configs (3 full + 3 LEXTREME benchmark):
| Config | Train | Val | Test | Period |
|---|---|---|---|---|
pre_war |
102,460 | 12,807 | 12,808 | 2008–2013 |
hybrid_war |
120,000 | 15,000 | 15,000 | 2014–2021 |
full_scale |
120,000 | 15,000 | 15,000 | 2022–2026 |
pre_war_lextreme |
102,460 | 999 | 999 | 2008–2013 |
hybrid_war_lextreme |
120,000 | 999 | 999 | 2014–2021 |
full_scale_lextreme |
120,000 | 999 | 999 | 2022–2026 |
LEXTREME configs have balanced val/test (333 per class). All splits are temporal (chronological by adjudication date). Text is full untruncated facts section.
Text length stats (untruncated):
| Epoch | Median | Max | >10K chars |
|---|---|---|---|
| pre_war | 4,607 | 150,194 | 18% |
| hybrid_war | 7,575 | 150,890 | 36% |
| full_scale | 13,790 | 194,480 | 65% |
Sorry, I mean the lextreme dataset card here in the PR
Got it -- updating the LEXTREME dataset card (README.md) in this PR to:
- Add
ukto the language list - Add Ukrainian Court Decisions to the tasks table
- Update the dataset summary to reflect 12 datasets / 21 tasks
Will push the commit shortly.
Looks good, thanks for the contribution.