AINoon Tutorial 4

The goal of this tutorial is to vibe-code a simple web application.

What is Vibe-coding?

Refer to What is Vibe-coding? and Uses of Vibe-coding slides

Vibe-coding an app

  1. Open gemini.google.com
  2. Give it the following prompt:
Build an app that lets me upload an image and crops that image to 200 x 200 and then lets me download it

What did that do?

  1. It explains to us what its doing
  2. It generates a lot of code
  3. Its running the app for us to try!

Does it work?

  1. Open technoon.org/ainoon
  2. Download cooper.jpg from the Resources section
  3. Upload cooper.jpg into your app
  4. Download the image

AUDIENCE QUESTION: Did it work?

What has it generated?

Making changes

Ask the agent to make some changes to the app, like:

  1.    Allow me to select the cropped region of the image
  2.    Add the image filename as a watermark to the image
  3.    Change the title of the app to "Image Cropper 2000"

Adding an AI Feature

With Gemini, we can even add a feature to our app that uses Gemini AI:

Add a button to generate a caption for the image using Gemini

Sharing your app

Under the Share button, you can:

Gotchas

This highlights the security risks of releasing apps when you don’t know what the code is actually doing!

The same warning goes for not being sure of the correctness

Scaling up AI-Assisted Coding

Refer to Scaling up AI-Assisted Coding slide

Conclusion

In this tutorial, we’ve seen how vibe-coding is a powerful tool for rapid prototyping and simple, low-stakes apps.

However, we’ve also seen the risks to security and correctness if you don’t know what the code is actually doing.

This recurring theme of great power requiring great responsibility is something we’ve seen multiple times throughout the course - and is one of the most important ideas to keep in mind as you learn and use even more AI tools in the future!