SASergio Torres Aguilar

Sergio Torres Aguilar

*This is an algorithmically generated author record based on publicly available information.

Current Organizations / Institutes

The organizations/institutes from the scholar's latest article

Previous Organizations / Institutes

The organizations / institutes from the scholar's other articles in the past ten years


Sergio Torres Aguilar has a total of 3 co-authors. Here are the top co-authors by number of shared publications:


Latest Publications

  • Un modèle de reconnaissance automatique des entités nommées et des structures textuelles pour les corpus diplomatiques médiolatins.

    by Sergio Torres Aguilar

    Nous présentons dans cette thèse deux modèles informatiques développés pour délivrer de l'information structurée et applicables à de grandes bases de données de textes médiévaux. Les deux modèles, l'un appliqué à la reconnaissance des entités nommées, l'autre à la détection des parties du discours diplomatique, ont suivi un apprentissage supervisé utilisant la méthode des Champs aléatoires conditionnelles (CRF) sur un corpus manuellement annoté de actes médiévaux (Corpus Burgundiae Medii Aevi ou CBMA).Notre modèle principal de reconnaissance d'entités nommées a prouvé sa robustesse lorsqu'il a été appliqué sur des échantillons de corpus de taille, chronologie et origine très variés. Le modèle secondaire détectant les parties du discours diplomatique, bien que moins performant, s'est montré valide comme outil de structuration. Ils peuvent à présent être utilisés pour l'indexation et l’étude d’une grande variété de sources diplomatiques, économisant, ainsi des considérables efforts humains.Nous avons développé différentes solutions destinées à trouver un juste équilibre entre la dépendance du modèle à son corpus d'origine et sa capacité à être appliqué à d’autres corpus. De même, différents ajouts et corrections ont été opérés sur le corpus de référence à partir de plusieurs observations de type historique et linguistique concernant les documents utilisés, ce qui a permis d'améliorer la performance initiale.Nous avons ensuite appliqué les outils ainsi générés à la reconnaissance de noms de personnes, de lieux et de parties du discours diplomatique sur des milliers d'actes du CBMA afin d'étudier différentes questions intéressant la science historique et la diplomatique. Ces études concernent la datation semi-automatique d'un cartulaire qui en était dépourvu ; l'évolution du vocabulaire spatial dans les actes du Moyen Âge Central; et l'indexation des documents à partir des modules les intégrant, notamment les formules du protocole des actes. Par ces études nous poursuivons un double objectif: illustrer différentes stratégies permettant d'abstraire et d'adapter au traitement automatique des données des méthodes de recherche classiques en Histoire ; démontrer que nos outils de traitement massif permettent la génération de connaissances pertinentes pour la science historique.

  • Open Access

    "Don't Teach Minerva": Guiding LLMs Through Complex Syntax for Faithful Latin Translation with RAG

    by Sergio Torres Aguilar

    Translating a morphology-rich, low-resource language like Latin poses significant challenges. This paper introduces a reproducible draft-based refinement pipeline that elevates open-source Large Language Models (LLMs) to a performance level statistically comparable to top-tier proprietary systems. Our method first uses a fine-tuned NLLB-1.3B model to generate a high-quality, structurally faithful draft. A zero-shot LLM (Llama-3.3 or Qwen3) then polishes this draft, a process that can be further enhanced by augmenting the context with retrieved out-context examples (RAG). We demonstrate the robustness of this approach on two distinct benchmarks: a standard in-domain test set (Rosenthal, 2023) and a new, challenging out-of-domain (OOD) set of 12th-century Latin letters (2025). Our central finding is that this open-source RAG system achieves performance statistically comparable to the GPT-5 baseline, without any task-specific LLM fine-tuning. We release the pipeline, the Chartres OOD set, and evaluation scripts and models to facilitate replicability and further research.

    • 8 March 2025
    • Published by HAL in HAL
    Open Access

    Dual-Style Transcription of Historical Manuscripts based on Multimodal Small Language Models with Switchable Adapters

    by Sergio Torres Aguilar

    The transcription of historical manuscripts presents unique challenges due to complex writing styles, pervasive abbreviations, and significant linguistic heterogeneity. Recent multimodal architectures that integrate powerful language models with vision encoders offer promising and flexible solutions. In this work, we propose a two-stage training strategy to model two main transcription paradigms: diplomatic (abbreviated) and semi-diplomatic (expanded). Our approach leverages two specialized corpora—CATMuS Medieval (abbreviated) and TRIDIS (non-abbreviated). In Stage 1, we pre-train a single model on a random combined dataset using a loss penalization mechanism to discourage the prediction of Medieval Unicode Font Initiative (MUFI) characters during expanded-text generation. In Stage 2, this pre-trained model serves as the foundation to train \emph{separate} LoRA adapters for each transcription style, which can be dynamically switched at inference.We benchmark our approach using MiniCPM-Llama3-V-2.5, Phi-3.5 Vision and Qwen2-VL (all published end-2024) against two established baselines (Kraken v5 and TrOCR). Our results indicate that while the unified “double-head” model provides a solid initialization, fine-tuning separate, switchable LoRA adapters leveraging that base yields progressive superior performance by better adapting to each transcription style. We discuss the limitations of a single adapter and advocate for switched adapters to achieve optimal flexibility. This integrated approach supports historians, linguists, and digital humanities scholars in exploring complex historical corpora at multiple interpretive levels.

  • Top Cited Papers
    Open Access

    Handwritten Text Recognition for Documentary Medieval Manuscripts

    by Sergio Torres Aguilar, Vincent Jolivet

    Handwritten Text Recognition (HTR) techniques aim to accurately recognize sequences of characters in input manuscript images by training artificial intelligence models to capture historical writing features. Efficient HTR models can transform digitized manuscript collections into indexed and quotable corpora, providing valuable research insight for various historical inquiries. However, several challenges must be addressed, including the scarcity of relevant training corpora, the consequential variability introduced by different scribal hands and writing scripts, and the complexity of page layouts. This paper presents two models and one cross-model approach for automatic transcription of Latin and French medieval documentary manuscripts, particularly charters and registers, written between the 12th and 15th centuries and classified into two major writing scripts: Textualis (from the late-11th to 13th century) and Cursiva (from the 13th to the 15th century). The architecture of the models is based on a Convolutional Recurrent Neural Network (CRNN) coupled with a Connectionist Temporal Classification (CTC) loss. The training and evaluation of the models, involving 120k lines of text and almost 1M tokens, were conducted using three available ground-truth corpora : The e-NDP corpus, the Alcar-HOME database and the Himanis project. This paper describes the training architecture and corpora used, while discussing the main training challenges, results, and potential applications of HTR techniques on medieval documentary manuscripts.


  • Open Access

    Automatic medieval charters structure detection : A Bi-LSTM linear segmentation approach

    by Sergio Torres Aguilar, Pierre Chastang, Xavier Tannier

    This paper presents a model aiming to automatically detect sections in medieval Latin charters. These legal sources are some of the most important sources for medieval studies as they reflect economic and social dynamics as well as legal and institutional writing practices. An automatic linear segmentation can greatly facilitate charter indexation and speed up the recovering of evidence to support historical hypothesis by the means of granular inquiries on these raw, rarely structured sources. Our model is based on a Bi-LSTM approach using a final CRF-layer and was trained using a large, annotated collection of medieval charters (4,700 documents) coming from Lombard monasteries: the CDLM corpus (11th-12th centuries). The evaluation shows a high performance in most sections on the test-set and on an external evaluation corpus consisting of the Montecassino abbey charters (10th-12th centuries). We describe the architecture of the model, the main problems related to the treatment of medieval Latin and formulaic discourse, and we discuss some implications of the results in terms of record-keeping practices in High Middle Ages.

  • La reconnaissance des entités nommées dans les bases numériques de chartes médiévales en latin : le cas du Corpus Burgundiae Medii Aevi (xe-xiiie siècle)

    by Sergio Torres Aguilar

    La disponibilité d’une quantité phénoménale de manuscrits médiévaux numérisés nous oblige à chercher des méthodes efficaces pour en réaliser une exploitation à grande échelle. Mais ce travail ne peut être réalisé que dans des bases de données structurées où les propriétés textuelles ont été explicitées et formalisées. Une telle structuration, lorsqu’elle est effectuée à la main, est coûteuse en termes de temps et d’effort, ce qui a conduit à chercher des manières de l’automatiser. Nous en présentons ici un exemple : la création d’un modèle de reconnaissance des entités nommées, qui sont un agent structurant primaire, puisque y sont identifiés tous les sujets et objets qui adoptent des noms spécifiques. Nous détaillons la création et la mise en œuvre du modèle créé à partir des chartes de Bourgogne (Corpus Burgundiae Medii Aevi), produites entre le xe et le xiiie siècle ainsi que diverses expériences de validation pour en tester la robustesse sur un large éventail de sources, tout en soumettant les résultats à une discussion qui tente d’exposer les divers avantages et défis qu’offre un corpus de manuscrits médiévaux pour ce type de technique.