Electoral crime: Using machine-learning algorithms to extract data from unstructured court documents

Policy brief State Effectiveness and Sustainable Growth

This study investigates how convictions for electoral crimes affect politicians’ chances of running for office and being re-elected, using novel data from electoral courts in Brazil. Exploiting random assignment of judges, it identifies the causal impact of enforcement on political careers and electoral integrity.

Project

  • Automated, machine-learning-based models have come a long way in extracting useful data from unstructured documents.
  • Relative to manual extraction by experts, the model has an accuracy of over 70% for two-thirds of the questions. 
  • Even for complicated legal language, the model seems to understand the context and is able to classify the documents into different legal categories with more than 80% accuracy.

Using the data extracted using our Machine-Learning pipeline, we analyse the effects of a guilty verdict in election-related cases. Although the estimates are not precise because of data limitations, the preliminary results, based on manual extraction, can be summarised as follows: a guilty verdict leads to:

  • Lower likelihood of being a candidate in future elections.
  • Lower likelihood of being elected, conditional on being a candidate in future elections.