Use AI to Generate Podcast Descriptions with OpenAI and Airtable

Jan 11, 2023Rosie Threlfall

In this simple tutorial, we'll run through the steps involved to automatically generate several short descriptions for a list of podcasts using AI.

We'll be using the OpenAI Airtable integration and Data Fetcher. This requires no code and can all be done for free.

The OpenAI Airtable integration uses GPT3 deep learning technology to produce human-like text for our podcast descriptions. We can also OpenAI and Data Fetcher to generate images using AI.

Create Podcast and Description Table

In your Airtable base, create a table called 'Podcasts'.

In the primary 'Name' field, enter the names of the podcasts you would like OpenAI to create descriptions for. For this example, we will use the following podcasts:

My First Million
The Tim Ferriss Show
Huberman Lab
How I Built This
Lenny’s Podcast With Lenny Rachitsky

Create another field called 'Description' (with type 'Long text').

OpenAI-Podcasts.jpg

Create a new Grid view called 'Needs Info' and add the following conditions (conditions are created using the 'Filter' menu option);

  • The 'Name' field is not empty.

  • The 'Description' field is empty.

OpenAI-Podcasts2.jpg

Add Data Fetcher to Base

Add Data Fetcher to your Airtable base and sign up for a free Data Fetcher account by entering a password and clicking 'Sign up for free'. You can also use your Google account. If you already have a Data Fetcher account use the 'Have an account?' text in the bottom left of the screen to log in.

Data Fetcher is free to start using and can be used to import many different types of data from many APIs or websites into Airtable.

Data Fetcher Sign Up

Generate AI Descriptions

Requests in Data Fetcher are how you import data into or send data from your Airtable base. Click 'Create your first request' on the home screen of the Data Fetcher extension.

Create your first request in Data Fetcher

For Application, select 'OpenAI' to use the OpenAI Airtable integration.

OpenAI-3.jpg

You'll need an API key from OpenAI. If you don't already have an account with OpenAI you can sign up for one here and generate an OpenAI API here

OpenAI will automatically give you $18 worth of free credit. This is plenty to complete this tutorial, but if you plan to use OpenAI once this has run out, you will need to upgrade your account and add more credit.

Copy and paste your OpenAI API key into Data Fetcher under Authorization.

OpenAI-4.jpg

For Endpoint choose 'Create completion from a text prompt'.

OpenAI-Podcasts3.jpg

Give your request a name such as 'Generate AI Podcast Descriptions' and click 'Save and Continue.'

OpenAI-Podcasts4.jpg

On the next screen, for Model choose 'text-davinci-003' (this is the default).

OpenAI-Podcasts5.jpg

The Prompt is where you add an instruction describing what you would like OpenAI to do for you. In this example, we want to generate short descriptions for our podcasts, so enter: 'Write a single-sentence, description of the podcast '. (Note the space at the end of the prompt.)

Next, with your cursor still in the text box (where the space is), click the + button to insert a reference to the values in our 'Name' Airtable field.

Please note: The exact words you use for the prompt are crucial for ensuring you achieve the correct results from OpenAI. It's worth reading these basic tips and more info on writing good prompts for OpenAI

OpenAI-Podcasts17.jpg

On the modal that opens, select your output Table. Then select 'Name' for Field and 'Needs Info' for Run for every record in view.

Click 'Confirm'.

OpenAI-Podcasts15.jpg

The Prompt field should now contain a reference to the output table.

OpenAI-Podcasts16.jpg

For Max tokens, enter 50 (this will ensure the description created is long enough.)

OpenAI-Podcasts9.jpg

Click 'Save & Run'.

OpenAI-Podcasts12.jpg

Now the Data Fetcher request will run, and the Response field mapping modal will open. This is where you can specify which fields to import from the OpenAI API and how they map to fields in Airtable. 

Set the 'Result' field to map to your Existing field of 'Description' and click 'Save & Run'.

OpenAI-Podcasts8.jpg

Data Fetcher will now run the OpenAI Airtable integration. In your output table, you'll see that short descriptions describing the podcasts have been generated using AI and added to the 'Description' field.

OpenAI-Podcasts7.jpg

Automatically Run the OpenAI Airtable Integration

Currently, you'd need to run the request manually request each time you want to create any new descriptions for your Podcasts in Airtable. However, you can automatically run the OpenAI Airtable integration on a chosen schedule using Data Fetcher's paid scheduling feature.

To upgrade your account, In Data Fetcher, scroll to Schedule and click 'Upgrade'.

schedule1.jpg

Choose a plan from the different options depending on your needs and enter your payment details.

data fetcher upgrade options

In Data Fetcher, click 'I've done this'.

schedule2.jpg

Click 'Add API key' and copy and paste your Airtable API key. You can find your Airtable API key here.

Group 11(1).png

Enter your Airtable API key and click 'Save'.

save-airtable-api-key.png

Toggle Schedule this request to on.

schedule-data-fetcher-request.png

Select a schedule for the OpenAI Airtable integration to run. You can choose intervals of 'Minutes', 'Hours', 'Days' or 'Months', then click 'Save'.

Now, if you make any changes or additions to the podcasts in your table, descriptions will be created by OpenAI using GPT and imported into Airtable automatically on your chosen schedule.

schedule-a-sequence-intervals.png

Related Posts