0

As in question - I'm wondering if there is a way to find word/phrase equivalent when I have two translated sentences. For example:

  • No. - Me molesta.
  • No. - But it bothers me.

Is there an algorithm that would tell me molesta in Spanish is bothers in English? I have more sentences like that and I would like to get list of possible translations of word molesta for example. I know it is very general question but I don't know where I should search solution. I would do it in Kotlin. Thanks in advance.

Oktawian
  • 334
  • 1
  • 2
  • 16
  • Are you currently using any type of translation service? – cutiko Apr 01 '21 at 14:31
  • Syntax in different languages might be very different also one word can become multiple during translation. I know there is a project trying something similar by analizing the official paper of the EU-parlament (They want to train a automated translator). – MrSmith42 Apr 01 '21 at 14:58
  • Why not simply download the dict.cc database and use it as lookup? – MrSmith42 Apr 01 '21 at 14:58

1 Answers1

2

There are a few libraries for word alignment:

If you are anyway starting from the original text only and using machine translation, you can use the includeAlignment option of the Microsoft Translator API or wrap each word in HTML tags, as described in this answer. All major machine translation APIs support HTML translation. However, we at ModelFront have noticed that including HTML tags can hurt the translation quality.

You could also look at libraries for term extraction:

Adam Bittlingmayer
  • 1,169
  • 9
  • 22