luganda-reasoning / README.md
henryhale's picture
Update README.md
b2f3e03 verified
|
Raw History Blame Contribute Delete
2.95 kB
metadata
language:
  - lg
license: other
license_name: cc-by-nc-4.0-and-source-licenses
task_categories:
  - text-generation
  - question-answering
tags:
  - reasoning
  - chain-of-thought
  - math
  - commonsense
  - machine-translated
  - luganda
size_categories:
  - 10K<n<100K
source_datasets:
  - openai/gsm8k
  - ChilleD/StrategyQA
  - tasksource/ecqa
  - cs-giung/clean-gsm8k-aug-nl
configs:
  - config_name: default
    data_files:
      - split: train
        path: data/*.parquet

Luganda Reasoning

Short question → reasoning → answer examples in Luganda, about half math and half commonsense, for teaching small models to reason step by step. Every row is at most 1,400 English characters before translation.

source Taken from Reasoning Answer Rows
openai/gsm8k openai/gsm8k (main, train + test) Worked solution Number TBD
ChilleD/StrategyQA ChilleD/StrategyQA Supporting facts Yee / Nedda 2,035
tasksource/ecqa tasksource/ecqa Explanation of the choice One of 5 options TBD
cs-giung/clean-gsm8k-aug-nl cs-giung/clean-gsm8k-aug-nl (random sample, no GSM8K repeats) Step-by-step solution Number TBD

Usage

from datasets import load_dataset

ds = load_dataset("henryhale/luganda-reasoning", split="train")
train = ds.filter(lambda r: r["split"] != "test")  # keep the sources' test rows for evaluation
math = ds.filter(lambda r: "gsm8k" in r["source"])  # or pick sources by the `source` column

def to_text(r):
    return {"text": f"{r['question']}\n<think>\n{r['reasoning']}\n</think>\n{r['answer']}"}

train = train.map(to_text)

Columns: question, reasoning, answer, split (the split the row came from in its source: train / validation / test), source and source_id (<file>:<row> in the source repo).

How it was made

Translated from English with facebook/nllb-200-distilled-1.3B (CTranslate2, int8, beam 2), sentence by sentence. Worked arithmetic (48/2 = 24) and GSM8K answers were copied unchanged. A row was dropped if any translated sentence was empty, had a length ratio outside 0.5–2×, repeated itself or lost a number, or if a text of 50+ characters was not Luganda according to GlotLID. The translations were not reviewed by people. Expect some unnatural phrasing.

License

The translations were made with NLLB-200 (CC BY-NC 4.0), so use this dataset for non-commercial research only. Each row is also under its source's license: GSM8K, StrategyQA and clean-gsm8k-aug-nl are MIT, and ECQA is CDLA-Sharing-1.0. clean-gsm8k-aug-nl was written by GPT-4, so OpenAI's terms also apply to it.