Interface SMOntologyAggWeighted

All Superinterfaces:
SimilarityMeasure, SMOntology
All Known Subinterfaces:
SMOntologyAggAvg, SMOntologyAggMin
All Known Implementing Classes:
SMOntologyAggAvgImpl, SMOntologyAggMinImpl, SMOntologyAggWeightedImpl

public interface SMOntologyAggWeighted extends SMOntology
Calculates the similarity between query and case based on the local similarities of the connected objects of the query and case entities via specific relations in an ontology. The local similarity calculations can be defined by the name of the relation, a similarity measure to be used and a weight for the weighted average.
Author:
Tobias Dahlem
  • Field Details

    • DEFAULT_WEIGHT

      static final double DEFAULT_WEIGHT
      The default similarity value is 1.0.
      See Also:
    • DEFAULT_IGNORE_MISSING_RELATIONS_IN_QUERY

      static final boolean DEFAULT_IGNORE_MISSING_RELATIONS_IN_QUERY
      The default for ignoring missing relations in a query true.
      See Also:
  • Method Details

    • setRelation

      void setRelation(String relationName, String simMeasure, Double weight)
      Parameters:
      relationName - name of the relation to be inferred
      simMeasure - similarity measure to be used
      weight - weight of the relation
    • setInferredRelation

      void setInferredRelation(String relationName, String relationQuery, String relationQueryParamName, String simMeasure, double weight)
      Parameters:
      relationName - name of the relation to be inferred
      relationQuery - SPARQL string
      relationQueryParamName - name of the parameter used in relationQuery
      simMeasure - similarity measure to be used
      weight - weight of the relation
    • getRelations

      Returns:
      map with all registered relations and corresponding weight and similarity measure
    • getDefaultWeight

      double getDefaultWeight()
      Returns:
      default weight
    • setDefaultWeight

      void setDefaultWeight(double weight)
      Parameters:
      weight - is the default weight for each relation, which hasn't an own weight
    • isIgnoreMissingRelationsInQuery

      boolean isIgnoreMissingRelationsInQuery()
    • setIgnoreMissingRelationsInQuery

      void setIgnoreMissingRelationsInQuery(boolean ignoreMissingRelationsInQuery)