Edit model card

hebert-finetuned-hebrew-squad

This model fine-tunes avichr/heBERT model on SQuAD dataset auto-translated to Hebrew.

Intended uses & limitations

Hebrew SQuAD

Training and evaluation data

Dataset Split # samples
Hebrew_Squad_v1 train 52,405
Hebrew_Squad_v1 validation 7,455

Training procedure

Training hyperparameters

The following hyperparameters were used during training:

  • learning_rate: 2e-05
  • train_batch_size: 8
  • eval_batch_size: 8
  • seed: 42
  • optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
  • lr_scheduler_type: linear
  • num_epochs: 15

It took about 9.5 hours to finish training.

Framework versions

  • Transformers 4.17.0
  • Pytorch 1.10.0+cu111
  • Datasets 1.18.4
  • Tokenizers 0.11.6

Results

Model size: 415M

Metric # Value
Exact Match 42.6
F1 55.9

Example Usage

from transformers import pipeline

model_checkpoint = "tdklab/hebert-finetuned-hebrew-squad"
qa_pipeline = pipeline(
    "question-answering",
    model=model_checkpoint, 
    )

predictions = qa_pipeline({
    'context': "ירושלים היא עיר הבירה של מדינת ישראל , והעיר הגדולה ביותר בישראל בגודל האוכלוסייה. נכון לשנת 2021, מתגוררים בה כ-957 אלף תושבים. בירושלים שוכנים מוסדות הממשל של ישראל: הכנסת, בית המשפט העליון, משכן הנשיא, בית ראש הממשלה ורוב משרדי הממשלה. ירושלים שוכנת בהרי יהודה, על קו פרשת המים הארצי של ארץ ישראל, בין הים התיכון וים המלח, ברום של 570 עד 857 מטרים מעל פני הים.",
    'question': "מהי עיר הבירה של מדינת ישראל?"
})

print(predictions)
# output:
# {'score': 0.9999890327453613, 'start': 0, 'end': 7, 'answer': 'ירושלים'}

About Us

Created by Matan Ben-chorin, May Flaster, Guided by Dr. Oren Mishali. This is our final project as part of computer engineering B.Sc studies in the Faculty of Electrical Engineering combined with Computer Science at Technion, Israel Institute of Technology. For more cooperation, please contact email: Matan Ben-chorin: matan.bh1@gmail.com May Flaster: mayflaster96@gmail.com

Downloads last month
400

Dataset used to train tdklab/hebert-finetuned-hebrew-squad

Space using tdklab/hebert-finetuned-hebrew-squad 1