build: switch to hatchling + src layout; tighten runtime deps

This commit is contained in:
2026-05-12 00:51:28 +08:00
parent 9ecb9ebf5f
commit a724ecf878
3 changed files with 152 additions and 20 deletions

View File

@@ -1,15 +1,39 @@
[project]
name = "ai-mouse"
version = "0.1.0"
version = "0.2.0"
description = "Human-like mouse trajectory and scroll wheel event generator (ONNX Runtime SDK)."
requires-python = ">=3.12,<3.14"
dependencies = [
"torch>=2.2.0",
"numpy>=1.26.0",
"onnxruntime>=1.17.0",
]
[project.urls]
Repository = "https://github.com/<owner>/ai_mouse"
[dependency-groups]
dev = [
"torch>=2.2.0",
"fastapi>=0.111.0",
"uvicorn>=0.29.0",
"scipy>=1.10.0",
"matplotlib>=3.8.0",
"pytest>=8.0.0",
"pytest-asyncio>=0.23.0",
"httpx>=0.27.0",
"onnx>=1.15.0",
]
[dependency-groups]
dev = ["pytest>=8.0.0", "pytest-asyncio>=0.23.0", "httpx>=0.27.0"]
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["src/ai_mouse"]
[tool.hatch.build.targets.wheel.force-include]
"src/ai_mouse/assets" = "ai_mouse/assets"
[tool.pytest.ini_options]
asyncio_mode = "auto"
testpaths = ["tests"]