|
--- |
|
license: cc-by-4.0 |
|
dataset_info: |
|
features: |
|
- name: english_reference |
|
dtype: string |
|
- name: hebrew_reference |
|
dtype: string |
|
- name: text |
|
dtype: string |
|
- name: transliteration |
|
dtype: string |
|
- name: translation |
|
dtype: string |
|
- name: dStrongs |
|
dtype: string |
|
- name: manuscript_source |
|
dtype: string |
|
splits: |
|
- name: train |
|
num_bytes: 30435977 |
|
num_examples: 305638 |
|
download_size: 13210659 |
|
dataset_size: 30435977 |
|
configs: |
|
- config_name: default |
|
data_files: |
|
- split: train |
|
path: data/train-* |
|
language: |
|
- he |
|
- en |
|
tags: |
|
- Bible |
|
pretty_name: Original Language Bible Corpus -- Ancient Hebrew |
|
--- |
|
## Citation Information |
|
If you use this data, please cite: |
|
|
|
**BibTeX:** |
|
``` |
|
@dataset{original_language_bibles, |
|
author = {Hope McGovern}, |
|
title = {{{Original Language Bible Corpus}}: {{Translator's Amalgamated Hebrew Old Testament}} and {{Translator's Amalgamated Greek New Testament}} with Word-Level Translations}, |
|
year = {2024}, |
|
publisher = {Hugging Face Hub}, |
|
note = {TAHOT DOI: \href{https://huggingface.co/datasets/hmcgovern/original-language-bibles-hebrew}{10.57967/hf/4174}, TAGNT DOI: \href{https://huggingface.co/datasets/hmcgovern/original-language-bibles-greek}{10.57967/hf/4184}} |
|
} |
|
``` |
|
|
|
## Aggregate to Line-Level |
|
To aggregate this dataset to the line (verse) level, you can use a `.map()` function like this: |
|
``` |
|
def aggregate_to_line(examples, priority='english'): |
|
aggregated = {} |
|
for ref, word, gloss in zip(examples[f"{priority}_reference"], examples["text"], examples["translation"]): |
|
verse_key = ".".join(ref.split(".")[:-1]) # Extract the verse key (e.g., Gen.1.1) |
|
if verse_key not in aggregated: |
|
aggregated[verse_key] = {"texts": [], "translations": []} |
|
aggregated[verse_key]["texts"].append(word) |
|
aggregated[verse_key]["translations"].append(gloss) |
|
|
|
# Convert the aggregated results into line-level entries |
|
return { |
|
"verse": list(aggregated.keys()), |
|
"text": [" | ".join(aggregated[verse]["texts"]) for verse in aggregated], |
|
"translation": [" | ".join(aggregated[verse]["translations"]) for verse in aggregated], |
|
} |
|
ds = ds.map(aggregate_to_line, batched=True, remove_columns=ds['train'].column_names, fn_kwargs={"priority": "hebrew"}) |
|
``` |
|
Where `priority` denotes whether to use English or Hebrew verse delineations. `english` priority -> 23_547 verses, `hebrew` priority -> 23_499 verses |