code wiki / (root) / nx_edgar_balance.nx

nx_edgar_balance.nx

buildroot/runtime/nx_edgar_balance.nx

4626 B96 linesdepth 8pulls 13 transitivereach 0 importersview sourcekind tool
docsdependenciesstructsconstsfunctions

about

nx_edgar_balance.nx -- check OUR arithmetic against an AUTHORITATIVE SEC filing. The finance|statement-accuracy axis wants computed figures vs an authoritative filing. The accounting identity ASSETS = LIABILITIES + STOCKHOLDERS EQUITY is exactly that test: take the three facts the company itself filed, add two of them OURSELVES, and see whether we reproduce the third as filed. WHY THIS EXISTS RATHER THAN A PYTHON SCRIPT: I first ran this comparison with python doing the JSON parse and the addition. It matched 6/6 -- and proved nothing about US. The oracle may be third-party; the CAPABILITY must not be. Parsing and arithmetic are the capability here, so they belong in our code, using nx_edgar_lib's own fact extractor. ★★★★★IF A THIRD-PARTY TOOL DOES THE COMPUTING, THE MEASUREMENT IS ABOUT THAT TOOL. Input files are fetched by our sovereign TLS client (nx_https_get_cli2 --body). SEC is the oracle. license_tier: ORIGINAL No hw writes (Rule 26).

dependencies 1 imports · 0 importers

nx_edgar_lib.nx nx_edgar_balance.nx

imports: nx_edgar_lib.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main eb_p edgar_read sys_read eb_num edgar_num_last edgar_mkkey edgar_find_last

structs

none

consts

18const EB_CAP: i64 = 4194304

functions

20func eb_p(s: *u8) -> i64
called by 1: main
27func eb_num(v: i64) -> i64
called by 1: main
44func main(argc: i64, argv: *i64) -> i64