Text process and translate with Language Services

Rating & reviews (0 reviews)
Study notes

Language Service

  • Language detection
    Works with documents (max 5210 characters) and single phrases. Max 1000 items(ids) per collections.
    For mixed languages => return predominantlanguage.
    If not able to provide response return NaN or Not a Number.
  • Key phrase extraction
    Process of evaluating the text of a document, or documents, and then identifying the main points around the context of the document
    Max 5120 characters. Bigger document, better results.
  • Sentiment analysis
    Quantifying positive / negative "message"
    Return overall document sentiment and individual sentence sentiment for each document submitted to the service.
    Overall document sentiment is based on sentences:
    • All sentences are neutral, the overall sentiment is neutral.
    • Sentence classifications include only positive and neutral, the overall sentiment is positive.
    • Sentence classifications include only negative and neutral, the overall sentiment is negative.
    • Sentence classifications include positive and negative, the overall sentiment is mixed.
  • Named entity recognition
    Recognize entities mentioned in text (people, locations, time periods, organizations, etc)
    • Person
    • Location
    • DateTime
    • Organization
    • Address
    • Email
    • URL
  • Entity linking
    Entities reference links to Wikipedia articles.
    Possibly, the same name might be applicable to more than one entity.
    Wikipedia provides the knowledge base for the Text Analytics service. Specific article links are determined based on entity context within the text.
Translator Service

  • Language detection
    Compared with Language detection from Language service,this return if translation and transliteration is supported.
    Return example.
    "isTranslationSupported": true,
    "isTransliterationSupported": true,
    "language": "ja",
    "score": 1.0
  • Translation and One-to-many translation
    Specifying a single from parameterto indicate the source language,and one or more to parameters to specify the languages into which you want the text translated
    {"text": "Hello", "to": "en"},
    {"text": "Bonjour", "to": "fr"}
  • Script transliteration
    Converting text from its native script to an alternativescript.
    Translate to the same language but a different dialect.

  • Translation options
    Word alignment - spaces not always are used to separate words.
  • Sentence length - useful to know the length of a translation
  • Profanity filtering
    • NoAction: Profanities are translated along with the rest of the text.
    • Deleted: Profanities are omitted in the translation.
    • Marked: Profanities are indicated using the technique indicated in the profanityMarker parameter (if supplied).
Custom translations
Solution for businesses or industries in that have specific vocabularies of terms that require custom translation.
To solve this problem, you can create a custom model that maps your own sets of source and target terms for translation.
Use Azure Custom Translator Portal

Process is the same like Azure ML Designer. To create a custom model:
  1. Create a workspacelinked to your Translator resource
  2. Create a project
  3. Upload training data files
  4. Traina model
Your custom model is assigned a unique category Id, which you can specify in translate calls to your Translator resource by using the category parameter, causing translation to be performed by your custom model instead of the default model.

How to use any of above services:
  • Provision a resource (Language or Cognitive service)
  • Call it using Endpoint and Key, submit data using JSON to REST interface or using an SDK.

Hands-On - Analyze text, Login to view

Hands-On - Translate text, Login to view