This is a set of Python tools developed to handle a specific headache: moving translation data between Excel and XLIFF when standard TMS (Translation Management System) workflows break down.
I built this because we had to switch TMS platforms mid-project and couldn't export our progress as XLIFFs. The only thing we had was a partially translated Excel file, so I needed a way to "reconstruct" that into an XLIFF to avoid losing weeks of work.
- Merged XLIFF Generation: You give it a Source Excel and a Target Excel (with your current translations), and it spits out a merged XLIFF 1.2 file.
- Hash-based Verification: Every segment gets an MD5 hash of the source text. If the source changes later, the tool knows, preventing you from accidentally injecting translations into the wrong cells.
- Target Excel Generation: Allows you to generate a finalized Target Excel file by injecting an updated/localized XLIFF back into the original Source Excel structure.
- Customizable Extraction:
- Option to ignore hidden cells to avoid translating internal notes or metadata.
- Option to leave target segments blank if they are identical to the source.
To launch the application, run the following command from your terminal:
python main.py
- Open the tool and select the Source and Target languages.
- Configure your settings (Hidden cells and Target string preferences).
- Click on Export Excel -> XLIFF.
- Select your Source Excel file.
- Select your Target Excel (the one containing the translations to be rescued).
- Choose a name for your new
.xlifffile and wait for the process to complete.
- Click on Import XLIFF -> Excel.
- Select the Original Source Excel (used to maintain structure and formatting).
- Select the localized XLIFF (this must be the one previously generated by the tool or an updated version of it).
- Choose a name for your final Target
.xlsx.. - Wait for the tool to finish the injection process.
- How to add more languages?
- You can customize the available languages by editing the
languages.jsonfile located in the/datafolder. Simply add the corresponding ISO language code and language name to the list.
- You can customize the available languages by editing the
Python 3.11+
Libraries: openpyxl for Excel, lxml for XML/XLIFF parsing, and tkinter for the interface.
