You are currently viewing Shiprocket Enters Multilingual Market at Kingdom of Saudi Arabia

Shiprocket Enters Multilingual Market at Kingdom of Saudi Arabia

  • By Ruchi Parijat
  • Post category:Engineering
  • Reading time:11 mins read

Shiprocket- The Indian startup, with our massive success, we wanted to make our presence in other parts of the world. We were already getting demand for SR in other countries for quite a while from our sellers who do business in offshore countries apart from India. So during some brainstorming sessions with Shiprocketers, we were discussing how to expand our wings globally.  We were thinking about how our application might do in a foreign market. We might be asked about this in many different ways. Eventually, a few questions came to us like, “Should we extend the same product or create a new one for other languages? What’s it going to take to get our product ready for the international market? “

We faced this exact situation when we started expanding our business in Saudi Arabia,with our product “Global”.  The management part of our team was striving to figure out the problem statements i.e., “What’s it going to take to get our product ready for the Arabic market?” and, “How much will it cost to prepare our product for other languages and to expand on it ?” Eventually, we will distribute our applications in Arabic markets but where do we start? and then begins our journey for internationalisation.

What is locale?

Before we begin, let’s understand what the locale is.  A locale describes a group of target users. It almost always includes a physical location, a language, and any associated preferences those users may have. 

Locales help us distinguish between different groups, like users in France and users in China. In our case, users are the citizens of the Kingdom of Saudi Arabia. 

The Challenges We Faced

In the scenario below, our customer Adeeba is a seller originally from the Kingdom of Saudi Arabia but lives in India. She’s been using our product to ship orders to her customers for quite some time now. However, she is now keen to expand her business to Saudi.

For her Indian customers, Adeeba is using our product in English. However, now that she plans to sell in Saudi, her offshore team’s experience with the initial translation is less than ideal. As a result, she goes in to rate the translation, and is then offered the opportunity, she gets to experience our portal in Arabic. 

Now, she and her team in Saudi is getting a more personalised experience for their business in Saudi. In fact, she is our happy user. Her team is able to navigate and explore our product in their native language, with a high sense of confidence. But, just to make Adeeba, and customers like her, “happy users”, our team went through a lot to make this product a customer success. 

Linguistic barrier

With physical products, people understand that there’s more than just translating the language to consider. To relate this to development, there are several engineering and design changes that you will need to make to your product behind the scenes before it will be ready for a foreign market. 

Alignment of languages 

Languages like Arabic are read from the right side and not the left. Some systems may need to be reworked to accommodate foreign money, foreign measurements, and foreign formats. All of these points are considered because they might break the UI, ruining the user experience. Arabic requires the layout of whole pages to be reversed from left-alignment to right-alignment. 

For instance, here’s the Dashboard of Shiprocket in English:

And then, it’s translated counterpart in Arabic:

The alignment is totally opposite of both the above pages so much that for a split second they appear to be two different websites! But this should give some perspective on the challenges our UI Engineers faced during the process.

Singular and Plurals

In Arabic, there are actually six different possible plural forms, but how would you need to structure your logic? How is that logic different for other products? If you need more information on complex plurals, then you have to code your own solution with the help of a language specialist. You can even see the rules you would want to implement in your logic.

Grammar Complications

I want to give you a couple of brief examples to demonstrate what kinds of complications can arise. 

  • Firstly, there’s ambiguity. If the word edit is used in English on a button in multiple locations or menus, perhaps, the question could arise for the translator, is that a verb or a noun? Is it the action of editing like in, “Would you like to edit this video?” Or is that referring to a specific change that was made, like in, “The most recent edit was made 10 minutes ago.” You can see that when these are used in full sentences, the context is very obvious. 
  • Secondly, as an example of contexts that don’t exist in English, there are concepts like grammatical gender and noun cases. In some languages, a gender is assigned to all nouns. When talking about people, that gender makes sense. But, for inanimate objects, this concept of gender affects the way the word is formed and how it behaves. For the most part, the only practical effect it has is on the surrounding words used to introduce or describe that term. 

Going back to the story of Adeeba, moving to language solely wasn’t sufficient. Her Saudi team uses the local currency i.e. Saudi riyal. Later on, she also told us that pincode isn’t mandatory there. So, there were multiple changes done in order to be compliant as per requirements. 

  1. Currency : It is crucial to be compliant in an aspect where we are supposed to accept payments. For product based companies like us, at Shiprocket, selection of the right payment partner was an important decision. Our payment portal acts as the switch between the various entities in the payment network. This allows funds to pass securely between the customer and the merchant. 
  1. Timezone : This is one of the inevitable challenges that our team experienced while working with companies way outside their time zones. The only solution to this challenge is seeking the cooperation of a company that sits conveniently with you in the same time zone as your locality. But, that’s not how it works when you are into logistics. You cannot expect their demands to be covered in a different timezone. Hence, our Tech-Rockstars came up with an initiative of the moment library. It converts the time, sent by the backend,  according to the required timezone. Here, in our case, we converted to AST. 
  1. Pincode: Here’s a fun fact.  Pincode isn’t mandatory in the Kingdom of Saudi Arabia. Shocked, right? So was our team. Hence, the mandatory pincode part was changed to mandatory city part. As the entire workflow is dependent on city flow, our technical team created the system taking that in consideration. 

