Debian Codegraph @

test/command/suite/tokenizers/document_vector_tf_idf/normalize_false.test

raw
1 table_create Memos TABLE_NO_KEY
2 column_create Memos content COLUMN_SCALAR Text
3
4 load --table Memos
5 [
6 {"content": "a b c a"},
7 {"content": "c b c"},
8 {"content": "b b a"},
9 {"content": "a c c"},
10 {"content": "a"}
11 ]
12
13 table_create Tokens TABLE_PAT_KEY ShortText \
14 --normalizer NormalizerNFKC121 \
15 --default_tokenizer TokenNgram
16 column_create Tokens memos_content COLUMN_INDEX|WITH_POSITION Memos content
17
18 table_create DocumentVectorTFIDF TABLE_HASH_KEY Tokens \
19 --default_tokenizer \
20 'TokenDocumentVectorTFIDF("index_column", "memos_content", \
21 "df_column", "df", \
22 "normalize", false)'
23 column_create DocumentVectorTFIDF df COLUMN_SCALAR UInt32
24
25 column_create Memos content_feature COLUMN_VECTOR|WITH_WEIGHT|WEIGHT_FLOAT32 \
26 DocumentVectorTFIDF content
27
28 select Memos
29
30 select DocumentVectorTFIDF --output_columns _id,_key,df