pub struct Signals {Show 16 fields
pub label_predicate: Option<String>,
pub default_lang: Option<String>,
pub base_iri: Option<String>,
pub time_predicates: Vec<String>,
pub numeric_predicates: Vec<String>,
pub link_predicates: Vec<String>,
pub annotation_predicates: Vec<String>,
pub quoting_predicates: Vec<String>,
pub annotated_statement: Option<(String, String)>,
pub geo_wkt: bool,
pub geo_latlong: bool,
pub temporal_extent: Option<(String, String)>,
pub spatial_bbox: Option<[f64; 4]>,
pub text_index: Option<TextIndexSignal>,
pub permutations: Option<PermutationsSignal>,
pub quoted_triples: Option<QuotedTriplesSignal>,
}Expand description
Detected affordances — the index-free hints a newcomer (or the query-library generator) needs to know what the data supports and how to address it. Every field is optional/empty when the corresponding signal is absent, so geo/time query families are emitted only when the data actually has geometry/time.
Fields§
§label_predicate: Option<String>Most frequent labelling predicate (rdfs:label/skos:prefLabel/…).
default_lang: Option<String>Dominant non-empty language tag over literal objects.
base_iri: Option<String>Dominant subject namespace — the dataset’s own base IRI.
time_predicates: Vec<String>Temporal predicates, ranked by frequency (most-used first).
numeric_predicates: Vec<String>Predicates whose objects are numeric (xsd integer/decimal/double/float),
ranked by frequency — candidates for MIN/AVG/MAX value-range queries.
link_predicates: Vec<String>Cross-dataset link predicates present (owl:sameAs/skos:exactMatch/…).
annotation_predicates: Vec<String>Predicates that make a statement about a statement — the predicate
of a statement whose subject is a quoted triple
(<< s p o >> :recordedBy :who) — ranked by frequency.
Derived from the triples, and therefore stored, unlike the
Signals::quoted_triples presence bit below, which is read off the
header at display time. The two answer different questions and neither
substitutes for the other: presence says will I meet triple terms in
this file, which every already-published file can answer for free;
this says which vocabulary annotates statements here, which only a
pass over the statements knows and which is what a starter query has to
be written in. Empty on the overwhelming majority of datasets, and the
whole qt-* query family is gated on it.
quoting_predicates: Vec<String>Predicates whose object is a quoted triple (:claim :states << s p o >>) — the other place a triple term can stand — ranked by
frequency. A dataset can have one shape and not the other, and a query
written for the wrong one returns nothing, so they are counted apart.
annotated_statement: Option<(String, String)>The commonest annotated statement shape: (the predicate inside the quoted triple, the predicate that annotates it), for a statement this
graph was seen both to assert (s p o) and to annotate
(<< s p o >> :about ?v).
The pair is the witness — the same role class_links plays for
LABELED_CLASS. annotation_predicates[0] and the commonest quoted
predicate are two independent maxima and need not describe the same
statement, so a body that pins both is only safe when the derivation
saw them together. Assertedness is part of the witness because RDF-star
does not entail it: << s p o >> :about ?v says nothing about whether
s p o is in the graph, and a coverage query over a relation the graph
never asserts would report 0 / 0.
Matched over a sample of the star layer (ANNOTATION_WITNESS_SAMPLE),
so a miss can drop the query that needs it but can never ship a broken
one.
geo_wkt: boolAny geo:asWKT / geo:wktLiteral geometry present.
geo_latlong: boolBoth wgs84:lat and wgs84:long present.
temporal_extent: Option<(String, String)>MIN/MAX lexical extent over the dominant time predicate (same datatype).
spatial_bbox: Option<[f64; 4]>[minLon, minLat, maxLon, maxLat] over wgs84 lat/long objects.
text_index: Option<TextIndexSignal>Whether the file carries a full-text (TEXT_INDEX) section.
Unlike every other signal this one is not derived from the triples and
not stored in the card: it is measured from the file’s section
directory by whoever reads the card, and DatasetCard::to_json_bytes
strips it before the bytes are written. See TextIndexSignal for why.
None therefore means unknown — a card read out of a saved JSON
document, with no file to measure — and never “no index”.
permutations: Option<PermutationsSignal>Which index permutations the file stores. Like
Signals::text_index, measured from the file at read time and
stripped before the card’s bytes are written; None means unknown (a
card document with no file behind it), never “the default”.
quoted_triples: Option<QuotedTriplesSignal>Whether the file holds any quoted triple, and which export surfaces
a consumer can ask for. Like the two signals above, measured from the
file at read time and stripped before the card’s bytes are written;
None means unknown (a card document with no file behind it), never
“no quoted triples”. See QuotedTriplesSignal.