Potential Solutions

Within many applications, certain messages may appear in a number of different locations. This might be a labeled button, an error message, or it might be a helpful reminder to our users. One potential solution is to use string interpolation. However, the use of string interpolation to add a word to a string, perhaps a user name can complicate things since you would need multiple versions of the same interpolated string to accommodate the different genders of your user. 

For instance, in Spanish, “The new car” can be translated as “El nuevo coche,” but “The new table” could be translated as “La nueva mesa.”

“El” and “la” both mean “the,” but since coche is masculine, and mesa is feminine, they use different forms for the word “the.” It’s the same with nuevo and nueva. It’s the same word, but in its masculine and feminine forms. 

So the next decision led us to translation memory. Unfortunately, at the time, the system we were already invested in using simply wasn’t robust enough to help us translate that amount of text efficiently. Many of these sorts of complications can be avoided up front if you’re developing an application to be localized from the very beginning. 

But if you’re working to localize an existing product, be aware that there will probably be some cases where you’ll need to rework a few things to help make translation easier. Often, the best way to work through these is by getting input from your translators, or localization consultants, to understand how your current product is getting in the way of a good translation, and how you can rework things to provide the best experience for all of your users, regardless of their language.

Implementation 

Here’s how we implemented locale on our system step by step. 

Get an Expert for Translations

There are a whole variety of internationalisation and localisation specialists who are available to help you through every step of the process. They aren’t just translators. There are consultants who can walk you through the whole process or other specialists. 

So, we hired a specialist to assess our services, like how well prepared our platform was for internationalisation or analysing how effective our localisation processes are. They worked alongside our development team to internationalise our code. 

Define Translation Strings

  • You can’t use the same string in two different contexts. Any extra work in translation that might be created by having multiple copies of a string can be very quickly dealt with by making use of a proper translation memory system.
  • You need duplication if the same phrase occurs in two different contexts, that phrase will likely be translated two different ways as we have seen previously. And to add to that complication, some of those contexts that you’ll need to keep separate may not even exist in some specific native language.
  • So we defined our translation strings for the project. Predominantly, there are two approaches for this. 

You can define your translation strings in a JSON file under the resources/lang directory. For instance, here’s how you can create an en.json file that manages all translations pertaining to the English language. Consequently, you can create an es.json file that does the same for the Saudi language. 


Alternatively, you may also store these language strings in different files under the resources/lang directory. Consider the below snippet where we have created two directories pertaining to each language – en and es under the resources/lang directory. 

Inside each of these directories, we manage our language strings using a messages.php file as shown below. 

Configuring the locale

Once you’re through with your language strings, you need to define a default locale in the config file. You can also do it on the fly using the setLocale method. For a fallback scenario where you can’t find a translation to a given string, you can set a fallback language that can be used instead. 

Retrieving the translations

Next, you need to retrieve these translation strings wherever you wish to use them. For this purpose, you can use the _helper function. Pass the file that contains the key and the key itself to the function using “dot” syntax. 

Translation strings  can be retrieved from the language files using the _helper function.

Here’s how you can replace the parameters placeholders in your translation strings:

'welcome' => 'Welcome, :name',
__('messages.welcome', ['name' => 'John']);

You can use the pipe (|) symbol to specify plurals against a translation.
Ex:

'apples' => 'There is one apple|There are many apples'

Once you’ve defined a translation string with options for pluralisation, you can use the trans_choice function to retrieve the line for a given “count”. 

Test Rigorously 

  • With the reports received from the data team, it was derived that translation isn’t always very effective. Lastly, there are QA and testing services conducted from the user’s perspective to overcome this challenge. They took an in-depth look at the product and the translation to make sure that it functions properly after localisation and that it feels appropriate to the target market. 
  • In many cases, they save our time and assure a level of quality for the final localized product. The thorough testing of localization proved to be of great importance. It removed all and any unwanted friction in launching our product on time. 

Conclusion

With our implementation route, we safely navigated to the multilingual market at the Kingdom of Saudi Arabia. It was a challenging process, but all the necessary steps we took helped us launch Shiprocket Global without any hurdles. 

Eventually this helped many more customers like Adeeba and we brought a simplified shipping experience to the E-commerce stores of Saudi.