The OECD.AI Policy Navigator

Our policy navigator is a living repository from more than 80 jurisdictions and organisations. Use the filters to browse initiatives and find what you are looking for.

CiudadanIA: AI-Powered Citizen Correspondence Processing for the Spanish Prime Minister’s Office


Added by:   OECD analyst
Added on:   04 Aug 2026
Updated by:   OECD analyst
Updated on:   04 Aug 2026

CiudadanIA uses AI to accelerate the processing of citizen letters addressed to the Spanish President through the “Write to the President” service. Small language models generate summaries of citizen correspondence, enabling faster routing and response. The project also produced open-source tools for testing AI prompts and models at scale, including an LLM-as-a-judge evaluation framework, contributing to trustworthy AI in government.

Name in original language

CiudadanIA: Procesamiento con IA de Correspondencia Ciudadana para el Gabinete de Presidencia del Gobierno de España

Initiative overview

CiudadanIA is an AI initiative within the PresidencIA programme that applies generative AI to improve the processing of citizen correspondence addressed to the President of Spain through the official “Escribe al Presidente” (Write to the President) service. This channel receives thousands of letters from citizens raising concerns, making requests, and sharing opinions on policy matters. Each letter requires reading, summarising, categorising, and routing to the appropriate government department, a labour-intensive process that directly affects how quickly and effectively citizens receive responses.  

CiudadanIA automates the summarisation step using small language models. Rather than relying exclusively on large cloud-based AI systems, the project combined cloud with fine-tuned compact models (specifically Gemma-3-4B, quantised for efficiency) to run on local government infrastructure. This design decision was driven by two requirements: citizen letters contain personal and sensitive information, and the government’s AI sovereignty objectives call for reduced dependency on third-party systems.  The fine-tuning and evaluation process was rigorous. Government staff who process citizen correspondence daily provided expert feedback on model outputs, identifying systematic errors such as hallucinated information (inventing details not present in letters), tone distortion (characterising respectful requests as demands), and omission of relevant content. This feedback was used to iteratively refine prompts and model behaviour.  To support this evaluation at scale, the programme developed an open-source LLM evaluation workbench that enables systematic testing of different prompts, models, and configurations. 

The tool supports both cloud APIs and local models, includes batch processing for evaluating large sets of correspondence, and implements an LLM-as-a-judge methodology where one language model evaluates the quality of another’s outputs against configurable criteria (accuracy, conciseness, tone preservation). The tool also supports English and Spanish and is available for other government teams. 

Other relevant details

CiudadanIA demonstrates a complete pipeline for responsible AI deployment in citizen-facing government services: identifying a concrete need, developing purpose-built solutions with privacy-by-design, involving domain experts in evaluation, producing reusable open-source tooling, and running models on sovereign infrastructure. The approach is transferable to any government that processes citizen correspondence, public consultations, or similar high-volume text processing tasks. The project keeps human-in-the-loop, maintaining oversight over all final decisions that affect how citizen letters are handled and responded to. Fine-tuned models deployable on local infrastructure, processing correspondence without sending data to external providers. Expert government staff provided systematic feedback on model outputs, driving iterative quality improvements. LLM evaluation tool published at with LLM-as-judge capability, batch testing, and bilingual support. Prompt optimisation reduced hallucination and tone distortion errors identified in early testing. Supervised fine-tuning (SFT) together with diverse reinforcement learning for better performance. Impacts: faster processing of citizen correspondence, improved service quality, reduced staff workload on routine summarisation, and reusable evaluation methodology applicable to other government AI deployments.