NanoBEIR-th / README.md
hotchpotch's picture
Update NanoBEIR BM25 candidates and README
c44017b verified
|
Raw History Blame
13.8 kB
metadata
configs:
  - config_name: bm25
    data_files:
      - split: NanoArguAna
        path: bm25/NanoArguAna.parquet
      - split: NanoClimateFEVER
        path: bm25/NanoClimateFEVER.parquet
      - split: NanoDBPedia
        path: bm25/NanoDBPedia.parquet
      - split: NanoFEVER
        path: bm25/NanoFEVER.parquet
      - split: NanoFiQA2018
        path: bm25/NanoFiQA2018.parquet
      - split: NanoHotpotQA
        path: bm25/NanoHotpotQA.parquet
      - split: NanoMSMARCO
        path: bm25/NanoMSMARCO.parquet
      - split: NanoNFCorpus
        path: bm25/NanoNFCorpus.parquet
      - split: NanoNQ
        path: bm25/NanoNQ.parquet
      - split: NanoQuoraRetrieval
        path: bm25/NanoQuoraRetrieval.parquet
      - split: NanoSCIDOCS
        path: bm25/NanoSCIDOCS.parquet
      - split: NanoSciFact
        path: bm25/NanoSciFact.parquet
      - split: NanoTouche2020
        path: bm25/NanoTouche2020.parquet
  - config_name: corpus
    data_files:
      - split: NanoArguAna
        path: corpus/NanoArguAna.parquet
      - split: NanoClimateFEVER
        path: corpus/NanoClimateFEVER.parquet
      - split: NanoDBPedia
        path: corpus/NanoDBPedia.parquet
      - split: NanoFEVER
        path: corpus/NanoFEVER.parquet
      - split: NanoFiQA2018
        path: corpus/NanoFiQA2018.parquet
      - split: NanoHotpotQA
        path: corpus/NanoHotpotQA.parquet
      - split: NanoMSMARCO
        path: corpus/NanoMSMARCO.parquet
      - split: NanoNFCorpus
        path: corpus/NanoNFCorpus.parquet
      - split: NanoNQ
        path: corpus/NanoNQ.parquet
      - split: NanoQuoraRetrieval
        path: corpus/NanoQuoraRetrieval.parquet
      - split: NanoSCIDOCS
        path: corpus/NanoSCIDOCS.parquet
      - split: NanoSciFact
        path: corpus/NanoSciFact.parquet
      - split: NanoTouche2020
        path: corpus/NanoTouche2020.parquet
  - config_name: qrels
    data_files:
      - split: NanoArguAna
        path: qrels/NanoArguAna.parquet
      - split: NanoClimateFEVER
        path: qrels/NanoClimateFEVER.parquet
      - split: NanoDBPedia
        path: qrels/NanoDBPedia.parquet
      - split: NanoFEVER
        path: qrels/NanoFEVER.parquet
      - split: NanoFiQA2018
        path: qrels/NanoFiQA2018.parquet
      - split: NanoHotpotQA
        path: qrels/NanoHotpotQA.parquet
      - split: NanoMSMARCO
        path: qrels/NanoMSMARCO.parquet
      - split: NanoNFCorpus
        path: qrels/NanoNFCorpus.parquet
      - split: NanoNQ
        path: qrels/NanoNQ.parquet
      - split: NanoQuoraRetrieval
        path: qrels/NanoQuoraRetrieval.parquet
      - split: NanoSCIDOCS
        path: qrels/NanoSCIDOCS.parquet
      - split: NanoSciFact
        path: qrels/NanoSciFact.parquet
      - split: NanoTouche2020
        path: qrels/NanoTouche2020.parquet
  - config_name: queries
    data_files:
      - split: NanoArguAna
        path: queries/NanoArguAna.parquet
      - split: NanoClimateFEVER
        path: queries/NanoClimateFEVER.parquet
      - split: NanoDBPedia
        path: queries/NanoDBPedia.parquet
      - split: NanoFEVER
        path: queries/NanoFEVER.parquet
      - split: NanoFiQA2018
        path: queries/NanoFiQA2018.parquet
      - split: NanoHotpotQA
        path: queries/NanoHotpotQA.parquet
      - split: NanoMSMARCO
        path: queries/NanoMSMARCO.parquet
      - split: NanoNFCorpus
        path: queries/NanoNFCorpus.parquet
      - split: NanoNQ
        path: queries/NanoNQ.parquet
      - split: NanoQuoraRetrieval
        path: queries/NanoQuoraRetrieval.parquet
      - split: NanoSCIDOCS
        path: queries/NanoSCIDOCS.parquet
      - split: NanoSciFact
        path: queries/NanoSciFact.parquet
      - split: NanoTouche2020
        path: queries/NanoTouche2020.parquet
    default: true
