Files
gyxx-flow/config/commands.json
T
wangyunlong 6f1c193f4b feat(product-commerce): 款式主键统一 style_id 并下线评价采集
采集端与 data-hub 统一用 style_id (= dim_style.id) 关联款式,style_name 降级为显示冗余。

款式主键:
- 14 张采集表加 style_id BIGINT + style_match_method + *_style_id_idx 索引
- 一律逻辑外键:不建 FOREIGN KEY,早期 10 个 *_style_id_fk 在 schema.sql 里幂等 DROP
- loader 下发 dim_style.id;db 层 attach_style_ids / resolve_style_ids_by_product 兜底
- 新增 backfill_style_id.py 三段回填(款名 / 日报按商品 ID / 广告表按 spu_id)
- 新增视图 v_style_id_coverage、v_style_unmatched_product、v_style_unmatched_source
- 实库补录 199 个商品 ID 到 67 款 spus;日报 style_id 覆盖 49.1% -> 79.0%,
  tm 广告 99.4% / jd 92.4% / dy 83.2%,其余 11 张 100%

评价采集下线:
- product_reviews 归档为 product_reviews_archived_20261101
- 差评改由 shop.{tmall,jd,dy}_negative_reviews.daily 采集,消费方读 v_negative_reviews
- 删除 import_product_reviews.py / orchestrate_review_collection.py 及相关命令与绑定
- dy_product_scraping 默认流程摘除评论采集,保留 --reviews-only

天猫广告:
- 迁移到独立表 tm_product_ad_daily_metrics,不再写 product_daily_metrics.raw_data

同批附带:
- 光合上传支持天猫新店 new_bag(仅黑曜石系列)
- 京东商智双月日历排除 -diff-month 补位格
- 万相主体搜索词覆盖 STYLE_SEARCH_KEYWORDS
- ERP 部分编码失败时用已成功编码销量兜底,避免整款归零
2026-11-01 16:43:27 +08:00

533 lines
13 KiB
JSON

