CoolFace
Modelpublic

PulseWave/PAYMENT-TERMS

sourceHugging Faceupdated 3y agoView on Hugging Face
0likes6downloads
README.md130 linesDownload Raw Back to root
1---2library_name: setfit3tags:4- setfit5- sentence-transformers6- text-classification7- generated_from_setfit_trainer8metrics:9- accuracy10widget: []11pipeline_tag: text-classification12inference: true13---14 15# SetFit16 17This is a [SetFit](https://github.com/huggingface/setfit) model that can be used for Text Classification. A [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance is used for classification.18 19The model has been trained using an efficient few-shot learning technique that involves:20 211. Fine-tuning a [Sentence Transformer](https://www.sbert.net) with contrastive learning.222. Training a classification head with features from the fine-tuned Sentence Transformer.23 24## Model Details25 26### Model Description27- **Model Type:** SetFit28<!-- - **Sentence Transformer:** [Unknown](https://huggingface.co/unknown) -->29- **Classification head:** a [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance30- **Maximum Sequence Length:** 512 tokens31- **Number of Classes:** 2 classes32<!-- - **Training Dataset:** [Unknown](https://huggingface.co/datasets/unknown) -->33<!-- - **Language:** Unknown -->34<!-- - **License:** Unknown -->35 36### Model Sources37 38- **Repository:** [SetFit on GitHub](https://github.com/huggingface/setfit)39- **Paper:** [Efficient Few-Shot Learning Without Prompts](https://arxiv.org/abs/2209.11055)40- **Blogpost:** [SetFit: Efficient Few-Shot Learning Without Prompts](https://huggingface.co/blog/setfit)41 42## Uses43 44### Direct Use for Inference45 46First install the SetFit library:47 48```bash49pip install setfit50```51 52Then you can load this model and run inference.53 54```python55from setfit import SetFitModel56 57# Download from the 🤗 Hub58model = SetFitModel.from_pretrained("setfit_model_id")59# Run inference60preds = model("I loved the spiderman movie!")61```62 63<!--64### Downstream Use65 66*List how someone could finetune this model on their own dataset.*67-->68 69<!--70### Out-of-Scope Use71 72*List how the model may foreseeably be misused and address what users ought not to do with the model.*73-->74 75<!--76## Bias, Risks and Limitations77 78*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*79-->80 81<!--82### Recommendations83 84*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*85-->86 87## Training Details88 89### Framework Versions90- Python: 3.11.791- SetFit: 1.0.392- Sentence Transformers: 2.3.193- Transformers: 4.37.294- PyTorch: 2.2.095- Datasets: 2.16.196- Tokenizers: 0.15.197 98## Citation99 100### BibTeX101```bibtex102@article{https://doi.org/10.48550/arxiv.2209.11055,103    doi = {10.48550/ARXIV.2209.11055},104    url = {https://arxiv.org/abs/2209.11055},105    author = {Tunstall, Lewis and Reimers, Nils and Jo, Unso Eun Seo and Bates, Luke and Korat, Daniel and Wasserblat, Moshe and Pereg, Oren},106    keywords = {Computation and Language (cs.CL), FOS: Computer and information sciences, FOS: Computer and information sciences},107    title = {Efficient Few-Shot Learning Without Prompts},108    publisher = {arXiv},109    year = {2022},110    copyright = {Creative Commons Attribution 4.0 International}111}112```113 114<!--115## Glossary116 117*Clearly define terms in order to be accessible across audiences.*118-->119 120<!--121## Model Card Authors122 123*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*124-->125 126<!--127## Model Card Contact128 129*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*130-->