distance metric

The similarity/distance function under which an embedding or index is meaningful — cosine and euclidean disagree about what is 'near', so the metric is provenance, not a detail. Domain-free: carried by Embedding and VectorIndex alike.

Structure

Property shape: object property; ? -> gmeow:DistanceMetric; functional

Practical Pattern

Use gmeow:distanceMetric from ? to gmeow:DistanceMetric when the relationship itself belongs in the native GMEOW graph.

Example Snippets

These snippets are generated from canonical slice examples and trimmed to the Turtle blocks where this term appears.

Lillith Pipeline

ex:embedding-7 a gmeow:Embedding ;
    gmeow:embeddingOf ex:chunk-7 ;
    gmeow:embeddingModel ex:embedder ;
    gmeow:embeddingDimensions "1024"^^xsd:positiveInteger ;
    gmeow:distanceMetric gmeow:distanceMetricCosine ;
    gmeow:vectorRef "s3://lillith/vectors/chunk-7"^^xsd:anyURI ;
    gmeow:wasGeneratedBy ex:embed-run ;
    gmeow:wasDerivedFrom ex:chunk-7 ;
    gmeow:contentDigest "blake3:1111222233334444555566667777888899990000aaaabbbbccccddddeeeeffff" .

ex:index-lillith a gmeow:VectorIndex ;
    gmeow:contentDigest "blake3:2222333344445555666677778888999900001111aaaabbbbccccddddeeeeff00" ;
    gmeow:indexesCorpus ex:corpus-lillith ;
    gmeow:indexAlgorithm gmeow:indexAlgorithmHnsw ;
    gmeow:distanceMetric gmeow:distanceMetricCosine ;
    gmeow:indexParameters "{\"M\": 16, \"efConstruction\": 200}" ;
    gmeow:wasGeneratedBy ex:index-build .

Common Companion Terms

gmeow:DistanceMetric