The SOS Card Project

Converting of existing bilingual texts into TMX files

Step 1: Prepare a TAB separated (or CSV) file containing the translation text

Using OpenOffice

Create a new OpenOffice Calc document (or use any other Spreadsheet file software) and copy the source text in the first column, the translated text in the second column. The entries can (should) be full sentences.

1 Guten Tag! 你好!
2 Guten Tag! 你们好!
3 Auf Wiedersehen! 再见!
4 Mit freundlichen Grüßen 祝您工作顺利!

Use Save as… and save as a Comma Separated File Text CSV (.csv).

In the dialogue, choose charset = UTF-8, field separator = , and text separator =

Filename here: de-zh.csv (for German-Chinese)

Using an editor

Simply create a two-column UTF-8 text file (no BOM!), TAB seperated. Save as .csv (not .txt!).

Step 2: Convert into .po

Use the translate-toolkit to convert the CSV file into a Portable Object file (.po). At the command prompt, enter:

csv2po --charset=utf-8 --duplicates=merge --columnorder=source,target --input=de-zh.csv  --output=de-zh.po

Double entries are merged (–duplicates=merge command), which, in our example, will remove the second possible translation for “Guten Tag!”, “你们好!”. However, this option is useful if you collect translations from “random” files which may contain a number of identical text.

More at

Step 3: Convert into .tmx

Use the translate-toolkit to convert the Portable Object file (.po) into a Translation Memory eXchange file (.tmx). At the command prompt, enter:

po2tmx --source-language=de-DE --language=zh-CN de-zh.po de-zh.tmx

For the languages, you have to state the name of the language and the country name in ISO codes, see Language Codes; here: de-DE stands for High German (de) spoken in Germany (DE) and zh-CN means Standard Chinese (zh) spoken in China mainland (CN). Other examples: de-CH = Swiss German; en-UK British English, fr-FR French of France.

Detailed information at

Step 4: Make it available in OmegaT

Move the newly generated TMX file in the /tm/ folder of your OmegaT project. This could be something like:


At the Linux command prompt, you can use:

mv de-zh.tmx ~/OmegaT-Projects/sos-card/tm/ 

to do that. A following

rm  de-zh.po

will delete (or remove) the temporary .po file.

You have to restart the project Project » Reload to make the new file available. Translations from the new TMX file will be shown in the “Fuzzy Matches” window (usually upper right window in OmegaT). Details can be found on the page (Re-)Using TMX files.

Step 5: Make it available for all

Please send your TMX file to ! This will help other translators in this project. Of course, you are welcome to use the TMX files for your own projects as well. As a subject line, you may simply write “TMX: source-language – target-language”, here for example: TMX de-DE - zh-CN

Up · Next