How to build a custom GPT

Introduction

I lead partnerships and community at MindStone globally.

Not many, so I will give you the full introduction.

Role and Scope

So we are effectively the biggest practical AI community in the world, with about 20,000 members registered on our platform.

And by practical AI, I mean that we really focus on concrete AI applications, on practical use cases and how to use AI tools and applications to improve productivity in the workplace.

Approaches to Practical AI

And we do this in two ways.

One is through these meetups that happen all around the world, not just here in Boston, but also in London, New York, Madrid, Lisbon, Paris.

I actually lead the meetups in Paris.

And we are very new in Boston, but in London, where we have been for two or three years, as I said, pretty much 200 or 300 people show up every month.

And the reason is really that I think we have found, as a company, a sweet spot between the technical and the conceptual approaches to AI.

So there are a lot of technical fora where people need to discuss advances in AI and how how to improve and perfect the large language models, for example, sharing research and insights.

And then there are a lot of conferences where people speculate on what the future might look like. But we feel that what's missing is precisely the sweet spot.

Community Engagements

places where people can starting from practical applications think about what the impact will be on the economy and society and so this is why we are here today do you have any questions on ah sorry this is the the first the first part the meetups and then we also run structured training programs

And the flagship program would have nine hours of learning in total with some live sessions with experts, but also some homework and practical applications and concrete use cases on a platform.

So you have an overview of the company.

Any questions on this? Any curiosities, things you would like to ask, things you would like to know?

Then we jump straight in.

Exploring Custom GPTs

And all of these meetups have three talks, typically. And we have three types of talk.

There's a practical demo, a technical demo, and theoretical talks about how the future might look like with AI.

And today, I'm going to start with a practical demo. Then we are going to have Michael and Andre that will do a technical demo for us.

Understanding Custom GPTs

So what I think I would do is to show you a little bit how custom GPTs work on ChartGPT. Now, how many of you have used custom GPTs on ChartGPT before? One. Many of you. So about half of you.

So let's try to make it be more advanced than I had in mind. Let's try to build one together. on some topic that we think could be interesting.

Now, for those that don't know them, I will start by explaining what they are.

So they are available on the plus, starting from the plus type of account in ChartGPT. So you see, you can access them by clicking on Creating a GTP.

And then you can either create it in a conversation with ChatGPT or configure it. And what this basically does, it creates a pre-programmed version of ChatGPT that focuses on a specific task.

And it's really ideal if there is something that you are doing pretty much every day, maybe multiple times a day, because it means that you don't need to write very long prompts, but you can write very simple prompts. And ChartGPT will be pre-programmed to understand the context and a lot of information that you need to make the prompt, to write a good prompt.

Application Examples

So I will give you an example of one that I have developed, which is a customer support assistant.

And so assume we have Amy that wants to know how long the Mindstorm programs are. Hey there. How long is the Mindstorm program?

I need to specify at the beginning, reply to email, because that's how I pre-programmed the machine. And you see that with just this very short prompt. the custom GPT has written a fairly good reply that I could pretty much copy paste without changing too much.

Part of the reason is that I really invested a lot of time in making it suitable to my writing style. So I will show you how that looks like before we build one together.

so if i go here you see the instructions that i've developed system for mind stone responsible for answering questions is very important you should only respond If a question cannot be answered, you should respond that information is not available. And you should only use information from the two documents that contain information on the milestone courses.

So all of this is massively reducing the probability of hallucinations. And then. There is something on the style.

So I want it to sound a little bit British. I study in the UK. If it has to sound like me, it has to sound a little bit British.

But yeah, European. It should be short. And then there are some, or it should provide some very concise points.

And then there is the rules. I distinguish between replying to a question in an email or replying to an email. And if it replies to an email, then there is a specific form that I want the model to use to close the email.

So all of this is basically saving me quite a bit of time in replying to customer queries.

I can basically, just following these instructions, just pretty much copy and paste whatever the model spits out, at least for very simple questions.

Interactive Demonstrations

So let's try to do one together. Can I ask a question? Yes, of course.

On the previous screen at the bottom, there was a go back. Yeah, give me a second. Yes.

There's this knowledge thing at the bottom. Yes. I see.

So those are the documents that you're attaching. Yes. I see.

It's just documents that you're attaching. Yeah, I can show you.

They are very nothing. They are just the PowerPoints presenting the program. It's nothing.

These are the documents. So they are not engineered to be particularly readable for charge GPT. The model is quite powerful and can generally pick up information from most types of documents.

So can you think about something very boring that you would like to automate? Go crazy. Not too much, because I still need to be able to do this.

What kind of emails? So the suggestion was replying to emails. What kind of emails?

emails or some specific requests that are sent when a representative is not available. When a representative is not available. Of the company.

So it's very similar to what I have already. Do we basically want to rebuild that together? You want to see the process?

What data do you have available? can download something from the internet we can really go crazy here all right something about stock prices maybe company annual reports or something you can download them okay so we are in boston give me a company from boston

Do we still have companies in Boston? I would go for Johnson and Johnson. Johnson and Johnson, all right.

Building a Custom AI Solution

