How lsx-uniwue/semeval-2025-task-2 works
Project Overview
• Type & Purpose: This is a specialized machine translation system that augments translations by incorporating entity-aware knowledge extracted via SQL-based retrieval. It is designed for competitive performance in entity-aware MT tasks without relying on gold-standard entity IDs.
• Key Features: Two-stage approach (entity retrieval followed by knowledge integration) and the use of configurations (via Hydra) and the uv package manager to streamline experiments and training runs.
Main Components
a. External Data & Support Systems:
• Wikidata Database: An external, pre-built database derived from the Wikidata dump (located in /data/wikidata). It serves as the entity knowledge base.
• Data Inputs: Raw input text to be translated and associated Wikidata-derived information.
b. Core Processing Modules:
• Entity Retrieval Module:
• Implements normalized string matching using SQL.
• Retrieves and scores candidate entities based on relevance and string length.
• This as a dedicated component that interacts with the Wikidata database.
• Knowledge Integration Module:
• Augments the source text with entity-translation pairs.
• Implements pointer generation and logit biasing during beam search.
• Translation Module:
• Uses the augmented input for translation output.
• Likely built using models defined in src/models (e.g., entity_aware_m2m100_model, translation_module, entity_reranker_model).
c. Configuration and Management:
• Configuration Management: Handled by Hydra using configuration files (such as src/conf/translation_config.yaml) to manage hyperparameters (e.g., pointer generator flag, sequence bias weight).
• Package/Environment Management: Managed via uv (see the uv.sync and uv.run commands in the README).
d. Auxiliary Components:
• Data Management: Data ingestion and preparation components (found in directories like src/data and dspy-approach) that prepare inputs and manage predictions.
• Evaluation & Experimentation: Notebooks in eval_notebooks and Slurm scripts (semeval_slurm.sh, slurm_runs.sh, slurm_ablations.sh) for running ablation studies and cluster-based experiments.
• Baselines/Comparative Pipelines: Multiple baseline directories under /data/predictions (e.g., Baseline_Deepl, Baseline_Google, Mask&Translate, etc.) showing experimental comparisons.
Architectural Patterns and Technologies
• Layered Architecture: Separate modules for data ingestion/preprocessing, entity retrieval, knowledge integration, and translation.
• Config Driven Execution: The system leverages Hydra to manage configurations robustly.
• Containerization & CI: The presence of GitHub workflows (in .github/workflows) and uv as a package manager indicate a structured deployment and testing mechanism.
• Experimental Design: Multiple baselines are maintained, and evaluation scripts and notebooks facilitate comparative analysis.