Inspiration
Courtfall was inspired by a real public challenge in England and Wales: the growing Crown Court backlog. Delays in the criminal justice system affect victims, defendants, witnesses, lawyers, and the wider public, yet most people only see headline statistics rather than tools that help decision-makers act on the problem.
I wanted to build something that goes beyond a static dashboard. Instead of only showing where pressure exists, Courtfall asks a more useful question: what should I do about it? My goal was to turn official Ministry of Justice court data into a decision-support tool that helps forecast pressure, simulate interventions, and compare policy choices.
What it does
Courtfall is an AI-powered decision-support platform for Crown Courts in England and Wales.
It does three main things:
Predict It forecasts each court’s next-quarter ineffective trial rate using historical court data and a machine learning model.
Simulate It models how a court’s open caseload (backlog) changes over the next 8 quarters using receipts, disposals, and intervention assumptions.
Decide It compares interventions such as extra sitting days or reductions in trial failures, then ranks them by their modelled impact per pound spent.
The result is an interactive product where a user can explore courts across the country, test “what-if” scenarios, inspect historical backtests, and see how recommendations change when assumptions change.
How we built it
I built Courtfall using public Ministry of Justice Criminal Court Statistics Quarterly data, primarily:
- trial effectiveness data by court and quarter
- Crown Court receipts, disposals, and outstanding caseload data
- court location data for mapping
I cleaned and joined these datasets into a single court-quarter dataset for 68 Crown Courts.
From there, the project was built in layers:
- ETL / data preparation using Python and pandas
- Prediction model using LightGBM, blended with a 4-quarter historical average, to predict next-quarter ineffective trial rates
- Backlog simulator using a stock-flow equation:
[ \text{Open}_{t+1} = \text{Open}_t + \text{Receipts}_t - \text{Disposals}_t ]
- Decision engine to compare interventions and estimate modelled cost-effectiveness
- Interactive Streamlit app with charts, maps, backtests, and a live Decision Lab
We also built historical backtests so that users can see how well the predictive model and backlog simulator perform on real past data.
Challenges we ran into
One of the biggest challenges was separating what the data proves from what we have to assume.
For example:
- We have official data on court outcomes, backlogs, and sitting-day costs.
- But we do not have perfect public evidence for the exact causal effect of every intervention.
- We also do not have public per-court sitting-day data, so some operational estimates had to be approximated.
Another major challenge was making the system honest and interactive at the same time. It is easy to make a dashboard look impressive, but much harder to ensure the simulator, backtests, and recommendations are actually connected to real calculations rather than static outputs.
We also had to debug cost-accounting logic in the decision engine, especially around how intervention spending should be charged across the full 8-quarter horizon.
Accomplishments that we're proud of
We are proud that Courtfall is not just a visualisation project — it is a full prediction + simulation + decision-making system.
Some highlights we are especially proud of:
- Building a clean court-level dataset from official MoJ data
- Predicting next-quarter ineffective trial rates across 68 Crown Courts
- Backtesting our forecasting approach rather than relying on untested claims
- Creating a live Decision Lab that shows when recommendations are robust and when they flip under different assumptions
- Discovering a meaningful policy insight: under our model, reducing collapsed trials helps, but capacity constraints appear to be the larger driver of backlog pressure
I am also proud of making the system transparent about its limitations instead of pretending the model is more certain than it really is.
What I learned
This project taught me a lot about the difference between:
- prediction
- simulation
- decision-making
- and causal evidence
I learned that an accurate forecast is only one part of a useful product. Real decision-support also requires:
- clear assumptions
- robust backtesting
- sensitivity analysis
- and honest communication of uncertainty
We also learned that simple baselines can be very strong. In our case, a blended approach combining LightGBM with a 4-quarter average performed better than relying on machine learning alone.
Most importantly, we learned that data products for public policy need to be transparent and challengeable, not just technically impressive.
What's next for CourtFall
Next, I want to make Courtfall even more useful and rigorous by:
- improving the live simulator and real-time backtesting experience
- adding stronger assumption controls and sensitivity analysis across all courts
- strengthening the evidence base behind intervention effects
- exploring national budget allocation strategies across courts
- refining the UI so decision-makers can move more easily from “What is happening?” to “What should we fund?”
Longer term, with better access to operational justice data, Courtfall could evolve from a hackathon prototype into a practical planning tool for policymakers, analysts, and justice-sector decision-makers.
Built With
- decision-trees
- lightgbm
- machine-learning
- numpy
- pandas
- parquet
- plotly
- predictive-analytics
- pydeck
- python
- pyyaml
- scikit-learn
- shap
- streamlit
Log in or sign up for Devpost to join the conversation.