feat: support uv for xiaozhi-server

This commit is contained in:
Ming.wei 2025-11-23 21:22:53 +08:00
parent 7a13e1481f
commit e3f90c9a80
2 changed files with 2550 additions and 0 deletions

View file

@ -0,0 +1,69 @@
# XiaoZhi ESP32 Server - AI Voice Assistant Backend
# 现代化的 Python 项目配置,使用 pyproject.toml 管理依赖
[project]
name = "xiaozhi-server"
version = "0.1.0"
description = "XiaoZhi ESP32 Server - AI Voice Assistant Backend"
requires-python = ">=3.10,<3.11"
dependencies = [
# 核心依赖 - 固定版本
"torch==2.2.2",
"torchaudio==2.2.2",
"numpy==1.26.4",
"websockets==14.2",
# 其他依赖
"pyyml==0.0.2",
"silero_vad==6.1.0",
"opuslib_next==1.1.5",
"pydub==0.25.1",
"funasr==1.2.7",
"openai==2.7.1",
"google-generativeai==0.8.5",
"edge_tts==7.2.3",
"httpx==0.28.1",
"aiohttp==3.13.2",
"aiohttp_cors==0.8.1",
"ormsgpack==1.12.0",
"ruamel.yaml==0.18.16",
"loguru==0.7.3",
"requests==2.32.5",
"cozepy==0.20.0",
"mem0ai==1.0.0",
"bs4==0.0.2",
"modelscope==1.23.2",
"sherpa_onnx==1.12.15",
"mcp==1.20.0",
"cnlunar==0.2.0",
"PySocks==1.7.1",
"dashscope==1.24.6",
"baidu-aip==4.16.13",
"chardet==5.2.0",
"aioconsole==0.8.2",
"markitdown==0.1.3",
"mcp-proxy==0.10.0",
"PyJWT==2.10.1",
"psutil==7.0.0",
"portalocker==3.2.0",
"Jinja2==3.1.6",
"vosk==0.3.44",
]
[tool.uv]
# 使用国内镜像加速
index-url = "https://mirrors.aliyun.com/pypi/simple/"
# 其他可选镜像源:
# index-url = "https://pypi.tuna.tsinghua.edu.cn/simple/" # 清华源
# index-url = "https://mirrors.ustc.edu.cn/pypi/simple/" # 中科大源
# index-url = "https://pypi.org/simple/" # 官方源(国外用户)
[tool.uv.sources]
# torch 需要从 CPU 版本源安装
torch = { index = "torch" }
torchaudio = { index = "torch" }
[[tool.uv.index]]
name = "torch"
url = "https://download.pytorch.org/whl/cpu"
explicit = true

2481
main/xiaozhi-server/uv.lock Normal file

File diff suppressed because it is too large Load diff