Interface IInputDataScenario

All Known Implementing Classes:
InputDataScenario

public interface IInputDataScenario
Knowledge base reasoning scenario as input data.
  • Method Details

    • getName

      String getName()
      Retrieves the name of the scenario.
      Returns:
      The name of the scenario.
    • KB

      static IInputDataScenario KB(FactBase fb, RuleBase rb)
      Builds a knowledge-base scenario from a fact base and a rule base.
      Parameters:
      fb - the fact base to attach
      rb - the rule base to attach
      Returns:
      the KB scenario
    • OMQ

      static IInputDataScenario OMQ(RuleBase rb, Collection<Query> queries)
      Builds an ontology-mediated-query scenario from rules and queries.
      Parameters:
      rb - the rule base to attach
      queries - the queries to attach
      Returns:
      the OMQ scenario
    • OMQA

      static IInputDataScenario OMQA(FactBase fb, RuleBase rb, Collection<Query> queries)
      Builds an ontology-mediated-query-answering scenario from facts, rules, and queries.
      Parameters:
      fb - the fact base to attach
      rb - the rule base to attach
      queries - the queries to attach
      Returns:
      the OMQA scenario
    • QA

      static IInputDataScenario QA(FactBase fb, Collection<Query> queries)
      Builds a query-answering scenario from facts and queries.
      Parameters:
      fb - the fact base to attach
      queries - the queries to attach
      Returns:
      the QA scenario
    • Compilation

      static IInputDataScenario Compilation(RuleBase ruleBase)
      Builds a rule-compilation scenario from a rule base.
      Parameters:
      ruleBase - the rule base to compile
      Returns:
      the Compilation scenario
    • OMQAHybrid

      static IInputDataScenario OMQAHybrid(FactBase fb, RuleBase rb_sat, RuleBase rb_rew, Collection<Query> queries)
      Builds a hybrid OMQA scenario from facts, saturated rules, rewriting rules, and queries.
      Parameters:
      fb - the fact base to attach
      rb_sat - the saturation rule base
      rb_rew - the rewriting rule base
      queries - the queries to attach
      Returns:
      the hybrid OMQA scenario
    • getFactbasePaths

      Optional<Collection<String>> getFactbasePaths()
      Retrieves the path(s) to the fact base file(s).
      Returns:
      an Optional containing the file paths or empty if not set
    • setFactbasePaths

      void setFactbasePaths(String... factbasepath)
      Sets the path(s) to the fact base file, if not already set.
      Parameters:
      factbasepath - the path to the fact base file
    • getFactBase

      Optional<FactBase> getFactBase()
      Retrieves the fact base object.
      Returns:
      an Optional containing the FactBase, or empty if not set
    • setFactbase

      void setFactbase(FactBase factbase)
      Sets the fact base object, if not already set.
      Parameters:
      factbase - the FactBase object to set
    • getFederatedFactBase

      Optional<FederatedFactBase> getFederatedFactBase() throws Exception
      Gets the federated fact base.
      Returns:
      FederatedFactBase
      Throws:
      Exception - if the federated fact base cannot be constructed or retrieved
    • setFederatedFactBase

      void setFederatedFactBase(FederatedFactBase federatedfactbase)
      Sets the federated fact base object, if not already set.
      Parameters:
      federatedfactbase - the FederatedFactBase object to set
    • setFactBaseFromInputDLGP

      default void setFactBaseFromInputDLGP(Object inputObject)
      Sets the fact base object from an object that represents a DLGP string.
      Parameters:
      inputObject - an object that can be turn into DLGP ; required not null
    • getMappingbasePaths

      Optional<Collection<String>> getMappingbasePaths()
      Retrieves the path(s) to the mapping base file(s).
      Returns:
      an Optional containing the file paths, or empty if not set
    • setMappingbasePaths

      void setMappingbasePaths(String... mappingbasepath)
      Sets the path to the mapping base file, if not already set.
      Parameters:
      mappingbasepath - the path to the mapping base file
    • getRulebasePath

      Optional<Collection<String>> getRulebasePath()
      Retrieves the path(s) to the rule base file(s).
      Returns:
      an Optional containing the file paths, or empty if not set
    • setRulebasePaths

      void setRulebasePaths(String... rulebasepath)
      Sets the path to the rule base file, if not already set.
      Parameters:
      rulebasepath - the path to the rule base file
    • getRuleBase

      Optional<RuleBase> getRuleBase()
      Retrieves the rule base object.
      Returns:
      an Optional containing the RuleBase, or empty if not set
    • setRulebase

      void setRulebase(RuleBase rulebase)
      Sets the rule base object, if not already set.
      Parameters:
      rulebase - the RuleBase object to set
    • setHybridRulebasePaths

      void setHybridRulebasePaths(Collection<String> rulebasepath_sat, Collection<String> rulebasepath_rew)
      Sets the path for the file holding the hynrid rule base, but only if the rulebase has not been already set.
      Parameters:
      rulebasepath_sat - for saturation
      rulebasepath_rew - for rewriting
    • setHybridRulebase

      void setHybridRulebase(RuleBase rb_sat, RuleBase rb_rew)
      Sets the hybrid rule base fact base object, but only if the rulebase has not been already set.
      Parameters:
      rb_sat - rule base for saturation
      rb_rew - rule base for rewriting
    • getHybridRulebaseSat

      Optional<RuleBase> getHybridRulebaseSat()
      Gets the hybrid rule base for saturation.
      Returns:
      the rulebase for saturation
    • getHybridRulebaseRew

      Optional<RuleBase> getHybridRulebaseRew()
      Gets the hybrid rule base for saturation.
      Returns:
      the rulebase for saturation
    • getHybridRulebaseSatPaths

      Optional<Collection<String>> getHybridRulebaseSatPaths()
      Gets the paths to the files defining the hybrid rule base for saturation.
      Returns:
      the rulebase for saturation
    • getHybridRulebaseRewPaths

      Optional<Collection<String>> getHybridRulebaseRewPaths()
      Gets the paths to the files defining the hybrid rule base for rewriting.
      Returns:
      the rulebase for rewriting
    • getQuerybasePaths

      Optional<Collection<String>> getQuerybasePaths()
      Retrieves the path(s) to the query base file(s).
      Returns:
      an Optional containing the file paths, or empty if not set
    • setQuerybasePaths

      void setQuerybasePaths(String... querybasepath)
      Sets the path to the query base file, if not already set.
      Parameters:
      querybasepath - the path to the query base file
    • getQueryBase

      Optional<Collection<Query>> getQueryBase()
      Retrieves the query base object.
      Returns:
      an Optional containing the Set of Query objects, or empty if not set
    • setQuerybase

      void setQuerybase(Collection<Query> queries)
      Sets the query base object, if not already set.
      Parameters:
      queries - the Set of Query objects to set
    • setQuerybase

      default void setQuerybase(Query query)
      Sets the query base object, if not already set.
      Parameters:
      query - of Query object to set
    • setStrikeLength

      void setStrikeLength(int value)
      Sets the lenght of the prefix of the query sequence to consider
      Parameters:
      value - the number of queries from the prefix to consider
    • getStrikeLength

      Optional<Integer> getStrikeLength()
      Returns the configured strike length when one has been set.
      Returns:
      the strike length, if configured
    • getAllReferencedFilePaths

      Collection<String> getAllReferencedFilePaths()
      Returns all file paths referenced by this handler.
      Returns:
      the set of paths to files referenced by the object