Expand description
Detect defects in generated text deterministically and report coverage in outbound technical artifacts.
The library performs no I/O and no clock reads. analyze is a pure
function of (input, config, policy). The embedded policy package is the
single rule source.
Re-exports§
pub use report::Coverage;pub use report::Finding;pub use report::Report;pub use waiver::Approval;pub use waiver::VerifyOutcome;pub use waiver::Waiver;
Modules§
- engine
- Compiled matching engines: two global Aho-Corasick automatons split by case mode, and one multi-pattern DFA served through an overlapping forward-plus-reverse adapter. All engines compile once per process.
- extract
- One markdown parse via
into_offset_iter(). The same walk builds prose regions, the section tree, the segmentation map, and structural stats.Event::Codeand text insideCodeBlockare never prose. - input
- Input contract: decoding, limits, BOM handling, commit-format split, and manifest field extraction. Fail-closed boundary.
- policy
- Policy package loading, validation, and digest.
- render
- The locally computed rendered view. No network, no external renderer: the comparison is derived from the same pulldown-cmark parse recorded in the extraction walk.
- report
- Output schema, deterministic ordering, escaping, and the emit-time span
invariant. A mapping bug returns
instrumentation_error. It emits no finding at the wrong bytes. - rules
- Rule evaluation beyond the word-set and regex-set engines: structural, ratio, and profile-contract rules. One module per rule family that needs code beyond the shared engines.
- skill
- SKILL.md snapshot generation from the policy package. The snapshot carries the policy digest and the per-profile core-rule stances.
- views
- The norm view: one owned String plus a run-length
(norm_range -> source_range)segment table resolved by binary search. Applied in order: NFC normalization, enumerated entity decoding, markdown escape resolution, default-ignorable (invisible) removal, soft break folding. - waiver
- Approval records, waivers, the authority floor, and
verify.
Structs§
- Config
- Deployment
- Deployment configuration. All fields optional.
- Limits
Enums§
- Analysis
Error - Field
- Commit-message field, used for per-field rule stances.
- Input
Format - Profile
- Stance
- A resolved rule stance for one profile and field.
- Waiver
Authority
Constants§
Functions§
- analyze
- Analyze one artifact. No input causes this function to panic.
- policy_
digest - The sha256 digest of the canonicalized embedded policy package.
- verify
- Verify a payload against an approval record.
now_unixis the caller’s clock reading as unix seconds.