{
"schema_version": 1,
"commands": [
{
"id": "content.metrics.collect_collaborators",
"module": "content_marketing",
"entry": "run_all.py",
"kind": "python"
},
{
"id": "content.mapping.refresh_self",
"module": "content_marketing",
"entry": "data/tools/refresh_self_mapping.py",
"kind": "python"
},
{
"id": "content.metrics.collect_self_bilibili",
"module": "content_marketing",
"entry": "self_bilibili_scraper.py",
"kind": "python"
},
{
"id": "content.metrics.collect_self_douyin",
"module": "content_marketing",
"entry": "chanmama_scraper.py",
"kind": "python"
},
{
"id": "content.metrics.collect_self_xiaohongshu",
"module": "content_marketing",
"entry": "self_xhs_scraper.py",
"kind": "python"
},
{
"id": "content.metrics.sync",
"module": "content_marketing",
"entry": "data/tools/sync_metrics_to_cmt_notes.py",
"kind": "python"
},
{
"id": "content.metrics.sync_self_video_metrics",
"module": "content_marketing",
"entry": "data/tools/sync_self_video_metrics.py",
"kind": "python"
},
{
"id": "content.marketing_report.generate",
"module": "content_marketing",
"entry": "daily_marketing_report.py",
"kind": "python",
"notification_workflow_id": "content.marketing_report.daily"
},
{
"id": "content.creator_report.generate",
"module": "content_marketing",
"entry": "data/tools/generate_creator_report.py",
"kind": "python"
},
{
"id": "content.summary.monthly",
"module": "content_marketing",
"entry": "monthly_summary_all.py",
"kind": "python"
},
{
"id": "content.notes_master.sync",
"module": "content_marketing",
"entry": "data/tools/sync_notes_master.py",
"kind": "python"
},
{
"id": "content.comments.collect_bilibili",
"module": "content_marketing",
"entry": "data/tools/batch_rescrape_bilibili.py",
"kind": "python"
},
{
"id": "content.comments.collect_xiaohongshu",
"module": "content_marketing",
"entry": "data/tools/batch_rescrape_xiaohongshu.py",
"kind": "python"
},
{
"id": "content.comments.collect_douyin",
"module": "content_marketing",
"entry": "data/tools/batch_rescrape_douyin.py",
"kind": "python"
},
{
"id": "content.summary.weekly",
"module": "content_marketing",
"entry": "weekly_summary_all.py",
"kind": "python"
},
{
"id": "content.mapping.rebuild",
"module": "content_marketing",
"entry": "data/tools/rebuild_mapping.py",
"kind": "python"
},
{
"id": "content.failed.retry",
"module": "content_marketing",
"entry": "data/tools/retry_failed.py",
"kind": "python"
},
{
"id": "shop.metrics.collect",
"module": "shop_intelligence",
"entry": "runners/run_shop.py",
"kind": "python"
},
{
"id": "shop.competitor.collect",
"module": "shop_intelligence",
"entry": "runners/run_peer_store.py",
"kind": "python"
},
{
"id": "shop.jd_self_operated.collect_brand",
"module": "shop_intelligence",
"entry": "collectors/jd_self_operated_brand_daily.py",
"kind": "python",
"default_args": [
"--start-date",
"{business_date}",
"--end-date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.jd_self_operated.collect_product",
"module": "shop_intelligence",
"entry": "collectors/jd_self_operated_product_daily.py",
"kind": "python",
"default_args": [
"--start-date",
"{business_date}",
"--end-date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.jd_customer_service.collect",
"module": "shop_intelligence",
"entry": "collectors/jd_customer_service_messages.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.jd_negative_reviews.collect",
"module": "shop_intelligence",
"entry": "collectors/jd_negative_reviews.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.jd_after_sales_issues.collect",
"module": "shop_intelligence",
"entry": "collectors/jd_after_sales_issues.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.douyin_customer_service.collect",
"module": "shop_intelligence",
"entry": "collectors/dy_customer_service_messages.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.tmall_negative_reviews.collect",
"module": "shop_intelligence",
"entry": "collectors/tmall_negative_reviews.py",
"kind": "python",
"default_args": [
"--start-date",
"{business_date}",
"--end-date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.tmall_customer_service.collect",
"module": "shop_intelligence",
"entry": "collectors/tmall_customer_service_messages.py",
"kind": "python",
"default_args": [
"--start-date",
"{business_date}",
"--end-date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.dy_negative_reviews.collect",
"module": "shop_intelligence",
"entry": "collectors/dy_negative_reviews.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.douyin_after_sales_quality.collect",
"module": "shop_intelligence",
"entry": "collectors/dy_after_sales_quality.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "shop.douyin_price_appeal",
"module": "shop_intelligence",
"entry": "collectors/dy_store_competitor_store_scraping.py",
"kind": "python",
"default_args": [
"--price-appeal",
"--execute"
]
},
{
"id": "product.persona.collect",
"module": "product_commerce",
"entry": "run_daily_persona.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}"
]
},
{
"id": "product.daily.orchestrate",
"module": "product_commerce",
"entry": "orchestrate_daily_collection.py",
"kind": "python"
},
{
"id": "product.alert.run",
"module": "product_commerce",
"entry": "commands/run_alerts.py",
"kind": "python",
"notification_workflow_id": "product.alert.daily"
},
{
"id": "product.online_stock_alert.run",
"module": "product_commerce",
"entry": "online_stock_alert.py",
"kind": "python",
"notification_workflow_id": "product.online_stock_alert.daily"
},
{
"id": "product.points_exchange_weekly.run",
"module": "product_commerce",
"entry": "points_exchange_weekly.py",
"kind": "python",
"default_args": [
"--from",
"{business_date}"
],
"notification_workflow_id": "product.points_exchange.weekly"
},
{
"id": "product.import.daily",
"module": "product_commerce",
"entry": "commands/import_daily.py",
"kind": "python"
},
{
"id": "product.tmall_wanxiang_ads.collect",
"module": "product_commerce",
"entry": "collect_tmall_wanxiang_ads.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "product.import.tmall_ads",
"module": "product_commerce",
"entry": "import_tmall_product_ads.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--execute"
]
},
{
"id": "product.jd_ad_costs.collect",
"module": "product_commerce",
"entry": "collect_jd_ad_costs.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "product.douyin_qianchuan_ads.collect",
"module": "product_commerce",
"entry": "collect_douyin_qianchuan_ads.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--headless"
]
},
{
"id": "product.import.douyin_qianchuan_ads",
"module": "product_commerce",
"entry": "import_douyin_qianchuan_ads.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--execute"
]
},
{
"id": "product.import.jd_ad_costs",
"module": "product_commerce",
"entry": "import_jd_ad_costs.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--execute"
]
},
{
"id": "product.style_analysis.run",
"module": "product_commerce",
"entry": "analyze_style.py",
"kind": "python"
},
{
"id": "product.main_image.collect_jd",
"module": "product_commerce",
"entry": "run_weekly_jd_main_image.py",
"kind": "python"
},
{
"id": "product.main_image.collect_tmall",
"module": "product_commerce",
"entry": "run_weekly_main_image.py",
"kind": "python"
},
{
"id": "product.video_upload.run",
"module": "product_commerce",
"entry": "upload_video_to_guanghe.py",
"kind": "python",
"default_args": [
"--store",
"all",
"--execute",
"--keep-browser-open-on-failure"
]
},
{
"id": "product.jd_video_upload.run",
"module": "product_commerce",
"entry": "upload_video_to_jd.py",
"kind": "python",
"default_args": [
"--anchor-record-id",
"recvrXTRWWFXeJ",
"--manual-login",
"--execute"
]
},
{
"id": "product.tmall_baibu_apply.old_chain_bag",
"module": "product_commerce",
"entry": "tmall_baibu_apply_old_chain_bag.py",
"kind": "python",
"default_args": [
"--execute"
]
},
{
"id": "product.tmall_baibu_apply.old_all_bag",
"module": "product_commerce",
"entry": "tmall_baibu_apply_old_all_bag.py",
"kind": "python",
"default_args": [
"--execute"
]
},
{
"id": "product.tmall_baibu_apply.old_all_3c",
"module": "product_commerce",
"entry": "tmall_baibu_apply_old_all_3c.py",
"kind": "python",
"default_args": [
"--execute"
]
},
{
"id": "product.tmall_baibu_apply.old_chain_3c",
"module": "product_commerce",
"entry": "tmall_baibu_apply_old_chain_3c.py",
"kind": "python",
"default_args": [
"--execute"
]
},
{
"id": "product.tmall_baibu_apply.new_chain_bag",
"module": "product_commerce",
"entry": "tmall_baibu_apply_new_chain_bag.py",
"kind": "python",
"default_args": [
"--execute"
]
},
{
"id": "product.tmall_baibu_apply.new_all_bag",
"module": "product_commerce",
"entry": "tmall_baibu_apply_new_all_bag.py",
"kind": "python",
"default_args": [
"--execute"
]
},
{
"id": "product.sales_sheet.sync",
"module": "product_commerce",
"entry": "sync_monthly_sales_sheet.py",
"kind": "python",
"default_args": [
"--month",
"{business_date}",
"--execute"
]
},
{
"id": "product.erp_all_shop_daily",
"module": "product_commerce",
"entry": "backfill_erp_all_shop_daily.py",
"kind": "python",
"default_args": [
"--from",
"{business_date}",
"--to",
"{business_date}"
]
},
{
"id": "product.erp_sales_theme_daily.collect",
"module": "product_commerce",
"entry": "collect_erp_sales_theme_daily.py",
"kind": "python",
"default_args": [
"--date",
"{business_date}",
"--execute"
]
},
{
"id": "product.hk_anpei_public_inventory.refresh",
"module": "product_commerce",
"entry": "public_sku_inventory_sheet.py",
"kind": "python"
},
{
"id": "product.backfill.run",
"module": "product_commerce",
"entry": "backfill_collect.py",
"kind": "python",
"default_args": [
"--from",
"{business_date}",
"--to",
"{business_date}"
]
},
{
"id": "product.market_rank.orchestrate",
"module": "product_commerce",
"entry": "orchestrate_market_rank_collection.py",
"kind": "python",
"notification_workflow_id": "product.market_rank"
},
{
"id": "supply.replenishment.arrival_sync",
"module": "supply_chain",
"entry": "orchestrator/scripts/collect_replenishment_arrival_sync.py",
"kind": "python"
},
{
"id": "supply.workflow.run",
"module": "supply_chain",
"entry": "run.py",
"kind": "python",
"default_args": [
"mcp-run",
"purchase-order-update"
]
}
]
}