Skip to content

This app emerged during the initial surge of interest in ChatGPT prompting. We believed that a visual component was missing from the process. To generate ideas for prompts, we considered integrating the YOLOv8 model and using the data to prompt ChatGPT.

Notifications You must be signed in to change notification settings

Matti88/yolo_recipe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Recipe Detector

Object Detection using YOLOv8 and Tensorflow.js to create recipe prompts for ChatGPT


Object Detection application right in your browser. Serving YOLOv8 in browser using tensorflow.js with webgl backend.

How it works

The steps are the following:

  • First you select an Image to upload 📸
  • The AI model will generate a prompt for you 🧠
  • You can check, modify and copy to clipboard the prompt for ChatGPT for obtaining a custom recipe 🍱
  • Last Step: prepare, enjoy and dont' waste food! ♻️

How it works

Setup

git clone https://github.com/Matti88/yolo_recipe.git
cd yolo_recipe
yarn install #Install dependencies

Scripts

yarn start --host # Start dev server
yarn build        # Build for productions

Model

YOLOv8n model converted to tensorflow.js.

used model : yolov8n
size       : 13 Mb

Use another model

Use another YOLOv8 model.

  1. Export YOLOv8 model to tfjs format. Read more on the official documentation

    from ultralytics import YOLO
    
    # Load a model
    model = YOLO("yolov8n.pt")  # load an official model
    
    # Export the model
    model.export(format="tfjs")
  2. Copy yolov8*_web_model to ./public

  3. Update modelName in App.jsx to new model name

    ...
    // model configs
    const modelName = "yolov8*"; // change to new model name
    ...
  4. Done! 😊

Note: Custom Trained YOLOv8 Models

Please update src/utils/labels.json with your new classes.

Reference

Installin Label Studio for Mac

pip install label-studio
brew install postgresql
brew install postgis
pip install psycopg2

About

This app emerged during the initial surge of interest in ChatGPT prompting. We believed that a visual component was missing from the process. To generate ideas for prompts, we considered integrating the YOLOv8 model and using the data to prompt ChatGPT.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published