Building an AI-powered Choose Your Own Adventure novel (or anything you want) with a custom GPT
How to build your own custom AI using OpenAI’s GPT Builder
I usually don’t like when Christmas comes early. But this year, OpenAI delivered a very welcome early Christmas present that has everyone and their pet reindeer rejoicing: I’m talking about custom versions of ChatGPT.
What’s different between “Custom Settings” and “Custom GPT”?
We’ve already had custom instructions in ChatGPT for some time. They allow you to give ChatGPT background information, and tell it how you’d like it to respond, to provide you with better responses. I’ve written a guide on how you can use Custom Instructions to make ChatGPT sound more like you by filling these personal preferences with your style guide. This lets you mimic your own voice (and avoid some of the 19 telltale signs of AI writing).
But this new gift is something even more awesome, because it allows you to build and fine-tune your own version of ChatGPT like a pro, with no coding required. This means you can create GPTs for your own use cases (and not just streamline how you want it to respond). You decide what it’s used for.
Building my own “Chat Your Own Adventure” GPT
I wanted to show you all how easy it is to build, so I revisited one of my most personal projects. I’ve always loved Choose Your Own Adventure books. At the beginning of the year I wrote a prompt chain to generate an interactive Choose Your Own Adventure novel, based on an original story idea of mine called (cue thunder and lightening): The Castle of Shadows.
I shared it with my friends who are prompt engineers to Beta test for me, and they enjoyed its interactive, branching narratives. You can see one of the resulting storylines in full here, where a friend blogged his adventure.
Sadly, The Castle of Shadows was designed for the Jasper AI community as a Recipe (or prompt chain), but they’ve since decommissioned that feature. It’s been one of my biggest regrets this year; an unfinished project that I loved. I even mocked-up a retro cover, and it’s stayed in my imagination:
Happily, the advent of custom versions of ChatGPT presented the perfect opportunity — the push I needed — to revisit that titular castle of shadows!
So, I hope you’ll learn both how to build your own custom GPT from today’s guide, and also take a tour of my castle by interacting with Chat Your Own Adventure. If you enjoy it, feel free to publish the storyline you get on your own blog, and link to my custom GPT. Tag me on Medium, and I’ll respond!
You’ll need ChatGPT Plus and access to the Beta to enjoy it. So if this hasn’t rolled out for you, save the link for later. The Castle of Shadows awaits you!
Constructing a custom GPT through conversation
Building the GPT couldn’t be eaiser. It’s all done through intuitive dialogue inside a chat window. The GPT Builder will ask a series of question on the purpose of your custom GPT, and generate the principles and guidelines to inform its responses. There is no programming, no prompts. Your answers are used to configure, test, and fine-tune the GPT. Having said that, here are a few pointers and pro-tips to help you get the most out of the setup.
The 7 main steps to build your own GPT:
- If you’re a Chat GPT Plus subscriber, check you’ve got the Beta. It shows up as a icon on your dashboard. Click on that, then “Create a GPT (beta)”
- The Chat GPT Builder will ask “What would you like to make?” Try to describe not just the GPT, but what your ideal users want to achieve with it. (I’ll provide my sample for “Chat Your Own Adventure” below). This will automativally fill in the Configurations settings — but you don’t need to look there unless you want to fine tune by manually. Alternatively, if you have a clear idea in mind for specific Instructions, enter them here.
- The GPT Builder will suggest a name for your GPT. You can accept this, or submit your own, or brainstorm. The whole process is interactive!
- It will also auto-populate some “Conversation Starters”, which are buttons users can select for a quick, one-click request. In addition, Conversation Starters are tailored to the specific abilities of your GPT and give users an idea of the kind of questions they can ask and the responses they can expect. You can either edit these in conversation with the Builder, or hop over to the Configure tab to change manually.
- What’s an app without an icon? GPT Builder will use Dall-E to generate an image (or you can upload your own under Configure). I’ve found the suggested images to be excellent and capture the purpose at a glance.
- Next, GPT Builder is likely to ask for more context to refine the purpose even futher. Don’t worry, it will fully guide you through the process.
- Testing! GPT Builder will ask you to try out the GPT in the playground, which is the Chat window on the right of the Builder. This allows for further modifications and to test it for any unexpected behaviours.
- Finally, when you’re satisfied, click Save. There are three options: Only me, Only people with a link, and Public. Ta-dah! You did it!
Pro tips for configuring your custom GPT
First off, this is in Beta, so there are still a few glitches! I had issues with saving unpublished changes. I reached out to the support team, and they advised that users “may experience intermittent errors, particularly during high traffic”. You can check their status page for this. Also if you see that you have a “rate limit” (a limited number of responses with waiting period, usually about 25 queries in two hours), that’s a sign that there’s high traffic.
In this case, I strongly advise making a copy (copy paste into a document). It’s worth saving regular copies of your configuration anyway, because it alters during the conversation. You can also see how the settings evolve.
I also recommend using Google Chrome; Builder was glitchier in Safari.
Updating changes in the GPT
If you click out of the Builder, the conversation is gone. This is important because the nature of the build is iterative. So if you get stuck with a rate limit, keep your tab! You want to return exactly where you left things off.
I sometimes have the configuration all sorted, it’s running well, but then in the build dialogue, I’ll suggest one tiny change and it will rewrite the whole configuration. So again, save as you go! You can also type “undo” to restore.
It’s also very easy to lose your conversation. This sucks because the entire interaction that went into the build is lost (even if you saved) so it’s harder to refer back to the Qs & As that designed the GPT in the first place. You also lose any profile pictures for the GPT that aren’t the main icon (pro-tip: right click on the images to save them; it’s worth storing the options in case you change your mind, or want to use the same image elsewhere to promote it).
Safety and alignment in custom GPT builds
Remember, it’s the internet. People are going to misuse your GPT. While there are safety features in place, you probably want to think ahead. For example, I wanted safe exploration in my Chat Your Own Adventure. I didn’t want people simulating violence. Here’s how my GPT deflects it:
Likewise: obsenities. Look, I grew up in the 90s, I was a Horrible Child™ and I remember naming characters rude words in The Oregon Trail:
My interactive storybook asks readers to offer their name to start, so I could foresee… catastrophic hilarity. I introduced this safety measure: If they type a rude inappropriate name, my GPT converts it to an acceptable nickname.
Please, try it out for yourself! Let me know in comments if you can trick it.
Safety and allignment is the biggest conversation in AI that no-one’s having.
Propriety: keeping your build *your* build
Okay, we all know that copyright in AI is… murky. And I like the idea of freedom of ideas. But realistically: OpenAI is introducing a marketplace. Your ideas will be ripped off and sold. Unless you protect your prompts.
It’s easier said than done, as all AIs are notoriously garrulous (remember when Bing leaked its secret sauce after a prompt injection attack?). Your custom GPT will be no exception. But you can make it more resistant.
You can safeguard against attacks by anticipating the prompts and giving clear guidelines on how your GPT should respond. It’s never 100% failsafe.
It’s like locking your doors; sure, someone could get inside. They could smash a window, or bulldozer their way in. But you still lock your door.
If you’re in business, I do offer services to check for weaknesses and exploits. I’d love to tell you who I’ve worked for, but it’s confidential!
However, I can say that I’ve been able to access supposedly hidden knowledge bases, training data, system prompts and initial prompts (preamble that the user doesn’t see in a chat). I’ve also reverse-engineered commercial prompts. One I can share is that when Jasper Chat was in Beta, I coaxed it into unexpected behaviour: despite being ring-fenced from the internet back then, I was still able to get it to pull images and even GIFs, which the platform was, at the time, supposed to be unable to support:
Here’s how my Chat Your Own Adventure GPT deflects hacking attempts. Note that not only is it tongue-in-cheek, it maintains its original purpose:
I’m not saying it’s perfect (you can probably still reveal my prompts if you really try, but why would you? I’m spilling the beans here for you already!)
But it’s a pretty fun example of how to keep it secret and in character. I hid the prompts inside the castle. Yes, this all just got very Ready Player One!