learningview / core /base_analyzer.py
ArrowDust's picture
LearnView Pro: Clean Production Build
408b7e6
Raw History Blame Contribute Delete
510 Bytes
from abc import ABC, abstractmethod
class ClinicalAnalyzer(ABC):
"""
Abstract Base for all diagnostic interpretation logic.
Ensures 'Certainty over Velocity' across different clinical modules.
"""
@abstractmethod
def calculate_risk(self, metrics: dict) -> int:
pass
def interpret_score(self, score: int) -> str:
"""Standardized interpretation across all modules."""
if score > 75: return "High"
if score > 40: return "Moderate"
return "Low"