Skip to main content

Module parsers

Module parsers 

Source
Expand description

Dual-format argument parser: accepts Unix epoch and RFC 3339. Input format parsers (timestamp, range validators).

Constants§

CANONICAL_RELATIONS
The 12 well-known relation types from v1.0.0.

Functions§

is_canonical_relation
Returns true when the relation is one of the 12 canonical types.
normalize_relation
Normalizes a relation string: lowercase + hyphens to underscores.
parse_bool_flexible
Flexible boolean parser for Clap env var integration.
parse_expected_updated_at
Accepts a Unix epoch (integer >= 0) or RFC 3339 timestamp and returns the Unix epoch.
parse_k_range
Validates -k/--k for recall and hybrid-search to the inclusive range 1..=4096.
parse_relation
Clap value_parser for --relation: normalizes and validates format.
validate_relation_format
Validates that a normalized relation matches ^[a-z][a-z0-9_]*$.
warn_if_non_canonical
Emits a tracing::warn! when the relation is not in CANONICAL_RELATIONS.