How to Use FlexTrans for Machine Translation
FlexTrans is a powerful, rule-based machine translation system developed by SIL, a global faith-based nonprofit committed to overcoming linguistic barriers and promoting community flourishing. SIL’s comprehensive areas of work include translation, training, technology development, and advocacy, impacting over 855 million people across 1,300 language communities. FlexTrans leverages the linguistic richness of FLEx (FieldWorks Language Explorer) to enable precise translations, helping people thrive using their most valued languages.
In this article, we will guide you through the process of using FlexTrans for machine translation. Whether you are new to FlexTrans or looking to refine your skills, this step-by-step guide will help you effectively use this tool to translate texts between different languages.
Getting Started with FlexTrans
1. Preparatory Steps
1.1 Set up Your Projects
- Enable Project Sharing:
- Open your source and target FLEx projects.
- Go to
File > Project Management > FieldWorks Project Properties
. - Click the
Sharing
tab and checkShare project contents with programs on this computer
.
- Add a Custom Field:
- In your source FLEx project, navigate to the Lexicon area.
- Go to
Tools > Configure > Custom Fields
and clickAdd
. - Set
Custom Field Name
toTarget Equivalent
,Location
toSense
, andType
toSingle-line Text
.
- Create a Language Pair Folder:
- Go to the
WorkProjects
subfolder in the installation folder (typicallyDocuments\\\\FLExTrans
). - Copy and rename the
TemplateProject
folder to match your language pair (e.g.,French-Spanish
).
- Go to the
- Configure FlexTools:
- Start FlexTools by navigating to your project folder and double-clicking
FlexTools.vbs
. - Select your source database and adjust settings using
FLExTrans > Settings
from the menu.
- Start FlexTools by navigating to your project folder and double-clicking
1.2 Choose Your Parser for Synthesis
FlexTrans supports two parsing models: XAmple and HermitCrab. By default, XAmple is used. To use HermitCrab:
- Enable HermitCrab in the
Settings Tool
by selectingFLExTrans > Settings
and settingUse HermitCrab synthesis
toYes
.
1.3 Prepare Your Data
Ensure the following in your FLEx projects:
- Unique glosses for affixes.
- No spaces in glosses.
- Properly defined Parts of Speech with names and abbreviations.
- Names for all templates, slots, and affixes in templates.
1.4 Pre-populate Transfer Rules with Categories and Attributes
Use the Set Up Transfer Rule Categories and Attributes Tool
to automatically populate categories and attributes in your transfer rules file.
2. Basic Machine Translation Steps
2.1 Analyze the Source Text
- Create and Analyze Text:
- Create a new text in FLEx and paste some text.
- Analyze the text and divide each word into its morphemes.
- Accept the analysis of each word.
2.2 Link Senses
- Run Sense Linker Tool:
- Go to the
Sense Linker Tool
from theTools
tab and run the module. - Link each sense by checking the appropriate boxes or selecting from the drop-down list.
- Go to the
2.3 Write Transfer Rules
Modify existing transfer rules to handle specific translation needs. For example, to remove affixes from nouns:
- Open Transfer Rules File:
- Navigate to your project folder and open the
transfer_rules-Swedish.t1x
file in XMLmind XML Editor.
- Navigate to your project folder and open the
- Edit Rules:
- Change the rule pattern to match nouns and modify the output to exclude affixes.
2.4 Run FlexTrans Modules
- Run All Steps:
- In FlexTools, go to the
All Steps
tab and clickRun All
. - Check the results in the target FLEx project.
- In FlexTools, go to the
- Find specific how-to guides and videos for various FlexTrans tasks, such as handling inflectional variants and managing phrasal verbs.
For more detailed instructions, tutorials, and videos, please refer to the official FLExTrans User Documentation or the provided step-by-step sections.
By following these steps and utilizing the provided tools, you can effectively use FlexTrans for accurate and efficient machine translation, contributing to the flourishing of language communities worldwide.