How spyysalo/finbert-text-classification works
This repository runs Finnish text-classification experiments with BERT for the Yle and Ylilauta tasks. The main workflow reads labeled corpus splits, selects task labels, and runs training, evaluation, and/or prediction; prediction writes results to the configured output directory. Separate utilities summarize experiment logs and select the best parameter sets. The classifier excerpt shows calls into the bundled BERT code, but the BERT implementation and corpus contents were not sampled, so their internal stages and finer-grained data flow are not represented.
Main entry points: run_classifier.py BERT classifier · select_params.py Parameter selector · summarize.py Log summarizer · bert BERT toolkit
Components 12
Classification
- BERT classifier
run_classifier.py - BERT toolkit
bert
Data
- Task labels
task_config.py - Yle corpus
yle-corpus - Ylilauta corpus
ylilauta-corpus
Experiment analysis
- Log summarizer
summarize.py - Parameter selector
select_params.py
Other components
- Experiment operator
- TensorFlow runtime
- BERT checkpoint
- Prediction results
- Experiment logs
Connections 13
- Experiment operator → BERT classifier: runs
- BERT classifier → Yle corpus: reads splits
- BERT classifier → Ylilauta corpus: reads splits
- BERT classifier → Task labels: loads labels
- BERT classifier → BERT toolkit: calls APIs
- BERT classifier → TensorFlow runtime: runs estimator
- BERT classifier → BERT checkpoint: loads checkpoint
- BERT classifier → Prediction results: writes results
- Experiment operator → Log summarizer: runs
- Log summarizer → Experiment logs: reads logs
- Experiment operator → Parameter selector: runs
- Parameter selector → Experiment logs: reads logs
- Parameter selector → Log summarizer: calls log reader