metadata
tags:
- setfit
- sentence-transformers
- text-classification
- generated_from_setfit_trainer
widget:
- text: >-
The monitoring and evaluation framework will track progress to deliver
nutrition results, valuable lessons will be learnt, the cost effectiveness
of prioritised interventions will be established, targets will be realised
and the impact of nutrition interventions will be understood. Successful
implementation of the Strategic Plan will therefore be dependent on the
quality of data collected and reported in a timely manner.
- text: >-
ncrease the production of vital local foods Improve the trade balance for
selected commodities where import substitution is economically viable
- text: >-
nsure effective communication of agricultural related priorities to
international partners through formal and non-formal donor coordination
meetings. Strengthen capacity of the donor coordinatio
- text: >-
In the national policy space for nutrition and food security, the National
Council for Food Security, Sovereignty and Nutrition of Timor-Leste
(KONSSANTIL), a government-led body, is vital in coordinating
multi-sectoral responses to food security and nutrition. While it offers a
unique role in shaping the country’s food and nutrition security
situation, it faces some operational challenges as the government has not
formally endorsed the KONSSTANTIL statute to coordinate cross-sectoral
nutrition and food security programs. Also, as an effort to improve multi-
sectoral coordination and add footprints to the global nutrition agenda,
Timor-Leste, joined the global Scaling Up Nutrition (SUN) movement. The
SUN movement secretariate at the Prime Minister’s Office has played a
significant role in multi-sectoral coordination for food and nutrition
security, including elaboration, positioning, and facilitating the
endorsement of the statute of KONSSANTIL and the development of the SDG 2
Consolidated Action Plan for Nutrition and Food Security, a common results
framework for SUN
- text: >-
Multi-hazard approach: A multi-hazard approach identifies and supports the
implementation of solutions that address more than one hazard
simultaneously. With this approach, it is possible to use the resources
more efficiently to address the diverse array of climate hazards
metrics:
- accuracy
pipeline_tag: text-classification
library_name: setfit
inference: true
base_model: sentence-transformers/paraphrase-mpnet-base-v2
model-index:
- name: SetFit with sentence-transformers/paraphrase-mpnet-base-v2
results:
- task:
type: text-classification
name: Text Classification
dataset:
name: Unknown
type: unknown
split: test
metrics:
- type: accuracy
value: 0.5483870967741935
name: Accuracy
SetFit with sentence-transformers/paraphrase-mpnet-base-v2
This is a SetFit model that can be used for Text Classification. This SetFit model uses sentence-transformers/paraphrase-mpnet-base-v2 as the Sentence Transformer embedding model. A LogisticRegression instance is used for classification.
The model has been trained using an efficient few-shot learning technique that involves:
- Fine-tuning a Sentence Transformer with contrastive learning.
- Training a classification head with features from the fine-tuned Sentence Transformer.
Model Details
Model Description
- Model Type: SetFit
- Sentence Transformer body: sentence-transformers/paraphrase-mpnet-base-v2
- Classification head: a LogisticRegression instance
- Maximum Sequence Length: 512 tokens
- Number of Classes: 3 classes
Model Sources
- Repository: SetFit on GitHub
- Paper: Efficient Few-Shot Learning Without Prompts
- Blogpost: SetFit: Efficient Few-Shot Learning Without Prompts
Model Labels
| Label | Examples |
|---|---|
| 1.1. Food Security & Nutrition |
|
| 6.3.3 Awareness and use of the evidence-based / agrifood systems approach |
|
| 6.3.4 Effectiveness of Policy Implementation |
|
Evaluation
Metrics
| Label | Accuracy |
|---|---|
| all | 0.5484 |
Uses
Direct Use for Inference
First install the SetFit library:
pip install setfit
Then you can load this model and run inference.
from setfit import SetFitModel
# Download from the 🤗 Hub
model = SetFitModel.from_pretrained("setfit_model_id")
# Run inference
preds = model("ncrease the production of vital local foods Improve the trade balance for selected commodities where import substitution is economically viable")
Training Details
Training Set Metrics
| Training set | Min | Median | Max |
|---|---|---|---|
| Word count | 5 | 123.0 | 1014 |
| Label | Training Sample Count |
|---|---|
| 1.1. Food Security & Nutrition | 65 |
| 6.3.3 Awareness and use of the evidence-based / agrifood systems approach | 32 |
| 6.3.4 Effectiveness of Policy Implementation | 22 |
Training Hyperparameters
- batch_size: (16, 16)
- num_epochs: (1, 1)
- max_steps: -1
- sampling_strategy: oversampling
- 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: 42
- eval_max_steps: -1
- load_best_model_at_end: True
Training Results
| Epoch | Step | Training Loss | Validation Loss |
|---|---|---|---|
| 0.0019 | 1 | 0.2492 | - |
| 0.0949 | 50 | 0.206 | - |
| 0.1898 | 100 | 0.1261 | - |
| 0.2846 | 150 | 0.1029 | - |
| 0.3795 | 200 | 0.0616 | - |
| 0.4744 | 250 | 0.0567 | - |
| 0.5693 | 300 | 0.0559 | - |
| 0.6641 | 350 | 0.0504 | - |
| 0.7590 | 400 | 0.0523 | - |
| 0.8539 | 450 | 0.0476 | - |
| 0.9488 | 500 | 0.0513 | - |
| 1.0 | 527 | - | 0.2939 |
Framework Versions
- Python: 3.12.8
- SetFit: 1.1.1
- Sentence Transformers: 3.3.1
- Transformers: 4.49.0
- PyTorch: 2.6.0
- Datasets: 3.3.2
- Tokenizers: 0.21.0
Citation
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}
}