Skip to content

andrewlpmcneill/fun-with-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fun with AI

Fun with AI is an app with two modes:

  1. Send plain-text prompts to GPT-3 using the OpenAI API and receive a response
  2. Send images to the backend, where optical character recognition (OCR) is performed using TesseractJS's library and the result is sent to OpenAI's API for cleanup and final processing

Demos

Sending a prompt:

'Prompt flow'

Uploading an image for OCR text extraction and GPT-3 cleanup:

'Image flow'

GPT-3 generating a colour based on a prompt, and the app theme reflecting it to the user:

'Colour change'

The app is fully responsive and suitable for mobile devices:

'Mobile combined'

Stack

Front End

  • React
  • HTML
  • CSS

Back End

  • Node.js
  • Express
  • Multer
  • TesseractJS

APIs

  • OpenAI
  • imgur

Setup

  1. Create the .env by using .env.example as a reference: cp .env.example .env
  2. Update the .env file with your correct local information
  • OPENAI_API_KEY: Get an API key for free at OpenAI
  • CLIENT_ID: Create an account at imgur and register an application here
  1. Install dependencies: npm i
  2. Run the Node.js server in the 'backend' directory: npm run dev
  • Note: nodemon is used, so you should not have to restart your server
  1. Run the React server in the 'frontend' directory: npm start
  2. Visit http://localhost:3000/

Credits

Built by Andrew McNeill

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published