Roberta Large Tweetner7 All
基於roberta-large在tner/tweetner7數據集上微調的命名實體識別模型,專門用於推特文本中的實體識別
下載量 170.06k
發布時間 : 7/2/2022
模型概述
該模型是針對推特文本優化的命名實體識別模型,能夠識別推文中的公司、創意作品、事件、團體、地點、人物和產品等實體類別
模型特點
推特文本優化
專門針對推特文本進行優化,處理了賬戶名和URL的特殊格式
多類別實體識別
能夠識別7種不同的實體類別,包括人物、地點、產品等
高精度人物識別
在人物實體識別上表現最佳,F1分數達到0.829
模型能力
推特文本實體識別
多類別實體分類
社交媒體文本處理
使用案例
社交媒體分析
推特用戶分析
識別推文中提及的人物、組織和產品
可幫助分析用戶興趣和社交網絡
品牌監控
追蹤社交媒體上品牌和產品的提及情況
可用於市場分析和競爭情報
🚀 tner/roberta-large-tweetner7-all
tner/roberta-large-tweetner7-all
是一個基於 roberta-large
模型在 tner/tweetner7
數據集上微調得到的模型,用於命名實體識別任務。它能有效處理特定格式的推文數據,在相關評估指標上有不錯的表現。
✨ 主要特性
- 基於
roberta-large
模型進行微調,在tner/tweetner7
數據集上有良好表現。 - 支持使用
tner
庫調用,方便快捷。 - 提供了詳細的評估指標和訓練超參數。
📦 安裝指南
此模型可通過 tner 庫 使用,可通過以下命令安裝該庫:
pip install tner
💻 使用示例
基礎用法
import re
from urlextract import URLExtract
from tner import TransformersNER
extractor = URLExtract()
def format_tweet(tweet):
# mask web urls
urls = extractor.find_urls(tweet)
for url in urls:
tweet = tweet.replace(url, "{{URL}}")
# format twitter account
tweet = re.sub(r"\b(\s*)(@[\S]+)\b", r'\1{\2@}', tweet)
return tweet
text = "Get the all-analog Classic Vinyl Edition of `Takin' Off` Album from @herbiehancock via @bluenoterecords link below: http://bluenote.lnk.to/AlbumOfTheWeek"
text_format = format_tweet(text)
model = TransformersNER("tner/roberta-large-tweetner7-all")
model.predict([text_format])
高級用法
暫未提供高級用法示例。
📚 詳細文檔
數據集和指標
屬性 | 詳情 |
---|---|
數據集 | tner/tweetner7 |
評估指標 | F1、Precision、Recall、Macro F1、Macro Precision、Macro Recall、Entity Span F1、Entity Span Precision、Entity Span Recall |
模型結果
該模型在 2021 年測試集上的表現如下:
- F1 (micro): 0.6574551220340903
- Precision (micro): 0.644212629008989
- Recall (micro): 0.6712534690101758
- F1 (macro): 0.6124665667529737
- Precision (macro): 0.6005167968535563
- Recall (macro): 0.625251837701222
各實體的 F1 分數如下:
- corporation: 0.5392156862745098
- creative_work: 0.4760582928521859
- event: 0.4673321234119782
- group: 0.6139798488664987
- location: 0.6707399864222675
- person: 0.8293212669683258
- product: 0.6906187624750498
F1 分數的置信區間(通過自助法獲得)如下:
- F1 (micro):
- 90%: [0.6484148010152769, 0.6672289519134409]
- 95%: [0.6470100684797441, 0.6689850350992637]
- F1 (macro):
- 90%: [0.6484148010152769, 0.6672289519134409]
- 95%: [0.6470100684797441, 0.6689850350992637]
完整評估結果可參考 NER 評估文件 和 實體跨度評估文件。
訓練超參數
以下是訓練過程中使用的超參數:
- 數據集: ['tner/tweetner7']
- 數據集分割: train_all
- 數據集名稱: None
- 本地數據集: None
- 模型: roberta-large
- CRF: True
- 最大長度: 128
- 訓練輪數: 30
- 批次大小: 32
- 學習率: 1e-05
- 隨機種子: 0
- 梯度累積步數: 1
- 權重衰減: 1e-07
- 學習率熱身步數比例: 0.15
- 最大梯度範數: 1
完整配置可參考 微調參數文件。
🔧 技術細節
該模型基於 roberta-large
進行微調,使用了 CRF 層來提升性能。在訓練過程中,使用了特定的超參數進行優化,以在 tner/tweetner7
數據集上達到較好的效果。
📄 許可證
文檔未提及相關許可證信息。
📖 引用
如果使用該模型,請引用 T-NER 論文和 TweetNER7 論文:
- T-NER
@inproceedings{ushio-camacho-collados-2021-ner,
title = "{T}-{NER}: An All-Round Python Library for Transformer-based Named Entity Recognition",
author = "Ushio, Asahi and
Camacho-Collados, Jose",
booktitle = "Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: System Demonstrations",
month = apr,
year = "2021",
address = "Online",
publisher = "Association for Computational Linguistics",
url = "https://aclanthology.org/2021.eacl-demos.7",
doi = "10.18653/v1/2021.eacl-demos.7",
pages = "53--62",
abstract = "Language model (LM) pretraining has led to consistent improvements in many NLP downstream tasks, including named entity recognition (NER). In this paper, we present T-NER (Transformer-based Named Entity Recognition), a Python library for NER LM finetuning. In addition to its practical utility, T-NER facilitates the study and investigation of the cross-domain and cross-lingual generalization ability of LMs finetuned on NER. Our library also provides a web app where users can get model predictions interactively for arbitrary text, which facilitates qualitative model evaluation for non-expert programmers. We show the potential of the library by compiling nine public NER datasets into a unified format and evaluating the cross-domain and cross- lingual performance across the datasets. The results from our initial experiments show that in-domain performance is generally competitive across datasets. However, cross-domain generalization is challenging even with a large pretrained LM, which has nevertheless capacity to learn domain-specific features if fine- tuned on a combined dataset. To facilitate future research, we also release all our LM checkpoints via the Hugging Face model hub.",
}
- TweetNER7
@inproceedings{ushio-etal-2022-tweet,
title = "{N}amed {E}ntity {R}ecognition in {T}witter: {A} {D}ataset and {A}nalysis on {S}hort-{T}erm {T}emporal {S}hifts",
author = "Ushio, Asahi and
Neves, Leonardo and
Silva, Vitor and
Barbieri, Francesco. and
Camacho-Collados, Jose",
booktitle = "The 2nd Conference of the Asia-Pacific Chapter of the Association for Computational Linguistics and the 12th International Joint Conference on Natural Language Processing",
month = nov,
year = "2022",
address = "Online",
publisher = "Association for Computational Linguistics",
}
Indonesian Roberta Base Posp Tagger
MIT
這是一個基於印尼語RoBERTa模型微調的詞性標註模型,在indonlu數據集上訓練,用於印尼語文本的詞性標註任務。
序列標註
Transformers 其他

