--- tags: - setfit - sentence-transformers - text-classification - generated_from_setfit_trainer widget: - text: " (Coupon Image) [View|View] | Gültig bis 27.12.2025 () [TextView|View] |\ \ Persil Waschmittel () [TextView|View] | 16WLx1,04kg, verschiedene Sorten ()\ \ [TextView|View] | Coupon bereits aktiviert () [TextView|View] | (Coupon Image)\ \ [View|View] | Gültig bis 27.12.2025 () [TextView|View] | Freixenet () [TextView|View]\ \ | 6 x 0,7l, verschiedene Sorten () [TextView|View] | Coupon bereits aktiviert\ \ () [TextView|View] | APP Preis () [TextView|View] | (Coupon Image) [View|View]\ \ | Gültig bis 27.12.2025 () [TextView|View] | Whiskas Pouch () [TextView|View]\ \ | verschiedene Sorten, 12 x 85g () [TextView|View] | Coupon bereits aktiviert\ \ () [TextView|View] | APP Preis () [TextView|View]\n\n[SELECTED START]\n\n (Coupon\ \ Image) [View|View] | Gültig bis 27.12.2025 () [TextView|View] | Freixenet ()\ \ [TextView|View] | 6 x 0,7l, verschiedene Sorten () [TextView|View] | Coupon\ \ bereits aktiviert () [TextView|View] | APP Preis () [TextView|View] | (Coupon\ \ Image) [View|View] | Gültig bis 27.12.2025 () [TextView|View] | Whiskas Pouch\ \ () [TextView|View] | verschiedene Sorten, 12 x 85g () [TextView|View] | Coupon\ \ bereits aktiviert () [TextView|View] | APP Preis () [TextView|View] | (Coupon\ \ Image) [View|View] | Gültig bis 27.12.2025 () [TextView|View] | Ramazzotti ()\ \ [TextView|View] | 0,70l () [TextView|View] | Coupon bereits aktiviert () [TextView|View]\ \ | APP Preis () [TextView|View] | (Coupon Image) [View|View] | Gültig bis 27.12.2025\ \ () [TextView|View] | Schwartau Fruchtaufstriche () [TextView|View] | diverse\ \ Sorten () [TextView|View]\n[CONTEXT SEPARATOR]\n (Coupon Image) [View|View]\ \ | Gültig bis 27.12.2025 () [TextView|View] | Freixenet () [TextView|View] |\ \ 6 x 0,7l, verschiedene Sorten () [TextView|View] | Coupon bereits aktiviert\ \ () [TextView|View] | APP Preis () [TextView|View] | (Coupon Image) [View|View]\ \ | Gültig bis 27.12.2025 () [TextView|View] | Whiskas Pouch () [TextView|View]\ \ | verschiedene Sorten, 12 x 85g () [TextView|View] | Coupon bereits aktiviert\ \ () [TextView|View] | APP Preis () [TextView|View] | (Coupon Image) [View|View]\ \ | Gültig bis 27.12.2025 () [TextView|View] | Ramazzotti () [TextView|View] |\ \ 0,70l () [TextView|View] | Coupon bereits aktiviert () [TextView|View] | APP\ \ Preis () [TextView|View] | (Coupon Image) [View|View] | Gültig bis 27.12.2025\ \ () [TextView|View] | Schwartau Fruchtaufstriche () [TextView|View] | diverse\ \ Sorten () [TextView|View]" - text: 'Ja, sehr! () [TextView|SubActivity] [SELECTED START] Prospekt () [TextView|SubActivity] | 1 / 12 () [TextView|SubActivity] [CONTEXT SEPARATOR] Prospekt () [TextView|SubActivity] | 1 / 12 () [TextView|SubActivity]' - text: 'Dein Aktionscode () [TextView|View] | Was steckt hinter deinem Code? Jetzt eingeben und Vorteil entdecken () [TextView|View] | Code eingeben () [EditText|View] | Überprüfen () [TextView|View] | Die Teilnahmebedingungen unserer Aktionen findest du u.a. auf den Werbematerialien zur Aktion. Weitere Informationen entnimmst du bitte unseren Nutzungsbedingungen. () [TextView|View] | So funktionieren Aktionscodes () [TextView|View] | Du registrierst dich für ein Kundenkonto bei EDEKA. So kannst du unsere Coupons und Angebote nutzen. () [TextView|View] | Gib einen gültigen Aktionscode in das Eingabefeld ein. () [TextView|View] | Wähle einen Markt in dem du deinen Aktionscode einlösen willst. () [TextView|View] | Warum einen Markt auswählen? () [TextView|View] | Weil nicht alle Märkte an jeder Aktion teilnehmen. () [TextView|View] [SELECTED START] 24.08. - 18.10.2025 () [TextView|View] | Tierischer Sammelspaß mit schleich® und WWF! () [TextView|View] | Noch 5 Treuepunkte zum Prämien-Sonderpreis. () [TextView|View] | Pro 5 Euro Einkaufswert gibt es einen Treuepunkt. () [TextView|View] | 07.09. - 05.10.2025 () [TextView|View] | Deine Treue wird belohnt - einfach punkten und sparen! () [TextView|View] | Noch 15 Treuepunkte zum Prämien-Sonderpreis. () [TextView|View] | Für je 20€ Einkaufwert erhälst du einen Treuepunkt () [TextView|View] | (EDEKA Logo) [ImageView|View] | EDEKA Schöck () [TextView|View] | (Pfeil nach unten) [View|View] | MT () [TextView|View] | (Start) [View|View] | Start () [TextView|View] | (Sparen) [View|View] | Sparen () [TextView|View] | Kasse () [TextView|View] | (Prämien) [View|View] | Prämien () [TextView|View] | (Einkaufsliste) [View|View] | Einkaufsliste () [TextView|View] | (Kasse) [View|View] [CONTEXT SEPARATOR] 24.08. - 18.10.2025 () [TextView|View] | Tierischer Sammelspaß mit schleich® und WWF! () [TextView|View] | Noch 5 Treuepunkte zum Prämien-Sonderpreis. () [TextView|View] | Pro 5 Euro Einkaufswert gibt es einen Treuepunkt. () [TextView|View] | 07.09. - 05.10.2025 () [TextView|View] | Deine Treue wird belohnt - einfach punkten und sparen! () [TextView|View] | Noch 15 Treuepunkte zum Prämien-Sonderpreis. () [TextView|View] | Für je 20€ Einkaufwert erhälst du einen Treuepunkt () [TextView|View] | (EDEKA Logo) [ImageView|View] | EDEKA Schöck () [TextView|View] | (Pfeil nach unten) [View|View] | MT () [TextView|View] | (Start) [View|View] | Start () [TextView|View] | (Sparen) [View|View] | Sparen () [TextView|View] | Kasse () [TextView|View] | (Prämien) [View|View] | Prämien () [TextView|View] | (Einkaufsliste) [View|View] | Einkaufsliste () [TextView|View] | (Kasse) [View|View]' - text: 'Einstellungen () [TextView|MainActivity] | Weitere Funktionen () [TextView|MainActivity] | Marktsuche () [TextView|MainActivity] | Aktionscodes () [TextView|MainActivity] | Rückverfolgung () [TextView|MainActivity] | Hilfe & Feedback () [TextView|MainActivity] | Hilfe & FAQ () [TextView|MainActivity] | Kontakt () [TextView|MainActivity] | App bewerten () [TextView|MainActivity] | Weitere Informationen () [TextView|MainActivity] | Datenschutzhinweise () [TextView|MainActivity] | Nutzungsbedingungen () [TextView|MainActivity] | Impressum () [TextView|MainActivity] [SELECTED START] Einstellungen () [TextView|MainActivity] | Weitere Funktionen () [TextView|MainActivity] | Marktsuche () [TextView|MainActivity] | Aktionscodes () [TextView|MainActivity] | Rückverfolgung () [TextView|MainActivity] | Hilfe & Feedback () [TextView|MainActivity] | Hilfe & FAQ () [TextView|MainActivity] [CONTEXT SEPARATOR] Einstellungen () [TextView|MainActivity] | Weitere Funktionen () [TextView|MainActivity] | Marktsuche () [TextView|MainActivity] | Aktionscodes () [TextView|MainActivity] | Rückverfolgung () [TextView|MainActivity] | Hilfe & Feedback () [TextView|MainActivity] | Hilfe & FAQ () [TextView|MainActivity]' - text: "sortieren nach () [TextView|MainActivity] | (Drop-down-Menü) [View|MainActivity]\ \ | Kategorien () [TextView|MainActivity] | (dropdown arrow) [ImageView|MainActivity]\ \ | Obst & Gemüse () [TextView|MainActivity] | (Am Samstag: Gut & Günstig Mini\ \ Pflaumentomaten) [View|MainActivity] | Am Samstag: Gut & Günstig Mini Pflaumentomaten\ \ () [TextView|MainActivity] | 1 () [EditText|MainActivity] | Menge () [TextView|MainActivity]\ \ | (offer valid for current store) [View|MainActivity] | Grundnahrung () [TextView|MainActivity]\ \ | (La Molisana Linguine 500 g) [View|MainActivity] | La Molisana Linguine 500\ \ g () [TextView|MainActivity] | La Molisana () [TextView|MainActivity] | 1 ()\ \ [EditText|MainActivity] | Menge () [TextView|MainActivity] | (EDEKA Bio Zucker\ \ 1000 g) [View|MainActivity] | EDEKA Bio Zucker 1000 g () [TextView|MainActivity]\ \ | EDEKA Bio () [TextView|MainActivity] | 1 () [EditText|MainActivity] | Menge\ \ () [TextView|MainActivity] | (Kaba Das Original Bananen Geschmack 400 g) [View|MainActivity]\ \ | Kaba Das Original Bananen Geschmack 400 g () [TextView|MainActivity] | (navigate\ \ to switcher) [View|MainActivity] | Meine Einkaufsliste () [TextView|MainActivity]\ \ | (edit) [View|MainActivity] | (share) [View|MainActivity] | (use scanner)\ \ [View|MainActivity] | Artikel hinzufügen () [TextView|MainActivity] | Meine\ \ Einkaufsliste () [TextView|MainActivity] | (Start) [View|MainActivity] | Start\ \ () [TextView|MainActivity] | (Sparen) [View|MainActivity] | Sparen () [TextView|MainActivity]\ \ | Kasse () [TextView|MainActivity] | (Prämien) [View|MainActivity] | Prämien\ \ () [TextView|MainActivity] | (Einkaufsliste) [View|MainActivity] | Einkaufsliste\ \ () [TextView|MainActivity] | (Kasse) [View|MainActivity]\n\n[SELECTED START]\n\ \n (Tabelle schließen) [View|c1]\n[CONTEXT SEPARATOR]\n (Tabelle schließen) [View|c1]" metrics: - accuracy pipeline_tag: text-classification library_name: setfit inference: true datasets: - tmp-org/edeka-dataset-ctx-1 base_model: Alibaba-NLP/gte-multilingual-base --- # SetFit with Alibaba-NLP/gte-multilingual-base This is a [SetFit](https://github.com/huggingface/setfit) model trained on the [tmp-org/edeka-dataset-ctx-1](https://huggingface.co/datasets/tmp-org/edeka-dataset-ctx-1) dataset that can be used for Text Classification. This SetFit model uses [Alibaba-NLP/gte-multilingual-base](https://huggingface.co/Alibaba-NLP/gte-multilingual-base) as the Sentence Transformer embedding model. A [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance is used for classification. The model has been trained using an efficient few-shot learning technique that involves: 1. Fine-tuning a [Sentence Transformer](https://www.sbert.net) with contrastive learning. 2. Training a classification head with features from the fine-tuned Sentence Transformer. ## Model Details ### Model Description - **Model Type:** SetFit - **Sentence Transformer body:** [Alibaba-NLP/gte-multilingual-base](https://huggingface.co/Alibaba-NLP/gte-multilingual-base) - **Classification head:** a [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) instance - **Maximum Sequence Length:** 8192 tokens - **Number of Classes:** 24 classes - **Training Dataset:** [tmp-org/edeka-dataset-ctx-1](https://huggingface.co/datasets/tmp-org/edeka-dataset-ctx-1) ### Model Sources - **Repository:** [SetFit on GitHub](https://github.com/huggingface/setfit) - **Paper:** [Efficient Few-Shot Learning Without Prompts](https://arxiv.org/abs/2209.11055) - **Blogpost:** [SetFit: Efficient Few-Shot Learning Without Prompts](https://huggingface.co/blog/setfit) ### Model Labels | Label | Examples | |:----------------------------|:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | Other_Prospekt | | | Start_Start | | | Other_Code einlösen | | | Prämien_Prämien | | | Other_Loading | | | Other_Treueaktionen | | | Other_Neuigkeiten | | | Other_Produktherkunft | | | Other_Marktsuche | | | Other_Menu | | | Kasse_Mobil bezahlen | | | Other_Kassenbons | | | Sparen_Angebote | | | Sparen_Coupons | | | Other_Coupon details | | | Kasse_Kasse | | | Kasse_Aktivierte Coupons | | | Einkaufsliste_Einkaufsliste | | | Kasse_Unknown | | | Other_Unknown | | | Start_Loading | | | Sparen_Loading | | | Other_Other | | | Kasse_Loading | | ## Uses ### Direct Use for Inference First install the SetFit library: ```bash pip install setfit ``` Then you can load this model and run inference. ```python from setfit import SetFitModel # Download from the 🤗 Hub model = SetFitModel.from_pretrained("tmp-org/tmp_cv_model_2025_09_15_0") # Run inference preds = model("Ja, sehr! () [TextView|SubActivity] [SELECTED START] Prospekt () [TextView|SubActivity] | 1 / 12 () [TextView|SubActivity] [CONTEXT SEPARATOR] Prospekt () [TextView|SubActivity] | 1 / 12 () [TextView|SubActivity]") ``` ## Training Details ### Training Set Metrics | Training set | Min | Median | Max | |:-------------|:----|:---------|:----| | Word count | 9 | 266.6559 | 711 | | Label | Training Sample Count | |:----------------------------|:----------------------| | Einkaufsliste_Einkaufsliste | 27 | | Kasse_Aktivierte Coupons | 36 | | Kasse_Kasse | 18 | | Kasse_Loading | 2 | | Kasse_Mobil bezahlen | 6 | | Kasse_Unknown | 1 | | Other_Code einlösen | 2 | | Other_Coupon details | 28 | | Other_Kassenbons | 9 | | Other_Loading | 2 | | Other_Marktsuche | 6 | | Other_Menu | 36 | | Other_Neuigkeiten | 4 | | Other_Other | 1 | | Other_Produktherkunft | 7 | | Other_Prospekt | 29 | | Other_Treueaktionen | 32 | | Other_Unknown | 8 | | Prämien_Prämien | 34 | | Sparen_Angebote | 36 | | Sparen_Coupons | 36 | | Sparen_Loading | 3 | | Start_Loading | 5 | | Start_Start | 36 | ### Training Hyperparameters - batch_size: (4, 4) - num_epochs: (1, 1) - max_steps: -1 - sampling_strategy: undersampling - body_learning_rate: (2e-05, 1e-05) - head_learning_rate: 0.01 - loss: CosineSimilarityLoss - distance_metric: cosine_distance - margin: 0.25 - end_to_end: False - use_amp: False - warmup_proportion: 0.1 - l2_weight: 0.01 - seed: 4242 - eval_max_steps: -1 - load_best_model_at_end: False ### Training Results | Epoch | Step | Training Loss | Validation Loss | |:------:|:----:|:-------------:|:---------------:| | 0.0003 | 1 | 0.1534 | - | | 0.0166 | 50 | 0.2315 | - | | 0.0331 | 100 | 0.1717 | - | | 0.0497 | 150 | 0.1471 | - | | 0.0663 | 200 | 0.1256 | - | | 0.0828 | 250 | 0.1337 | - | | 0.0994 | 300 | 0.0823 | - | | 0.1160 | 350 | 0.1027 | - | | 0.1325 | 400 | 0.0838 | - | | 0.1491 | 450 | 0.0779 | - | | 0.1657 | 500 | 0.054 | - | | 0.1822 | 550 | 0.0678 | - | | 0.1988 | 600 | 0.0587 | - | | 0.2154 | 650 | 0.0485 | - | | 0.2319 | 700 | 0.0579 | - | | 0.2485 | 750 | 0.0441 | - | | 0.2651 | 800 | 0.0414 | - | | 0.2816 | 850 | 0.0597 | - | | 0.2982 | 900 | 0.0555 | - | | 0.3148 | 950 | 0.0441 | - | | 0.3313 | 1000 | 0.0449 | - | | 0.3479 | 1050 | 0.0351 | - | | 0.3645 | 1100 | 0.0336 | - | | 0.3810 | 1150 | 0.0463 | - | | 0.3976 | 1200 | 0.0455 | - | | 0.4142 | 1250 | 0.0433 | - | | 0.4307 | 1300 | 0.0324 | - | | 0.4473 | 1350 | 0.0302 | - | | 0.4639 | 1400 | 0.0177 | - | | 0.4805 | 1450 | 0.0322 | - | | 0.4970 | 1500 | 0.0191 | - | | 0.5136 | 1550 | 0.03 | - | | 0.5302 | 1600 | 0.0268 | - | | 0.5467 | 1650 | 0.0572 | - | | 0.5633 | 1700 | 0.0293 | - | | 0.5799 | 1750 | 0.015 | - | | 0.5964 | 1800 | 0.0351 | - | | 0.6130 | 1850 | 0.0171 | - | | 0.6296 | 1900 | 0.006 | - | | 0.6461 | 1950 | 0.0349 | - | | 0.6627 | 2000 | 0.0572 | - | | 0.6793 | 2050 | 0.0263 | - | | 0.6958 | 2100 | 0.026 | - | | 0.7124 | 2150 | 0.0357 | - | | 0.7290 | 2200 | 0.022 | - | | 0.7455 | 2250 | 0.043 | - | | 0.7621 | 2300 | 0.0143 | - | | 0.7787 | 2350 | 0.0238 | - | | 0.7952 | 2400 | 0.0158 | - | | 0.8118 | 2450 | 0.0095 | - | | 0.8284 | 2500 | 0.0371 | - | | 0.8449 | 2550 | 0.0286 | - | | 0.8615 | 2600 | 0.0153 | - | | 0.8781 | 2650 | 0.0208 | - | | 0.8946 | 2700 | 0.0238 | - | | 0.9112 | 2750 | 0.0263 | - | | 0.9278 | 2800 | 0.0193 | - | | 0.9443 | 2850 | 0.0145 | - | | 0.9609 | 2900 | 0.0136 | - | | 0.9775 | 2950 | 0.0195 | - | | 0.9940 | 3000 | 0.0162 | - | ### Framework Versions - Python: 3.12.6 - SetFit: 1.1.2 - Sentence Transformers: 5.2.2 - Transformers: 4.57.1 - PyTorch: 2.10.0+cu128 - Datasets: 3.6.0 - Tokenizers: 0.22.2 ## Citation ### BibTeX ```bibtex @article{https://doi.org/10.48550/arxiv.2209.11055, doi = {10.48550/ARXIV.2209.11055}, url = {https://arxiv.org/abs/2209.11055}, author = {Tunstall, Lewis and Reimers, Nils and Jo, Unso Eun Seo and Bates, Luke and Korat, Daniel and Wasserblat, Moshe and Pereg, Oren}, keywords = {Computation and Language (cs.CL), FOS: Computer and information sciences, FOS: Computer and information sciences}, title = {Efficient Few-Shot Learning Without Prompts}, publisher = {arXiv}, year = {2022}, copyright = {Creative Commons Attribution 4.0 International} } ```