Reference · Systems & runtime
Metaprogramming & code rules
18 functions in 13 classes, grouped by what they do, each with the explanation the library gives of itself.
The story of this area, for a general reader: what a crafter does with it, an example run and its rated lanes, is on its Platform page.
The functions, by what they do
Testing and checking
- CanRevert reversibility (a data-model primitive) in stzRefinableCode
composed example
cCfg = 'vat = <R:PARAM name="vat" value="0.10" min="0" max="0.25">' o1 = new stzRefinableCode(cCfg) ? o1.CanRevert() #--> 0
composed from the signature, run for this page - HasMethod introspection in stzSelfDoc
oDoc = StzSelfDocQ("stzList") ? oDoc.HowTo("remove duplicates") ? oDoc.HasMethod("DuplicatesRemoved") #--> Q([...]).RemoveDuplicates() -- composed by grammar (remove duplicates) #--> 1library test - CheckRules Every method as [ class, method, line ] -- the locus a code RULE needs (MethodsOf gives names only). @aMethods is [ class, method, file, line ]. The uniform graph-owned verb: the code graph checks ITSELF against the code rule set, in the unified finding shape -- so an stzRuleReport can Collect it like any other graph. (StzCheckCode remains the per-line adapter for source snippets; this is the whole-graph, unified-shape path.) in stzCodeGraph
- HasCallEdges CALL edges (present only with a real-parse backend) in stzCodeGraph
Counting and measuring
- HowTo HowTo(intent) -- resolve a plain-English intent to a runnable method call on this class, DETERMINISTICALLY (no LLM). Two engines, unified: (1) the GRAMMAR composes a method name from the intent and grounds it against this class's real API; if the class implements it, that is the answer (highest confidence, it is derived not guessed). (2) Otherwise fall back to semantic RETRIEVAL (the ranker: reranker/embeddings/lexical). Returns a human line: the call template + how it was resolved + the name's grammatical gloss. in stzSelfDoc
oDoc = StzSelfDocQ("stzList") ? oDoc.HowTo("remove duplicates") ? oDoc.HasMethod("DuplicatesRemoved") #--> Q([...]).RemoveDuplicates() -- composed by grammar (remove duplicates) #--> 1library test - NumberOfMethods introspection in stzSelfDoc
composed example
o1 = new stzSelfDoc("stzListOfStrings") ? o1.NumberOfMethods() #--> 171composed from the signature, run for this page - NumberOfInheritedMethods How many of the harvested methods are inherited (defined by an ancestor). in stzSelfDoc
composed example
o1 = new stzSelfDoc("stzListOfStrings") ? o1.NumberOfInheritedMethods() #--> 171composed from the signature, run for this page
Replacing and setting
- SetLineageCapacity How many decisions this governance keeps. Lowering it below the current count drops the oldest immediately -- and counts them. in stzGovernance
- SetRiskFor Governance config MUST go through these delegators: GovernedBy stores a COPY (governance is pure Haro lists, no shared handle), so mutating the caller's original would leave this copy stale (the Haro aliasing doctrine). Delegating keeps @oGov the one live truth. Declare a point's refinement risk tier ("refine-<point>"). in stzRefinableCode
- SetAllowRefine Grant the actor permission (CAN) to refine a point. in stzRefinableCode
- SetAuthorityLevel Set the actor's authority (SHOULD): :Advisory/:Delegated/ :Autonomous/:EmergencyOverride. in stzRefinableCode
Adding
- AddTestSamples Union in the TEST SAMPLES of the given test topics (L3): every narrated Then("desc", code, expected) becomes an "(example)" record -- a natural query can surface a REAL verified call. Chainable; re-index on next Ask. in stzLibDoc
Converting
- As EXECUTION TRUST POSTURES (5.8) -------------------------------------- A posture says WHERE a refinement came from. Trust rank (high -> low): :trusted (3, in-process/verified) > :external (2, an external tool) > :sandboxed (1, isolated run) > :llm (0, LLM-composed). A proposal defaults to :trusted; As(posture) declares otherwise for the next To(). The posture rides into the audit chain; a point's TrustFloor refuses anything below the required rank (LLM-composed edits to a critical knob can be forbidden without forbidding a human's). in stzRefinableCode
- To apply a value to the pending point THROUGH the gate. Returns [ :admitted, :why ]; on rejection the source is unchanged. in stzRefinableCode
Showing, drawing and formatting
- Show explain (deterministic, templated -- no model) in stzSelfDoc
Reading and writing
- LoadFrom persistence (*.zgov) ------------------------------------------------------ LOAD a .zgov back INTO this governance -- the mirror of Save(), and the object's OWN act (LoadFrom: 'Load' is a Haro keyword). in stzGovernance
- OpenCommitment 3. COMMITMENT STATE (forward-only) in stzGovernance
- Save persistence (*.zrfn) in stzRefinableCode
The explanations are the ones the library gives of itself, read from its documentation comments on 2026-10-01 04:14, from the library at commit 0e72e2e2c, by the library's own stzSelfDoc over 635 class sources.
The classes of this area
- stzGovernance · 42 methods
- stzRefinableCode · 36 methods
- stzCodeGraph · 35 methods
- stzSelfDoc · 16 methods
- stzPredicateSet · 13 methods
- stzRingCodeGraph · 12 methods
- stzLibDoc · 10 methods
- stzPyCodeGraph · 5 methods
- stzJsCodeGraph · 2 methods
- stzCodeDeepRuleSet · 1 methods
- stzCodeProjectRuleSet · 1 methods
- stzCodeRule · 1 methods
- stzCodeRuleSet · 1 methods