Let's see what we manage to do in five minutes. And I will show you how I built the customer assistant later. We can just take five, 10 minutes separately.

Corporate reports of Johnson and Johnson. All right, this looks like the kind of thing we need. We download it.

140 pages. All right, so we then buy. I'm loving this.

It's going to be so much fun. So we basically build something.

It's a Johnson GPT. And it should know all information about Johnson & Johnson 2024, something like that.

But we are going to create it, because I'm choosing the option to create, because I think when you have not done this before, it's a bit more intuitive. Then once you have done it, you can just configure it. But I'd normally start from creating anyway.

Creation Process

So I need. an assistant that helps answer questions on Johnson & Johnson for investors.

Here is the annual report from the company. for 2024.

Information used in replies should, must. It's very important to be assertive. Must.

That's what I need to stop my British self. You must, to me, in English sounds very strong. Does it make a difference?

Yes, it does. It does.

It's only come from this source. So we saved it on the desktop.

The nice thing is that typos are fine with this, actually. Sorry? Typos are fine.

Yes, yes. So you need to know, this is very difficult for me.

I'm really bad at multitasking. So doing two things at the same time for me, it's really difficult. So you will see typos.

I might lose some words here and there, but the result is what counts. You need an assistant that helps answer questions from Johnson & Johnson for investors.

Here is the annual report from the company for 2024. Information used in replies from assistant must only come from this source. This might take a while, depending on the investor guide.

Does that work for you? Yes.

And then it's going to generate an image. Let's see what it comes up with for the image.

Costs and Considerations

How expensive is this process overall? How much does it cost to run the training of the model?

A few dollars or $10? It's a very good question.

I'm not sure. It's a very good question.

So the question was how expensive it is to run this process. I'm not sure.

Yeah. Can you repeat that one second?

So generally, it covers into plus one. If you are using GPT's API calls, then it charges based on tokens used.

So the question was how much it costs to not to access, to train these models in the first place. So that I do not know, but on the accessing side, yes, you can access with Plus, which is, I think, $20 a month. And then you pay extra for the APIs, for the API access.

All right. So let's see if this worked.

How many employees does the company have in 2024? All right, we want to cross-check that.

So it helps that I worked in a, I did an internship in a bank, so. In an investment bank, we are talking about 10 years ago, so I'm vaguely familiar with annual reports.

All right, so which number did it take? So the number is more or less right. It's right ballpark.

Let's have a look. Oh. So actually, it did pick up the right number.

Interesting. This seems to be working well.

Any other things we want to test? What segment of Johnson & Johnson was highly profitable? Actually, how about make a table with the most profitable segments?

Love that. Just to see if you can do more of that stuff too. So let's first go with which segment was most.

Let's go in order of difficulty. All right. I like that.

Which segment was most profitable for the company? I'm still using for the company to try to really make sure that it doesn't get confused. Not even medicine.

Does anyone know Johnson & Johnson? Is this right? Does this sound about right? Do I need to cross-check it?

Now, let's push it. Make a table. What table do you want, Andre?

Make a pie chart. Just push it. Make a pie chart with? With the 10 most profitable segments, right?

Five most profitable segments or something. Or something like that. Profitability across segments.

I think we're going to crash it. Let's see. I've created a Python script to generate a pie chart.

Interesting. OK, make it a table so we can cross-check the numbers. OK, how do we check this?

Does anyone know if the numbers are broadly right, or do we want to cross-check them? Sounds right. Let's see here.

Yes.

Data and Privacy in AI

What about the data you trained the agent on? Does it stay there, or you own the agent, you can delete it, you can wipe it out?

You can, so the question was, what about the data that you train the agent on? You have maximum flexibility.

You can extract them. You can, so you mean the report or? Yeah, like the PDF you used to train them.

You have maximum flexibility over that. You can wipe it out.

Yes. You have access to that. Yes. Yes.

Data Constraints

And if you ask a question that is not in the PDF, the agent does not pull from the No, because in this case, I've specifically said to use only information in the document.

But if you ask number of employees, I think 2022 wasn't there. Do we want to try? Do we want to try?

How about the number? OK. Let's make it more assertive. Give me the number of employees for 2020. Let's make it 2019, which is probably not in there.

Interesting. So that works in this case. But that's why it's really important to be assertive about it.

It's like, only information from this document, period. Because then if we go in the configuration, you see that this is actually quite short. But that's really reflective.

Referencing exclusively information in the 2024 annual report. So the must is translated in, this is really the only thing you should be looking at. The translation has worked well of that first prompt.

Any other questions on this? When you create the . Yeah.

Do we have mobility to choose which? So that's a good question.

So the question was, can we choose the model that OpenAI, the custom GPT is based on? I'm not sure what the answer is. I will double check and let you know. It's a very good question.

Publishing and Accessibility

By the way, these can be published. They can also be published publicly. So I have not published any of mine, but you can actually publish them.

If we go back to the create, you can actually make them available to the chat GPT store, effectively. I'm not sure it's called store, but that's what it is. If we go back to my GPTs, we should be able to see it.

Conclusion

Anyway, I hope this was useful.

Finished reading?