This new language model could be the pair programmer of your choice going forward

What is this about?
Two days ago OpenAI released .
Why is this important?
You’re joking, right?
Let’s get started
Ok, let’s get started! Let’s first check if ChatGPT is willing to help:

Ok, this is a promising start 😊 Let’s dive into the details, as requested by our companion!
Creating a CloudFormation template for the EC2 instance
We want to run this application on an EC2 instance, but we don’t want to click through the AWS console to create this EC2 instance. Therefore, our first task for ChatGPT is to create a CloudFormation template that sets up the EC2 instance:

The instruction are rather specific (I had to look up the AMI ID myself, for example), but still I was quite surprised that it came out with an almost perfect CF template. Note that ChatGPT also puts some disclaimers at the end of the code:

The entire code produced by ChatGPT:
This actually looks good to me, let’s try to run this without modifications. Copy and pasting this code into a file on EC2 called “app.py”. But how do we run Streamlit apps again? Let’s ask our “colleague”:

We already have Streamlit installed so let’s go ahead and run “streamlit run app.py”:

Seems all good!
Testing the application
Now comes the moment of truth. We plug in the URL streamlit exposed and see if the app runs.

Wow, ChatGPT just built an entire text sentiment app just with our instructions 🤯
Conclusion
I’m very much speechless. This has been so much fun and the possibilities are endless. I will try to experiment more with this model going forward and would also love to hear what you have built with it. Please comment below!
on Medium, where people are continuing the conversation by highlighting and responding to this story.
SOCIAL SHARE CARD GENERATOR