code wiki / _hdl_build / nx_feed_extract.nx

nx_feed_extract.nx

buildroot/runtime/_hdl_build/nx_feed_extract.nx

15511 B267 linesdepth 2pulls 2 transitivereach 5 importersview sourcekind librarytopic feed
docsdependenciesstructsconstsfunctions

about

nx_feed_extract.nx -- RSS 2.0 + Atom feed extractor (grow-capabilities 2026-07-05, MEASURED: reddit's /.rss returns 200 + a real Atom feed while its SPA shell is empty and .json is 403). Feeds are the crawler-FRIENDLY non-JS content path a huge slice of the web exposes (news/blogs/forums/reddit) -- they carry real item title + link + summary AND list fresh URLs (crawl frontier). This parses <entry> (Atom) and <item> (RSS) into indexable text (title + stripped summary per item) + returns the item count. A parser, not a JS VM. Pairs with nx_feed_discover (find the <link rel=alternate> feed URL in a shell). license_tier: ORIGINAL

dependencies 1 imports · 4 importers

nx_syscalls.nx nx_feed_extract.nx nx_feed_extract_gate.nx nx_feedfetch.nx nx_url_index.nx nx_web_crawl_step.nx

imports: nx_syscalls.nx

imported by: nx_feed_extract_gate.nxnx_feedfetch.nxnx_url_index.nxnx_web_crawl_step.nx

structs

none

consts

9const K_MAGIC_65536: i64 = 65536
10const K_MAGIC_8192: i64 = 8192

functions

12func fe_lc(c: i64) -> i64 { if c >= 65 { if c <= 90 { return c + 32 } } return c }
14func fe_find(hay: *u8, from: i64, hlen: i64, ndl: *u8, nlen: i64) -> i64
25func fe_tag_inner(xml: *u8, s: i64, e: i64, tag: *u8, tlen: i64, out: *u8, cap: i64) -> i64
61func fe_decode_entities(inb: *u8, inlen: i64, out: *u8, cap: i64) -> i64
91func fe_strip_tags(inb: *u8, inlen: i64, out: *u8, cap: i64) -> i64
140func nx_feed_discover(html: *u8, hlen: i64, out_url: *u8, cap: i64) -> i64
160func nx_feed_item_at(xml: *u8, xlen: i64, idx: i64,
213func nx_feed_extract(xml: *u8, xlen: i64, out: *u8, out_cap: i64) -> i64