code wiki / _hdl_build / nx_struct_extract.nx
nx_struct_extract.nx
buildroot/runtime/_hdl_build/nx_struct_extract.nx
about
nx_struct_extract.nx -- STRUCTURED-DATA extractor (grow-capabilities 2026-07-05): mine the high-quality
metadata modern sites embed for SEO/rich-results -- OpenGraph, Twitter-card, <meta name=description>,
<title>, and JSON-LD -- straight from the HTML. MEASURED motivation (SPA-shell probe): BBC/NYT ship
og:+jsonld+twitter in the shell; x.com ships og. This yields a CLEAN title + description (snippet) + type
+ site even when the visible <body> is JS-rendered, and IS the knowledge-card source the SERP lacked. It is
a PARSER, not a JS VM -- it does NOT execute client-only SPAs (reddit-class, no embedded data = still need
the browser-JS arc). Precedence: og > twitter > JSON-LD > <meta description>/<title>. license_tier: ORIGINAL
dependencies 1 imports · 4 importers
imports: nx_syscalls.nx
imported by: nx_bulk_index.nxnx_entity_card.nxnx_struct_extract_gate.nxnx_url_index.nx
structs
| none |
consts
| 9 | const K_MAGIC_1000000: i64 = 1000000 |
functions
| 11 | func se_lc(c: i64) -> i64 { if c >= 65 { if c <= 90 { return c + 32 } } return c } |
| 13 | func se_ci_at(hay: *u8, off: i64, hlen: i64, b: *u8, blen: i64) -> i64 |
| 21 | func se_attr(html: *u8, ts: i64, te: i64, name: *u8, nlen: i64, out: *u8, cap: i64) -> i64 |
| 65 | func se_meta(html: *u8, hlen: i64, keyattr: *u8, kalen: i64, key: *u8, klen: i64, out: *u8, cap: i64) -> i64 |
| 101 | func se_title(html: *u8, hlen: i64, out: *u8, cap: i64) -> i64 |
| 123 | func se_jsonld(html: *u8, hlen: i64, field: *u8, flen: i64, out: *u8, cap: i64) -> i64 |
| 161 | func nx_struct_extract(html: *u8, hlen: i64, |