Cross-Lingual and Uncertainty-Aware RAG for Medical Report Generation: An AI Gateway-Supported Proof of Concept
Abstract
The use of large language models (LLMs) in clinical decision support systems carries risks due to contextual noise, language barriers, and the models’ tendency to generate fabricated responses (hallucinations) even in situations of uncertainty. In this study, a cross-lingual and uncertainty- aware Retrieval-Augmented Generation (RAG) architecture, together with an Artificial Intelligence Gateway (AI Gateway) that operates this structure asynchronously, is presented in order to improve the accuracy of radiology report generation and to enable integration with local healthcare systems. In this study, detailed pre-processing was applied to clinical reports drawn from the MIMIC-CXR (Chest X-ray) dataset, and the texts were vectorized after being split into their logical sections (Findings and Impression). Proof-of-concept (PoC) tests carried out on a schema-compliant limited toy dataset showed that the cosine-similarity confidence threshold integrated into the AI Gateway filters out queries with insufficient context before they reach the model and forwards them to a physician approval queue (RabbitMQ). In addition, the Cross-Lingual layer enabled the lossless integration of English datasets with Turkish local systems by demonstrating a 95% schema compliance rate on test queries. The findings demonstrate that the proposed architecture reliably processes simultaneous requests, minimizing the risk of data loss andreducing the risk of hallucinations at the architectural level.