code wiki / (root) / nx_fin_extract.nx

nx_fin_extract.nx

buildroot/runtime/nx_fin_extract.nx

13373 B144 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind tooltopic fin
docsdependenciesstructsconstsfunctions

about

nx_fin_extract.nx -- RUNG 2 of THE NISHI FINANCIAL ECOSYSTEM researcher: EXTRACT stage. Streams each sovereignly-fetched knowledge/fetched/fin_*.raw (Wikipedia HTML) through the team's own nx_html_to_text renderer (strips tags, decodes 110+ entities, suppresses script/style, collapses whitespace) into clean, dated plain-text dossiers in the Nishi LIBRARY (knowledge/library/). 100% sovereign (no curl/gcc/3rd-party parser) -- reuses nx_html_to_text (DRY #15). Buffers are reused per file so no per-file accumulation. Re-runnable (overwrites). expect_exit: 0 license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_html_to_text.nx nx_fin_extract.nx

imports: nx_syscalls.nxnx_html_to_text.nx

imported by: nobody (leaf or entry point)

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

main sys_mmap extract_one read_all sys_openat_rd sys_read sys_close fx_puts sys_write fx_find nx_html_to_text nx_html_to_text_x h2t_state_new sys_mmap ↻ sys_mmap ↻ h2t_scan_tag h2t_skip_to_gt h2t_scan_name h2t_is_name h2t_is_block_tag h2t_name_eq_lit h2t_lc h2t_lc ↻ h2t_is_suppress_tag h2t_name_eq_lit ↻ h2t_emit_newline h2t_name_eq_lit ↻ h2t_emit_raw h2t_find_href h2t_lc ↻ h2t_is_name ↻ h2t_decode_entity h2t_decode_numeric h2t_is_name ↻ nx_html_entity_lookup h2t_emit_codepoint h2t_emit_text_byte h2t_is_ws h2t_emit_text_byte ↻ sys_munmap

structs

none

consts

9const K_MAGIC_8388608: i64 = 8388608

functions

11func fx_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 }
called by 2: extract_onemain calls 1: sys_write
12func fx_putn(v: i64) -> i64
called by 2: extract_onemain calls 2: sys_writesys_mmap
23func read_all(path: *u8, buf: *u8, cap: i64) -> i64
38func fx_find(text: *u8, n: i64, needle: *u8, from: i64) -> i64
called by 1: extract_one
51func extract_one(inpath: *u8, outpath: *u8, raw: *u8, txt: *u8, cap: i64) -> i64
70func main() -> i64