@Test void testParseBoostQueryString() { String description = "falling in the ocean!"; String actual = semanticSearchServiceHelper.parseBoostQueryString(description, 0.5); assertEquals("ocean^0.5 falling^0.5", actual); }
public String parseBoostQueryString(String queryString, double boost) { return StringUtils.join( removeStopWords(queryString).stream() .map(word -> word + CARET_CHARACTER + boost) .collect(Collectors.toSet()), SPACE_CHAR); }
SemanticSearchServiceHelper { public String parseBoostQueryString(String queryString, double boost) { return StringUtils.join( removeStopWords(queryString).stream() .map(word -> word + CARET_CHARACTER + boost) .collect(Collectors.toSet()), SPACE_CHAR); } }
SemanticSearchServiceHelper { public String parseBoostQueryString(String queryString, double boost) { return StringUtils.join( removeStopWords(queryString).stream() .map(word -> word + CARET_CHARACTER + boost) .collect(Collectors.toSet()), SPACE_CHAR); } SemanticSearchServiceHelper(
      DataService dataService,
      OntologyService ontologyService,
      TermFrequencyService termFrequencyService); }
SemanticSearchServiceHelper { public String parseBoostQueryString(String queryString, double boost) { return StringUtils.join( removeStopWords(queryString).stream() .map(word -> word + CARET_CHARACTER + boost) .collect(Collectors.toSet()), SPACE_CHAR); } SemanticSearchServiceHelper(
      DataService dataService,
      OntologyService ontologyService,
      TermFrequencyService termFrequencyService); QueryRule createDisMaxQueryRuleForAttribute(
      Set<String> searchTerms, Collection<OntologyTerm> ontologyTerms); QueryRule createDisMaxQueryRuleForTerms(List<String> queryTerms); QueryRule createBoostedDisMaxQueryRuleForTerms(
      List<String> queryTerms, Double boostValue); QueryRule createShouldQueryRule(String multiOntologyTermIri); List<String> parseOntologyTermQueries(OntologyTerm ontologyTerm); Set<String> getOtLabelAndSynonyms(OntologyTerm ontologyTerm); Map<String, String> collectExpandedQueryMap(
      Set<String> queryTerms, Collection<OntologyTerm> ontologyTerms); void collectOntologyTermQueryMap(
      Map<String, String> expanedQueryMap, OntologyTerm ontologyTerm); List<String> getAttributeIdentifiers(EntityType sourceEntityType); List<OntologyTerm> findTags(String description, List<String> ontologyIds); String processQueryString(String queryString); String parseBoostQueryString(String queryString, double boost); String escapeCharsExcludingCaretChar(String string); Set<String> removeStopWords(String description); }
SemanticSearchServiceHelper { public String parseBoostQueryString(String queryString, double boost) { return StringUtils.join( removeStopWords(queryString).stream() .map(word -> word + CARET_CHARACTER + boost) .collect(Collectors.toSet()), SPACE_CHAR); } SemanticSearchServiceHelper(
      DataService dataService,
      OntologyService ontologyService,
      TermFrequencyService termFrequencyService); QueryRule createDisMaxQueryRuleForAttribute(
      Set<String> searchTerms, Collection<OntologyTerm> ontologyTerms); QueryRule createDisMaxQueryRuleForTerms(List<String> queryTerms); QueryRule createBoostedDisMaxQueryRuleForTerms(
      List<String> queryTerms, Double boostValue); QueryRule createShouldQueryRule(String multiOntologyTermIri); List<String> parseOntologyTermQueries(OntologyTerm ontologyTerm); Set<String> getOtLabelAndSynonyms(OntologyTerm ontologyTerm); Map<String, String> collectExpandedQueryMap(
      Set<String> queryTerms, Collection<OntologyTerm> ontologyTerms); void collectOntologyTermQueryMap(
      Map<String, String> expanedQueryMap, OntologyTerm ontologyTerm); List<String> getAttributeIdentifiers(EntityType sourceEntityType); List<OntologyTerm> findTags(String description, List<String> ontologyIds); String processQueryString(String queryString); String parseBoostQueryString(String queryString, double boost); String escapeCharsExcludingCaretChar(String string); Set<String> removeStopWords(String description); static final int MAX_NUM_TAGS; }