Add Custom model and pipeline to make usage easier.
#1
by
tcapelle
- opened
This PR adds a custom model class: MultiHeadDebertaForSequenceClassificationModel
.
We also added a pipeline config, so now you can use this model using
pipe = pipeline("multi-head-text-classification", model="./celadon", trust_remote_code=True)
result = pipe("Woman are dumb and should stay at home.")
# [{'Race/Origin': 0, 'Gender/Sex': 3, 'Religion': 0, 'Ability': 0, 'Violence': 0}]
No more custom loading!
tcapelle
changed pull request title from
Upload CustomTextClassificationPipeline
to Add Custom model and pipeline to make usage easier.
tcapelle
changed pull request status to
closed