feat: Review Intelligence Features (Load Balancing, Pair Analytics, SLA Predictions) & Groq Failover Cascade #12
Review confidence threshold not met — re-review recommended
Residual risk 0.73 = Change Risk (0.82) × (1 − Review Confidence (0.11)).
Flagged for follow-up review before production rollout.
Model 1 · Change Risk (XGBoost)
Score: 0.82 · 2678 lines diff across 21 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.00 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 9% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.400
Shallow Review Depth
shallow_review_depth
0.350
Rapid Merge
rapid_merge
0.100
Mass File Touch
mass_file_touch
0.080
Real PR Conversation Timeline
2 items
Approved
LGTM
ankit-cybertron
Ishaan-Chaturved1
Summary
This PR delivers major intelligence capabilities to Vouch, refactors reviewer workload metrics, resolves frontend validator issues, and introduces an automatic dual-key failover cascade for AI risk narration with a refreshed GitHub Primer UI.
---
Key Highlights & Changes
1. Reviewer Load Balancing & Pair Intelligence
/pair-intelligence): Implemented pair co-review frequency tracking, collaboration depth scores, and reviewer affinity metrics to prevent reviewer silos.2. Review SLA Predictions & Org Health
Low,Moderate,High)./team-health): Added macro-level team review velocity, fatigue rates, department health KPIs, CSV/JSON report exports, and team-wide alert indicators.3. Dual-Key Groq Failover & Bedrock Cascade
- Resolves
GROQ_API_KEY(primary) $\to$GROQ_API_KEY_backup(secondary).- Automatically cascades on HTTP 401, 429 rate limit/quota, timeouts, or 5xx server errors.
- Returns
requires_key: trueto trigger an inline API key prompt if all configured keys fail or are unconfigured.4. UI & Template Polish
- Displays
Bedrock Claude 3 · Risk Narration (disconnected)status clearly in the header.- Places Groq on-demand risk narration directly below the disconnected header.
- Replaced legacy tag/bookmark icons with the official circular Groq logo (
/static/img/groq-logo.png).- Added user avatars and GitHub-style status badges across reviewer cards.
- Cleaned up inline Jinja CSS styles across
team_health.htmlto eliminate template validator warnings.- Updated repository count in the navbar and polished Model 1 attribution charts.
---
Commits Included
ccd88a0after ui changes bug fixes0768386feat(ui): polished UI improvements for Model 1 chart, sidebar risk breakdownf92db21feat(ui): update repos view, navbar count, team health avatars, and badgesec8cd6fMerge branch 'main' of https://github.com/ankit-cybertron/Vouch32ad550feat: Features 1, 5, 6, 8 — Load Balancing, Pair Intelligence, SLA Predictions, Org Healthc834d7afix(ui): remove inline Jinja styles to fix HTML/CSS validator errors and add reviewer avatars in team health08861e1feat(reviewer): replace Domain Expertise with Workload Capacity & Consistent Review Pairsc3c1eb5feat(explain): implement Groq multi-key failover cascade and UI redesign---
Verification & Testing
-
tests/unit/test_groq_explanation.py: verified primary $\to$ backup cascade, user key prompting, and Bedrock fallback.-
tests/unit/test_load_balancing.py,tests/unit/test_pair_intelligence.py,tests/unit/test_sla_predictions.py: verified routing and calculation engines.-
tests/integration/dashboard_routes.py: verified all views (/,/repos,/pulls,/reviewer/<id>,/pair-intelligence,/team-health).- 186 / 186 unit and integration tests passing.