Views
No views yet

| Metric | Value | Interpretation |
|---|---|---|
| Accuracy | 94.44% | Overall correct classification rate. |
| Precision | 70.00% | Reliability when predicting "Physics" class. |
| Recall | 62.30% | Ability to detect Physics content within the dataset. |
| F1-Score | 65.93% | Harmonic mean of precision and recall. |
| Validation Loss | 0.1574 | Low validation error indicating stable convergence. |

General (Non-Physics content, noise, or other topics)Physics (Scientific or educational content related to physics)pipeline:1from transformers import pipeline
2
3# Load the classifier
4classifier = pipeline("text-classification", model="Madras1/RobertaPhysics")
5
6# Example 1: Physics Content
7text_physics = "Quantum entanglement describes a phenomenon where linked particles remain connected."
8result_physics = classifier(text_physics)
9print(result_physics)
10# Expected Output: [{'label': 'Physics', 'score': 0.93}]
11
12# Example 2: General Content
13text_general = "The quarterly earnings report will be released to investors next Tuesday."
14result_general = classifier(text_general)
15print(result_general)
16# Expected Output: [{'label': 'General', 'score': 0.86}]