🚀 Indo-roberta-indonli
Indo-roberta-indonli 是一個基於 Indo-roberta 模型的自然語言推理分類器。它在 IndoNLI 數據集上進行訓練。所使用的模型為 Indo-roberta,並通過遷移學習轉換為自然推理分類器模型。該模型使用 GitHub 倉庫中提供的驗證集、測試層數據集和專家測試數據集進行測試,結果如下所示。
✨ 主要特性
- 基於強大的 Indo-roberta 模型,在自然語言推理任務上表現出色。
- 在 IndoNLI 數據集上進行訓練,具有良好的泛化能力。
📦 安裝指南
文檔未提及安裝步驟,此處跳過。
💻 使用示例
作為自然語言推理分類器
from transformers import pipeline
pretrained_name = "StevenLimcorn/indonesian-roberta-indonli"
nlp = pipeline(
"zero-shot-classification",
model=pretrained_name,
tokenizer=pretrained_name
)
nlp("Amir Sjarifoeddin Harahap lahir di Kota Medan, Sumatera Utara, 27 April 1907. Ia meninggal di Surakarta, Jawa Tengah, pada 19 Desember 1948 dalam usia 41 tahun. </s></s> Amir Sjarifoeddin Harahap masih hidup.")
📚 詳細文檔
結果
數據集 |
準確率 |
F1 值 |
精確率 |
召回率 |
測試層數據集 |
0.74329 |
0.74075 |
0.74283 |
0.74133 |
專家測試數據集 |
0.6115 |
0.60543 |
0.63924 |
0.61742 |
模型
該模型訓練了 5 個輪次,批次大小為 16,學習率為 2e - 5,權重衰減為 0.01。在不同輪次達到的指標如下所示。
輪次 |
訓練損失 |
驗證損失 |
準確率 |
F1 值 |
精確率 |
召回率 |
1 |
0.942500 |
0.658559 |
0.737369 |
0.735552 |
0.735488 |
0.736679 |
2 |
0.649200 |
0.645290 |
0.761493 |
0.759593 |
0.762784 |
0.759642 |
3 |
0.437100 |
0.667163 |
0.766045 |
0.763979 |
0.765740 |
0.763792 |
4 |
0.282000 |
0.786683 |
0.764679 |
0.761802 |
0.762011 |
0.761684 |
5 |
0.193500 |
0.925717 |
0.765134 |
0.763127 |
0.763560 |
0.763489 |
🔧 技術細節
文檔未提供足夠詳細的技術實現細節,此處跳過。
📄 許可證
本項目採用 MIT 許可證。
⚠️ 重要提示
需要考慮預訓練的 RoBERTa 模型和 INDONLI
數據集可能存在的偏差,這些偏差可能會影響該模型的結果。
👨💻 作者
Indonesian RoBERTa Base IndoNLI 由 Steven Limcorn 進行訓練和評估。所有的計算和開發工作均在 Google Colaboratory 上使用其免費 GPU 完成。
📖 參考資料
我們使用的數據集來自 IndoNLI。
@inproceedings{indonli,
title = "IndoNLI: A Natural Language Inference Dataset for Indonesian",
author = "Mahendra, Rahmad and Aji, Alham Fikri and Louvan, Samuel and Rahman, Fahrurrozi and Vania, Clara",
booktitle = "Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing",
month = nov,
year = "2021",
publisher = "Association for Computational Linguistics",
}