Files
datascale-ai-opentalking/pyproject.toml
kero-ly 8087110620 Add optional avatar background removal
Support immesive mode in 视频创作
2026-06-29 21:11:18 +08:00

222 lines
5.0 KiB
TOML

[build-system]
requires = ["setuptools>=68", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "opentalking"
version = "0.1.0"
description = "Real-time digital human framework with FlashTalk 14B inference"
readme = "README.md"
requires-python = ">=3.10"
license = { text = "Apache-2.0" }
authors = [{ name = "OpenTalking Contributors" }]
dependencies = [
"fastapi>=0.109",
"uvicorn[standard]>=0.27",
"pydantic>=2",
"pydantic-settings>=2",
"redis>=5",
"numpy>=1.24,<2",
"httpx>=0.26",
"edge-tts>=6.1",
"dashscope>=1.25.11",
"aiortc>=1.6",
'av>=14,<14.3; python_version < "3.13"',
"python-multipart>=0.0.9",
"pillow>=10",
"websockets>=13",
"loguru>=0.7",
"PyYAML>=6",
"opencv-python>=4.8,<4.12",
'mediapipe==0.10.21; python_version < "3.13" and platform_machine != "aarch64"',
'mediapipe==0.10.18; python_version < "3.13" and platform_machine == "aarch64"',
"kornia>=0.8.2",
"onnx2torch>=1.5.15",
"insightface>=0.7.3",
"transformers>=4.57,<6",
"openai>=1.0",
"lightrag-hku>=1.4.9",
"mem0ai>=0.1.115",
"huggingface-hub[cli]<1.0",
"rembg>=2.0.69",
]
[project.optional-dependencies]
engine = [
"torch>=2.0,<2.11",
"torchaudio>=2.0,<2.11",
"torchvision>=0.15,<0.26",
"diffusers>=0.34",
"transformers>=4.46",
"accelerate>=1.0",
"opencv-python>=4.8,<4.12",
"xfuser>=0.4",
"librosa>=0.10",
"pyloudnorm>=0.1.1",
"easydict>=1.13",
"imageio>=2.34",
"imageio-ffmpeg>=0.5",
"xformers>=0.0.28",
"optimum>=1.22",
"safetensors>=0.4",
"ftfy>=6.2",
"regex>=2024.0.0",
"sentencepiece>=0.2",
]
models = [
"torch>=2.0,<2.11",
"torchaudio>=2.0,<2.11",
"torchvision>=0.15,<0.26",
"opencv-python>=4.8,<4.12",
"kornia>=0.7",
"insightface>=0.7",
"librosa>=0.10",
"scipy>=1.10",
"tqdm>=4.65",
"diffusers>=0.34",
"accelerate>=1.0",
"openai-whisper>=20240930",
]
local-audio = [
"torch>=2.0,<2.11",
"torchaudio>=2.0,<2.11",
"torchvision>=0.15,<0.26",
"funasr>=1.2.7",
"modelscope>=1.31.0",
"huggingface-hub>=0.30",
"sherpa-onnx>=1.12.0",
"soundfile>=0.12",
"librosa>=0.10",
"scipy>=1.10",
]
local-qwen3-tts-service = [
"qwen-tts>=0.1.1",
"transformers==4.57.3",
"accelerate>=1.12",
"torch>=2.0,<2.11",
"torchaudio>=2.0,<2.11",
"soundfile>=0.12",
"fastapi>=0.109",
"uvicorn[standard]>=0.27",
]
quicktalk-cpu = [
"imageio-ffmpeg>=0.5",
"onnxruntime>=1.24.3",
]
quicktalk-cuda = [
"imageio-ffmpeg>=0.5",
"onnxruntime-gpu>=1.24.0,<1.27",
]
local-cosyvoice-service = [
"fastapi>=0.109",
"uvicorn[standard]>=0.27",
"numpy>=1.24,<2",
"torch>=2.0,<2.11",
"torchaudio>=2.0,<2.11",
"soundfile>=0.12",
"openai-whisper>=20240930",
"modelscope>=1.31.0",
"huggingface-hub>=0.30",
"onnxruntime-gpu>=1.24.0",
"librosa>=0.10",
]
ascend = ["torch-npu>=2.1"]
demo = ["gradio>=5.0"]
dev = [
"pytest>=7.4",
"pytest-asyncio>=0.23",
"opencv-python-headless>=4.8,<4.12",
"ruff>=0.4",
"mypy>=1.8",
"types-PyYAML>=6",
"soundfile>=0.12",
"pre-commit>=3",
'mediapipe==0.10.21; python_version < "3.13" and platform_machine != "aarch64"',
'mediapipe==0.10.18; python_version < "3.13" and platform_machine == "aarch64"',
]
[project.scripts]
opentalking = "apps.cli.main:main"
opentalking-api = "apps.api.main:main"
opentalking-worker = "opentalking.runtime.main:main"
opentalking-unified = "apps.unified.main:main"
opentalking-download = "apps.cli.download_models:main"
opentalking-doctor = "apps.cli.doctor:main"
opentalking-quicktalk-bench = "apps.cli.quicktalk_bench:main"
opentalking-prepare-cache = "apps.cli.prepare_cache:main"
opentalking-persona = "apps.cli.persona:main"
[tool.setuptools]
include-package-data = true
[tool.setuptools.package-data]
opentalking = [
"assets/voices/system/*/*.json",
"assets/voices/system/*/*.txt",
"assets/voices/system/*/*.wav",
"assets/reference_drivers/*.wav",
"assets/scene_backgrounds/*.jpg",
]
[tool.setuptools.packages.find]
where = ["."]
include = ["opentalking*", "apps*"]
exclude = [
"apps.web*",
"apps.*.tests*",
"tests*",
"examples*",
"configs*",
"deploy*",
"docs*",
"scripts*",
]
[tool.ruff]
line-length = 100
target-version = "py310"
[tool.pytest.ini_options]
asyncio_mode = "auto"
testpaths = ["tests", "apps/api/tests"]
filterwarnings = [
"ignore:Using `httpx` with `starlette.testclient` is deprecated.*",
"ignore:Type google\\._upb\\._message\\..* uses PyType_Spec.*:DeprecationWarning",
]
[[tool.mypy.overrides]]
module = [
"opentalking.providers.*",
"opentalking.pipeline.*",
"opentalking.runtime.*",
"opentalking.voice.*",
"apps.api.tests.*",
"tests.*",
]
ignore_errors = true
[tool.uv]
conflicts = [
[
{ extra = "quicktalk-cpu" },
{ extra = "quicktalk-cuda" },
],
[
{ extra = "quicktalk-cpu" },
{ extra = "local-cosyvoice-service" },
],
[
{ extra = "demo" },
{ extra = "local-cosyvoice-service" },
],
]
[[tool.uv.index]]
url = "https://pypi.tuna.tsinghua.edu.cn/simple"
default = true
[[tool.uv.index]]
url = "https://www.piwheels.org/simple"
name = "piwheels"
explicit = true