How to Create a Business Glossary with ChatGPT and Slack
Corporate jargon is ubiquitous in the business world: From “synergy” and “paradigm shift” to a constellation of acronyms, these terms can leave employees confused and disconnected from their work.
However, company buzzwords also serve as a shorthand for complex ideas, effectively streamlining communication for organizations.
As such, understanding its meaning can be crucial to success, but how do you provide this knowledge to employees while sparing them from having to ask others about it? The horror!
The answer is pretty simple: A business glossary. However, we’re not going to settle for the traditional, antiquated business glossary.
Instead, we’ll show you how to build an automated business glossary that anyone can access through an instant messaging platform like Slack.
Before we get to the tutorial, let’s take a moment to understand how it works.
The last business glossary your company will ever need
This business glossary relies on the following tools to provide every single employee with the necessary definitions:
And Make, of course. To build this solution, the Core Plan will be enough.
So, how does the glossary work?
From the user's perspective, everything takes place in Slack.
Simply send a message to a virtual Slack user (we’ll call it “Mr. Glossary” in this tutorial) with the definition you’re looking for, and you’ll receive the answer on the spot.
The beauty of this is that no one else knows when someone is looking for a definition: The fear of asking (and looking uninformed) is completely removed from the workplace.
The operating principles behind this solution are fairly simple:
There’s a “user” (virtual) that serves as a glossary (“Mr. Glossary”).*
Every time someone asks for a definition to Mr. Glossary, Make will retrieve it and answer the person asking. All of this happens via DM; it’s not a shared channel where everyone can see each other’s actions.
If it’s about an internal definition (a term exclusive to your company), Make will fetch it from Google Sheets (the app we will use to store internal definitions).
If the definition is not in the Google Sheets spreadsheet, Make will request a definition from ChatGPT and reply with the information over Slack.
Now, let’s see how to build this solution so everyone at your company gets up to speed with all the buzzwords!
*Important: In order for this solution to work, you will have to create a new Slack user. It'll be a dummy account managed by an admin, but it will act as a virtual agent for the rest of the company!
Step 1: Create the scenario and add the first Slack module
Assuming that you have Google, Make, Slack, and ChatGPT accounts, the first step will be to create a new scenario in Make.
Then, search for the Slack app in the scenario builder, and select the New Event module.
Note: The New Event module is webhook, and Make can process multiple webhook requests at the same time (in fact, it’s a distinctive aspect of our platform).
This is important because it allows multiple users to ask for definitions and get answers at the same time.
Okay, let’s configure the New Event module. To do it, follow these steps, and check the image below for reference.
First, click Add to create a new webhook. You can enter a name for the webhook (like we did) but it’s not mandatory to do so.
Next, select the New IM Message option in the Event type field.
Once you do this, click Add to connect your Slack account to Make.
To conclude, leave the Channel field blank so that you can receive messages from all users. Click Save and OK once done.
Step 2: Create the spreadsheet with definitions and add the Google Sheets module
In order for our glossary to provide definitions that are only used in your company, you’ll need to store these definitions somewhere - and Google Sheets is probably the easiest place to do it.
At this point, you can go ahead and create a Google Sheets spreadsheet in a Google Drive folder that you manage.
For reference, here’s the Google Sheets spreadsheet with the terms and definitions we are using in this example.
Important note: Please use the same headings in your sheet: Business Terms in A1 and Definitions in B1.
Once you created the spreadsheet and added the definitions (PS - you don’t have to add them all now, you can keep adding over time), head back to your Make scenario.
There, search for the Google Sheets app, and select the Search rows module.
This module will search for the requested term on the spreadsheet containing the full glossary (i.e. the Google Sheets spreadsheet you just created).
Now it’s time to configure this module.
Start by clicking Add and connect your Google account to Make.
Then, select the spreadsheet and the sheet within the spreadsheet that contains the glossary. See the image below for reference:
Once you do this, scroll down to the Filter.
There, select the Business Terms (A) row, and then select the Text operators: Contains (case insensitive) operator.
By doing this, you will ensure that even if someone types in a term in caps, small letters, or a combination of both, it will still be recognized by Make, and a definition for the term will be provided.
Once you do this, map the Text element in the bottom field, as you see below.
Step 3: Add a router
Once someone asks Mr. Glossary for a definition, there are two possible outcomes:
The requested term is either on the spreadsheet (along with its definition or meaning).
The term is not in the spreadsheet (or it was spelled incorrectly). In this case, ChatGPT will provide a definition for that term.
To reflect this logic in our Make scenario, we must create two paths - or routes, as we call them - one for each potential outcome.
To do this, click on the Tools menu at the bottom of Make’s scenario builder and select the Router.
Then, attach the Router to the Google Sheets - Search Rows module dragging it close by.
Next, click on the Router to open up two routes as you see below, and move on to the next step in this tutorial.
Step 4: Complete the top route
This route will be used to reply to a request with the term and its definition coming from the Google Sheets spreadsheet.
Start by clicking on the empty circle on the top route, select the Slack app, and then choose the Create a Message module.
The first step to configuring the Create a Message module is to select the same connection as the one in the New Event module.
Once you do this, you’ll see that there are three fields to configure and a Text box to enter the message.
Configure the module as follows and map the User element from the Slack > New Event module to the User field (first, toggle the Map switch at the right of the field) so that the requester receives the reply.
Below is how you should map the elements into the Text box. Notice that the word ‘Definition’ is highlighted here: This means you should add this to your text. More on that in a bit.
Since this route will only send terms and definitions that are on your spreadsheet, messages informing the requester that a term is not in the glossary must not be sent from this Slack module.
To prevent these messages from being sent, we need to use a filter, so click on the link between the Router and the Slack module on the top route.
Let’s pause for a moment to understand why we are using the filter here.
When a term is found in the glossary, the Search Rows module outputs 1 bundle of data.
If the term is not found, it outputs 0 bundles of data - and we will use this information to filter the data.
First, let’s name the filter "Term available in glossary". Then, map the Total number of bundles element to the top field.
After doing that, select the Numeric operators: Greater than operator, and enter ‘0’ in the bottom field to ensure that the bundle will only pass through this filter when a term is found (i.e 1 bundle outputted).
See the image below for reference:
Step 5: Complete the bottom route
The second route will only activate when a term is not found in the glossary spreadsheet.
At this point, our scenario will do two things at the same time for the inquiring user:
First, it will send a message telling them that the definition is not in the glossary.
Then, it will provide the definition of that term according to ChatGPT.
And this is what the second route does.
Let’s start building by adding the Slack > Create a Message module, and then configure it as follows.
Then, add the word “Oops!” in the text. We'll show you why in a second!
As in the top route, we need to set up a Filter between the router and the first module.
This filter allows bundles to pass through only if the term is not found in the glossary spreadsheet.
This means that the Google Sheets > Search Rows module outputs ‘0’ bundles of data.
So, add a filter in the bottom route between the Router and the Slack > Create a Message module, and configure it as you see below:
Step 6: ChatGPT enters the chat
After the Slack module, OpenAI > Create a Completion module to the bottom route of your scenario.
As you did with other apps, you’ll begin configuring the module by clicking Add and connecting your OpenAI account to Make.
Once you do this, select the Create a Chat Completion method and the GPT-4: gpt-4-0314 as the model.
Then, keep configuring the module as follows:
Select System as the Role
Click Add item under Messages
Map the Text element from the Slack > New event module
Once you do this, the module will be fully configured, so click OK and move to the next step.
Step 7: The last module in your scenario
For the final module, we will add another Slack > Create a message module to the scenario.
This module will send the ChatGPT response to the requester.
Configure it the same way as you did the other two Slack modules, and map the Choices > messages > content element from the OpenAI module to the text box.
Once again, include ‘ChatGPT Definition’ in your message, and click OK to finish configuring this module.
Step 8: Add the last (and most important) filter
Now it’s time to explain the words we entered in the three Slack modules:
First of all, let’s not forget about the big picture: Our scenario works with a webhook, which receives every message sent to a dedicated user (Mr. Glossary), which in turn attempts to find definitions and return them in the same chat.
However - and even when the message containing the definition, the message confirming that the term is not available or the ChatGPT definition - the scenario will execute again as it sees these replies as new requests.
This means that the scenario will get stuck in an endless loop.
The solution is to add a filter that will stop any bundle of data containing the words ‘Oops!’ or ‘Definition’ from passing through since we know these aren't "request" messages but replies instead.
To do this, click on the link between the New events and Search Rows modules.
Let’s name this filter ‘Definition requests only’ and map the Text element from the Slack module to the top field.
Then, select the Text operators: Does not contain (case insensitive) operator, and in the bottom field enter the word ‘Oops!’. Next, click the Add AND rule and repeat the process, but this time enter the word ‘Definition’ in the bottom field. Click OK once done.
Final step: Testing the scenario
This is it!
Our scenario should be ready, and to make sure it actually is, we’ll test it.
To do it, hit the Run once button located at the bottom left of the scenario builder.
Then, go over to Slack and send a message with a term that you know for sure it’s in the glossary spreadsheet.
If it works correctly, test it again by sending a message with a term that’s not in the glossary.
Are both working perfectly? Great!
Hit the Save button under the controls menu (at the bottom of the scenario builder) and then turn the scenario on by clicking the switch below the Run once button.
And that concludes this tutorial. Good job!
Final words: Creating real solutions with ChatGPT
For all the grand promises about AI-powered solutions, this is one you can create in less than an hour, and that will positively impact your entire workforce on the spot.
Moreover, this is an easy way to get started with ChatGPT, and a good stepping stone to building more complex solutions down the road.
All it takes is a Make account, and the desire to make everyone’s lives just a little bit easier.