| # Vibecheck Deep Dive — Confidence-Gated Cascade |
|
|
| ## Architecture |
|
|
| This is the **meta configuration repo** for the Vibecheck Deep Dive cascade. |
| It contains no model weights — weights are stored in the component repos below. |
|
|
| ## Component Repos |
|
|
| | Component | Repo | Task | |
| |-----------|------|------| |
| | Quick Vibe (Tier 1) | `itsLu/mentalbert-v5-source-aware` | Cooperative source-aware 8-class MentalBERT | |
| | Pathway A (Tier 2) | `itsLu/mentalbert-v5-specialist-a` | CSSRS-pure 6-class specialist | |
| | Pathway B (Tier 2) | `itsLu/longformer-v5-crisis-evidence` | Binary crisis-evidence Longformer | |
|
|
| ## Routing Logic |
|
|
| ```python |
| ROUTE_TO_DEEP_DIVE = ( |
| top1_prob < 0.65 |
| or (top1_class in {Depression, Suicidal} and margin < 0.2) |
| ) |
| # Pass-through: Normal and Directed Aggression always use Quick Vibe |
| ``` |
|
|
| ## Fusion Gate |
|
|
| ```python |
| crisis_boost = alpha * pathway_b_crisis_prob # alpha=1.5 |
| fused_logits[Suicidal] += crisis_boost |
| fused_logits[Depression] -= 0.5 * crisis_boost # mass conservation |
| final = softmax(fused_logits) |
| ``` |
|
|
| ## Load Pattern |
|
|
| ```python |
| import json |
| from huggingface_hub import hf_hub_download |
| |
| cascade_cfg = json.load(open(hf_hub_download('itsLu/vibecheck-deepdive-cascade', 'cascade_config.json'))) |
| pathway_a = load_specialist_a(cascade_cfg['pathway_a_repo']) |
| pathway_b = load_specialist_b(cascade_cfg['pathway_b_repo']) |
| result = cascade_predict(text, quick_vibe, pathway_a, pathway_b, cascade_cfg) |
| ``` |
|
|
| ## Test Metrics |
|
|
| | Metric | Value | |
| |--------|-------| |
| | Accuracy | 84.82% | |
| | F1 Macro | 0.8558 | |
| | Total bleed | 1179 | |
| | Dep→Sui | 482 | |
| | Sui→Dep (critical) | 697 | |
| | % routed to Deep Dive | 12.2% | |
|
|