jeopardy / README.md
soldni's picture
instructions, more
aebec90
|
raw
history blame
2.93 kB
---
license: other
license_name: j-archive-tos
license_link: https://j-archive.com/help.php#terms
dataset_info:
- config_name: all_questions
features:
- name: category
dtype: string
- name: air_date
dtype: string
- name: question
dtype: string
- name: value
dtype: string
- name: answer
dtype: string
- name: round
dtype: string
- name: show_number
dtype: string
- name: context
dtype: string
- name: ee-question
dtype: string
- name: ee-continuation
dtype: string
- name: ee-category
dtype: string
- name: continuation
dtype: string
- name: id
dtype: string
- name: og-category
dtype: string
- name: mosaicml_gauntlet
dtype: bool
splits:
- name: train
num_bytes: 110464105
num_examples: 216930
download_size: 67801636
dataset_size: 110464105
- config_name: mosaicml_gauntlet
features:
- name: category
dtype: string
- name: air_date
dtype: string
- name: question
dtype: string
- name: value
dtype: string
- name: answer
dtype: string
- name: round
dtype: string
- name: show_number
dtype: string
- name: context
dtype: string
- name: ee-question
dtype: string
- name: ee-continuation
dtype: string
- name: ee-category
dtype: string
- name: continuation
dtype: string
- name: id
dtype: string
- name: og-category
dtype: string
- name: mosaicml_gauntlet
dtype: bool
splits:
- name: train
num_bytes: 1083538
num_examples: 2116
download_size: 661802
dataset_size: 1083538
configs:
- config_name: all_questions
data_files:
- split: train
path: data/all_questions/train-*
- config_name: mosaicml_gauntlet
data_files:
- split: train
path: data/mosaicml_gauntlet/train-*
---
# Jeopardy questions from Mosaic Gauntlet
Sourced from https://github.com/mosaicml/llm-foundry/blob/main/scripts/eval/local_data/world_knowledge/jeopardy_all.jsonl
Description: Jeopardy consists of 2,117 Jeopardy questions separated into 5 categories:
Literature, American History, World History, Word Origins, and Science. The model is expected
to give the exact correct response to the question. It was custom curated by MosaicML from a
larger Jeopardy set available on [Huggingface](https://huggingface.co/datasets/jeopardy).
## How to use
```python
from datasets import load_dataset
dataset = load_dataset("soldni/jeopardy", "mosaicml_gauntlet")
model = ...
tokenizer = ...
# Given context, try to predict the continuation
for row in dataset:
input_ids = tokenizer(row['context'], return_tensors='pt').to(model.device)
outputs = model.generate(input_ids, max_new_tokens=100)
decoded = tokenizer.decode(outputs[0], skip_special_tokens=True)
correct = row['continuation'] in decoded
print("Gold:", row['continuation'])
print("Pred:", decoded)
print("Correct?", correct)
print("----")
```