Fighting SEO thin content with ChatGPT through OpenAI API

Rafa Noronha
Noronha dot tech
Published in
2 min readAug 5, 2023

This year I started building Valdir, a mobile app looking to help Brazilians take care of their cars and motorcycles.

Building Valdir app really have been pushing my product design and frontend engineering skills.
Alongside that I decided to also get going a website for Valdir. And I found in Tabela Fipe a way of getting Google know my website while delivering useful content for our audience.

Turns out Tabela Fipe consists of a catalog with thousands of items — thousands of prices of cars and motorcycles in Brazilian local market.
So suddenly my website have thousands of pages, which looks promising, but Google were not getting those pages indexed.
So I remembered something I heard about thanks to Suzane, an incredible Product Manager and SEO geek, whom I partner with in my daily corporate job.

Thin content is content that has little or no value to the user. Google considers doorway pages, low-quality affiliate pages, or simply pages with very little or no content as thin content pages.

So my pages had to deliver more value to our audience than just a thin price catalog.

Photo by Andrew Neel on Unsplash

Luckly we are living in the AI times and ChatGPT has a surprisingly easy to use API.
Through OpenAI API, I managed to generate and deliver thousands of descriptions alongside those prices and our webpages even look more professional now.
An engineering side note: here is all the source code I’ve written in order to connect our backend with OpenAI API and leverage value from this solution.


export { Content, initContentModel } from './model'

import { Configuration, OpenAIApi } from 'openai'

const configuration = new Configuration({
apiKey: process.env.OPENAI_API_KEY,
})

const openai = new OpenAIApi(configuration)

type GetContentForCarModelArgs = {
manufacturerName: string
modelName: string
}

export async function getContentForCarModel({
manufacturerName,
modelName,
}: GetContentForCarModelArgs): Promise {
const chatCompletion = await openai.createChatCompletion({
model: 'gpt-3.5-turbo',
messages: [
{
role: 'user',
content: `Escreva um texto com carca de 250 caracteres sobre o carro ${manufacturerName} ${modelName}. Não cite o nome do carro. A primeira frase do texto deve iniciar com um pronome indefinido seguido de um dos substantivos a seguir: carro, moto, modelo, hatch, sedan, picape, SUV, opção, escolha.`,
},
],
})

// eslint-disable-next-line @typescript-eslint/no-non-null-asserted-optional-chain
return chatCompletion.data.choices[0].message?.content!
}

--

--

Rafa Noronha
Noronha dot tech

Construindo produtos digitais desde antes da bolha tech