1、安装nodejs
sudo apt remove -y libnode-dev nodejs npm
sudo apt update sudo apt install -y nodejs
2、下载next-ai-draw-io
git clone https://github.com/DayuanJiang/next-ai-draw-io.git
3、安装依赖
cd next-ai-draw-io
rm -rf node_modules package-lock.json
npm install --registry=https://registry.npmmirror.com
4、申请API 密钥
在上面的网站申请key
5、部署
vi .env.local
AI_PROVIDER=openai
AI_MODEL=Pro/Qwen/Qwen2.5-Coder-7B-Instruct
OPENAI_API_KEY=sk-xxx
OPENAI_BASE_URL=https://api.siliconflow.cn/v1
上面key替换成自己申请的key
运行npm run dev
在 next-ai-draw-io 根目录
grep -r 'developer' . --include="*.js" --include="*.mjs" \
--exclude-dir=node_modules --exclude-dir=.git
将developer替换成system