A data pipeline system that fetches weather data from NOAA and serves it via a REST API with DLC (Discreet Log Contract) attestation support.
- Live site: 4casttruth.win
- Feel free to pull the parquet files and use in your own data analysis
[NOAA API] <- [daemon] -> parquet files -> [oracle] <- parquet files <- [browser DuckDB]
Components:
- daemon - Background process that pulls data from NOAA, transforms it into parquet files, and pushes to the oracle
- oracle - REST API that stores parquet files, serves them via browser UI, and provides DLC attestation
- ui - Browser interface using DuckDB-WASM for client-side querying of parquet files
- core - Shared library for configuration loading and utilities
# Enter development shell
nix develop
# Build both binaries
cargo build --workspace
# Or use just commands
just build# Run daemon (fetches NOAA data)
just run-daemon
# Run oracle (serves data and API)
just run-oracle
# Run oracle with pre-existing weather data
just run-oracle-standalone /path/to/weather/dataConfiguration follows XDG Base Directory Specification. Files are searched in order:
- Environment variable (
ORACLE_CONFIG/DAEMON_CONFIG) - Current directory (
./oracle.toml/./daemon.toml) - XDG config (
~/.config/noaa-oracle/oracle.toml) - System config (
/etc/noaa-oracle/oracle.toml)
Example configurations are in the config/ directory:
config/oracle.example.tomlconfig/daemon.example.toml
[oracle]
host = "127.0.0.1"
port = "9800"
log_level = "info"
# Path to weather data (parquet files)
weather_dir = "/var/lib/noaa-oracle/weather"
# Path to UI files
ui_path = "/var/lib/noaa-oracle/ui"
# Oracle private key for DLC attestation
oracle_private_key = "/etc/noaa-oracle/oracle.pem"[daemon]
log_level = "info"
# Where to store downloaded parquet files
data_path = "/var/lib/noaa-oracle/data"
# Oracle endpoint to push files to
oracle_url = "http://localhost:9800"
# Fetch interval in seconds (default: 3600 = 1 hour)
fetch_interval = 3600Add to your NixOS configuration:
{
inputs.noaa-oracle.url = "github:tee8z/noaa-oracle";
outputs = { self, nixpkgs, noaa-oracle, ... }: {
nixosConfigurations.myhost = nixpkgs.lib.nixosSystem {
modules = [
noaa-oracle.nixosModules.default
{
services.noaa-oracle = {
enable = true;
oracle = {
enable = true;
host = "0.0.0.0";
port = 9800;
};
daemon = {
enable = true;
fetchInterval = 3600;
};
};
}
];
};
};
}# Enter dev shell
nix develop
# Format code
just fmt
# Run clippy
just clippy
# Run tests
just test
# Build release
just release- Observations: MADIS METAR via Aviation Weather API
- Forecasts: NOAA Graphical Forecasts
Data is updated hourly by NOAA; the daemon respects this by fetching once per hour.
- No remote database needed - just a file server, cheap to run
- Client-side querying via DuckDB-WASM for flexible analysis
- Simple, decoupled components that scale independently
- Immutable data model (snapshots over time)
MIT