项目体检收尾:更新 CLAUDE.md 移除 EMOS/LGBM 引用,清理前端死字段,移除 git 跟踪的临时文件,VPS 关闭退役钱包监控
This commit is contained in:
@@ -63,3 +63,9 @@ frontend/.next-start.log
|
||||
.codex/skills/.system/**
|
||||
!.codex/prompts/
|
||||
!.codex/prompts/**
|
||||
tmp_apikey.js
|
||||
tmp_obs.js
|
||||
tmp_rctp.html
|
||||
playwright-home-check.png
|
||||
.codex-backend-*.log
|
||||
frontend-next-*.log
|
||||
|
||||
@@ -103,13 +103,12 @@ curl http://127.0.0.1:8000/metrics
|
||||
|
||||
| Directory | Purpose |
|
||||
|-----------|---------|
|
||||
| `src/analysis/` | DEB algorithm, trend engine, probability calibration (EMOS/LGBM), market alert engine, settlement rounding |
|
||||
| `src/analysis/` | DEB algorithm, trend engine, market alert engine, settlement rounding |
|
||||
| `src/auth/` | Supabase entitlement checks, Telegram group pricing |
|
||||
| `src/bot/` | Telegram bot handlers and orchestrator |
|
||||
| `src/database/` | SQLite-based runtime state, DB manager, daily/truth/training feature repositories |
|
||||
| `src/data_collection/` | Weather sources (METAR, TAF, Open-Meteo, JMA, KMA, MGM, NMC, Russia stations, settlement sources), city registry (52 cities), Polymarket readonly layer. Also: `madis_sources.py` (NOAA 5-min NetCDF), `amos_station_sources.py` (Korean runway sensors), `country_networks.py` (per-country provider routing + `_airport_primary_from_raw`) |
|
||||
| `src/data_mining/` | Historical data fetch utilities |
|
||||
| `src/models/` | LightGBM daily-high model training and feature engineering |
|
||||
| `src/onchain/` | Polygon wallet watcher, Polymarket wallet activity watcher |
|
||||
| `src/payments/` | Onchain checkout, event listener, confirm loop, contract audit |
|
||||
| `src/strategy/` | Trading strategy modules |
|
||||
@@ -120,7 +119,7 @@ curl http://127.0.0.1:8000/metrics
|
||||
| `frontend/components/dashboard/` | Dashboard UI components (map, sidebar, detail panel, modals, charts, scan terminal). `scan-root-styles.ts` is the CSS Module barrel, combining 22 module roots into one pre-composed className. `monitoring/` subdirectory: `MonitorPanel`, `monitor-temperature.ts` (temp resolution chain), `monitor-refresh-policy.ts`. |
|
||||
| `frontend/lib/` | Shared client logic: types (`dashboard-types.ts`, including `AirportCurrentConditions`, `CityDetail`), API client, chart utils, i18n, `source-freshness.ts` (per-source freshness with `expected_next_update_at`), dashboard utils |
|
||||
| `frontend/hooks/` | React hooks: dashboard store (global state), Leaflet map, chart helper |
|
||||
| `scripts/` | Operational scripts: probability calibration training, backfills, payment reconciliation. `supabase/` subdirectory: DB schema and migration SQL. |
|
||||
| `scripts/` | Operational scripts: backfills, payment reconciliation. `supabase/` subdirectory: DB schema and migration SQL. |
|
||||
| `config/` | YAML config (city list, weather settings, logging) |
|
||||
| `docs/` | Bilingual product & technical docs |
|
||||
|
||||
@@ -134,7 +133,6 @@ curl http://127.0.0.1:8000/metrics
|
||||
- **Configuration**: `.env.example` is the comprehensive reference (8 config sections: runtime, Telegram, weather cache, auth, ops, frontend, optional modules, Polygon monitor). Copy to `.env` and fill in secrets.
|
||||
- **Auth gating** (frontend middleware): Token-based (`POLYWEATHER_DASHBOARD_ACCESS_TOKEN`) or Supabase session-based (`POLYWEATHER_AUTH_ENABLED`). Local dev hosts bypass auth.
|
||||
- **CORS**: Allowed origins from `WEB_CORS_ORIGINS` env var (defaults: localhost:3000, polyweather-pro.vercel.app)
|
||||
- **EMOS/CRPS calibration**: Trainable but production should use `legacy` or `emos_shadow` engine; `emos_primary` only after local evaluation + manual rollout
|
||||
- **API proxy**: Frontend uses Next.js rewrites to proxy `/api/*` to the FastAPI backend; see `frontend/lib/api-proxy.ts` and `frontend/lib/backend-api.ts`
|
||||
|
||||
## Commit Convention
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
|
||||
> polyweather-frontend@1.5.4 start
|
||||
> next start -p 3002
|
||||
|
||||
▲ Next.js 15.5.12
|
||||
- Local: http://localhost:3002
|
||||
- Network: http://172.23.64.1:3002
|
||||
|
||||
✓ Starting...
|
||||
✓ Ready in 541ms
|
||||
@@ -309,12 +309,12 @@ export function OverviewPageClient() {
|
||||
<div className="text-[11px] text-slate-500">有真值</div>
|
||||
</div>
|
||||
<div className="rounded-xl bg-white/5 p-3 text-center">
|
||||
<div className="text-xl font-bold text-purple-400">{coverage.with_emos_samples ?? 0}</div>
|
||||
<div className="text-[11px] text-slate-500">有EMOS</div>
|
||||
<div className="text-xl font-bold text-purple-400">{coverage.with_feature_rows ?? 0}</div>
|
||||
<div className="text-[11px] text-slate-500">有特征</div>
|
||||
</div>
|
||||
<div className="rounded-xl bg-white/5 p-3 text-center">
|
||||
<div className="text-xl font-bold text-amber-400">{coverage.with_lgbm_samples ?? 0}</div>
|
||||
<div className="text-[11px] text-slate-500">有LGBM</div>
|
||||
<div className="text-xl font-bold text-amber-400">{td?.truth_records?.row_count ?? 0}</div>
|
||||
<div className="text-[11px] text-slate-500">真值行数</div>
|
||||
</div>
|
||||
</div>
|
||||
</CardContent>
|
||||
|
||||
@@ -40,8 +40,6 @@ export function TrainingPageClient() {
|
||||
const truth = td?.truth_records;
|
||||
const features = td?.training_features;
|
||||
const coverage = td?.city_coverage;
|
||||
const emos = td?.emos_samples as Record<string, unknown> | undefined;
|
||||
const lgbm = td?.lgbm_samples as Record<string, unknown> | undefined;
|
||||
const modelCities = td?.model_cities;
|
||||
|
||||
return (
|
||||
@@ -76,35 +74,6 @@ export function TrainingPageClient() {
|
||||
<StatRow label="城市总数" value={coverage?.total_cities ?? "—"} />
|
||||
<StatRow label="有真值" value={coverage?.with_truth_rows ?? "—"} />
|
||||
<StatRow label="有特征" value={coverage?.with_feature_rows ?? "—"} />
|
||||
<StatRow label="有EMOS" value={coverage?.with_emos_samples ?? "—"} />
|
||||
<StatRow label="有LGBM" value={coverage?.with_lgbm_samples ?? "—"} />
|
||||
</CardContent>
|
||||
</Card>
|
||||
</div>
|
||||
|
||||
<div className="grid grid-cols-1 md:grid-cols-2 gap-6">
|
||||
<Card>
|
||||
<CardHeader><CardTitle>EMOS 样本</CardTitle></CardHeader>
|
||||
<CardContent>
|
||||
{emos ? (
|
||||
<dl className="space-y-1 text-sm">
|
||||
{Object.entries(emos).map(([k, v]) => (
|
||||
<StatRow key={k} label={k} value={String(v)} />
|
||||
))}
|
||||
</dl>
|
||||
) : <span className="text-slate-500 text-sm">无数据</span>}
|
||||
</CardContent>
|
||||
</Card>
|
||||
<Card>
|
||||
<CardHeader><CardTitle>LGBM 样本</CardTitle></CardHeader>
|
||||
<CardContent>
|
||||
{lgbm ? (
|
||||
<dl className="space-y-1 text-sm">
|
||||
{Object.entries(lgbm).map(([k, v]) => (
|
||||
<StatRow key={k} label={k} value={String(v)} />
|
||||
))}
|
||||
</dl>
|
||||
) : <span className="text-slate-500 text-sm">无数据</span>}
|
||||
</CardContent>
|
||||
</Card>
|
||||
</div>
|
||||
@@ -119,7 +88,7 @@ export function TrainingPageClient() {
|
||||
{modelCities.strongest.map((c, i) => (
|
||||
<li key={i} className="text-sm text-slate-300">
|
||||
<span className="text-white font-medium">{c.city}</span>
|
||||
<span className="text-slate-500 ml-3">EMOS:{c.emos ?? "—"} LGBM:{c.lgbm ?? "—"}</span>
|
||||
<span className="text-slate-500 ml-3">真值:{c.truth_rows ?? "—"} 特征:{c.feature_rows ?? "—"}</span>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
|
||||
@@ -44,13 +44,9 @@ export type SystemStatusPayload = {
|
||||
total_cities?: number;
|
||||
with_truth_rows?: number;
|
||||
with_feature_rows?: number;
|
||||
with_emos_samples?: number;
|
||||
with_lgbm_samples?: number;
|
||||
};
|
||||
emos_samples?: Record<string, unknown>;
|
||||
lgbm_samples?: Record<string, unknown>;
|
||||
model_cities?: {
|
||||
strongest?: Array<{ city: string; emos?: number; lgbm?: number }>;
|
||||
strongest?: Array<{ city: string; truth_rows?: number; feature_rows?: number }>;
|
||||
gaps?: string[];
|
||||
};
|
||||
};
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 212 KiB |
@@ -1,3 +0,0 @@
|
||||
// This Synoptic API key is for weather.gov websites/queries
|
||||
var mesoToken='7c76618b66c74aee913bdbae4b448bdd';
|
||||
|
||||
-3098
File diff suppressed because it is too large
Load Diff
-1238
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user