rroonga 4.0.0-x86-mingw32 → 4.0.1-x86-mingw32
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.yardopts +6 -0
- data/doc/text/news.textile +26 -0
- data/ext/groonga/rb-grn-column.c +42 -2
- data/ext/groonga/rb-grn-index-column.c +57 -159
- data/ext/groonga/rb-grn-object.c +7 -0
- data/ext/groonga/rb-grn-table.c +19 -3
- data/ext/groonga/rb-grn-utils.c +4 -1
- data/ext/groonga/rb-grn-variable-size-column.c +405 -5
- data/ext/groonga/rb-grn.h +18 -1
- data/lib/1.9/groonga.so +0 -0
- data/lib/2.0/groonga.so +0 -0
- data/lib/2.1/groonga.so +0 -0
- data/lib/groonga/dumper.rb +46 -22
- data/lib/groonga/expression-builder.rb +2 -4
- data/lib/groonga/schema.rb +16 -234
- data/rroonga-build.rb +3 -3
- data/rroonga.gemspec +1 -1
- data/test/test-array.rb +6 -5
- data/test/test-column.rb +0 -14
- data/test/test-database.rb +6 -5
- data/test/test-double-array-trie.rb +6 -5
- data/test/test-expression.rb +2 -2
- data/test/test-hash.rb +6 -5
- data/test/test-index-column.rb +163 -33
- data/test/test-patricia-trie.rb +6 -5
- data/test/test-schema-dumper.rb +39 -7
- data/test/test-table-dumper.rb +46 -1
- data/test/test-table-select-weight.rb +12 -0
- data/test/test-variable-size-column.rb +87 -3
- data/vendor/local/bin/groonga-benchmark.exe +0 -0
- data/vendor/local/bin/groonga.exe +0 -0
- data/vendor/local/bin/libgroonga-0.dll +0 -0
- data/vendor/local/bin/libmecab-1.dll +0 -0
- data/vendor/local/bin/libmsgpack-3.dll +0 -0
- data/vendor/local/bin/libmsgpackc-2.dll +0 -0
- data/vendor/local/bin/mecab.exe +0 -0
- data/vendor/local/include/groonga/groonga.h +6 -1
- data/vendor/local/lib/groonga/plugins/query_expanders/tsv.a +0 -0
- data/vendor/local/lib/groonga/plugins/query_expanders/tsv.dll +0 -0
- data/vendor/local/lib/groonga/plugins/query_expanders/tsv.dll.a +0 -0
- data/vendor/local/lib/groonga/plugins/suggest/suggest.a +0 -0
- data/vendor/local/lib/groonga/plugins/suggest/suggest.dll +0 -0
- data/vendor/local/lib/groonga/plugins/suggest/suggest.dll.a +0 -0
- data/vendor/local/lib/groonga/plugins/table/table.a +0 -0
- data/vendor/local/lib/groonga/plugins/table/table.dll +0 -0
- data/vendor/local/lib/groonga/plugins/table/table.dll.a +0 -0
- data/vendor/local/lib/groonga/plugins/tokenizers/mecab.a +0 -0
- data/vendor/local/lib/groonga/plugins/tokenizers/mecab.dll +0 -0
- data/vendor/local/lib/groonga/plugins/tokenizers/mecab.dll.a +0 -0
- data/vendor/local/lib/libgroonga.a +0 -0
- data/vendor/local/lib/libgroonga.dll.a +0 -0
- data/vendor/local/lib/libmecab.a +0 -0
- data/vendor/local/lib/libmecab.dll.a +0 -0
- data/vendor/local/lib/libmsgpack.a +0 -0
- data/vendor/local/lib/libmsgpack.dll.a +0 -0
- data/vendor/local/lib/libmsgpackc.a +0 -0
- data/vendor/local/lib/libmsgpackc.dll.a +0 -0
- data/vendor/local/lib/pkgconfig/groonga.pc +2 -2
- data/vendor/local/libexec/mecab/mecab-cost-train.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-dict-gen.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-dict-index.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-system-eval.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-test-gen.exe +0 -0
- data/vendor/local/share/doc/groonga/en/html/.buildinfo +1 -1
- data/vendor/local/share/doc/groonga/en/html/_sources/install/centos.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/debian.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/fedora.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/mac_os_x.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/others.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/solaris.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/ubuntu.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/windows.txt +9 -9
- data/vendor/local/share/doc/groonga/en/html/_sources/news.txt +41 -0
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/column.txt +25 -0
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/columns/vector.txt +333 -0
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/cache_limit.txt +1 -1
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/column_create.txt +1 -2
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/column_rename.txt +37 -17
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/delete.txt +4 -5
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/normalize.txt +1 -2
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/select.txt +99 -0
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/table_create.txt +1 -1
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/truncate.txt +1 -2
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/executables/groonga-suggest-httpd.txt +128 -4
- data/vendor/local/share/doc/groonga/en/html/_sources/reference/executables/groonga-suggest-learner.txt +11 -1
- data/vendor/local/share/doc/groonga/en/html/_sources/reference.txt +3 -2
- data/vendor/local/share/doc/groonga/en/html/_static/basic.css +1 -1
- data/vendor/local/share/doc/groonga/en/html/_static/doctools.js +1 -1
- data/vendor/local/share/doc/groonga/en/html/_static/searchtools.js +1 -1
- data/vendor/local/share/doc/groonga/en/html/_static/websupport.js +1 -1
- data/vendor/local/share/doc/groonga/en/html/characteristic.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/community.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/com.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/cooperation.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/document.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/query.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/release.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/repository.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/test.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/documentation/c-api.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/documentation/i18n.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/documentation.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/report.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/development/travis-ci.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/development.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/genindex.html +11 -11
- data/vendor/local/share/doc/groonga/en/html/geolocation_search.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/index.html +68 -67
- data/vendor/local/share/doc/groonga/en/html/install/centos.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/debian.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/fedora.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/mac_os_x.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/others.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/solaris.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/ubuntu.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/windows.html +14 -14
- data/vendor/local/share/doc/groonga/en/html/install.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/limitations.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/0.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/1.0.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/1.1.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/1.2.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/senna.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news.html +247 -200
- data/vendor/local/share/doc/groonga/en/html/objects.inv +0 -0
- data/vendor/local/share/doc/groonga/en/html/reference/api/global_configurations.html +24 -24
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_cache.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_column.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_command_version.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_ctx.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_db.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_encoding.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_expr.html +24 -24
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_geo.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_hook.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_ii.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_index_cursor.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_info.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_match_escalation.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_obj.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_proc.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_search.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_table.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_table_cursor.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_type.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_user_data.html +22 -22
- data/vendor/local/share/doc/groonga/en/html/reference/api.html +38 -38
- data/vendor/local/share/doc/groonga/en/html/reference/cast.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/column.html +153 -0
- data/vendor/local/share/doc/groonga/en/html/reference/columns/vector.html +857 -0
- data/vendor/local/share/doc/groonga/en/html/reference/command/command_version.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/command/output_format.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/command/return_code.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/command.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/reference/commands/cache_limit.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/reference/commands/check.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/clearlock.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/column_create.html +8 -9
- data/vendor/local/share/doc/groonga/en/html/reference/commands/column_list.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/column_remove.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/column_rename.html +47 -26
- data/vendor/local/share/doc/groonga/en/html/reference/commands/define_selector.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/defrag.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/delete.html +8 -9
- data/vendor/local/share/doc/groonga/en/html/reference/commands/dump.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/load.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/log_level.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/log_put.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/log_reopen.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/normalize.html +10 -10
- data/vendor/local/share/doc/groonga/en/html/reference/commands/quit.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/register.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/ruby_eval.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/ruby_load.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/select.html +193 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/shutdown.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/status.html +12 -12
- data/vendor/local/share/doc/groonga/en/html/reference/commands/suggest.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/table_create.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/reference/commands/table_list.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/table_remove.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/tokenize.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/commands/truncate.html +8 -9
- data/vendor/local/share/doc/groonga/en/html/reference/executables/grnslap.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-benchmark.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-httpd.html +10 -10
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-server-http.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-suggest-create-dataset.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-suggest-httpd.html +165 -13
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-suggest-learner.html +25 -8
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga.html +7 -7
- data/vendor/local/share/doc/groonga/en/html/reference/executables.html +12 -12
- data/vendor/local/share/doc/groonga/en/html/reference/function.html +28 -28
- data/vendor/local/share/doc/groonga/en/html/reference/functions/between.html +40 -40
- data/vendor/local/share/doc/groonga/en/html/reference/functions/edit_distance.html +32 -32
- data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_distance.html +50 -50
- data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_in_circle.html +32 -32
- data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_in_rectangle.html +32 -32
- data/vendor/local/share/doc/groonga/en/html/reference/functions/html_untag.html +34 -34
- data/vendor/local/share/doc/groonga/en/html/reference/functions/now.html +30 -30
- data/vendor/local/share/doc/groonga/en/html/reference/functions/query.html +46 -46
- data/vendor/local/share/doc/groonga/en/html/reference/functions/rand.html +32 -32
- data/vendor/local/share/doc/groonga/en/html/reference/functions/snippet_html.html +32 -32
- data/vendor/local/share/doc/groonga/en/html/reference/functions/sub_filter.html +36 -36
- data/vendor/local/share/doc/groonga/en/html/reference/grn_expr/query_syntax.html +62 -62
- data/vendor/local/share/doc/groonga/en/html/reference/grn_expr/script_syntax.html +140 -140
- data/vendor/local/share/doc/groonga/en/html/reference/grn_expr.html +22 -22
- data/vendor/local/share/doc/groonga/en/html/reference/indexing.html +24 -24
- data/vendor/local/share/doc/groonga/en/html/reference/log.html +26 -26
- data/vendor/local/share/doc/groonga/en/html/reference/normalizers.html +31 -31
- data/vendor/local/share/doc/groonga/en/html/reference/output.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/reference/pseudo_column.html +22 -22
- data/vendor/local/share/doc/groonga/en/html/reference/query_expanders/tsv.html +36 -36
- data/vendor/local/share/doc/groonga/en/html/reference/query_expanders.html +18 -18
- data/vendor/local/share/doc/groonga/en/html/reference/tables.html +13 -13
- data/vendor/local/share/doc/groonga/en/html/reference/tokenizers.html +17 -17
- data/vendor/local/share/doc/groonga/en/html/reference/tuning.html +38 -38
- data/vendor/local/share/doc/groonga/en/html/reference/types.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/reference.html +69 -68
- data/vendor/local/share/doc/groonga/en/html/search.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/searchindex.js +1 -1
- data/vendor/local/share/doc/groonga/en/html/server/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/http/comparison.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/http/groonga-httpd.html +9 -9
- data/vendor/local/share/doc/groonga/en/html/server/http/groonga.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/http.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/package.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/spec/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/spec/search.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/spec.html +9 -9
- data/vendor/local/share/doc/groonga/en/html/suggest/completion.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/correction.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/introduction.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/suggestion.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/tutorial.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/troubleshooting/different_results_with_the_same_keyword.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/troubleshooting/mmap_cannot_allocate_memory.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/troubleshooting.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/data.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/drilldown.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/index.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/introduction.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/tutorial/lexicon.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/match_columns.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/micro_blog.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/network.html +12 -12
- data/vendor/local/share/doc/groonga/en/html/tutorial/patricia_trie.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/query_expansion.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/search.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/.buildinfo +1 -1
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/centos.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/debian.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/fedora.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/mac_os_x.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/others.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/solaris.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/ubuntu.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/windows.txt +9 -9
- data/vendor/local/share/doc/groonga/ja/html/_sources/news.txt +41 -0
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/column.txt +25 -0
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/columns/vector.txt +333 -0
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/cache_limit.txt +1 -1
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/column_create.txt +1 -2
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/column_rename.txt +37 -17
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/delete.txt +4 -5
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/normalize.txt +1 -2
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/select.txt +99 -0
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/table_create.txt +1 -1
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/truncate.txt +1 -2
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/executables/groonga-suggest-httpd.txt +128 -4
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference/executables/groonga-suggest-learner.txt +11 -1
- data/vendor/local/share/doc/groonga/ja/html/_sources/reference.txt +3 -2
- data/vendor/local/share/doc/groonga/ja/html/_static/basic.css +1 -1
- data/vendor/local/share/doc/groonga/ja/html/_static/doctools.js +1 -1
- data/vendor/local/share/doc/groonga/ja/html/_static/searchtools.js +1 -1
- data/vendor/local/share/doc/groonga/ja/html/_static/websupport.js +1 -1
- data/vendor/local/share/doc/groonga/ja/html/characteristic.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/community.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/com.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/cooperation.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/document.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/query.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/release.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/repository.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/test.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/documentation/c-api.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/documentation/i18n.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/documentation.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/report.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/development/travis-ci.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/development.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/genindex.html +11 -11
- data/vendor/local/share/doc/groonga/ja/html/geolocation_search.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/index.html +67 -66
- data/vendor/local/share/doc/groonga/ja/html/install/centos.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/debian.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/fedora.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/mac_os_x.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/others.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/solaris.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/ubuntu.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/windows.html +14 -14
- data/vendor/local/share/doc/groonga/ja/html/install.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/limitations.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/0.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/1.0.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/1.1.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/1.2.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/senna.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news.html +262 -200
- data/vendor/local/share/doc/groonga/ja/html/objects.inv +0 -0
- data/vendor/local/share/doc/groonga/ja/html/reference/api/global_configurations.html +22 -22
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_cache.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_column.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_command_version.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_ctx.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_db.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_encoding.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_expr.html +22 -22
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_geo.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_hook.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_ii.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_index_cursor.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_info.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_match_escalation.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_obj.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_proc.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_search.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_table.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_table_cursor.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_type.html +24 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_user_data.html +20 -20
- data/vendor/local/share/doc/groonga/ja/html/reference/api.html +35 -35
- data/vendor/local/share/doc/groonga/ja/html/reference/cast.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/column.html +150 -0
- data/vendor/local/share/doc/groonga/ja/html/reference/columns/vector.html +824 -0
- data/vendor/local/share/doc/groonga/ja/html/reference/command/command_version.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/command/output_format.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/command/return_code.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/command.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/cache_limit.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/check.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/clearlock.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_create.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_list.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_remove.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_rename.html +45 -24
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/define_selector.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/defrag.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/delete.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/dump.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/load.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_level.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_put.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_reopen.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/normalize.html +8 -7
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/quit.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/register.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/ruby_eval.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/ruby_load.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/select.html +174 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/shutdown.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/status.html +10 -10
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/suggest.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_create.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_list.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_remove.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/tokenize.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/truncate.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/grnslap.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-benchmark.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-httpd.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-server-http.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-suggest-create-dataset.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-suggest-httpd.html +167 -11
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-suggest-learner.html +23 -6
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/function.html +25 -25
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/between.html +38 -38
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/edit_distance.html +30 -30
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_distance.html +48 -48
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_in_circle.html +30 -30
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_in_rectangle.html +30 -30
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/html_untag.html +32 -32
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/now.html +28 -28
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/query.html +44 -44
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/rand.html +30 -30
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/snippet_html.html +30 -30
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/sub_filter.html +34 -34
- data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr/query_syntax.html +60 -60
- data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr/script_syntax.html +138 -138
- data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr.html +19 -19
- data/vendor/local/share/doc/groonga/ja/html/reference/indexing.html +21 -21
- data/vendor/local/share/doc/groonga/ja/html/reference/log.html +23 -23
- data/vendor/local/share/doc/groonga/ja/html/reference/normalizers.html +28 -28
- data/vendor/local/share/doc/groonga/ja/html/reference/output.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/pseudo_column.html +19 -19
- data/vendor/local/share/doc/groonga/ja/html/reference/query_expanders/tsv.html +34 -34
- data/vendor/local/share/doc/groonga/ja/html/reference/query_expanders.html +15 -15
- data/vendor/local/share/doc/groonga/ja/html/reference/tables.html +10 -10
- data/vendor/local/share/doc/groonga/ja/html/reference/tokenizers.html +14 -14
- data/vendor/local/share/doc/groonga/ja/html/reference/tuning.html +35 -35
- data/vendor/local/share/doc/groonga/ja/html/reference/types.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference.html +69 -68
- data/vendor/local/share/doc/groonga/ja/html/search.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/searchindex.js +1 -1
- data/vendor/local/share/doc/groonga/ja/html/server/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http/comparison.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http/groonga-httpd.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http/groonga.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/package.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/spec/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/spec/search.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/spec.html +9 -9
- data/vendor/local/share/doc/groonga/ja/html/suggest/completion.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/correction.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/introduction.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/suggestion.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/tutorial.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/troubleshooting/different_results_with_the_same_keyword.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/troubleshooting/mmap_cannot_allocate_memory.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/troubleshooting.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/data.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/drilldown.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/index.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/introduction.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/tutorial/lexicon.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/match_columns.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/micro_blog.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/network.html +12 -12
- data/vendor/local/share/doc/groonga/ja/html/tutorial/patricia_trie.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/query_expansion.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/search.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial.html +5 -5
- data/vendor/local/share/man/ja/man1/groonga.1 +526 -73
- data/vendor/local/share/man/man1/groonga.1 +552 -80
- metadata +148 -139
@@ -0,0 +1,824 @@
|
|
1
|
+
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
3
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
4
|
+
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
7
|
+
<head>
|
8
|
+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
9
|
+
|
10
|
+
<title>ベクターカラム — Groonga v4.0.1ドキュメント</title>
|
11
|
+
|
12
|
+
<link rel="stylesheet" href="../../_static/groonga.css" type="text/css" />
|
13
|
+
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
14
|
+
|
15
|
+
<script type="text/javascript">
|
16
|
+
var DOCUMENTATION_OPTIONS = {
|
17
|
+
URL_ROOT: '../../',
|
18
|
+
VERSION: '4.0.1',
|
19
|
+
COLLAPSE_INDEX: false,
|
20
|
+
FILE_SUFFIX: '.html',
|
21
|
+
HAS_SOURCE: true
|
22
|
+
};
|
23
|
+
</script>
|
24
|
+
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
25
|
+
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
26
|
+
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
27
|
+
<script type="text/javascript" src="../../_static/translations.js"></script>
|
28
|
+
<link rel="shortcut icon" href="../../_static/favicon.ico"/>
|
29
|
+
<link rel="top" title="Groonga v4.0.1ドキュメント" href="../../index.html" />
|
30
|
+
</head>
|
31
|
+
<body role="document">
|
32
|
+
<div class="header">
|
33
|
+
<h1 class="title">
|
34
|
+
<a id="top-link" href="../../index.html">
|
35
|
+
<span class="project">groonga</span>
|
36
|
+
<span class="separator">-</span>
|
37
|
+
<span class="description">オープンソースのカラムストア機能付き全文検索エンジン</span>
|
38
|
+
</a>
|
39
|
+
</h1>
|
40
|
+
|
41
|
+
<div class="other-language-links">
|
42
|
+
<ul>
|
43
|
+
<li><a href="../../../../en/html/reference/columns/vector.html"><img src="../../_static/us.png" alt="English">English page</a></li>
|
44
|
+
</ul>
|
45
|
+
</div>
|
46
|
+
</div>
|
47
|
+
|
48
|
+
|
49
|
+
<div class="related" role="navigation" aria-label="related navigation">
|
50
|
+
<h3>ナビゲーション</h3>
|
51
|
+
<ul>
|
52
|
+
<li class="right" style="margin-right: 10px">
|
53
|
+
<a href="../../genindex.html" title="総合索引"
|
54
|
+
accesskey="I">索引</a></li>
|
55
|
+
<li><a href="../../index.html">Groonga v4.0.1ドキュメント</a> »</li>
|
56
|
+
</ul>
|
57
|
+
</div>
|
58
|
+
|
59
|
+
<div class="document">
|
60
|
+
<div class="documentwrapper">
|
61
|
+
<div class="bodywrapper">
|
62
|
+
<div class="body" role="main">
|
63
|
+
|
64
|
+
<div class="section" id="vector-column">
|
65
|
+
<h1>ベクターカラム<a class="headerlink" href="#vector-column" title="このヘッドラインへのパーマリンク">¶</a></h1>
|
66
|
+
<div class="section" id="summary">
|
67
|
+
<h2>概要<a class="headerlink" href="#summary" title="このヘッドラインへのパーマリンク">¶</a></h2>
|
68
|
+
<p>ベクターカラムはデータストアオブジェクトです。ベクターカラムは0個以上のスカラー値を保存できます。ざっくり言うと、スカラー値とは数値や文字列といった1つの値のことです。スカラー値の詳細は <tt class="xref doc docutils literal"><span class="pre">scalar</span></tt> を参照してください。</p>
|
69
|
+
<p>ベクターカラムのユースケースの1つはタグの保存です。ベクターカラムを使うとタグの値を複数保存できます。</p>
|
70
|
+
<p>スカラーカラムと同じように、ベクターカラムもインデックスを使って検索できます。各要素に重みをつけることもできます。1以上の重みがついた要素がマッチすると、重みがついていない場合よりも大きなスコアがつきます。これはベクターカラム特有の機能です。重みも保存できるベクターカラムのことは重み付きベクターカラムと呼びます。</p>
|
71
|
+
<p>各要素がテキストなら、各要素に対して全文検索することもできます。しかし、重みを使った場合は検索スコアが高くなりすぎることに注意してください。重み付きベクターカラムに対して全文検索をするときは注意してください。</p>
|
72
|
+
</div>
|
73
|
+
<div class="section" id="usage">
|
74
|
+
<h2>使い方<a class="headerlink" href="#usage" title="このヘッドラインへのパーマリンク">¶</a></h2>
|
75
|
+
<p>ベクターカラムには3種類あります。</p>
|
76
|
+
<blockquote>
|
77
|
+
<div><ul class="simple">
|
78
|
+
<li><p class="first">ノーマルベクターカラム</p>
|
79
|
+
</li>
|
80
|
+
<li><p class="first">参照型ベクターカラム</p>
|
81
|
+
</li>
|
82
|
+
<li><p class="first">重み付きベクターカラム</p>
|
83
|
+
</li>
|
84
|
+
</ul>
|
85
|
+
</div></blockquote>
|
86
|
+
<p>このセクションではこれらの種類の使い方について説明します。</p>
|
87
|
+
<div class="section" id="normal-vector-column">
|
88
|
+
<span id="id1"></span><h3>ノーマルベクターカラム<a class="headerlink" href="#normal-vector-column" title="このヘッドラインへのパーマリンク">¶</a></h3>
|
89
|
+
<p>ノーマルベクターカラムは0個以上のスカラーデータを保存します。スカラーデータとは、例えば、数値や文字列です。</p>
|
90
|
+
<p>ノーマルベクターカラムは同じ型の要素だけを保存できます。型を混ぜることはできません。例えば、同じノーマルベクターカラムに数値と文字列を保存できません。</p>
|
91
|
+
<p>ノーマルベクターカラムは、1つのレコードが、1つのキーに対して複数の値を持っているときに便利です。タグは一番よくあるユースケースです。</p>
|
92
|
+
<div class="section" id="how-to-create">
|
93
|
+
<h4>作り方<a class="headerlink" href="#how-to-create" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
94
|
+
<p>ノーマルベクターカラムを作るためには <a class="reference internal" href="../commands/column_create.html"><em>column_create</em></a> コマンドを使います。ポイントは <tt class="docutils literal"><span class="pre">COLUMN_VECTOR</span></tt> フラグです。</p>
|
95
|
+
<p>実行例:</p>
|
96
|
+
<div class="highlight-none"><div class="highlight"><pre>table_create Bookmarks TABLE_HASH_KEY ShortText
|
97
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
98
|
+
column_create Bookmarks tags COLUMN_VECTOR ShortText
|
99
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
100
|
+
</pre></div>
|
101
|
+
</div>
|
102
|
+
<p>1つのブックマークに0個以上のタグを設定できます。</p>
|
103
|
+
</div>
|
104
|
+
<div class="section" id="how-to-load">
|
105
|
+
<h4>ロード方法<a class="headerlink" href="#how-to-load" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
106
|
+
<p>JSONの配列構文で指定してベクターデータをロードします:</p>
|
107
|
+
<div class="highlight-none"><div class="highlight"><pre>[ELEMENT1, ELEMENT2, ELEMENT3, ...]
|
108
|
+
</pre></div>
|
109
|
+
</div>
|
110
|
+
<p>以下のデータをロードしましょう。</p>
|
111
|
+
<table border="1" class="docutils">
|
112
|
+
<colgroup>
|
113
|
+
<col width="50%" />
|
114
|
+
<col width="50%" />
|
115
|
+
</colgroup>
|
116
|
+
<thead valign="bottom">
|
117
|
+
<tr class="row-odd"><th class="head"><tt class="docutils literal"><span class="pre">_key</span></tt></th>
|
118
|
+
<th class="head"><tt class="docutils literal"><span class="pre">tags</span></tt></th>
|
119
|
+
</tr>
|
120
|
+
</thead>
|
121
|
+
<tbody valign="top">
|
122
|
+
<tr class="row-even"><td><tt class="docutils literal"><span class="pre">http://groonga.org/</span></tt></td>
|
123
|
+
<td><tt class="docutils literal"><span class="pre">["groonga"]</span></tt></td>
|
124
|
+
</tr>
|
125
|
+
<tr class="row-odd"><td><tt class="docutils literal"><span class="pre">http://mroonga.org/</span></tt></td>
|
126
|
+
<td><tt class="docutils literal"><span class="pre">["mroonga",</span> <span class="pre">"mysql",</span> <span class="pre">"groonga"]</span></tt></td>
|
127
|
+
</tr>
|
128
|
+
<tr class="row-even"><td><tt class="docutils literal"><span class="pre">http://ranguba.org/</span></tt></td>
|
129
|
+
<td><tt class="docutils literal"><span class="pre">["ruby",</span> <span class="pre">"groonga"]</span></tt></td>
|
130
|
+
</tr>
|
131
|
+
</tbody>
|
132
|
+
</table>
|
133
|
+
<p>以下がデータをロードするコマンドです。</p>
|
134
|
+
<p>実行例:</p>
|
135
|
+
<div class="highlight-none"><div class="highlight"><pre>load --table Bookmarks
|
136
|
+
[
|
137
|
+
{"_key": "http://groonga.org/", "tags": ["groonga"]},
|
138
|
+
{"_key": "http://mroonga.org/", "tags": ["mroonga", "mysql", "groonga"]},
|
139
|
+
{"_key": "http://ranguba.org/", "tags": ["ruby", "groonga"]}
|
140
|
+
]
|
141
|
+
# [[0, 1337566253.89858, 0.000355720520019531], 3]
|
142
|
+
</pre></div>
|
143
|
+
</div>
|
144
|
+
<p>ロードしたデータはJSONの配列構文で出力されます。</p>
|
145
|
+
<p>実行例:</p>
|
146
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks
|
147
|
+
# [
|
148
|
+
# [
|
149
|
+
# 0,
|
150
|
+
# 1337566253.89858,
|
151
|
+
# 0.000355720520019531
|
152
|
+
# ],
|
153
|
+
# [
|
154
|
+
# [
|
155
|
+
# [
|
156
|
+
# 3
|
157
|
+
# ],
|
158
|
+
# [
|
159
|
+
# [
|
160
|
+
# "_id",
|
161
|
+
# "UInt32"
|
162
|
+
# ],
|
163
|
+
# [
|
164
|
+
# "_key",
|
165
|
+
# "ShortText"
|
166
|
+
# ],
|
167
|
+
# [
|
168
|
+
# "tags",
|
169
|
+
# "ShortText"
|
170
|
+
# ]
|
171
|
+
# ],
|
172
|
+
# [
|
173
|
+
# 1,
|
174
|
+
# "http://groonga.org/",
|
175
|
+
# [
|
176
|
+
# "groonga"
|
177
|
+
# ]
|
178
|
+
# ],
|
179
|
+
# [
|
180
|
+
# 2,
|
181
|
+
# "http://mroonga.org/",
|
182
|
+
# [
|
183
|
+
# "mroonga",
|
184
|
+
# "mysql",
|
185
|
+
# "groonga"
|
186
|
+
# ]
|
187
|
+
# ],
|
188
|
+
# [
|
189
|
+
# 3,
|
190
|
+
# "http://ranguba.org/",
|
191
|
+
# [
|
192
|
+
# "ruby",
|
193
|
+
# "groonga"
|
194
|
+
# ]
|
195
|
+
# ]
|
196
|
+
# ]
|
197
|
+
# ]
|
198
|
+
# ]
|
199
|
+
</pre></div>
|
200
|
+
</div>
|
201
|
+
</div>
|
202
|
+
<div class="section" id="how-to-search">
|
203
|
+
<h4>検索方法<a class="headerlink" href="#how-to-search" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
204
|
+
<p>ノーマルベクターカラムを検索するにはインデックスを作る必要があります。</p>
|
205
|
+
<p>実行例:</p>
|
206
|
+
<div class="highlight-none"><div class="highlight"><pre>table_create Tags TABLE_PAT_KEY ShortText
|
207
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
208
|
+
column_create Tags bookmark_index COLUMN_INDEX Bookmarks tags
|
209
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
210
|
+
</pre></div>
|
211
|
+
</div>
|
212
|
+
<p>ベクターカラム固有の方法はありません。スカラーカラムにインデックスを作る方法と同じです。</p>
|
213
|
+
<p>全文検索と同じ構文で <tt class="docutils literal"><span class="pre">tags</span></tt> 内の要素を検索できます。</p>
|
214
|
+
<p><a class="reference internal" href="../commands/select.html#select-match-columns"><em>match_columns</em></a> と <a class="reference internal" href="../commands/select.html#select-query"><em>query</em></a> を使った場合:</p>
|
215
|
+
<p>実行例:</p>
|
216
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks --match_columns tags --query mysql --output_columns _key,tags,_score
|
217
|
+
# [
|
218
|
+
# [
|
219
|
+
# 0,
|
220
|
+
# 1337566253.89858,
|
221
|
+
# 0.000355720520019531
|
222
|
+
# ],
|
223
|
+
# [
|
224
|
+
# [
|
225
|
+
# [
|
226
|
+
# 1
|
227
|
+
# ],
|
228
|
+
# [
|
229
|
+
# [
|
230
|
+
# "_key",
|
231
|
+
# "ShortText"
|
232
|
+
# ],
|
233
|
+
# [
|
234
|
+
# "tags",
|
235
|
+
# "ShortText"
|
236
|
+
# ],
|
237
|
+
# [
|
238
|
+
# "_score",
|
239
|
+
# "Int32"
|
240
|
+
# ]
|
241
|
+
# ],
|
242
|
+
# [
|
243
|
+
# "http://mroonga.org/",
|
244
|
+
# [
|
245
|
+
# "mroonga",
|
246
|
+
# "mysql",
|
247
|
+
# "groonga"
|
248
|
+
# ],
|
249
|
+
# 1
|
250
|
+
# ]
|
251
|
+
# ]
|
252
|
+
# ]
|
253
|
+
# ]
|
254
|
+
</pre></div>
|
255
|
+
</div>
|
256
|
+
<p><a class="reference internal" href="../commands/select.html#select-match-columns"><em>match_columns</em></a> の中で重みを使うこともできます。</p>
|
257
|
+
<p>実行例:</p>
|
258
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks --match_columns 'tags * 3' --query mysql --output_columns _key,tags,_score
|
259
|
+
# [
|
260
|
+
# [
|
261
|
+
# 0,
|
262
|
+
# 1337566253.89858,
|
263
|
+
# 0.000355720520019531
|
264
|
+
# ],
|
265
|
+
# [
|
266
|
+
# [
|
267
|
+
# [
|
268
|
+
# 1
|
269
|
+
# ],
|
270
|
+
# [
|
271
|
+
# [
|
272
|
+
# "_key",
|
273
|
+
# "ShortText"
|
274
|
+
# ],
|
275
|
+
# [
|
276
|
+
# "tags",
|
277
|
+
# "ShortText"
|
278
|
+
# ],
|
279
|
+
# [
|
280
|
+
# "_score",
|
281
|
+
# "Int32"
|
282
|
+
# ]
|
283
|
+
# ],
|
284
|
+
# [
|
285
|
+
# "http://mroonga.org/",
|
286
|
+
# [
|
287
|
+
# "mroonga",
|
288
|
+
# "mysql",
|
289
|
+
# "groonga"
|
290
|
+
# ],
|
291
|
+
# 3
|
292
|
+
# ]
|
293
|
+
# ]
|
294
|
+
# ]
|
295
|
+
# ]
|
296
|
+
</pre></div>
|
297
|
+
</div>
|
298
|
+
<p><a class="reference internal" href="../commands/select.html#select-filter"><em>filter</em></a> を使った場合:</p>
|
299
|
+
<p>実行例:</p>
|
300
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks --filter 'tags @ "msyql"' --output_columns _key,tags,_score
|
301
|
+
# [
|
302
|
+
# [
|
303
|
+
# 0,
|
304
|
+
# 1337566253.89858,
|
305
|
+
# 0.000355720520019531
|
306
|
+
# ],
|
307
|
+
# [
|
308
|
+
# [
|
309
|
+
# [
|
310
|
+
# 0
|
311
|
+
# ],
|
312
|
+
# [
|
313
|
+
# [
|
314
|
+
# "_key",
|
315
|
+
# "ShortText"
|
316
|
+
# ],
|
317
|
+
# [
|
318
|
+
# "tags",
|
319
|
+
# "ShortText"
|
320
|
+
# ],
|
321
|
+
# [
|
322
|
+
# "_score",
|
323
|
+
# "Int32"
|
324
|
+
# ]
|
325
|
+
# ]
|
326
|
+
# ]
|
327
|
+
# ]
|
328
|
+
# ]
|
329
|
+
</pre></div>
|
330
|
+
</div>
|
331
|
+
</div>
|
332
|
+
</div>
|
333
|
+
<div class="section" id="reference-vector-column">
|
334
|
+
<span id="id2"></span><h3>参照型ベクターカラム<a class="headerlink" href="#reference-vector-column" title="このヘッドラインへのパーマリンク">¶</a></h3>
|
335
|
+
<p>TODO</p>
|
336
|
+
<p>Reference vector column is space-efficient if there are many same
|
337
|
+
value elements. Reference vector column keeps reference record IDs not
|
338
|
+
value itself. Record ID is smaller than value itself.</p>
|
339
|
+
<div class="section" id="id3">
|
340
|
+
<h4>作り方<a class="headerlink" href="#id3" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
341
|
+
<p>TODO</p>
|
342
|
+
</div>
|
343
|
+
<div class="section" id="id4">
|
344
|
+
<h4>ロード方法<a class="headerlink" href="#id4" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
345
|
+
<p>TODO</p>
|
346
|
+
</div>
|
347
|
+
<div class="section" id="id5">
|
348
|
+
<h4>検索方法<a class="headerlink" href="#id5" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
349
|
+
<p>TODO</p>
|
350
|
+
</div>
|
351
|
+
</div>
|
352
|
+
<div class="section" id="weight-vector-column">
|
353
|
+
<span id="id6"></span><h3>重み付きベクターカラム<a class="headerlink" href="#weight-vector-column" title="このヘッドラインへのパーマリンク">¶</a></h3>
|
354
|
+
<p>重み付きベクターカラムはノーマルベクターカラムに似ています。複数の要素を保存できます。さらに、要素の重みも保存できます。重みとはその要素の重要度です。</p>
|
355
|
+
<p>重みは正の整数です。デフォルトの重みは <tt class="docutils literal"><span class="pre">0</span></tt> です。これは重みがないという意味になります。</p>
|
356
|
+
<p>重みが1以上なら、検索スコアーに重みが加算されます。重みが <tt class="docutils literal"><span class="pre">0</span></tt> なら検索スコアーは <tt class="docutils literal"><span class="pre">1</span></tt> です。重みが <tt class="docutils literal"><span class="pre">10</span></tt> なら検索スコアーは <tt class="docutils literal"><span class="pre">11</span></tt> ( <tt class="docutils literal"><span class="pre">=</span> <span class="pre">1</span> <span class="pre">+</span> <span class="pre">10</span></tt> )です。</p>
|
357
|
+
<p>重み付きベクターカラムは検索スコアーのチューニングに便利です。 <a class="reference internal" href="../commands/select.html#select-adjuster"><em>adjuster</em></a> も参照してください。特定のレコードの検索スコアーを増やすことができます。</p>
|
358
|
+
<div class="section" id="limitations">
|
359
|
+
<h4>制限<a class="headerlink" href="#limitations" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
360
|
+
<p>今のところいくつか制限があります。将来的には解消される予定です。</p>
|
361
|
+
<p>以下が制限です。</p>
|
362
|
+
<blockquote>
|
363
|
+
<div><ul class="simple">
|
364
|
+
<li><p class="first">ロード時に要素の値を文字列での表現で指定しなければいけません。例えば、数値の29を指定するために、 <tt class="docutils literal"><span class="pre">29</span></tt> を使うことはできません。 <tt class="docutils literal"><span class="pre">"29"</span></tt> と文字列で表記する必要があります。</p>
|
365
|
+
</li>
|
366
|
+
<li><p class="first">参照型を使うことができません。</p>
|
367
|
+
</li>
|
368
|
+
</ul>
|
369
|
+
</div></blockquote>
|
370
|
+
</div>
|
371
|
+
<div class="section" id="id7">
|
372
|
+
<h4>作り方<a class="headerlink" href="#id7" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
373
|
+
<p>重み付きベクターカラムを作るには <a class="reference internal" href="../commands/column_create.html"><em>column_create</em></a> を使います。ポイントは <tt class="docutils literal"><span class="pre">COLUMN_VECTOR|WITH_WEIGHT</span></tt> フラグです。</p>
|
374
|
+
<p>実行例:</p>
|
375
|
+
<div class="highlight-none"><div class="highlight"><pre>table_create Bookmarks TABLE_HASH_KEY ShortText
|
376
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
377
|
+
column_create Bookmarks tags COLUMN_VECTOR|WITH_WEIGHT ShortText
|
378
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
379
|
+
</pre></div>
|
380
|
+
</div>
|
381
|
+
<p><tt class="docutils literal"><span class="pre">WITH_WEIGHT</span></tt> フラグを指定しないと、ただのノーマルベクターカラムになります。</p>
|
382
|
+
<p>1つのブックマークに重み付きで0個以上のタグを設定できます。</p>
|
383
|
+
</div>
|
384
|
+
<div class="section" id="id8">
|
385
|
+
<h4>ロード方法<a class="headerlink" href="#id8" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
386
|
+
<p>JSONのオブジェクト構文でベクターデータをロードします:</p>
|
387
|
+
<div class="highlight-none"><div class="highlight"><pre>{"ELEMENT1": WEIGHT1, "ELEMENT2": WEIGHT2, "ELEMENT3": WEIGHT3, ...}
|
388
|
+
</pre></div>
|
389
|
+
</div>
|
390
|
+
<p>以下のデータをロードしましょう。</p>
|
391
|
+
<table border="1" class="docutils">
|
392
|
+
<colgroup>
|
393
|
+
<col width="50%" />
|
394
|
+
<col width="50%" />
|
395
|
+
</colgroup>
|
396
|
+
<thead valign="bottom">
|
397
|
+
<tr class="row-odd"><th class="head"><tt class="docutils literal"><span class="pre">_key</span></tt></th>
|
398
|
+
<th class="head"><tt class="docutils literal"><span class="pre">tags</span></tt></th>
|
399
|
+
</tr>
|
400
|
+
</thead>
|
401
|
+
<tbody valign="top">
|
402
|
+
<tr class="row-even"><td><tt class="docutils literal"><span class="pre">http://groonga.org/</span></tt></td>
|
403
|
+
<td><tt class="docutils literal"><span class="pre">{"groonga":</span> <span class="pre">100}</span></tt></td>
|
404
|
+
</tr>
|
405
|
+
<tr class="row-odd"><td><tt class="docutils literal"><span class="pre">http://mroonga.org/</span></tt></td>
|
406
|
+
<td><tt class="docutils literal"><span class="pre">{"mroonga":</span> <span class="pre">100,</span> <span class="pre">"mysql":</span> <span class="pre">50,</span> <span class="pre">"groonga":</span> <span class="pre">10}</span></tt></td>
|
407
|
+
</tr>
|
408
|
+
<tr class="row-even"><td><tt class="docutils literal"><span class="pre">http://ranguba.org/</span></tt></td>
|
409
|
+
<td><tt class="docutils literal"><span class="pre">{"ruby":</span> <span class="pre">100,</span> <span class="pre">"groonga":</span> <span class="pre">50}</span></tt></td>
|
410
|
+
</tr>
|
411
|
+
</tbody>
|
412
|
+
</table>
|
413
|
+
<p>以下がデータをロードするコマンドです。</p>
|
414
|
+
<p>実行例:</p>
|
415
|
+
<div class="highlight-none"><div class="highlight"><pre>load --table Bookmarks
|
416
|
+
[
|
417
|
+
{"_key": "http://groonga.org/",
|
418
|
+
"tags": {"groonga": 100}},
|
419
|
+
{"_key": "http://mroonga.org/",
|
420
|
+
"tags": {"mroonga": 100,
|
421
|
+
"mysql": 50,
|
422
|
+
"groonga": 10}},
|
423
|
+
{"_key": "http://ranguba.org/",
|
424
|
+
"tags": {"ruby": 100,
|
425
|
+
"groonga": 50}}
|
426
|
+
]
|
427
|
+
# [[0, 1337566253.89858, 0.000355720520019531], 3]
|
428
|
+
</pre></div>
|
429
|
+
</div>
|
430
|
+
<p>ロードしたデータはJSONのオブジェクト構文で出力されます。</p>
|
431
|
+
<p>実行例:</p>
|
432
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks
|
433
|
+
# [
|
434
|
+
# [
|
435
|
+
# 0,
|
436
|
+
# 1337566253.89858,
|
437
|
+
# 0.000355720520019531
|
438
|
+
# ],
|
439
|
+
# [
|
440
|
+
# [
|
441
|
+
# [
|
442
|
+
# 3
|
443
|
+
# ],
|
444
|
+
# [
|
445
|
+
# [
|
446
|
+
# "_id",
|
447
|
+
# "UInt32"
|
448
|
+
# ],
|
449
|
+
# [
|
450
|
+
# "_key",
|
451
|
+
# "ShortText"
|
452
|
+
# ],
|
453
|
+
# [
|
454
|
+
# "tags",
|
455
|
+
# "ShortText"
|
456
|
+
# ]
|
457
|
+
# ],
|
458
|
+
# [
|
459
|
+
# 1,
|
460
|
+
# "http://groonga.org/",
|
461
|
+
# {
|
462
|
+
# "groonga": 100
|
463
|
+
# }
|
464
|
+
# ],
|
465
|
+
# [
|
466
|
+
# 2,
|
467
|
+
# "http://mroonga.org/",
|
468
|
+
# {
|
469
|
+
# "mroonga": 100,
|
470
|
+
# "groonga": 10,
|
471
|
+
# "mysql": 50
|
472
|
+
# }
|
473
|
+
# ],
|
474
|
+
# [
|
475
|
+
# 3,
|
476
|
+
# "http://ranguba.org/",
|
477
|
+
# {
|
478
|
+
# "ruby": 100,
|
479
|
+
# "groonga": 50
|
480
|
+
# }
|
481
|
+
# ]
|
482
|
+
# ]
|
483
|
+
# ]
|
484
|
+
# ]
|
485
|
+
</pre></div>
|
486
|
+
</div>
|
487
|
+
</div>
|
488
|
+
<div class="section" id="id9">
|
489
|
+
<h4>検索方法<a class="headerlink" href="#id9" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
490
|
+
<p>重み付きベクターを検索するためにはインデックスを作る必要があります。 <tt class="docutils literal"><span class="pre">column_create</span></tt> に <tt class="docutils literal"><span class="pre">WITH_WEIGHT</span></tt> フラグを指定することを忘れないでください。</p>
|
491
|
+
<p>実行例:</p>
|
492
|
+
<div class="highlight-none"><div class="highlight"><pre>table_create Tags TABLE_PAT_KEY ShortText
|
493
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
494
|
+
column_create Tags bookmark_index COLUMN_INDEX|WITH_WEIGHT Bookmarks tags
|
495
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
496
|
+
</pre></div>
|
497
|
+
</div>
|
498
|
+
<p><tt class="docutils literal"><span class="pre">WITH_WEIGHT</span></tt> 以外は重み付きベクターカラムに特有の方法はありません。スカラーカラムにインデックスを作る方法と同じです。</p>
|
499
|
+
<p>全文検索と同じ構文で <tt class="docutils literal"><span class="pre">tags</span></tt> 内の要素を検索できます。</p>
|
500
|
+
<p><a class="reference internal" href="../commands/select.html#select-match-columns"><em>match_columns</em></a> と <a class="reference internal" href="../commands/select.html#select-query"><em>query</em></a> を使った場合:</p>
|
501
|
+
<p>実行例:</p>
|
502
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks --match_columns tags --query groonga --output_columns _key,tags,_score
|
503
|
+
# [
|
504
|
+
# [
|
505
|
+
# 0,
|
506
|
+
# 1337566253.89858,
|
507
|
+
# 0.000355720520019531
|
508
|
+
# ],
|
509
|
+
# [
|
510
|
+
# [
|
511
|
+
# [
|
512
|
+
# 3
|
513
|
+
# ],
|
514
|
+
# [
|
515
|
+
# [
|
516
|
+
# "_key",
|
517
|
+
# "ShortText"
|
518
|
+
# ],
|
519
|
+
# [
|
520
|
+
# "tags",
|
521
|
+
# "ShortText"
|
522
|
+
# ],
|
523
|
+
# [
|
524
|
+
# "_score",
|
525
|
+
# "Int32"
|
526
|
+
# ]
|
527
|
+
# ],
|
528
|
+
# [
|
529
|
+
# "http://groonga.org/",
|
530
|
+
# {
|
531
|
+
# "groonga": 100
|
532
|
+
# },
|
533
|
+
# 101
|
534
|
+
# ],
|
535
|
+
# [
|
536
|
+
# "http://mroonga.org/",
|
537
|
+
# {
|
538
|
+
# "mroonga": 100,
|
539
|
+
# "groonga": 10,
|
540
|
+
# "mysql": 50
|
541
|
+
# },
|
542
|
+
# 11
|
543
|
+
# ],
|
544
|
+
# [
|
545
|
+
# "http://ranguba.org/",
|
546
|
+
# {
|
547
|
+
# "ruby": 100,
|
548
|
+
# "groonga": 50
|
549
|
+
# },
|
550
|
+
# 51
|
551
|
+
# ]
|
552
|
+
# ]
|
553
|
+
# ]
|
554
|
+
# ]
|
555
|
+
</pre></div>
|
556
|
+
</div>
|
557
|
+
<p><a class="reference internal" href="../commands/select.html#select-match-columns"><em>match_columns</em></a> の重みと一緒に使うこともできます。スコアーは <tt class="docutils literal"><span class="pre">(1</span> <span class="pre">+</span> <span class="pre">重み付きベクターの重み)</span> <span class="pre">*</span> <span class="pre">match_columnsの重み</span></tt> 。</p>
|
558
|
+
<p>実行例:</p>
|
559
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks --match_columns 'tags * 3' --query groonga --output_columns _key,tags,_score
|
560
|
+
# [
|
561
|
+
# [
|
562
|
+
# 0,
|
563
|
+
# 1337566253.89858,
|
564
|
+
# 0.000355720520019531
|
565
|
+
# ],
|
566
|
+
# [
|
567
|
+
# [
|
568
|
+
# [
|
569
|
+
# 3
|
570
|
+
# ],
|
571
|
+
# [
|
572
|
+
# [
|
573
|
+
# "_key",
|
574
|
+
# "ShortText"
|
575
|
+
# ],
|
576
|
+
# [
|
577
|
+
# "tags",
|
578
|
+
# "ShortText"
|
579
|
+
# ],
|
580
|
+
# [
|
581
|
+
# "_score",
|
582
|
+
# "Int32"
|
583
|
+
# ]
|
584
|
+
# ],
|
585
|
+
# [
|
586
|
+
# "http://groonga.org/",
|
587
|
+
# {
|
588
|
+
# "groonga": 100
|
589
|
+
# },
|
590
|
+
# 303
|
591
|
+
# ],
|
592
|
+
# [
|
593
|
+
# "http://mroonga.org/",
|
594
|
+
# {
|
595
|
+
# "mroonga": 100,
|
596
|
+
# "groonga": 10,
|
597
|
+
# "mysql": 50
|
598
|
+
# },
|
599
|
+
# 33
|
600
|
+
# ],
|
601
|
+
# [
|
602
|
+
# "http://ranguba.org/",
|
603
|
+
# {
|
604
|
+
# "ruby": 100,
|
605
|
+
# "groonga": 50
|
606
|
+
# },
|
607
|
+
# 153
|
608
|
+
# ]
|
609
|
+
# ]
|
610
|
+
# ]
|
611
|
+
# ]
|
612
|
+
</pre></div>
|
613
|
+
</div>
|
614
|
+
<p><a class="reference internal" href="../commands/select.html#select-filter"><em>filter</em></a> を使った場合:</p>
|
615
|
+
<p>実行例:</p>
|
616
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks --filter 'tags @ "groonga"' --output_columns _key,tags,_score
|
617
|
+
# [
|
618
|
+
# [
|
619
|
+
# 0,
|
620
|
+
# 1337566253.89858,
|
621
|
+
# 0.000355720520019531
|
622
|
+
# ],
|
623
|
+
# [
|
624
|
+
# [
|
625
|
+
# [
|
626
|
+
# 3
|
627
|
+
# ],
|
628
|
+
# [
|
629
|
+
# [
|
630
|
+
# "_key",
|
631
|
+
# "ShortText"
|
632
|
+
# ],
|
633
|
+
# [
|
634
|
+
# "tags",
|
635
|
+
# "ShortText"
|
636
|
+
# ],
|
637
|
+
# [
|
638
|
+
# "_score",
|
639
|
+
# "Int32"
|
640
|
+
# ]
|
641
|
+
# ],
|
642
|
+
# [
|
643
|
+
# "http://groonga.org/",
|
644
|
+
# {
|
645
|
+
# "groonga": 100
|
646
|
+
# },
|
647
|
+
# 101
|
648
|
+
# ],
|
649
|
+
# [
|
650
|
+
# "http://mroonga.org/",
|
651
|
+
# {
|
652
|
+
# "mroonga": 100,
|
653
|
+
# "groonga": 10,
|
654
|
+
# "mysql": 50
|
655
|
+
# },
|
656
|
+
# 11
|
657
|
+
# ],
|
658
|
+
# [
|
659
|
+
# "http://ranguba.org/",
|
660
|
+
# {
|
661
|
+
# "ruby": 100,
|
662
|
+
# "groonga": 50
|
663
|
+
# },
|
664
|
+
# 51
|
665
|
+
# ]
|
666
|
+
# ]
|
667
|
+
# ]
|
668
|
+
# ]
|
669
|
+
</pre></div>
|
670
|
+
</div>
|
671
|
+
</div>
|
672
|
+
<div class="section" id="how-to-apply-just-weight">
|
673
|
+
<h4>重みだけを適用する方法<a class="headerlink" href="#how-to-apply-just-weight" title="このヘッドラインへのパーマリンク">¶</a></h4>
|
674
|
+
<p>マッチしたレコード集合を変更せずに、重み付きベクターカラムの重みの分だけ検索スコアーを増やすことができます。</p>
|
675
|
+
<p>この用途には <a class="reference internal" href="../commands/select.html#select-adjuster"><em>adjuster</em></a> を使います。</p>
|
676
|
+
<p>実行例:</p>
|
677
|
+
<div class="highlight-none"><div class="highlight"><pre>select Bookmarks \
|
678
|
+
--filter true \
|
679
|
+
--adjuster 'tags @ "mysql" * 10 + tags @ "groonga" * 5' \
|
680
|
+
--output_columns _key,tags,_score
|
681
|
+
# [
|
682
|
+
# [
|
683
|
+
# 0,
|
684
|
+
# 1337566253.89858,
|
685
|
+
# 0.000355720520019531
|
686
|
+
# ],
|
687
|
+
# [
|
688
|
+
# [
|
689
|
+
# [
|
690
|
+
# 3
|
691
|
+
# ],
|
692
|
+
# [
|
693
|
+
# [
|
694
|
+
# "_key",
|
695
|
+
# "ShortText"
|
696
|
+
# ],
|
697
|
+
# [
|
698
|
+
# "tags",
|
699
|
+
# "ShortText"
|
700
|
+
# ],
|
701
|
+
# [
|
702
|
+
# "_score",
|
703
|
+
# "Int32"
|
704
|
+
# ]
|
705
|
+
# ],
|
706
|
+
# [
|
707
|
+
# "http://groonga.org/",
|
708
|
+
# {
|
709
|
+
# "groonga": 100
|
710
|
+
# },
|
711
|
+
# 506
|
712
|
+
# ],
|
713
|
+
# [
|
714
|
+
# "http://mroonga.org/",
|
715
|
+
# {
|
716
|
+
# "mroonga": 100,
|
717
|
+
# "groonga": 10,
|
718
|
+
# "mysql": 50
|
719
|
+
# },
|
720
|
+
# 566
|
721
|
+
# ],
|
722
|
+
# [
|
723
|
+
# "http://ranguba.org/",
|
724
|
+
# {
|
725
|
+
# "ruby": 100,
|
726
|
+
# "groonga": 50
|
727
|
+
# },
|
728
|
+
# 256
|
729
|
+
# ]
|
730
|
+
# ]
|
731
|
+
# ]
|
732
|
+
# ]
|
733
|
+
</pre></div>
|
734
|
+
</div>
|
735
|
+
<p>この <tt class="docutils literal"><span class="pre">select</span></tt> コマンドは <tt class="docutils literal"><span class="pre">--filter</span> <span class="pre">true</span></tt> を使っています。そのため、すべてのレコードがマッチし、スコアーは1になります。それから、 <tt class="docutils literal"><span class="pre">--adjuster</span></tt> を適用します。アジャスターは以下のことをします。</p>
|
736
|
+
<blockquote>
|
737
|
+
<div><ul class="simple">
|
738
|
+
<li><p class="first"><tt class="docutils literal"><span class="pre">tags</span> <span class="pre">@</span> <span class="pre">"mysql"</span> <span class="pre">*</span> <span class="pre">10</span></tt> は <tt class="docutils literal"><span class="pre">"mysql"</span></tt> タグを含むレコードのスコアーを <tt class="docutils literal"><span class="pre">(1</span> <span class="pre">+</span> <span class="pre">重み)</span> <span class="pre">*</span> <span class="pre">10</span></tt> 増やします。</p>
|
739
|
+
</li>
|
740
|
+
<li><p class="first"><tt class="docutils literal"><span class="pre">tags</span> <span class="pre">@</span> <span class="pre">"groonga"</span> <span class="pre">*</span> <span class="pre">5</span></tt> は <tt class="docutils literal"><span class="pre">"groonga"</span></tt> タグを含むレコードのスコアーを <tt class="docutils literal"><span class="pre">(1</span> <span class="pre">+</span> <span class="pre">重み)</span> <span class="pre">*</span> <span class="pre">5</span></tt> 増やします。</p>
|
741
|
+
</li>
|
742
|
+
</ul>
|
743
|
+
</div></blockquote>
|
744
|
+
<p>例えば、 <tt class="docutils literal"><span class="pre">"http://mroonga.org/"</span></tt> レコードは <tt class="docutils literal"><span class="pre">"mysql"</span></tt> タグと <tt class="docutils literal"><span class="pre">"groonga"</span></tt> タグを両方持っています。そのため、スコアーは <tt class="docutils literal"><span class="pre">565</span></tt> ( <tt class="docutils literal"><span class="pre">=</span> <span class="pre">((1</span> <span class="pre">+</span> <span class="pre">50)</span> <span class="pre">*</span> <span class="pre">10)</span> <span class="pre">+</span> <span class="pre">((1</span> <span class="pre">+</span> <span class="pre">10)</span> <span class="pre">*</span> <span class="pre">5)</span> <span class="pre">=</span> <span class="pre">(51</span> <span class="pre">*</span> <span class="pre">10)</span> <span class="pre">+</span> <span class="pre">(11</span> <span class="pre">*</span> <span class="pre">5)</span> <span class="pre">=</span> <span class="pre">510</span> <span class="pre">+</span> <span class="pre">55</span></tt> )増えます。 <tt class="docutils literal"><span class="pre">--adjuster</span></tt> を適用する前は、<tt class="docutils literal"><span class="pre">--filter</span> <span class="pre">true</span></tt> によって検索スコアーは1になっています。そのため、 <tt class="docutils literal"><span class="pre">"http://mroonga.org/"</span></tt> レコードの最終的な検索スコアーは <tt class="docutils literal"><span class="pre">566</span></tt> ( <tt class="docutils literal"><span class="pre">=</span> <span class="pre">1</span> <span class="pre">+</span> <span class="pre">565</span></tt> )になります。</p>
|
745
|
+
</div>
|
746
|
+
</div>
|
747
|
+
</div>
|
748
|
+
</div>
|
749
|
+
|
750
|
+
|
751
|
+
</div>
|
752
|
+
</div>
|
753
|
+
</div>
|
754
|
+
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
|
755
|
+
<div class="sphinxsidebarwrapper">
|
756
|
+
<h3><a href="../../index.html">目次</a></h3>
|
757
|
+
<ul>
|
758
|
+
<li><a class="reference internal" href="#">ベクターカラム</a><ul>
|
759
|
+
<li><a class="reference internal" href="#summary">概要</a></li>
|
760
|
+
<li><a class="reference internal" href="#usage">使い方</a><ul>
|
761
|
+
<li><a class="reference internal" href="#normal-vector-column">ノーマルベクターカラム</a><ul>
|
762
|
+
<li><a class="reference internal" href="#how-to-create">作り方</a></li>
|
763
|
+
<li><a class="reference internal" href="#how-to-load">ロード方法</a></li>
|
764
|
+
<li><a class="reference internal" href="#how-to-search">検索方法</a></li>
|
765
|
+
</ul>
|
766
|
+
</li>
|
767
|
+
<li><a class="reference internal" href="#reference-vector-column">参照型ベクターカラム</a><ul>
|
768
|
+
<li><a class="reference internal" href="#id3">作り方</a></li>
|
769
|
+
<li><a class="reference internal" href="#id4">ロード方法</a></li>
|
770
|
+
<li><a class="reference internal" href="#id5">検索方法</a></li>
|
771
|
+
</ul>
|
772
|
+
</li>
|
773
|
+
<li><a class="reference internal" href="#weight-vector-column">重み付きベクターカラム</a><ul>
|
774
|
+
<li><a class="reference internal" href="#limitations">制限</a></li>
|
775
|
+
<li><a class="reference internal" href="#id7">作り方</a></li>
|
776
|
+
<li><a class="reference internal" href="#id8">ロード方法</a></li>
|
777
|
+
<li><a class="reference internal" href="#id9">検索方法</a></li>
|
778
|
+
<li><a class="reference internal" href="#how-to-apply-just-weight">重みだけを適用する方法</a></li>
|
779
|
+
</ul>
|
780
|
+
</li>
|
781
|
+
</ul>
|
782
|
+
</li>
|
783
|
+
</ul>
|
784
|
+
</li>
|
785
|
+
</ul>
|
786
|
+
|
787
|
+
<div role="note" aria-label="source link">
|
788
|
+
<h3>このページ</h3>
|
789
|
+
<ul class="this-page-menu">
|
790
|
+
<li><a href="../../_sources/reference/columns/vector.txt"
|
791
|
+
rel="nofollow">ソースコードを表示</a></li>
|
792
|
+
</ul>
|
793
|
+
</div>
|
794
|
+
<div id="searchbox" style="display: none" role="search">
|
795
|
+
<h3>クイック検索</h3>
|
796
|
+
<form class="search" action="../../search.html" method="get">
|
797
|
+
<input type="text" name="q" />
|
798
|
+
<input type="submit" value="検索" />
|
799
|
+
<input type="hidden" name="check_keywords" value="yes" />
|
800
|
+
<input type="hidden" name="area" value="default" />
|
801
|
+
</form>
|
802
|
+
<p class="searchtip" style="font-size: 90%">
|
803
|
+
モジュール、クラス、または関数名を入力してください
|
804
|
+
</p>
|
805
|
+
</div>
|
806
|
+
<script type="text/javascript">$('#searchbox').show(0);</script>
|
807
|
+
</div>
|
808
|
+
</div>
|
809
|
+
<div class="clearer"></div>
|
810
|
+
</div>
|
811
|
+
<div class="related" role="navigation" aria-label="related navigation">
|
812
|
+
<h3>ナビゲーション</h3>
|
813
|
+
<ul>
|
814
|
+
<li class="right" style="margin-right: 10px">
|
815
|
+
<a href="../../genindex.html" title="総合索引"
|
816
|
+
>索引</a></li>
|
817
|
+
<li><a href="../../index.html">Groonga v4.0.1ドキュメント</a> »</li>
|
818
|
+
</ul>
|
819
|
+
</div>
|
820
|
+
<div class="footer" role="contentinfo">
|
821
|
+
© Copyright 2009-2014, Brazil, Inc.
|
822
|
+
</div>
|
823
|
+
</body>
|
824
|
+
</html>
|