Dec 4, 2012

Migrating memoQ segmentation rules to another language variant

As we work with memoQ, many of us optimize our segmentation rules bit by bit to improve the results when importing documents to translate or align. But what do you do when you've worked hard setting up good rules for your usual target language but one day find a need to apply them to another variant of the language? Take all the rules you've spent months fine-tuning for "German" and apply then to "German (Austria)", for example?

The current version of memoQ offers no obvious way to do this. But it's not that hard to "cheat" and save many hours of tedious and unnecessary work.

First, find the ruleset you want to reuse. Segmentation rules can be accessed in three ways:
  • Tools > Resource Console... > Segmentation rules > [language in the drop-down menu]
  • Tools > Options > Default resources> Segmentation rules > [language in the drop-down menu]
  • Project home > Settings > Segmentation rules
Click Export and save the MQRES file somewhere you can find it.

The segmentation rule sets are named like this: <language-variant>#NameOfRuleset.mqres

So for German, for example: ger#MyRuleset.mqres, ger-DE#MyRuleset.mqres, ger-AT#MyRuleset.mqres, etc.

Rename the ruleset appropriately, then open it in Notepad or another text editor:

Then adapt the information in the part marked red here:

Change the text between the language tags particularly. The final result will be something like this:

Save the file. Then go back to the segmentation rules in memoQ in one of the three places listed above.

Click Import new and select your file that you edited.

Make whatever changes you like to the name and description. Click OK.

That’s all. If for some reason you forget to change the language codes in the file, you will get an error message (here I did that by choosing my original file for generic German and tried to import it to Austrian German):

This is not very helpful; it would be much better for memoQ to indicate that the language settings are wrong and perhaps offer to change them. But maybe that's on the Kilgray Roadmap for another day ;-)

No comments:

Post a Comment

Notice to spammers: your locations are being traced and fed to the recreational target list for my new line of chemical weapon drones :-)