Grooper Help - Version 25.0
25.0.0017 2,127
  • Overview
  • Help Status

Lucene Word

Lucene Query Grooper.GPT

Represents a word-based search expression for Azure AI Search queries.

Remarks

The Lucene Word class is used to construct search queries that match individual words or terms in document text or field values. Word queries are the most basic building block for search, enabling you to find documents containing specific keywords, product codes, names, or other single-word values.

Purpose and Usage

  • Use Lucene Word to search for documents containing a specific word or term.
  • Supports advanced options such as fuzzy matching (to find similar words) and boosting (to increase the relevance of certain terms).
  • Can be combined with fielded search, boolean logic, and other Lucene Query types for complex search scenarios.

Lucene Syntax Examples

Basic Word Search:
invoice
Returns documents containing the word "invoice".

Fielded Search:
category:finance
Returns documents where the "category" field contains "finance".

Wildcard Search:
inv*
Returns documents containing words that start with "inv", such as "invoice" or "inventory".

Fuzzy Search:
university~
Returns documents containing words similar to "university" (default edit distance 2).

Boosting:
priority^2
Returns documents containing "priority" and boosts their relevance by a factor of 2.

Boolean Combination:
invoice AND paid
Returns documents containing both "invoice" and "paid".

Grouped/Order of Operations:
invoice AND (paid OR overdue)
Returns documents containing "invoice" and either "paid" or "overdue".

Configuration Guidance

  • Set the 'Term' property to the word or pattern you want to match.
  • Use the 'Fuzzy Similarity' property to allow for misspellings or similar words.
  • Use the 'Boost Factor' property to increase the ranking of documents containing the word.
  • Combine with the 'Field Name' and 'Not' properties (inherited from Lucene Query) to further refine your search.

Best Practices

  • Use word queries for keywords, codes, or other single-word values where exact or near-exact matches are important.
  • Adjust fuzzy similarity to accommodate typos, OCR errors, or alternate spellings.
  • Apply boosting to prioritize key terms in ranking, especially when multiple search terms are used.
  • Test queries in the Azure portal or Grooper UI to ensure they return the expected results.

Example Scenarios

  • Find documents containing the word invoice:
    invoice
  • Find documents containing words similar to university (e.g., universty, university):
    university~
  • Boost results containing the word priority:
    priority^2

For more information, see the documentation for Lucene Query, Azure AI Search, and Lucene query syntax.

Properties

NameTypeDescription
Notification