Beginner's Guide to Using the GhanaNLP API

Prince LarbiPrince Larbi
4 min read

My inspiration for this blog post? Well, since my first post on LinkedIn about a project I was working on using the GhanaNLP API, quite a few people have reached out to me about setting up and using the API services. I thought it would be great to create a series just for that.

What is GhanaNLP?

Ghana NLP is an impressive Open Source Initiative focused on advancing Natural Language Processing (NLP) for Ghanaian languages. It aims to tackle unique local challenges by creating tools and resources that enhance the understanding and processing of these languages.

The project includes a diverse team of researchers and developers who collaborate to produce datasets, models, and applications specifically designed for the linguistic needs of Ghana. Their work helps bridge the gap in language technology for underrepresented languages, promoting better communication and technological inclusion. For more detailed information and to explore their various projects, visit their official page.

Ghana NLP API Platform

These are the steps to set up your account and access the service portal:

  • Navigate to the GhanaNLP API Platform

  • You have two options: either go straight to "Sign up" or explore the available APIs. I recommend exploring the APIs first.

There are three (3) API services publicly available for use:

  1. GhanaNLP Automatic Speech Recognition API - v1

  2. GhanaNLP Text-To-Speech API - v1

  3. GhanaNLP Translation REST API - v1

You can explore them further, then proceed with the sign up.

THEY ARE ALL REST APIs

Creating an account

To get started, you can either select "Sign in" to log in with an existing account or "Sign up" to register.

On the sign-up page, fill in your details: name, email, and password.

If you already have an account, go to the sign in page.

After setting up, you will see "Authenticating," and then you will be redirected to the home page.

Activating a service portal

Now, once we're done setting up our accounts on the platform, we head straight to the products page. On this page, we're shown the different tiers that the GhanaNLP service has available.

TierDescription
Basic$14.95 per month. Basic tier with a monthly quota of 3,000 calls.
DeveloperFree - Developer tier with a free monthly quota of 100 calls and charges for overage. (Email subscriptions@algorine.com if you don't have access to a credit/debit card for manual activation)
Enterprise$749.00 per month - Enterprise tier with a monthly quota of 200,000 calls.
PAYG$0.52 per 100 calls. Pay-as-you-go tier.
Pro$199.00 per month - Pro tier with a monthly quota of 50,000 calls and charges for overage.
Standard$89.95 per month - Standard tier with a monthly quota of 20,000 calls and charges for overage.

From the above, you make your best pick, and then from your service portal, you have to create a subscription, and you are good to go.

  1. Make sure you read and agree to the Terms of Use before creating a subscription.

  2. Choose a subscription name and proceed to checkout.

  3. You will be redirected to a payment page for the selected tier, and then you'll be ready to start building.


Familiarize with the API Services

You have three API services available to you. You can explore any of them to get familiar with the platform. Each service page has a "Try it" button.

From the listed services:

The translation API is my favorite. The performance is excellent, and I highly recommend building with the GhanaNLP translation API. Let's test it out, shall we?

After selecting the green Try it button, on the side, a sidebar pops up with different adjustable entries.

Yes, this is the structure of the request body:

And this is the output when an HTTP request is made:

There are demo code blocks in various programming languages that you can copy and paste into your code editor:

In the upcoming blogs, I will create mini projects using this API for practice. Happy building!


10
Subscribe to my newsletter

Read articles from Prince Larbi directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Prince Larbi
Prince Larbi

Enjoy the journey. yoghurt over coffee!! ...any day