Skip to main content

Module semantic

Module semantic 

Source
Expand description

Observation → fixed NQuin-compatible records (epistemic, not ground truth).

Layout matches Qualia NQuin (6 × u64). We keep a local definition so Phase-1 does not force a full qualia-core-db link for every UI binary; field meanings are identical and can be cast/transmuted at the core boundary.

V6: human reject/correct, bbox/track predicates, full compile (up to 4 quins/det).

Structs§

MediaDigest
Content digest of media bytes (FNV-1a over up to 64 KiB prefix + length).
VisionQuin
48-byte semantic quin (parity = XOR fold of other fields).

Constants§

CTX_HUMAN_ATTESTATION
CTX_VISION
MAX_OBS_QUINS
Max observation quins emitted per batch (up to 4 per detection in full compile).
P_HAS_BBOX
P_HAS_TRACK
P_HUMAN_CORRECTS
P_HUMAN_REJECTS
P_MODEL_DIGEST
P_PROPOSES_CLASS
P_VISUAL_OBSERVATION
Predicate / context IRIs (hashed with FNV-1a 64, same family as Qualia q_hash).

Functions§

bbox_quin
instance –hasBoundingBox–> packed box (metadata: score).
class_proposal_quin
Class proposal quin: instance –proposesClass–> class_hash.
compile_observation_quins
Compile detections into observation + class quins (epistemic layer).
compile_observation_quins_full
Full epistemic compile: model digest + per-det (observation, class, bbox, track). Machine claims are never erased by later human reject/correct (separate context).
format_detection_text_description
Detailed human-readable semantic description of an object detection.
format_detection_turtle_rdf
RDF Turtle representation of a detected object instance.
human_correct_quin
Human corrects class: subject = human, object = new_class_hash; metadata low 64 bits of original instance for linkage (instance in context xor).
human_reject_quin
Human rejects a machine observation instance (does not erase the machine claim). subject = human_did_hash, object = instance_hash that is rejected.
media_digest
Media digest.
model_digest_quin
media –modelDigest–> model_hash (provenance of which model produced claims).
observation_quin
One observation quin: media –VisualObservation–> instance, score in metadata low 16.
pack_bbox_u64
Pack normalized u16 bbox into a single u64 (x0|y0|x1|y1 as 16-bit lanes).
q_hash
FNV-1a 64 — matches Qualia URI hashing family.
q_hash_bytes
q_hash of bytes.
query_by_frame_range
Filter observation quins by media time / frame range (frame in observation metadata bits 16..48).
query_by_model
Filter by model hash mixed into context (context = CTX_VISION ^ model_hash).
query_instances_in_region
Region query over compiled observation quins: keep instances whose bbox intersects the query box (normalized u16). Writes matching instance hashes.
track_quin
instance –hasTrackId–> track_id (0 if untracked).
unpack_bbox_u64
Unpacks a u64 bbox.