duarteocarmo/fineweb2-bagaco
Bagaço 🍷🇵🇹 Bagaço is a pretraining dataset for European Portuguese. It filters the Fineweb2 dataset to URLs from Portuguese domains (e.g., .pt/). Each document is classified into one of 9 categories and scored for educational quality. Filtering Source: HuggingFaceFW/fineweb-2, subset por_Latn, split train Filter: URLs containing .pt/ (Portuguese top-level domain) Document classification Each document is classified into one of 9 categories:… See the full description on the dataset page: https://huggingface.co/datasets/duarteocarmo/fineweb2-bagaco.
Bagaço 🍷🇵🇹
Bagaço is a pretraining dataset for European Portuguese. It filters the Fineweb2 dataset to URLs from Portuguese domains (e.g., .pt/). Each document is classified into one of 9 categories and scored for educational quality.
Filtering
- Source:
HuggingFaceFW/fineweb-2, subsetpor_Latn, splittrain - Filter: URLs containing
.pt/(Portuguese top-level domain)
Document classification
Each document is classified into one of 9 categories: Society, Arts, Business, Science, Sports, Lifestyle, Health, Games, News.
Labeling:
- Model: Gemini 2.5 Flash Lite
- Labeled samples: 3,500
- Prompt:
System: Classify the Portuguese web text into one category.
User: <first 800 chars of document>
Response format: { category: Society | Arts | Business | Science | Sports | Lifestyle | Health | Games | News }Classifier:
- Embeddings:
intfloat/multilingual-e5-small - Model: Logistic Regression (
C=1.0,class_weight='balanced') - Validation: 20% held-out split (700 samples)
Educational score
Each document is assigned an educational quality score (0-5).
Labeling:
- Model: Qwen3 235B A22B
- Labeled samples: 30,000
- Prompt (adapted from FineWeb-Edu):
Below is an extract from a web page. Evaluate whether the page has a high educational value
and could be useful in an educational setting for teaching from primary school to grade school
levels using the additive 5-point scoring system described below. The text will be in Portuguese.
Evaluate its educational value based on content quality, not language.
- 1 point: basic information relevant to educational topics, even with ads/promotional material.
- 2 points: addresses elements pertinent to education but doesn't align closely with standards.
- 3 points: appropriate for educational use, introduces key concepts relevant to school curricula.
- 4 points: highly relevant for grade school education, clear writing, substantial content.
- 5 points: outstanding educational value, perfectly suited for primary/grade school teaching.
The extract: <first 1500 chars of document>
After examining the extract, briefly justify your total score (up to 100 words)
and provide the educational score (0-5).
Response format: { justification: str, educational_score: int }Classifier:
- Embeddings:
intfloat/multilingual-e5-small - Model: Logistic Regression (
C=1.0,class_weight='balanced') - Validation: 20% held-out split (train=24,000, test=6,000)
Confusion Matrix:
[[1679 319 40 15 3]
[ 847 1839 564 172 16]
[ 7 65 189 101 7]
[ 1 3 40 78 9]
[ 0 0 3 3 0]]Notes
referencescontains the labeled datasets used to train the classifiersscriptscontains the scripts used to train classifiers, classify documents, and process the dataset
