Closed asakous closed 3 years ago
This modification is not necessary, as you can use the Jieba tokenizer on the relevanssi_remove_punctuation
filter hook:
add_filter( 'relevanssi_remove_punctuation', 'rlv_use_jieba' );
function rlv_use_jieba( $string ) {
$string = jieba( $string, 1,1500 );
$string = @implode( ' ', $string );
return $string;
}
I'm not very keen to hardcode parameters to Relevanssi that I do not understand and that may not work in every occasion. With the filter function, you can use the parameters you see fit for your case.
I've updated the Relevanssi language instructions and will include the Taiwanese stop words. Thanks!
If site already installed phpjieba (a Chineses tokenizer extension) then use is as tokenizer.