This is a full stack web application that uses AI to explain code. The backend is built with Flask and the frontend with React.
-
Navigate to the
backenddirectory:cd backend -
Set up a virtual environment:
python -m venv venv
-
Activate the virtual environment:
- On Windows:
venv\Scripts\activate
- On macOS and Linux:
source venv/bin/activate
- On Windows:
-
Install the dependencies:
pip install -r requirements.txt
-
Run the Flask server:
python app.py
-
Navigate to the
frontenddirectory:cd frontend -
Install the dependencies:
npm install
-
Start the React development server:
npm start
The React app will be available at http://localhost:3000 and the Flask backend at http://localhost:5000.
- Enter your code into the textarea on the frontend.
- Click the "Explain Code" button.
- The explanation will be displayed below the button.