Skip to main content

Module evaluate

Module evaluate 

Source
Expand description

The bridge from the crisp SPARQL executor to the fuzzy algebra.

The engine evaluates a pattern and yields BindingRows; these helpers attach a degree to each (from a fuzzy FILTER membership, a fuzzy-RDF triple degree, or a similarity score) and assemble a FuzzyResultSet. A multi-pattern (BGP) query is then the conjunctive join of the per-pattern fuzzy sets.

Functions§

annotate
Annotate a slice of already-evaluated rows with a degree per row.
collect_from
Pull rows from a live engine operator and annotate them. pull is the engine’s row-at-a-time step (typically a closure wrapping PhysicalOperator::next(ctx, row)): it fills the row and returns true while more solutions remain. This is the genuine integration shape — no copy of the executor, no SparqlQueryContext leak into this library. cap bounds the pull (fail-safe against an unbounded operator).
conjunctive_query
A conjunctive (basic graph pattern) query over per-pattern fuzzy result sets: join them all under norm, then apply the α-cut threshold. An empty pattern list is an empty result. This is the f-SPARQL AND of graded triple patterns.