1.5 KiB
Run code
Set up
Create a virtual environment
cd backend
python -m venv venv
source ./venv/bin/activate
Install dependencies
pip install openai flask flask-cors
Run API
python api.py
Run frontend
Make sure you're in the frontend folder
Find app.js, and update BASE_URL
to match your backend URL
Run the application
npx http-server -p 8000
Try typing a message in the chat; you should see a response (assuming you're running this in a Codespace or have set up an access token).
Set up access token (if you're not running this in a Codespace)
Refer to Set up PAT
Disclaimer:
This document has been translated using the AI translation service Co-op Translator. While we aim for accuracy, please note that automated translations may include errors or inaccuracies. The original document in its native language should be regarded as the authoritative source. For critical information, professional human translation is advised. We are not responsible for any misunderstandings or misinterpretations resulting from the use of this translation.