# BordIRLines Dataset ## Dataset Summary The **BordIRLines Dataset** is an information retrieval (IR) dataset constructed from various language corpora. It contains queries and corresponding ranked docs along with their relevance scores. The dataset includes multiple languages, including English, Arabic, Spanish, and others, and is split across different sources like LLM-based outputs. ### Languages The dataset includes docs and queries in the following languages: - **en**: English - **zht**: Traditional Chinese - **ar**: Arabic - **zhs**: Simplified Chinese - **es**: Spanish - **fr**: French - **ru**: Russian - **hi**: Hindi - **ms**: Malay - **sw**: Swahili - **az**: Azerbaijani - **ko**: Korean - **pt**: Portuguese - **hy**: Armenian - **th**: Thai - **uk**: Ukrainian - **ur**: Urdu - **sr**: Serbian - **iw**: Hebrew - **ja**: Japanese - **hr**: Croatian - **tl**: Tagalog - **ky**: Kyrgyz - **vi**: Vietnamese - **fa**: Persian - **tg**: Tajik - **mg**: Malagasy - **nl**: Dutch - **ne**: Nepali - **uz**: Uzbek - **my**: Burmese - **da**: Danish - **dz**: Dzongkha - **id**: Indonesian - **is**: Icelandic - **tr**: Turkish - **lo**: Lao - **sl**: Slovenian - **so**: Somali - **mn**: Mongolian - **bn**: Bengali - **bs**: Bosnian - **ht**: Haitian Creole - **el**: Greek - **it**: Italian - **to**: Tonga - **ka**: Georgian - **sn**: Shona - **sq**: Albanian - **control**: see below The **control** language is English, and contains the queries for all 251 territories. In contrast, **en** is only the 38 territories which have an English-speaking claimant. Each `doc` is a passage from a Wikipedia article. ## Dataset Structure ### Data Fields The dataset consists of the following fields: -- **query_id** (`string`): The id of the query. - **query** (`string`): The query text as provided by the `queries.tsv` file. - **territory** (`string`): The territory of the query hit. - **rank** (`int32`): The rank of the document for the corresponding query. - **score** (`float32`): The relevance score of the document as provided by the search engine or model. - **doc_id** (`string`): The unique identifier of the article. - **doc_text** (`string`): The full text of the corresponding article or document. ### Download Structure The dataset is structured as follows: ``` data/ en/ llm/ en_docs.json en_query_hits.tsv ar/ llm/ ar_docs.json ar_query_hits.tsv ... queries.tsv ``` - **queries.tsv**: Contains the list of query IDs and their associated query texts. - **\_docs.json**: A JSON file with docs for a specific language. - **\_query_hits.tsv**: A TSV file with relevance scores and hit ranks for queries. ## Example Usage Below is example code to load the **BordIRLines Dataset** for experiments: ```python from datasets import load_dataset dataset = load_dataset( "borderlines/bordirlines", source='llm', # Source of the dataset (e.g., llm) name="all", # Load data for all supported languages n_hits=10, # Maximum number of hits per query <= 50 ) ``` This will download a DatasetDict for all languages, from the specified source (here, `llm`), with up to `n_hits` docs (here, 10). The keys are a language code, and the values are the associated Dataset.