I have created a custom custom tokenizer to create a index with bigrams and also created a another tokenizer to convert the search term to bigrams. But not able to find the results though there is a matching bigram available in inverted index. Not sure what I am doing wrong. please suggest
`function createLunrIndex(jsonObj){
var pipeline = new lunr.Pipeline
var bigram = function (token, idx, tokens) {
if(tokens[idx + 1]!==undefined){
return token + " " + tokens[idx + 1]
}
}
I have created a custom custom tokenizer to create a index with bigrams and also created a another tokenizer to convert the search term to bigrams. But not able to find the results though there is a matching bigram available in inverted index. Not sure what I am doing wrong. please suggest
`function createLunrIndex(jsonObj){ var pipeline = new lunr.Pipeline var bigram = function (token, idx, tokens) { if(tokens[idx + 1]!==undefined){ return token + " " + tokens[idx + 1] } }
}`
using the following code to search `function lunrSearch(lunrIndex, directory, keyword) {
} `