Optimus Project: “The Revolution of Artificial Intelligence in São Paulo’s Tax Processes”

The Optimus (Optimization of Municipal Tax Processes[1]) Project was designed to substantially improve efficiency in the management of administrative processes in the Lower-Level Tax Appeals Trial Division (DIJUL[2]). Although the initial scope was restricted to this area, the project was designed to be expanded to other areas of the São Paulo Municipal Finance Department (SF[3]) and to other future application contexts, especially because of the potential use of the applications and tools that the project employs.

Context and Motivation

Over the last few years, the analysis of lower-level administrative litigation cases has been characterized by essentially manual activities, which include document analysis and data capture and entry. This work dynamic results in low efficiency, prolonged deadlines, and a significant margin for error. The lack of standardization in administrative decisions and the need for constant human reinforcement make process management a challenge, as well as resulting in inefficient allocation of resources. In addition, the organization does not capture the data that moves through the area, preventing strategic management of tax credits that are challenged in the administrative sphere.

As a result, the number of cases to be tried has historically remained high. Currently, this number exceeds 10,000 cases, and the average trial time exceeds 270 days, even with many officials distributed to this task, with costs estimated at R$17 million per year.

In addition, the volume of tax credits that go through administrative litigation is significantly high: approximately R$2.4 billion annually, divided between 70% IPTU (Urban Property Tax[4]) and 30% ISS (Service Tax[5]). This scenario has led to the adoption of artificial intelligence (AI) and machine learning (ML) solutions, with particular focus on the use of large language models (LLMs) capable of automating and refining repetitive and complex operations.

The aim of introducing these tools is to create a virtual trial assistant to help analyst judges in their activities. It is not, therefore, an attempt to replace the human work carried out by the judge, but rather to add another (super-powerful) tool to their work environment.

Optimus Project Structure

The Optimus Project is divided into three main stages, developed in parallel, which are connected to guarantee the automation and efficiency of the system. The first, “Structure and Registration”, creates the basis for the system’s operation, by means of interfaces, registrations, and flow controls that standardize the registration and monitoring of processes, forming the structure on which the other functionalities will be based.

The second stage, “Process Automation”, focuses on integrating existing municipal systems, allowing simple processes, such as IPTU judicial challenges, to be handled automatically. This brings benefits such as reducing the time and costs involved in deciding these processes. This part is also responsible for integration with other municipal systems, automatically capturing data related to the trial process to be used by the Optimus System.

Finally, the third stage is the “engine” of the system, made up of “OCR, Anonymization, and AI & ML Tools”. This stage involves extracting text from the petition using OCR optical character recognition (), which is then anonymized using AI & ML tools and sent to LLM models to extract the claims and their details. For this last stage to be successful, the development team extracted and designed a “claim forest” made up of “branches”, each representing a possible claim, which are grouped into “trees”, each of the latter by tax themes, such as immunity, tax base, etc. The work carried out by the business team was based on the manual analysis of dozens of petitions, extracting the main claims and arguments presented by taxpayers. From this “claim forest”, the technical team iteratively improved the prompt to be sent to the LLM tool using the most advanced prompt engineering techniques, so as to capture the claims and their details as accurately as possible. The life cycle of the trial goes through these three stages and is completed with the production of two pieces: the judgment and the judge’s decision.

Partial Results

Before the formal start of the project in April 2024, the SF technicians decided to carry out a proof of concept (POC) throughout the first quarter of 2024, in order to test the LLMs‘ ability to achieve satisfactory results. To this end, various models, such as Claude, ChatGPT, and LLaMA were tested, all with different parameters (temperatures, claim forests, and prompts), with the aim of building the most flexible and efficient system possible. The POC proved successful, and the project was then formally started, with a first phase of 12 sprints to be developed over one year. Within this period, it is expected that a Beta version will be launched and made available to a group of DIJUL judges between December 2024 and January 2025, which will comprise the entire preparation of the trial analyst’s evaluation.

The partial results of analyzing petitions using LLM are extraordinary: at a cost of less than R$2, a petition of dozens of pages has its claims and details extracted in under 30 seconds, with over 90% accuracy.

Expected Benefits

The Optimus Project aims to transform the current environment of low efficiency, extended deadlines, high error-proneness, and high need for additional human resources into a highly automated and efficient system. The expected benefits include:

  • Reduced time and costs for analyzing cases;
  • Increased consistency and standardization in decisions;
  • Reduction in human errors due to increased automation;
  • Optimizing the allocation of human resources, allowing staff in the area to focus on more strategic activities for the organization, such as settling tax disputes internally, jurimetrics, and the analysis of the entire life cycle of the notice of violation[6];
  • Decision-making based on data, with the creation of a centralized strategic knowledge base.

It is estimated that the project could release up to R$2 billion in tax credits for collection each year, by speeding up the case analyses.

[1] Translator’s Note: original term in Portuguese: Otimização de Processos Tributários Municipais.

[2] Translator’s Note: original term in Portuguese: Divisão de Julgamento de Recursos Tributários de Primeira Instância.

[3] Translator’s Note: original term in Portuguese: Secretaria Municipal da Fazenda de São Paulo.

[4] Translator’s Note: original term in Portuguese: Imposto sobre a Propriedade Territorial Urbana. A tax applied in Brazil.

[5] Translator’s Note: original term in Portuguese: Imposto sobre Serviços. Another Brazilian tax.

[6] Translator’s Note: original term in Portuguese: auto de infração. Document specific to Brazil.

43 total views, 2 views today

Leave a Reply

Your email address will not be published.

CIAT Subscriptions

Browse through the site without restrictions. Consult and download the contents.

Subscribe to our electronic newsletters:

  • Blog
  • Academic offer (Only in spanish)
  • Newsletter
  • Publications
  • News alert

Activate subscription

CIAT Members

Representatives, Correspondent and Authorized staff (TA)