--- language: - gl - es license: cc-by-4.0 --- # Dataset Card for Spanish–Galician Legal Corpus ## Dataset Summary This dataset is derived from the **Translation Memory of the Directorate-General for Translation [(DGT-TM)](https://joint-research-centre.ec.europa.eu/language-technology-resources/dgt-translation-memory_en), a massive multilingual resource created by the European Commission. The original corpus contains the *Acquis Communautaire* (EU legislation) aligned across 24 official languages. The result is a **parallel corpus in Spanish–Galician**, focused on legal texts, with approximately **320,000 aligned sentence pairs**. While Galician is not included in the original release, Portuguese is. Using automatic transliteration and translation techniques, Portuguese segments were adapted into Galician. This adaptaion leveraged transliteration and localization tools found in our text [pipeline](https://github.com/proxectonos/pipeline) and [Apertium](https://github.com/apertium). The resulting texts were then normalized, ensuring linguistic consistency and readiness for model development. ## Dataset Creation - **Apertium pt-gl**: We translate original Portuguese segments into Galician using symbolic rules. - **Transliteration and localization**: Using [port2gal](https://github.com/gamallo/port2gal), we improve Apertium's output by processing all leftover tags for out-of-vocabulary words, which we either transliterate to Spanish orthography or localize to a more common Galician word. - **Encoding errors**: The entire text was scanned for encoding errors ensuring it is utf-8 encoded. - **Deduplication**: The filtered datasets were deduplicated to remove redundant sentence pairs. - **Pyplexity**: We used [pyplexity](https://github.com/citiususc/pyplexity) to filter texts that may contain non-linguistic content. - **Normalization**: The final Galician text present here was normalized (linguistically) to adhere to the autonomous standard of the Galician language. ## Supported Tasks and Benchmarks - **Machine Translation (MT):** Training and evaluation of MT systems for Spanish ↔ Galician. - **Bilingual Lexicon Induction:** Building dictionaries and glossaries for under-resourced language pairs. - **Evaluation:** Benchmarking translation quality in legal-domain corpora. - **Cross-lingual NLP:** Supporting tasks such as multilingual embeddings and semantic alignment. ## Languages - Spanish-Galician ## Dataset Structure - **Format:** Parallel text segments (aligned sentences) - **Domain:** Legal texts (EU legislation) - **Size:** ~320,000 lines ## Use Cases - Training MT models for Galician, a low-resource language. - Creating bilingual dictionaries and glossaries. - Evaluating translation systems in specialized legal domains. - Supporting research in cross-lingual transfer and underrepresented languages. ## Limitations - Domain-specific: Primarily legal texts, which may not generalize to everyday language. - Automatically adapted Galician segments may contain transliteration or translation artifacts. ## Funding This work is funded by the Ministerio para la Transformación Digital y de la Función Pública - Funded by EU – NextGenerationEU within the framework of the project Desarrollo de Modelos ALIA. Esta publicación del proyecto Desarrollo de Modelos ALIA está financiada por el Ministerio para la Transformación Digital y de la Función Pública y por el Plan de Recuperación, Transformación y Resiliencia – Financiado por la Unión Europea – NextGenerationEU.