EatAI
1.0.0
EatAI 是一款人工智能驱动的应用程序,旨在帮助用户做出更健康的饮食选择并实现健康目标。通过利用用户数据,EatAI 提供个性化建议,支持平衡和健康的生活方式。
EatAI GitHub 存储库
克隆存储库
git clone https://github.com/yashkanjariyaa/EatAI.git
cd EatAI
安装客户端依赖项
cd client
npm install
安装服务器依赖项
cd ../server
pip install -r requirements.txt
.env
文件使用以下内容在client
目录中创建一个.env
文件:
VITE_SERVER_BASE_URL = SERVER_URL
该变量指向后端服务器 API,使前端能够与服务器通信,或者您可以使用此部署的 URL - https://etai.onrender.com
.env
文件使用以下命令在server
目录中创建.env
文件:
GOOGLE_API_KEY = YOUR_API_KEY
此 API 密钥对于在服务器应用程序中集成 Google 服务是必需的。
启动服务器
导航到server
目录并使用 Gunicorn 启动 Flask 服务器:
cd server
gunicorn --config gunicorn_config.py app:app
启动客户端
在新终端中,导航到client
端目录并运行开发服务器:
cd client
npm run dev
在 Render 上设置项目并将服务器根指定为server
。
配置 Gunicorn 使用以下命令:
gunicorn --config gunicorn_config.py app:app
根据您的.env
文件在渲染设置中添加环境变量。
VITE_SERVER_BASE_URL
环境变量以指向已部署的后端 URL。 该项目是根据 MIT 许可证开源的。