
Francisco Javier Rodriguez Arias walks through building Wolfram|Alpha in Spanish, from refactoring the English-centric engine to handle grammar and number formatting, to shipping the web app and mobile versions with image recognition. The team is still translating millions of data points.
Chapters
Hello, my name is Francisco Javier Rodriguez Arias. I'm manager in the Lima office. I'm manager of the project Wolfram Alpha Spanish. I have uploaded also this notebook to the handout. You can follow the presentation. So this talk is about the Wolfram Alpha Spanish project. This is the latest release of the localization project and we talk about motivation, challenge and its current state. This is a brief outline of the presentation. We talk about workflow Alpha, then the Spanish around the world. This project challenges we have had the apps are available and examples of you. So wordframe Alpha is a unique system for computing answers. I guess everybody knows already wordfrang language and Wolfram Alpha here. So I will be briefing this part. It was released now, many years ago, since 2009 and is the most popular Wolfram product. The goal is trying to make the world's knowledge computable. So we know that it has a natural language querying interface. You can ask query in English, in natural language, initially in English and now we are expanding that, right? It has a systematic query data, many trillions of pieces of data in thousands of domains. Numerical, textual, binary, etc. And most of the textual data is always in English. Or now we are adding more data in different languages. And another thing that we have is that most of the sources were English only. And in many cases very use central in the sense of the data for flights. For some data that have more information. It's a computational intelligence because we have a domain expertise built into the system and many systems, many algorithms and methods that try to solve the problems and try to derive interesting information from the data that we have. And also it has a dynamic presentation of this computational knowledge. It generates and formats the results, makes summaries and visualizations. And sometimes they might have a English language or US oriented design or convention. Now let's talk a bit about Spanish around the world. This is probably one of the main motivations to do this project. There are almost 600 million of Spanish speakers around the world. It is the second most spoken native language after Mandarin. It means that people born in the Spanish language environment is the second most largest population, but actually the fourth largest by total speakers, meaning people that speaks English and in the second language are more than the total Spanish speakers anyways. The official language in 17 countries, national de facto in four. That means that it's not official in this country, but basically they only speak Spanish and there are a few other small countries where there is a large majority speaking, right? And then we use a source for this, the Espanol Enel Mundo Los Miro Intitres it was recently released and the Wolfram Alpha knowledge base, of course, here is a map on how we have speakers around the world, because not only in America, in the large continent of America there are speakers of Spanish, but also in many other countries we have a significant population of speakers, most of the cases of second language or immigrants, of course. And if we see that as a density, in particular, we can see this large density in all most American countries and of course in Spain and with a very significant density in some US states and some African countries where the Spanish empire had some presence. Now let's talk about the localization project itself. We wanted to make the knowledge accessible internationally and this first release that we have done now in a couple of languages is all the math related features. In particular, we have already released Japanese in June 2018 and Spanish in June 2022. This project is built on top of the English workflow Alpha and the localization team consists basically developers, translators, testers, data creators, and we have tried to have people who speak the language in a native way. So for example, the Spanish project has been mainly developed by the team we have here in Lima. And we have also people in the Wolfram Alpha project in general involved in different degrees. So we have the main page workflowpha.com you can start with ES or also with WW and change the the language. And we have also a nice example page where you can browse for all the different domains that we are covering in the Spanish website. As I said, basically we have done all the math stuff and we are expanding. We're expanding to the physics problems, to the chemistry. We want to expand soon. There is a focus of course, in the step by step solutions for all these different domains. Which challenge we have. There is a large amount of data to translate, not only for the output, but also for the input. So we should be aware that translating Wolfram Alpha doesn't mean translating is not a simple translation task, it's a refactoring task. So it's not as simple as say, okay, let's take a sentence in English and translate that to Spanish. Because we need to understand how how people might enter an input. We need to understand how we should output this so that it can be understood properly by someone speaking only Spanish. And there are many components in the system that need to be translated. So we have the components for the input, the components for the output, and also the content. And the answers are computed dynamically so that we need to consider also the logic for each language particular For Spanish case. And as I said, there are millions of names in Alpha we have this called grammar rules that are how we understand the input of the user, these millions of tokens that we have around the Alpha project. So one of these main challenges we had was about the sentence building because initially the project workflow Alpha had embed or hard coded all these strings in the code and we need to, they assume, let's say, the English order of the words, the English order of the sentences. So we need to start refactoring all this. Also something very important is the grammatical agreement between the words. Disagreement is always important in Spanish. So if you have a noun in plural, the adjective has to be in plural too. If the adjective, if the noun is feminine, the adjective needs to be feminine too. And that's something that, for example, in English when you build sentences, you don't need to consider. Also when you use definite or indefinite articles might be different in different languages and the way you enter the numbers. So all this needed to a lot of work in the refactoring the base code of Workfront Alpha. Another important issue we had in Spanish was the fact that the decimal separator in most Spanish countries is the comma and not the point. Actually in most European languages it's the comma, the decimal separator. Basically, only in English it's the point. And right now in some countries, like Mexico, for example, the point is most used. And that's because it's very close to the US Here, for example, in Peru also the point is widely used as decimal separator, even when I think officially is the comma. But you can see newspapers using the comma as decimal separator, other newspapers using point asparator. But what means that? That we need to understand any way that a user inputs a number, we need to be able to figure out what they are trying to ask. So another issue is how we format times. For example, the dates and time depend on more than the language, also on the place, right? So we need to be aware of the conventions for each country, if they use 24 hours or 12 hour style, for example, etc. And the time zone and how to express properly the date. So even for simple questions like korais, what I miss it, we need to be aware on how to display that properly. Also formatting the numbers needs to be aware of the language. And that's something that we take into account in this localization project. So for example, in English and most European languages also we use blocks of three digits and every three Digits we have a name for the number. In other languages it's every four digits. But in Spanish also we have for example this that we are using the long scale so that actually we jump from million, which is to beyond, which is the next one with a name which would be the equivalent to trillion in English. So all this needs to be account when displaying the numbers. So for example, if we ask for the Spain population, we have these different answers in English, Japanese, Spanish. So how we might display that it's different, as you can see in Japanese, for example, we display four digits for this case because the blocks they have in English we use these 47. In Spanish we would say 47,5 million Personas. So all this needs to be taken into account when building all these displays for alpha. Another important challenge we had in Spanish was the one character words. So in Spanish letters as A, E, O, U, Y have their own meaning as well. And not only their own meaning, but they are actually very common. So and one big problem with that is that these letters are also very common as part of math expressions. So all our grammar and tokenizer rules need to adapt to this and we have lots of heuristics to try to figure out if they refer to part of the math expression or part of the sentence. Like for example, if we ask for resolver equismas igual tres y equis menosigrega igualo, that is solve x plus y equal 3 and x minus y equal 8 and well, we have a small screenshot here. We can actually go to the website to check how it works and. Very quick representation to show. So this solves properly the equation makes the difference between its it's two equations that need to be solved and displace the result. So that's something that was actually hard to do in the sense that we needed to figure out all these cases where the, where the Y is an and or the y is a variable. Also for cases like truth table, like truth table for all these cases where the O and the Y here are actually the operators for and and or there are some cases where are kind of on the edge of this problem, like for example Solution I ds, where we can understand when the preposition is para instead of the preposition because here we can also ask for the solution for ax plus three equals ten. So that's also a very valid equation in Spanish. So in this case we recommend to the user to use a different preposition or to rephrase the question right. Now let's talk about the new Releases that we have for Alpha, we have released an iOS and Android apps that now support Spanish. This app is free to download. Of course, it requires the Pro subscription to access the Pro features. And the Pro features include the step by step and the machine put math OCR resolution. Here we have the links. Also you can point with your cell phones to the QRS to get the application. And let's see how this app works. So we have the icon for the app. This small. Video looks fine. So we have also developed a special keyword for Spanish that includes the ene and the accented words. And the idea is that we can use this keyword to enter the input. And the app works natively in the device, presents all the outputs from the website and we can go also to the step by step solution and go to the next step, next step so that we can check all these. Steps. It's a bit slow. And the idea is that we will show all this step by step in Spanish. Now it's fully translated, all these math inputs and users can interact with this. You need a Pro subscription to access the step by step solutions. But to access the applications you'll need that. So you can start using the Warframe Alpha Neo app in iPhone or in Android. Actually the Android Spanish version was released a couple of weeks ago, so it's recent release. Also something very nice that we have now is the introduction of the image inputs. So we can take a picture, for example here from the board. I wrote this with my ugly handwriting. Then I take the picture with the app. Now I have to select what part of the picture I want to interpret. So you can have lots of equations around and select which one you want to interpret. Press analysar and it starts analyzing the image and interprets the right integral. And that's it. You send the input to Alpha and and you can start playing with the step by step solution or looking at the plots. So we display the integral and start displaying all these steps to get the right solution. And all these steps are explained in Spanish of course, so that any student or anyone interested on this can learn how to do this with the different methods we provide. And in this way all is now accessible in Spanish. All this math content is accessible in Spanish. As I said before, we are expanding this also for the physics and chemistry domains. So all this is in continuous development. All the Spanish website. So it's not fully translated from Alpha to Spanish. There are millions of data points that we need to translate for regular domains, data domains. But that's an ongoing work. And we have also this is going to be released very soon. The examples browsing for Spanish right now the example have not been released, but expect for that in the next couple of next weeks. And you can again use this to browse examples. To browse output of these examples. Well, we have many examples to check. So there are many types of inputs that you can have. Like ask for the positions of each digit in this the place value for these inputs. Or you can write a very large number and it will be interpreted spell out this number. As I said, you can use commas for the input. For the decimal values, it will be properly interpreted. Ask for integrals request for example, the third digit of square PI. Ask statistics or ask about functions, the type of function, if this function is or not even function. Ask for periods, etc. So there are plenty domains that we are covering statistics. Again, enter a sequence of numbers and you will leave the answer. As for games also, for example Yanc. This is the name we use, for example, in Peru. There are many names for this game, which is the see source paper or rock. And we try to. That's part of adapting all these domains. Also for alpha in Spanish, because there is a large for some domains, there are many names that you can find for the same thing, right? So we need to incorporate that as possible inputs. You can see also in the alternate names all these names that is known in different countries. For example, a few of them I will not understand in other Spanish countries. Ask for logic or sets. And also something else that we have incorporated in Spanish is the 2D input. So you can enter the math equations in 2D. Let's try to go up into this. So the 2D input allows you to enter the equation in the right mathematical notation. So to avoid ambiguity. For example, if I enter this power 2 without the parenthesis or without these blocks, maybe it interprets the power 2 for only the 1 instead of of the M minus 1. And that works fine also in Spanish. So this is also available in the in the web. And I think this is my hassle for this. Now I want to thank all the Wolfram Alpha localization team and we are located in Lima. We have also many people working from Champaign for the localization team. And there are many around the world. So we have people working from Eastern Europe, from Japan, from different places. And of course you can contact the Spanish team in the contact us. Link that you can find in word for alpha. So that's all for the presentation. And let's see if there are some questions. Yes. Is there Any timeline on bringing this to more languages? Languages that share close grammatical structure with Spanish, like French, be easier to implement, right? There is no definite timeline right now. We are working on many other languages right now. That's true, but they are still in progress. And yes, you are right. Languages with closer structure to Spanish. We are now trying to use some also automated tools to speed up the translation project for these languages. Because given that the structure is similar, we don't need to work on all this challenge that we have already worked for Spanish. Like for example, changing the order of the sentences, right? So that's not that far, for example for Portuguese or French. So we are taking advantage of this work for speeding up the translation for these languages. So yes, we are working on French on Portuguese, but we don't have any timeline right now, so I cannot say when they will be released. Okay, then I think we can finish. Thanks all for attending and hope you enjoy the OR from Alpha Spanish website you can enter. Oh let me show also how you can switch between languages in case you enter to the website. So here in the website you can change the language here at the right top between English, Spanish and Japanese or leave that automatic. Automatic means that it will use your browser settings. So my browser for example is in Spanish, so that whenever you enter, if I enter here without any cookies set before it will enter, it will show up the Spanish website instead of the English one. And anyway, I can always change the language here. And of course all the mass input is localize it and explain in Spanish. So I think that's all for now. Thanks to all for attending. Thanks to the Wolfram Alpha team also for making all this possible.
More from Guy

Cheryl Strauss Einhorn | The Human Edge: Smarter Decisions in the Age of AI | Talks at Google

Rachel Glennerster | Innovation and the Center for Global Development | Talks at Google

Rebecca Winthrop | Rethinking the Purpose of Education in the Age of AI | Talks at Google

Dr. Robert Wachter | A Giant Leap: How AI Is Transforming Healthcare... | Talks at Google






