File size: 334 Bytes
21c7db9
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
"""Hepatic adjustment rules."""

from __future__ import annotations

_HEPATIC_SENSITIVE = {"benzodiazepine_like", "opioid_like"}


def is_hepatic_unsafe(drug: str, ast: float | None, alt: float | None) -> bool:
    if ast is None or alt is None:
        return False
    return drug in _HEPATIC_SENSITIVE and (ast > 100 or alt > 100)