Applying NL API in a practical case


Userlevel 1
Badge +1

Six months after the launch of our NL API and many subsequent industry- or use case-specific extensions, it would be a timely opportunity to take stock of the situation on how these API can simplify the development of NL based applications, and address questions I received from the broad community of software developers.

How to Think About NLP APIs

Let’s begin addressing the most common challenge developers with no language processing experience face on how to think in terms of NLP APIs in general. If you have been asked to build software that requires an understanding of text, simply think of this as a design pattern, or real-time inference, in which your NLP API is deployed like a microservice.

To illustrate how this works in simple terms, imagine you want to develop an email categorization engine.

When an email is delivered to the target account, your application needs to:

  • extract the text and maybe other metadata (e.g. the sender, the level of urgency, etc…);
  • query an NLP API with the plain text of the email and/or its attachments;
  • receive the data from the API in a structured format such as a JSON file;
    • Note: the richness and specificity of the data returned by the API is extremely critical for (amount and complexity of) the code required to complete the task.
  • leverage this data (and other extracted metadata) in the business rules you write into the code to either assign the email to a specific category or route it to the specific subject matter expert (SME).

The Value of NLP APIs

In this flow, the NLP model, made accessible through the API, interacts with your application just like any other web API. You can consider your NLP API as a simple function which accepts a text input and returns data in a structured format describing the content of the email.

The main advantages of microservices apply here. NLP APIs are updated and maintained by organizations like expert.ai, which can be done much more easily when they’re deployed independently from the application. The NLP models made accessible through the APIs are also typically the work of experts. Decoupling your query API from the rest of your application allows you to leverage their expertise in an effective way while you optimize the core code of the application.

Not All NLP APIs Are the Same

Now that you understand how to leverage NLP APIs in your code, keep in mind that not all NL APIs are the same. Their output and depth of analysis can vary significantly, as can their richness of the data and specificity (how much the data returned addresses the needs of a specific use case).  All of these factors can improve the quality of the code and performance of the application while shortening the development time. These are the main reasons why we made expert.ai NL API available last summer.

Why expert.ai NL API

Our symbolic AI core technology offers a set of unique features, including full natural language understanding (NLU) which is the ability to understand the meaning of words in context, which results in a unique, deep and rich level of text analysis. By making these powerful capabilities available through the API, they are now accessible to software developers. In addition, expert.ai has made available extensions of the API providing industry specific data and tools designed to enable developers to create customized APIs. But before we get too far, in the next post, I will talk about why data richness is so important for developers, even if they are new to NLP.


0 replies

Be the first to reply!

Reply