nx_fin_datasource.nx
buildroot/runtime/nx_fin_datasource.nx
about
nx_fin_datasource.nx -- the DATA-ACQUISITION doctrine as verified logic: how to get raw financial data LEGALLY
and POLITELY, free-first, and when we genuinely must license. Catalog SSOT = knowledge/finance/fin_datasources.conf;
human doc = knowledge/finance/DATA_SOURCES.md. Access tiers: 0=FREE_RAW (public-domain primary: SEC EDGAR, FRED,
gov), 1=FREE_TIER (keyed + rate-limited), 2=PAID (proprietary license). "Polite" = robots.txt respected + an
honest User-Agent where required + within the rate limit (throttle + cache). The HARD WALL: paid data without a
license is NEVER allowed (license it or use a free-raw alternative -- Cardinal 26 for data). Pure, i64.
license_tier: ORIGINAL
dependencies 1 imports · 1 importers
imports: nx_syscalls.nx
imported by: nx_fin_datasource_gate.nx
structs
| none |
consts
| 10 | const DS_FREE_RAW: i64 = 0 // public-domain / primary, free, no license |
| 11 | const DS_FREE_TIER: i64 = 1 // free but keyed + rate-limited |
| 12 | const DS_PAID: i64 = 2 // proprietary license required -- do NOT circumvent |
functions
| 15 | func ds_is_free(tier: i64) -> i64 { if tier <= DS_FREE_TIER { return 1 } return 0 } |
| 18 | func ds_prefer(a: i64, b: i64) -> i64 { if a < b { return a } return b } called by 1: main |
| 22 | func ds_polite_ok(robots_ok: i64, requires_ua: i64, ua_sent: i64, req_count: i64, rate_limit: i64) -> i64 |
| 31 | func ds_access_allowed(tier: i64, has_license: i64, robots_ok: i64, requires_ua: i64, ua_sent: i64, req_count: i64, rate_limit: i64) -> i64 |
| 40 | func ds_must_license(tier: i64, free_alt_exists: i64) -> i64 called by 1: main |