Files
intl_news/pyproject.toml
T
simon d4a55bcaaa feat: M9 日报结构化入库(HTML 改为写入 MySQL news_report/news_event,report_type=intl)
- 新增 report_db/ 包(models/schema/db,复用 news 项目实现,幂等 upsert)
- reporter.py: _build_report_data + generate_report 写库返回 report_id
- pipeline/cli 适配 report_id 返回值;HTML 渲染/上传保留 deprecated
- 新增 tests/test_report_db.py;.env.example 增加 NEWS_DB_* 配置
- 已部署 pi5 并验证:真实生成 report_id=184(12 事件)+ 幂等覆盖
2026-08-04 11:09:17 +08:00

74 lines
1.4 KiB
TOML

[project]
name = "en-news"
version = "0.1.0"
description = "国际财经新闻抓取与深度研究平台"
readme = "README.md"
requires-python = ">=3.11,<3.13"
license = { text = "MIT" }
authors = [
{ name = "summer" }
]
dependencies = [
"crawl4ai>=0.5.0",
"trafilatura>=2.0.0",
"pydantic>=2.0.0",
"httpx>=0.28.0",
"pyyaml>=6.0",
"apscheduler>=3.10.0",
"fastmcp>=0.1.0",
"qdrant-client>=1.12.0",
"typer>=0.15.0",
"rich>=13.0.0",
"psutil>=7.2.2",
"htmldate>=1.10.0",
"openai>=2.43.0",
"python-dotenv>=1.2.2",
"markdown>=3.10.2",
"pymysql>=1.2.0",
]
[project.optional-dependencies]
dev = [
"pytest>=8.0.0",
"pytest-asyncio>=0.25.0",
"pytest-cov>=6.0.0",
"ruff>=0.8.0",
]
[project.scripts]
en-news = "app.cli:app"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = [
"crawler",
"extractor",
"dedup",
"translator",
"llm",
"embedding",
"vectorstore",
"scheduler",
"mcp_server",
"app",
]
[tool.ruff]
target-version = "py311"
line-length = 100
[tool.ruff.lint]
select = ["E", "F", "I", "N", "W", "UP"]
[tool.ruff.lint.per-file-ignores]
"scheduler/reporter.py" = ["E501"] # 内嵌 HTML 模板 CSS 行较长
"report_db/schema.py" = ["E501"] # DDL SQL 语句较长,与 news 项目 schema 保持一致
[tool.pytest.ini_options]
testpaths = ["tests"]
asyncio_mode = "auto"