Skip to content
Unverified: This page has not yet been anchored to automated code tests.

vox-audit API Reference (generated)

Crate: vox-audit · Version: 0.6.0 · Target: Library (lib.rs)

Umbrella CR-L gate runner. Hosts the vox audit <thing> subcommand registry and implements the canonical JSON report shape defined in contracts/ci/vox-audit-contract.v1.yaml.

Umbrella crate hosting the [Subcommand] trait and the canonical vox audit <thing> registry. One subcommand per CR-L gate (CR-L0..CR-L8 / CR-L-retirement) from docs/src/architecture/v1-release-criteria.md §5, behaviorally conforming to contracts/ci/vox-audit-contract.v1.yaml.

Council-ratified 2026-05-15 (D21 in docs/src/architecture/v1-llm-target-implementation-plan-2026.md §8.1): new top-level crate, NOT a submodule of vox-cli — vox-cli is at TOESTUB sprawl limit and this concern deserves its own home.

  • Library API (this file + report.rs + subcommands/): callable from tests, vox-cli, and the vox-gui audit panel.
  • CLI binary (src/main.rs): the user-facing vox-audit executable.
  • Single planning anchor (contracts/ci/vox-audit-contract.v1.yaml) declares: CLI flag set, exit-code convention, telemetry namespace, per-subcommand gate / corpus / block_ga / cost_metered fields.
FeatureDefault / Enables
ci-gates—
default—
DependencyKind
vox-code-auditNormal
vox-compilerNormal
vox-configNormal
vox-containerNormal
vox-deploy-codegenNormal
vox-http-clientNormal
vox-packageNormal
vox-project-scaffoldNormal
vox-telemetryNormal
ModuleDescription
aggregator—
core_gates—
ga—
recorder—
report—
subcommands—
StructDescription
CommonArgsCommon arguments shared by every subcommand.
RunOutcomeOne run outcome: the report and the exit code the binary should return.
EnumDescription
TierRelease-criteria tier. Declaration order IS the GA evaluation order: foundation gates are evaluated and reported before any downstream gate (see CR-F0 in docs/src/architecture/v1-release-criteria.md and the --gate all --strict-block-ga roll-up).
CrlGateCR-L gate identifier — one variant per row in contracts/ci/vox-audit-contract.v1.yaml §subcommands.
TraitDescription
SubcommandTrait every vox audit <thing> subcommand implements. The umbrella runner (vox audit all) iterates over registered subcommands in CrlGate::all() order and aggregates their outcomes into a combined report at contracts/reports/audit-all/<date>.json.
FunctionDescription
as_strStable lowercase tier name used in the GA snapshot rows.
thing_nameStable name as used by vox audit <thing> and the report thing field.
block_gaPer-contract: does failure of this gate block GA? Tooling gates (non-CR-L) always return false — they exist to keep the corpus healthy during development, not to gate release.
cost_meteredPer-contract: does this gate meter LLM cost during measurement?
tierWhich release-criteria tier this gate belongs to. The CR-L gates are §3.5 Product; the stdlib-coverage gate is Tooling. Foundation / Distribution / GUI variants enter as their gates land (Phase 0+).
allIterator over every registered gate, in display order.
workspace_rootWorkspace-root locator: walks up from CARGO_MANIFEST_DIR looking for the top-level Cargo.toml that contains [workspace]. Used by subcommands to resolve contract paths.
registryBuild the canonical registry of subcommands (2 CR-F foundation gates + 9 CR-L gates + 1 tooling gate). Order matches CrlGate::all() and contracts/ci/vox-audit-contract.v1.yaml §subcommands. Tooling gates appear after the CR-L block.
gate_from_nameResolve a [CrlGate] from a stable thing-name string.
run_gateRun a single subcommand by gate, returning its outcome. Emits a vox.audit.run telemetry event for every invocation per contracts/ci/vox-audit-contract.v1.yaml §telemetry (A11, ratified 2026-05-15). record_event! is a no-op when no recorder is registered, so the emission adds zero cost to non-instrumented runs.
run_allRun every registered subcommand and aggregate their outcomes into a combined report at contracts/reports/audit-all/<date>.json. Worst-case exit code semantics per contract §umbrella: - 0 if all sub-runs return 0 - 1 if any sub returns 1 and none return 2 or 3 - 2 if any sub returns 2 and none return 3 - 3 if any sub returns 3 Emits one vox.audit.run telemetry event per sub-gate (with umbrella_run = true) per A11 contract compliance.
run_ga_snapshotRun every registered gate (foundation first per CR-F0) plus the standalone product binaries, fold them into a [ga::GaSnapshot] with blocked_by_foundation semantics, and (when args.write_canonical_report) write contracts/reports/_snapshot/<UTC>.json. This is the spine behind vox audit --gate all --strict-block-ga.
aggregate_exit_codeAggregate-exit-code per contract §umbrella.