Datasets:
File size: 8,641 Bytes
3fe61f1 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 | ---
license: apache-2.0
language:
- zh
tags:
- benchmark
- evaluation
- taiwan
- zh-tw
- multiple-choice
- twinkle-eval
- tcm-basic
task_categories:
- question-answering
size_categories:
- 1K<n<10K
configs:
- config_name: default
data_files:
- split: test
path: benchmark.csv
---
# Traditional Chinese Medicine — Basic Theory (中醫基礎醫學)
A multiple-choice benchmark for **Traditional Chinese Medicine — Basic Theory** — the subject 「中醫基礎醫學」 as
examined in Taiwan's national examinations, in Traditional Chinese. Built from the
papers published as open data by the **Ministry of Examination (考選部)**.
One dataset per **academic subject**: papers are grouped by the subject they examine,
not by the professional category sitting the exam.
Part of [**OpenTWBench**](https://huggingface.co/OpenTWBench) — an open evaluation suite for
Taiwan-domain knowledge.
## Overview
| Property | Value |
|---|---:|
| Questions | **4,430** (deduplicated) |
| Years | 2012–2026 |
| Source papers parsed | 65 of 74 |
| Format | 4-choice single-answer (A/B/C/D) |
| Language | Traditional Chinese (zh-TW) |
| Framework | Twinkle Eval compatible |
| Field | medicine |
## Fields
The row shape is the **Twinkle Eval MCQ** contract — `question`, `A`–`D`, `answer` —
with provenance columns alongside, which the harness ignores.
| Field | Description |
|---|---|
| `question` | Question stem |
| `A` / `B` / `C` / `D` | Option texts |
| `answer` | Gold option letter |
| `subject` | Full examination subject name (科目全名) |
| `subject_group` | Examination category (類科組別) |
| `exam_level` | Examination grade (等級分類) |
| `exam_name` | Official title of the examination |
| `year_roc` / `year_ce` | Exam year (ROC / CE calendar) |
| `q_no` | Question number on the original paper |
| `paper_id` | Originating paper identifier |
| `n_source_papers` | How many papers published this identical item |
## Examination Categories
| 類科組別 | Questions |
|---|---:|
| 中醫師(一) | 4,122 |
| 中醫師 | 308 |
## Examination Levels
| 等級分類 | Questions |
|---|---:|
| 專技高考 | 4,430 |
## Usage
### Twinkle Eval
```bash
twinkle-eval --init
# point `dataset_paths` at a directory holding benchmark.jsonl, then:
twinkle-eval --config config.yaml --export json csv
```
### datasets
```python
from datasets import load_dataset
ds = load_dataset("OpenTWBench/tw-tcm-basic-bench", split="test")
print(ds[0]["question"], ds[0]["answer"])
```
## Construction
1. **Index** — the Ministry of Examination open-data index
(`wHandExamQandA_CSV.ashx`), filtered to multiple-choice papers that publish an
answer key.
2. **Retrieval** — question and answer-key PDFs fetched directly, rate-limited and
cached.
3. **Parsing** — PDF text layer extracted with PyMuPDF; see the hazards below.
4. **Filtering and deduplication** — see below.
### Parsing hazards handled
These silently corrupt naive extraction, so they are documented here:
- Option markers live in the **EUDC Private Use Area** (`U+E18C`–`U+E190` = A–E)
rather than as literal letters; some older layouts use `A.` or `(A)` instead.
- Text mixes **CJK Compatibility Ideographs**. Normalised with **NFC** — *not*
NFKC, which rewrites 「,」 to an ASCII comma.
- Answer-key PDFs are **grids whose text layer comes out shuffled**: question
labels and answer letters arrive in separate runs, sometimes out of order.
Pairing by reading order misaligns the entire paper, so cells are paired **by
page coordinates** instead, with the column tolerance derived from the grid pitch.
- The first answer cell of a row is often **glued to the row label** in the text
layer (`答案C`). Left unhandled, that cell goes missing and every label in the
row pairs with its right-hand neighbour — shifting the whole paper by one.
- Question numbers must run **1..N monotonically**: a bare number inside a stem
(frequent in quantitative papers) would otherwise start a phantom question.
- Answer letters may be **full-width** (`A`) and `#` marks a voided question.
- Papers mix **single-select and multi-select** sections; multi-select keys are
multi-letter tokens (`ABDE`).
Every paper is cross-checked against the question count its own answer sheet
declares (`單選題數`/`複選題數`/`題數`); a mismatch rejects the paper rather than
importing a silently shifted key.
### Excluded
| Excluded | Count |
|---|---:|
| Multi-select items | 0 |
| Voided items (一律給分) | 52 |
| English-language items | 0 |
| Items referring to a figure or table | 14 |
| Follow-up items in a 題組 (「承上題」) | 24 |
| Items whose last option swallowed following text | 0 |
| Items not in 4-choice form | 53 |
| Items whose stem was displaced by table debris | 0 |
| Items whose duplicate keys disagreed | 0 |
| Items already in tw-legal-benchmark-v2 | 0 |
| Papers rejected by the answer-count check | 0 |
| Papers rejected as incompletely parsed | 9 |
Questions already published in
[`lianghsun/tw-legal-benchmark-v2`](https://huggingface.co/datasets/lianghsun/tw-legal-benchmark-v2)
are removed **item by item**, not by dropping whole domains: several 法規 subjects
(營建法規, 海巡法規, 郵政法規, 稅務法規) are examined inside otherwise non-legal
categories, so excluding the category would discard its non-legal questions too.
English items are detected from the **stem**, not by question number: the boundary
of the English section moves between years. Judging the options too would discard
the many Chinese questions that are answered in English terminology — 「下列何者可
以抑制 ribonucleotide reductase 的活性?」 with options like `dATP` is a Chinese
question about Taiwan-examined knowledge, and a zh-TW model is expected to answer
it.
Items that point at a figure, table or reading passage printed on the paper are
removed — they are unanswerable from the text alone, and keeping them would make
every model look worse for the same reason. So are the follow-up questions of a
題組, which open with 「承上題」 and refer to a scenario set up by the previous
question: the setup question is self-contained and stays, the follow-ups cannot
be answered by anyone once lifted out of the paper.
The last option on a paper has no following marker for the parser to stop at, so
table debris or the next question's text can run into it. Option texts are short
— the 99.9th percentile is 95 characters — so an option far outside that *and*
several times longer than its siblings is a parse failure, and the item is
dropped rather than shipped broken.
### Deduplication
The same paper is republished under several examination categories, so the same
item recurs verbatim. Items are fingerprinted on their stem plus their sorted
option set; **604** duplicate groups were collapsed,
of which **0** carried disagreeing answer keys and
were dropped entirely rather than guessed. `n_source_papers` records the
multiplicity — **604** of the kept items were published more than once.
**A benchmark built from this source without deduplication is inflated**, and its
accuracy is skewed toward whichever subset happens to be republished most.
## Known Properties
- **Answer-position distribution**: A=945, B=1,158, C=1,150, D=1,177.
Shuffle options when evaluating (`shuffle_options: true` is the Twinkle Eval default).
- **Contamination risk**: these are public past papers, widely discussed online and
very likely present in pretraining corpora. Absolute scores should be treated with
caution; the benchmark is most useful for **relative** comparison between models.
- **Answer extraction dominates low scores.** If a model scores near zero, check the
unparsed rate before believing the number — a model answering 「最終答案:C」 scores
very differently under `box` and `pattern` extraction. Match the extraction method
to the model.
- Item difficulty is set by the examination committee, not by us.
## Licensing
Questions and answer keys are official publications of the Ministry of Examination,
Republic of China (Taiwan), released as open data. The packaging, parsing,
deduplication and metadata in this repository are provided under Apache-2.0. Users
intending redistribution should confirm the current terms published by 考選部.
## Citation
```bibtex
@misc{opentwbench_tcm_basic,
title = {Traditional Chinese Medicine — Basic Theory Benchmark (Taiwan)},
author = {Huang, Liang-Hsun},
year = {2026},
url = {https://huggingface.co/datasets/OpenTWBench/tw-tcm-basic-bench}
}
```
|