AstroResearch/Cargo.toml
Asfmq 8f1ed6d08c feat: 观测层跨源扩展——ZTF/TESS 时域 + Gaia XP 光谱还原 + FITS 预览与统一全源检索
后端(新增 ~4400 行):
- 新增 IRSA/IPAC、MAST 两客户端:ZTF 光变曲线(IRSA REST,CSV,免认证)、
  TESS 光变(MAST TIC cone search + LC FITS),均复用 SSRF 安全重定向 + 重试
- Gaia DR3 XP_CONTINUOUS 光谱还原(gaia_xp/):逆向 GaiaXPy calibrate() 算法,
  55 个 Hermite 系数 → 采样光谱;design_matrix 启动时 OnceLock 预计算一次。
  因 fitsio crate 遇 PD(55) 变长数组列会 panic,改用 fitsio-sys 直连 CFITSIO
  原生读取;新增 fitsio/fitsio-sys(vendored,无需系统 cfitsio)
- FITS 预览解析层(preview.rs):跨 LAMOST/SDSS/DESI/Gaia XP 的异构 FITS
  (BinTable/Image/Hermite 系数)统一归一化为 ObservationPreview JSON
  (Spectrum/LightCurve/Photometry/Image 标签枚举,OCP 可扩展)
- 测光 fetcher(photometry.rs):2MASS/AllWISE/Pan-STARRS/Gaia 四源,
  均复用 VizieR/Gaia TAP 查询、零新 HTTP 代码,配置驱动表名/列名差异
- 统一全源检索(unified.rs):在 dispatch 之上叠加多目标 × 多源并发 cone 扇出,
  失败隔离,两阶段(检索聚合 → 勾选后复用现有 download 端点批量下载)
- registry 注册 6 个新 fetcher + list_all_keys() 暴露全 (Source,ProductSpec)
  组合供前端细粒度勾选;Source 枚举增 5 个变体
- 新增 3 条路由:GET /observation/preview、POST /observation/unified/{search,resolve}

前端(新增 ~1600 行):
- UnifiedSearchPanel:三模式目标输入(坐标/天体名/CSV)+ 源 chip 筛选,
  按 (source,product) 分组展示候选源并支持勾选批量下载
- SpectrumPlot:手写内联 SVG 光谱折线图(零第三方绘图库),多段叠加 + hover 取值
- ObservationPreviewRenderer + useObservationPreview:预览渲染接入
- useObservation/ObservationResultCard/App 联动统一检索状态与下载链路
2026-07-09 00:20:29 +08:00

80 lines
2.6 KiB
TOML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

[package]
name = "astroresearch"
version = "0.1.0"
edition = "2021"
default-run = "astroresearch"
[lib]
path = "src/lib.rs"
[[bin]]
name = "astroresearch"
path = "src/main.rs"
[[bin]]
name = "health_check"
path = "src/bin/health_check.rs"
[[bin]]
name = "astroresearch_cli"
path = "src/bin/cli.rs"
[dependencies]
tokio = { version = "1", features = ["rt", "rt-multi-thread", "macros", "signal", "time", "fs", "net", "sync", "process"] }
axum = { version = "0.7", features = ["macros", "multipart"] }
tower-http = { version = "0.5", features = ["cors", "fs", "trace", "set-header", "catch-panic"] }
sqlx = { version = "0.7", features = ["runtime-tokio-rustls", "sqlite", "chrono", "json"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
reqwest = { version = "0.12", default-features = false, features = ["json", "stream", "multipart", "cookies", "rustls-tls"] }
dotenvy = "0.15"
quick-xml = { version = "0.31", features = ["serialize"] }
anyhow = "1.0"
thiserror = "1.0"
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter", "json"] }
futures-util = { version = "0.3", features = ["io"] }
rand = "0.8"
regex = "1.10"
chrono = { version = "0.4", features = ["serde"] }
sha1 = "0.10"
sha2 = "0.10"
hmac = "0.12"
subtle = "2" # 恒定时间密码比较,防时序侧信道攻击
base64 = "0.22"
urlencoding = "2.1"
url = "2.5"
html2md = "0.2"
flate2 = "1.1.9"
zip = "8.6.0"
uuid = { version = "1.23.2", features = ["v4"] }
tracing-appender = "0.2.5"
obscura-browser = { path = "libs/obscura/crates/obscura-browser", optional = true }
obscura-net = { path = "libs/obscura/crates/obscura-net", optional = true }
libsqlite3-sys = { version = "0.27.0", features = ["bundled"] }
sqlite-vec = "0.1.9"
clap = { version = "4", features = ["derive"] }
async-trait = "0.1"
async-stream = "0.3"
serde_yaml = "0.9"
notify = { version = "6", default-features = false, features = ["macos_kqueue"] }
tempfile = "3"
glob = "0.3"
walkdir = "2"
lru = "0.12"
git2 = { version = "0.18", default-features = false, features = ["vendored-libgit2"] }
dashmap = "6"
fitsio = { version = "0.21", features = ["fitsio-src"] } # FITS 解析fitsio-src 自带 CFITSIO 源码编译,无需系统装 cfitsio
fitsio-sys = { version = "0.5", features = ["fitsio-src"] } # 直接访问 CFITSIO C API读 Gaia XP 变长数组列 PD(55)fitsio crate 不支持)
[features]
default = []
obscura-inprocess = ["dep:obscura-browser", "dep:obscura-net", "obscura-browser/stealth", "obscura-net/stealth"]
[profile.release-min]
inherits = "release"
opt-level = "s"
lto = true
codegen-units = 1
strip = true