metapy.index
https://github.com/meta-toolkit/metapy/blob/master/src/metapy_index.cpp
Table of Contents
metapy.index.make_inverted_index(configpath)
reference
- Options for index
config['index']
- The name for index, which will be used as a cache folder name.
config['indexer-ram-budget']
- (optional)
config['indexer-max-writers']
- (optional)
config['indexer-num-threads']
- (optional)
- Options for corpus
config['prefix']
- prefix for the dataset
config['dataset']
- dataset name
config['corpus']
{prefix}/{dataset}/{corpus}
to specify how handle the corpus.
- Options for analyzer:
[[analyzers]]
make_inverted_index
creates analyzer internally.
- https://github.com/meta-toolkit/metapy/blob/master/src/metapy_index.cpp#L193
- https://github.com/meta-toolkit/meta/blob/master/include/meta/index/make_index.h#L62
- https://github.com/meta-toolkit/meta/blob/master/include/meta/index/make_index.h#L102
- https://github.com/meta-toolkit/meta/blob/master/src/index/inverted_index.cpp
metapy.index.IREval(configpath)
reference
config['query-judgements']
- which is a path to a file formatted as follows.
For each row,
(<query id>, <doc id>, <relevance level>)
0 6 2
0 7 1
0 45 2
0 21 1
0 99 1
1 6 1
1 4 1
1 89 2