dce9e31bde
- 新增 JWT 认证模块,支持登录/注册/用户管理 - 新增文件上传接口,支持 .txt/.md/.html/.pdf/.docx 等格式解析入库 - 新增检索结果 AI 总结功能 - 新增文本去重缓存机制 - 新增全局认证夹具简化测试 - 新增配置项与环境变量支持 - 完善文档与测试覆盖
50 lines
1.1 KiB
TOML
50 lines
1.1 KiB
TOML
[project]
|
|
name = "qmdsearch"
|
|
version = "0.1.0"
|
|
description = "AI Agent 分层信息检索服务"
|
|
requires-python = ">=3.12"
|
|
dependencies = [
|
|
"fastapi>=0.115.0",
|
|
"uvicorn[standard]>=0.34.0",
|
|
"pydantic>=2.10.0",
|
|
"pydantic-settings>=2.7.0",
|
|
"qdrant-client>=1.12.0",
|
|
"redis>=5.2.0",
|
|
"httpx>=0.28.0",
|
|
"structlog>=24.4.0",
|
|
"openai>=1.58.0",
|
|
"pyjwt>=2.13.0",
|
|
"bcrypt>=5.0.0",
|
|
"python-multipart>=0.0.20",
|
|
"pypdf>=5.1.0",
|
|
"python-docx>=1.1.2",
|
|
"pypdfium2>=4.0.0", # PDF 渲染为图片供 OCR 使用
|
|
"rapidocr-onnxruntime>=1.3.8", # 扫描件 PDF OCR 降级(首次调用时下载约 25MB 模型)
|
|
]
|
|
|
|
[project.optional-dependencies]
|
|
dev = [
|
|
"pytest>=8.3.0",
|
|
"pytest-asyncio>=0.24.0",
|
|
"ruff>=0.8.0",
|
|
]
|
|
|
|
[build-system]
|
|
requires = ["hatchling"]
|
|
build-backend = "hatchling.build"
|
|
|
|
[tool.hatch.build.targets.wheel]
|
|
packages = ["app"]
|
|
|
|
[tool.ruff]
|
|
target-version = "py312"
|
|
line-length = 120
|
|
|
|
[tool.ruff.lint]
|
|
select = ["E", "F", "I", "N", "UP", "B"]
|
|
ignore = ["B008"] # FastAPI Depends() 在默认参数是标准用法,B008 为误报
|
|
|
|
[tool.pytest.ini_options]
|
|
asyncio_mode = "auto"
|
|
testpaths = ["tests"]
|