Refactor dependencies and add test extra in pyproject.toml

• Pin httpx version in api extra
• Extract test dependencies to new extra
• Move httpx pin from evaluation to api
• Add api dependency to evaluation extra
• Separate test from evaluation concerns
This commit is contained in:
yangdx 2025-12-02 03:02:43 +08:00
parent 2ecf77efe2
commit 268e4ff6f1

View file

@ -76,7 +76,7 @@ api = [
"distro", "distro",
"fastapi", "fastapi",
"httpcore", "httpcore",
"httpx", "httpx>=0.28.1",
"jiter", "jiter",
"bcrypt>=4.0.0", "bcrypt>=4.0.0",
"psutil", "psutil",
@ -130,16 +130,18 @@ offline = [
"lightrag-hku[api,offline-storage,offline-llm]", "lightrag-hku[api,offline-storage,offline-llm]",
] ]
evaluation = [ test = [
# Test framework dependencies "lightrag-hku[api]",
"pytest>=8.4.2", "pytest>=8.4.2",
"pytest-asyncio>=1.2.0", "pytest-asyncio>=1.2.0",
"pre-commit", "pre-commit",
"ruff", "ruff",
# RAG evaluation dependencies (RAGAS framework) ]
evaluation = [
"lightrag-hku[api]",
"ragas>=0.3.7", "ragas>=0.3.7",
"datasets>=4.3.0", "datasets>=4.3.0",
"httpx>=0.28.1",
] ]
observability = [ observability = [