| 
   
Article Details
Common Sense Advisory Blogs
Translation Exchange Makes Internationalization Easy
Posted by Arle Lommel on July 20, 2016  in the following blogs: Technology, Translation and Localization
Pages | |


Code internationalization requires strict discipline, and even the experts sometimes get things wrong. Programmers want to write code like the following:

echo(“$player_name hit the $monster_name with a $weapon_name and $player_pronoun gained an experience point”);

This example works well in languages like English or Chinese, but fails miserably for ones with complex grammars like German, Russian, or Hungarian, where much of the text cannot be translated without knowing the content of the variables in it. Embedded linguistic assumptions often have unexpected consequences that require re-engineering. The paths to failure are numerous and the consequences of even minor lapses can run to the hundreds or thousands of dollars.

Even though internationalization best practices are intended to make translation easier, they actually aren’t very friendly for translators either. They face lines and lines of strings with no context and nothing to guide them in how to translate them. On top of that, they often encounter constructs that simply don’t work in their language and that require awkward workarounds.

We recently spoke with Michael Berkovich and Merle Tenney at Translation Exchange about this problem. They developed a cross-platform and cross-language way to allow programmers to include text directly in their code – where it logically belongs – rather than externalize it. Their nine SDKs cover most major development frameworks and they support over 20 integrations with websites and content management systems. Although their technology offering covers many aspects of code development and translation, one in particular stood out because it has the potential to transform how programmers deal with internationalization:

Rather than externalizing strings, they use a method, tr(), that they wrap around localizable content anywhere in their code. This practice lets them leave text in situ and greatly reduces the need for external resources files. For example, in a hybrid Ruby on Rails/HTML application, the code might appear like the following:

<h2><%= tr("Localization is worth billions of dollars per year”) %></h2>

This method dynamically retrieves the translations for the string in question without the need to call on a separate file. Translations are cached on the developer’s own servers – rather than on a third-party proxy server – and dynamically inserted based on the language selection, making it easy to add and update languages. Because tr() eliminates the need for extracting strings and sending them off in a batch for localization, it reduces process bottlenecks: Translation Exchange argues that its approach essentially eliminates the numerous small export-translate-import-test cycles that can easily bog down Agile approaches.

For cases where static strings aren’t enough, tr() can be extended with Translation Markup Language (TML) to add support for linguistic complexity. Using it allows programmers to focus on writing functional code. For example, the following screen shot shows how a Ruby programmer might handle building dynamic text:

Creating conditional text in Ruby

Creating Conditional Text in Ruby
Source: Translation Exchange

The 13 lines of code in highlighted portion handle the linguistic complexities of only one language – English – and would need to be rewritten for any other ones, thus turning localization into a programming task on top of translation. By contrast, the shorter example below uses tr() to hide that linguistic complexity and TML rules enable it to handle multiple languages without rewriting.



TML and tr() Simplify Dynamic Text
Source: Translation Exchange

Anything that helps programmers do more without less effort is a good thing. Translation Exchange’s offerings do that, and simplify cross-platform development because they allow developers for websites, online applications, and mobile apps to approach localization in a consistent and simple manner. They include tools to allow translators to work in context and to update content in live applications, providing them with a more natural environment in which to work. Although the company is just starting out, its technology offering seems to hit a nice mid-point between traditional and cumbersome internationalization methods and the totally hands-off options provided by proxy server-based translation services.

 

Post a Comment

Name
Email address :(Your Email Address Will Not Be Displayed)
URL

Your Comments
Enter Code given below :    

Related Research
The Application Developer's Guide to Global Primetime
“Hello, World” as an Internationalization Wake-up Call
Using Proxy Servers to Make Website Globalization Easier
Link To This Page

Bookmark this page using the following link:http://www.commonsenseadvisory.com/Default.aspx?Contenttype=ArticleDetAD&tabID=63&Aid=36551&moduleId=390

Do you have a website? You can place a link to this page by copying and pasting the code below.
Back
Keywords: Internationalization, Localization, Translation technologies, Web globalization

  
Refine Your Search
  Date
Skip Navigation Links.
Skip Navigation Links.




 
 
Terms of Use | Privacy Statement | Contact Us
Copyright © 2017 Common Sense Advisory, Inc. All Rights Reserved.