Skip to content

react-declarative/chatgpt-form-builder

Repository files navigation

⚛️ ChatGPT React Generator

The ChatGPT app which write a JSX form for React-Vite application

gpt

A ChatGPT powered React Code Generator. Specify what kind of React form you want to build and directly get the code and a live preview.

Contribute

Important

Made by using react-declarative to solve your problems. ⭐Star and 💻Fork It on github will be appreciated

How It's Work

  1. The postinstall.mjs file download Nous-Hermes-2-Mistral-7B LLM

  2. The index.mjs file generate RAW ./tmp.txt according to the SYSTEM_PROMPT and the USER_PROMPT

  3. The index.mjs transform markdown in ./tmp.txt to jsx in ./src/out/index.jsx according to the TRANSFORM_PROMPT

  4. The Vite server start the UI on http://localhost:3000

Usage

  1. Run npm install

  2. Edit the USER_PROMPT

  3. Run npm start to generate the code. Will take a couple of minutes if running on CPU. GPU require at least 16Gb embedded RAM

  4. Run npm run test to launch the code