Skip to content

Commit

Permalink
token-filter stop-word: add "is_" prefix to boolean column
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Oct 4, 2014
1 parent 2128dfc commit 296ad5f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion plugins/token_filters/stop_word.c
Expand Up @@ -23,7 +23,7 @@

#include <string.h>

#define COLUMN_NAME "stop_word"
#define COLUMN_NAME "is_stop_word"

typedef struct {
grn_obj *table;
Expand Down
4 changes: 2 additions & 2 deletions test/command/suite/token_filters/stop_word/skip.expected
Expand Up @@ -8,11 +8,11 @@ table_create Terms TABLE_PAT_KEY ShortText --default_tokenizer TokenBigram -
[[0,0.0,0.0],true]
column_create Terms memos_content COLUMN_INDEX|WITH_POSITION Memos content
[[0,0.0,0.0],true]
column_create Terms stop_word COLUMN_SCALAR Bool
column_create Terms is_stop_word COLUMN_SCALAR Bool
[[0,0.0,0.0],true]
load --table Terms
[
{"_key": "and", "stop_word": true}
{"_key": "and", "is_stop_word": true}
]
[[0,0.0,0.0],1]
load --table Memos
Expand Down
4 changes: 2 additions & 2 deletions test/command/suite/token_filters/stop_word/skip.test
Expand Up @@ -8,11 +8,11 @@ table_create Terms TABLE_PAT_KEY ShortText \
--normalizer NormalizerAuto \
--token_filters TokenFilterStopWord
column_create Terms memos_content COLUMN_INDEX|WITH_POSITION Memos content
column_create Terms stop_word COLUMN_SCALAR Bool
column_create Terms is_stop_word COLUMN_SCALAR Bool

load --table Terms
[
{"_key": "and", "stop_word": true}
{"_key": "and", "is_stop_word": true}
]

load --table Memos
Expand Down

0 comments on commit 296ad5f

Please sign in to comment.