Grammar and Spelling Correction API, With Generative Models

What are Grammar and Spelling Corrections and Why Use Generative AI?

Grammar correction and spelling correction are about removing mistakes from a piece of text.

It sounds easier than it is as there are several kinds of mistakes. Sometimes it is just about a typo or a misspelled word, but it can also be a deeper sentence structure issue. Thanks to AI, it is now possible to reliably detect errors and propose a perfect correction, in most languages.

LLaMA 2, Dolphin, and ChatDolphin are the most advanced alternatives to GPT-4 and ChatGPT. These models are so big that they can adapt to many situations, and perfectly sounds like a human. For advanced use cases, it is possible to fine-tune Dolphin (train them with your own data), which is a great way to perform grammar and spelling application that is perfectly tailored to your company/product/industry.

Why Use a Grammar/Spelling Corrector?

Writing content with mistakes is bad for reputation, and it makes it hard to understand the underlying ideas. Here are a couple of examples:

Content Creation

Marketing teams write a lot of content on a regular basis. It is hard to write fast without making mistakes. In order to keep a high productivity, the best solution is perform a text correction on the content once it's finished and use the corrected text.

Support

Making mistakes when writing to customers is very bad for the brand. Good news is that it's easy to automatically correct every message before sending it!

Grammar and Spelling Correction with Generative AI

Building an inference API for grammar and spelling correction with generative models is a necessary step as soon a you want to use correction in production. But building such an API is hard... First because you need to code the API (easy part) but also because you need to build a highly available, fast, and scalable infrastructure to serve your models behind the hood (hardest part). It is especially hard for machine learning models as they consume a lot of resources (memory, disk space, CPU, GPU...).

Such an API is interesting because it is completely decoupled from the rest of your stack (microservice architecture), so you can easily scale it independently, and you can access it using any programming language. Most machine learning frameworks are developed in Python, but it's likely that you want to access them from other languages like Javascript, Go, Ruby...

NLP Cloud's Grammar and Spelling Correction API

NLP Cloud proposes a grammar and spelling correction API with generative models that gives you the opportunity to perform correction out of the box, with breathtaking results.

For more details, see our documentation about grammar and spelling correction with generative models here. For advanced usage, see the text generation API endpoint here. And easily test grammar and spelling correction on our playground.