Create a Custom Analyzer

  • how-to
March 16, 2025
+ 12
Create a custom analyzer with the Couchbase Server Web Console to modify the input text from a Search query or Search index and improve search results. For more information about analyzers, see customize-index.adoc#analyzers.

Prerequisites

Procedure

To create a custom analyzer with the Couchbase Server Web Console:

  1. Go to Search.

  2. Click the Search index where you want to create a custom analyzer.

  3. Click Edit.

  4. Expand Customize Index  Analyzers.

  5. Click Add Analyzer.

  6. In the Name field, enter a name for the new custom analyzer.

  7. To remove specific characters from search input before tokenizing, in the Character Filters list, do one of the following:

    1. To add a character filter to your analyzer, select a character filter and click + Add. You can select a default character filter or create your own.

    2. To remove a character filter from your analyzer, click remove.

  8. In the Tokenizer list, click the tokenizer you want to use to create tokens from Search input. You can select a default tokenizer or create your own.

    For more information, see Default Tokenizers or Create a Custom Tokenizer.

  9. To modify the tokens created by the tokenizer, in the Token Filters list, do one of the following:

    1. To add a token filter to your analyzer, select a token filter and click + Add. You can select a default token filter or create your own.

      For more information, see Default Token Filters or Create a Custom Token Filter.

    2. To remove a token filter from your analyzer, click remove.

  10. Click Save.

Next Steps