I
w11wo
2.2M
7
Bert Base NER
MIT
基於BERT微調的命名實體識別模型,可識別四類實體:地點(LOC)、組織機構(ORG)、人名(PER)和雜項(MISC)
序列標註 英語
B
dslim
1.8M
592
Deid Roberta I2b2
MIT
該模型是基於RoBERTa微調的序列標註模型,用於識別和移除醫療記錄中的受保護健康信息(PHI/PII)。
序列標註
Transformers 支持多種語言

D
obi
1.1M
33
Ner English Fast
Flair自帶的英文快速4類命名實體識別模型,基於Flair嵌入和LSTM-CRF架構,在CoNLL-03數據集上達到92.92的F1分數。
序列標註
PyTorch 英語
N
flair
978.01k
24
French Camembert Postag Model
基於Camembert-base的法語詞性標註模型,使用free-french-treebank數據集訓練
序列標註
Transformers 法語

F
gilf
950.03k
9
Xlm Roberta Large Ner Spanish
基於XLM-Roberta-large架構微調的西班牙語命名實體識別模型,在CoNLL-2002數據集上表現優異。
序列標註
Transformers 西班牙語

X
MMG
767.35k
29
Nusabert Ner V1.3
MIT
基於NusaBert-v1.3在印尼語NER任務上微調的命名實體識別模型
序列標註
Transformers 其他

N
cahya
759.09k
3
Ner English Large
Flair框架內置的英文4類大型NER模型,基於文檔級XLM-R嵌入和FLERT技術,在CoNLL-03數據集上F1分數達94.36。
序列標註
PyTorch 英語
N
flair
749.04k
44
Punctuate All
MIT
基於xlm-roberta-base微調的多語言標點符號預測模型,支持12種歐洲語言的標點符號自動補全
序列標註
Transformers

P
kredor
728.70k
20
Xlm Roberta Ner Japanese
MIT
基於xlm-roberta-base微調的日語命名實體識別模型
序列標註
Transformers 支持多種語言

X
tsmatz
630.71k
25
精選推薦AI模型
Llama 3 Typhoon V1.5x 8b Instruct
專為泰語設計的80億參數指令模型,性能媲美GPT-3.5-turbo,優化了應用場景、檢索增強生成、受限生成和推理任務
大型語言模型
Transformers 支持多種語言

L
scb10x
3,269
16
Cadet Tiny
Openrail
Cadet-Tiny是一個基於SODA數據集訓練的超小型對話模型,專為邊緣設備推理設計,體積僅為Cosmo-3B模型的2%左右。
對話系統
Transformers 英語

C
ToddGoldfarb
2,691
6
Roberta Base Chinese Extractive Qa
基於RoBERTa架構的中文抽取式問答模型,適用於從給定文本中提取答案的任務。
問答系統 中文
R
uer
2,694
98