language:
  - multilingual
tags:
  - information-retrieval
  - retrieval
  - nano
  - bm25
  - hakari-bench

NanoBEIR-th

This dataset is a Nano-style retrieval dataset. Nano-series evaluation can be run easily with HAKARI-Bench.

NanoBEIR-th is derived from MNanoBEIR / NanoBEIR. It follows the Hugging Face Datasets layout convention used by sentence-transformers/NanoBEIR-en: each Nano split has separate corpus, queries, and qrels tables, and BM25 candidates are provided separately in a bm25 table. This layout follows the NanoBEIR-style evaluation approach summarized in NanoBEIR.

NanoBEIR-th is the Thai language-specific component of MNanoBEIR. It groups compact BEIR-derived retrieval tasks for efficient evaluation of document ranking in that language.

Source Links

Data Layout

This dataset uses four Hugging Face Datasets configs:

  • corpus: documents with _id and text
  • queries: queries with _id and text
  • qrels: positive relevance labels with query-id and corpus-id
  • bm25: BM25 candidate lists with query-id and corpus-ids

Each config has the same Nano split names.

The qrels config is positive-only. Source rows with score <= 0 are treated as non-relevant or hard-negative annotations and are not included in qrels. When the source provides such rows, their documents are preferentially used as hard negatives in the corpus config before generic corpus-fill documents. Source hard negatives are sampled deterministically with query round-robin so one query's negative pool does not dominate the corpus.

Split Statistics

Length statistics are computed with len(str(text)) over the queries and corpus tables. std is the population standard deviation over the rows in each split.

Nano split Queries Corpus Qrels Query avg Query std Query median Query p25 Query p75 Doc avg Doc std Doc median Doc p25 Doc p75
NanoArguAna 50 3635 50 820.6 133.1 881.5 772.2 913.0 860.1 467.1 771.0 535.0 1073.0
NanoClimateFEVER 50 3408 148 118.6 46.2 113.0 86.2 151.2 1395.4 732.3 1263.5 851.8 1799.2
NanoDBPedia 50 6045 1158 30.9 13.4 28.5 19.2 42.5 316.4 132.5 345.0 224.0 414.0
NanoFEVER 50 4996 57 46.9 15.8 45.5 36.8 57.0 1084.7 722.4 930.5 545.8 1455.2
NanoFiQA2018 50 4598 123 55.2 19.5 51.5 39.5 70.0 779.2 667.4 574.5 314.0 999.8
NanoHotpotQA 50 5090 100 79.7 27.7 74.0 57.5 99.8 330.7 239.4 287.0 151.0 449.0
NanoMSMARCO 50 5043 50 32.1 13.6 29.0 25.2 38.5 293.9 115.0 266.0 221.0 339.0
NanoNFCorpus 50 2953 1651 22.6 13.3 20.5 10.2 31.0 1387.4 461.6 1409.0 1102.0 1647.0
NanoNQ 50 5035 57 40.8 12.5 39.0 33.0 44.8 473.6 424.0 402.0 161.0 673.0
NanoQuoraRetrieval 50 5046 70 46.9 16.9 42.0 37.2 56.0 53.7 27.5 47.0 36.0 62.0
NanoSCIDOCS 50 2210 244 69.1 19.4 68.5 57.0 82.0 820.4 528.2 814.5 510.2 1100.0
NanoSciFact 50 2919 56 92.7 39.1 88.5 57.5 117.8 1328.8 519.6 1245.0 978.5 1617.0
NanoTouche2020 49 5745 932 46.3 16.0 42.0 37.0 55.0 1438.1 1332.4 886.0 287.0 2677.0

Construction Steps

This dataset is constructed as follows.

  1. Use MNanoBEIR / NanoBEIR as the upstream benchmark or dataset family.
  2. Load source datasets from the hakari-bench/NanoBEIR-th corpus, queries, and qrels tables.
  3. Source evaluation split policy: the NanoBEIR split set.
  4. Create one Nano split for each selected source retrieval task.
  5. Keep up to 200 eligible queries per Nano split.
  6. Treat source relevance rows with score > 0 as qrels-positive documents. If the source has no score column, treat its qrels as positive-only only when that is the source task convention.
  7. Exclude source rows with score <= 0 from qrels. When such rows are available for selected queries, use their documents as hard-negative corpus candidates before generic fill documents.
  8. Include all qrels-positive documents for the selected queries.
  9. Use the included corpus tables for each Nano split; no additional document resampling is performed.
  10. Remove exact duplicate query text and document text within each split. If a removed document duplicate was referenced by qrels, the qrels row was removed.
  11. Store corpus text as title plus body text when available.
  12. Generate BM25 top-100 candidates with wordseg:th tokenization.
  13. If a qrels-positive document is missing from the raw BM25 result, insert it into the final bm25 candidate list by replacing a tail non-positive candidate.

