Commit Graph

27 Commits

Author SHA1 Message Date
2569718930@qq.com fe6f8b43b0 DEB 接入小时级误差计算,多模型权重基于每日+小时 MAE 融合
新增 compute_hourly_model_errors 聚合逐模型小时 MAE/RMSE

新增 _blend_mae 按样本数加权混合每日/小时误差(24样本=70%小时权重)

calculate_dynamic_weights 从 daily_record 读取 hourly_error 参与权重计算

update_daily_record 接受并持久化 hourly_error 字段

Tested: ruff check, pytest 186/186
2026-05-21 21:03:49 +08:00
2569718930@qq.com 4c6a93498c 移除源码中硬编码的 API token:NOAA MesoWest 密钥和 CWA 占位符 2026-05-19 15:18:49 +08:00
2569718930@qq.com b93a75516d 移除未使用的 Groq 和 Meteoblue 服务代码及配置 2026-05-19 00:05:07 +08:00
2569718930@qq.com 6c08a68413 @
性能与用户体验全面优化

    前端性能:
    - 移除 Three.js 依赖(~600KB),天气粒子改为纯 CSS 动画 + Canvas 2D
    - Google Fonts 切换为 next/font 自托管,消除跨域字体请求
    - 合并 ScanTerminalLightTheme.module.css (37KB) 到主 CSS,亮/暗主题统一用 CSS 变量
    - 新增 /api/dashboard/init 聚合端点,首次加载 4 次往返 → 1 次
    - 添加 Service Worker 静态资源缓存,修复 PWA manifest 配置

    用户体验:
    - 新增全局错误边界 error.tsx / global-error.tsx,崩溃不再白屏
    - 决策卡和城市详情的更新时间改为相对时间("15秒前"),每秒自动刷新
    - 数据陈旧时状态标签从青色切换为琥珀色提示

    DEB 算法增强:
    - 市场扫描路径接入 Open-Meteo 多模型数据(ECMWF/GFS/ICON/JMA/HRDPS 等)
    - MAE 计算加入时间衰减(decay_factor=0.85),近期模型误差权重更高

    Scope-risk: MEDIUM — 全量 170 测试通过,前端 TypeScript/build 通过,ruff 零告警
    Tested: python -m pytest -q (170 passed), npx tsc --noEmit (0 errors), npm run build (success), ruff check .
@
2026-05-14 21:31:05 +08:00
2569718930@qq.com 9ec86e0504 Group model stack and dedupe DEB families 2026-04-17 00:35:48 +08:00
2569718930@qq.com 611e2d9009 Expand calibration samples and extend training retention 2026-04-16 01:05:43 +08:00
2569718930@qq.com 53d2ae4c10 Retire dual storage mode and default runtime state to sqlite 2026-04-16 00:52:55 +08:00
2569718930@qq.com a5b5711863 Remove AI analysis and rank cities by recent DEB performance 2026-04-05 07:13:00 +08:00
2569718930@qq.com 781c247952 Add ops dashboards for training data and model coverage 2026-04-03 00:57:19 +08:00
2569718930@qq.com 7237278f5a Generalize NOAA settlement handling across dashboard and docs 2026-03-27 20:58:38 +08:00
2569718930@qq.com 2007ded86d Add HKO-backed Shek Kong settlement and history support 2026-03-27 20:11:08 +08:00
2569718930@qq.com 4ac690228e Bootstrap recent METAR history for new cities 2026-03-24 01:02:18 +08:00
2569718930@qq.com 5ac5caf3ef Preserve model forecasts and add gap backfill script 2026-03-23 23:41:56 +08:00
2569718930@qq.com 43749fff7c Unify runtime state in SQLite and add rollout observability 2026-03-20 23:00:07 +08:00
2569718930@qq.com 1c84893bed Add CI and shadow calibration reporting 2026-03-20 20:59:30 +08:00
2569718930@qq.com dbf10253a8 feat: Implement multi-source weather data collection with caching, rate limiting, and disk persistence. 2026-03-20 13:35:34 +08:00
2569718930@qq.com de6cf68ee7 feat: Implement reconciliation of recent actual high temperatures using METAR data and integrate it into the DEB command. 2026-03-12 02:43:19 +08:00
2569718930@qq.com 1060945d08 feat: Implement Dynamic Ensemble Blending (DEB) algorithm with historical data management, dynamic weight calculation, and accuracy tracking. 2026-03-12 02:32:10 +08:00
2569718930@qq.com aab4477ab3 feat: Implement the PolyWeather dashboard including frontend components, data collection, analysis, and API endpoints. 2026-03-10 04:45:40 +08:00
2569718930@qq.com 3c2749544f feat: record mu and probability snapshots in daily_records for accuracy tracking 2026-03-04 02:41:21 +08:00
2569718930@qq.com 7926cedc97 feat: Introduce a web interface with an interactive map and implement a Dynamic Ensemble Blending (DEB) algorithm for weather prediction. 2026-03-03 21:27:57 +08:00
2569718930@qq.com c8a7fe8548 fix(ci): format code and fix ruff lintings issues 2026-03-03 00:12:16 +08:00
2569718930@qq.com 3ed775816b fix: cast to float in get_deb_accuracy to fix str subtraction error 2026-03-01 19:02:20 +08:00
2569718930@qq.com ee535e9efa feat: DEB accuracy tracking - save predictions, compute WU hit rate and MAE 2026-03-01 15:53:29 +08:00
2569718930@qq.com 305e2e7a6b feat: auto-prune DEB records older than 14 days to prevent unbounded growth 2026-02-27 22:08:13 +08:00
2569718930@qq.com 596d8144a7 perf(deb): add file lock & caching for high concurrency queries 2026-02-27 01:47:38 +08:00
2569718930@qq.com f60f5601d9 feat(ai): integrate Dynamic Ensemble Blending & simplify user output 2026-02-27 01:43:46 +08:00