October 2019
Beginner
186 pages
5h 39m
English
A pattern analyzer splits the text into terms using a regular expression. The regular expression must match the token separators and not the tokens themselves. The regular expression defaults to non-word characters using \W+:
POST _analyze { "analyzer": "pattern", "text": "This is my first program and these are my first line."}
This will output the following result, in a single term:
[this, is, my, first, program, and, these, are my first line.]
The pattern analyzer can be configured using the following:
Read now
Unlock full access