The qrels config is positive-only. When needed for top-k reranking coverage, positive qrels are capped per query to the BM25 top-k.

The bm25 candidate subset is generated from the included corpus for each split.

For top-100 reranking diagnostics, positive qrels are capped to at most 100 documents per query before BM25 positive forcing. This makes full relevant coverage possible for splits whose upstream qrels contain more than 100 positives for a single query.

BM25 Subset Policy

The bm25 config is a candidate subset for first-stage retrieval and reranking. It is not a separate source dataset. Each row contains one query id and a ranked list of up to 100 corpus ids.

BM25 candidates are generated from the selected corpus for each split. When a qrels-positive document is not present in the raw BM25 top-100 results, the missing positive is forced into the final candidate list by replacing a tail candidate that is not positive for that query. Candidate ids are kept unique after replacement.

Concretely, each bm25 row is produced by tokenizing the selected split corpus and query texts with wordseg:th, ranking the corpus with BM25, then writing the ranked corpus ids as corpus-ids for that query. The list is a candidate subset for downstream evaluation, not a full-corpus ranking.

Source hard negatives, including documents referenced by source rows with score <= 0, may appear in the selected corpus and can naturally appear in BM25 candidates. They are still non-relevant and are not listed in qrels.

When source hard negatives are available, the default corpus sampling policy is query round-robin: group hard negatives by selected query, preserve source rank/order within each query, add at most one new hard negative from each query per pass, remove duplicate IDs and exact duplicate text, then fill any remaining slots from source corpus order.

Split Mapping

Each Nano split maps to one source retrieval task unless noted otherwise.

Nano split Source task Source dataset Queries Corpus Qrels
NanoArguAna NanoArguAna hakari-bench/NanoBEIR-th 50 3635 50
NanoClimateFEVER NanoClimateFEVER hakari-bench/NanoBEIR-th 50 3408 148
NanoDBPedia NanoDBPedia hakari-bench/NanoBEIR-th 50 6045 1158
NanoFEVER NanoFEVER hakari-bench/NanoBEIR-th 50 4996 57
NanoFiQA2018 NanoFiQA2018 hakari-bench/NanoBEIR-th 50 4598 123
NanoHotpotQA NanoHotpotQA hakari-bench/NanoBEIR-th 50 5090 100
NanoMSMARCO NanoMSMARCO hakari-bench/NanoBEIR-th 50 5043 50
NanoNFCorpus NanoNFCorpus hakari-bench/NanoBEIR-th 50 2953 1651
NanoNQ NanoNQ hakari-bench/NanoBEIR-th 50 5035 57
NanoQuoraRetrieval NanoQuoraRetrieval hakari-bench/NanoBEIR-th 50 5046 70
NanoSCIDOCS NanoSCIDOCS hakari-bench/NanoBEIR-th 50 2210 244
NanoSciFact NanoSciFact hakari-bench/NanoBEIR-th 50 2919 56
NanoTouche2020 NanoTouche2020 hakari-bench/NanoBEIR-th 49 5745 932

BM25 nDCG@10

nDCG@10 is computed from the included BM25 ranking against the included qrels.

Coverage is measured against included qrels at the same BM25 top-k used for reranking diagnostics. The included BM25 candidate subset has 100.00% query coverage and 100.00% relevant coverage for every split.

Nano split Tokenizer Forced BM25 positives Query cov Relevant cov BM25 nDCG@10
NanoArguAna wordseg:th 3 100.00% 100.00% 0.4051
NanoClimateFEVER wordseg:th 70 100.00% 100.00% 0.2368
NanoDBPedia wordseg:th 403 100.00% 100.00% 0.5043
NanoFEVER wordseg:th 3 100.00% 100.00% 0.7001
NanoFiQA2018 wordseg:th 48 100.00% 100.00% 0.2726
NanoHotpotQA wordseg:th 14 100.00% 100.00% 0.5523
NanoMSMARCO wordseg:th 10 100.00% 100.00% 0.2907
NanoNFCorpus wordseg:th 1397 100.00% 100.00% 0.3243
NanoNQ wordseg:th 9 100.00% 100.00% 0.3191
NanoQuoraRetrieval wordseg:th 2 100.00% 100.00% 0.7283
NanoSCIDOCS wordseg:th 107 100.00% 100.00% 0.2641
NanoSciFact wordseg:th 8 100.00% 100.00% 0.6334
NanoTouche2020 wordseg:th 234 100.00% 100.00% 0.5108

Skipped Tasks

No source tasks were skipped.

License

NanoBEIR-th is a derived dataset. Users must comply with the licenses, terms, and attribution requirements of the upstream source datasets.