14#include <nlohmann/json.hpp>
43 std::vector<std::pair<std::string, std::string>>
roles;
const char * severity_name(Severity s)
const Catalogue & builtin_catalogue()
The catalogue embedded at build time (src/crules/catalogue.json), parsed once.
Catalogue parse_catalogue(std::string_view json_text)
Parses the catalogue JSON.
Signal
What a detector looks at (doc 15 §3.1).
Catalogue load_catalogue_file(const std::string &path)
const char * signal_name(Signal s)
std::string_view builtin_catalogue_json()
std::size_t rule_count() const
std::vector< Category > categories
int suggest
confidence thresholds (doc 15 §3.2)
double prop_delay_outer
Skew ps -> mm without a stackup (doc 15 §4, §5.3): conservative FR-4 delays, outer / inner layers.
int index_of(std::string_view id) const
-1 if absent
double stitch_via_within_mm
General high-speed guidance (defaults.general_high_speed): a stitching via within this distance of a ...
std::vector< RuleSpec > rules
std::vector< std::pair< std::string, std::string > > roles
name -> description, catalogue order
bool has_signal(Signal s) const
std::vector< Detector > detect
int weight
0..100; confidence = min(100, sum of matching weights)
std::string pattern
ECMAScript regex (case-insensitive), or a topology name for Signal::Topology.
std::regex re
compiled pattern (unused for topology)
nlohmann::ordered_json params
std::vector< std::string > sources
std::vector< std::string > applies_to
std::vector< std::string > enforce
bool enforced_in(std::string_view stage) const