How jpvoelz/emotion-classification works
Project Type and Purpose
• This is a data-science experiment pipeline for multi-label emotion classification using the GoEmotions dataset.
• Implemented entirely in a Jupyter notebook (GoEmotions_Project.ipynb), with results formalized in a PDF slide deck.
File Structure Insights
• Top level contains only the notebook, README, and a slide deck.
• No distinct “src” or “backend/frontend” folders implies an all-in-one exploratory/analysis pipeline.
• The notebook orchestrates data loading, preprocessing, model training, evaluation, and result visualization.
Key Components
a. Data Ingestion
• GoEmotions dataset (CSV/JSON storage) → loaded by notebook.
b. Preprocessing
• Text cleaning/tokenization
• Construction of feature matrices for logistic regression
• Embedding/tokenizer stages for RNN and BERT
c. Model Training Pipelines (parallel branches)
• One-vs-Rest Logistic Regression
• RNN classifier (embedding layer + recurrent layers)
• BERT-based classifier (Hugging Face Transformers)
d. Evaluation & Metrics
• Precision, recall, F1 per label + macro-averages
• Bias analysis subroutine (gender bias test)
e. Reporting/Output
• Plots (matplotlib/Seaborn) embedded in notebook
• Final PDF slide deck
f. (Optional) Data Augmentation Branch
• ChatGPT (or other LLM) based synthetic comment generator
Relationships and Data Flow
• Data Ingestion → Preprocessing → three parallel Model Training components → Evaluation module → Visualizations → Slide deck.
Architectural Patterns & Design Principles
• Pipeline pattern (sequential data transformation)
• Branching for comparative model experiments
• Reproducibility: notebook cell ordering as orchestration, versioned dataset tag
• Modularity: separate preprocessing functions, model definitions, evaluation routines
Essential Elements
• Component labels (exact names from the notebook and README)
• Annotations on connectors where helpful (e.g., “tokenized text,” “embeddings,” “predicted labels”)
• A title block: “GoEmotions Multi-Label Classification Pipeline”