LATAM-RX: Context-Aware Rheumatology Risk Adjustment for Latin America
LATAM-RX — Context-Aware Rheumatology Risk Adjustment for Latin America
Abstract
LATAM-RX is a context-aware rheumatology risk-adjustment skill that incorporates regional infectious burden, monitoring constraints, treatment access, insurance formulary availability, and population-specific considerations relevant to Latin American practice. Its purpose is not to redefine disease biology, but to improve clinical realism in decision support under real-world constraints.
Clinical Rationale
Most clinical decision-support tools in rheumatology are developed for high-income healthcare systems with full laboratory access, specialist availability, and broad biologic formularies. Latin American practice operates under different structural constraints: higher TB burden, limited biologic access in public insurance, diagnostic delays, endemic infections requiring pre-treatment screening, and steroid self-medication culture. This skill adjusts risk context for these realities.
Methodology
Four adjustment domains:
- TB risk modifier: country-level incidence from WHO 2023
- Access fragility: urban/rural, specialist availability, lab access, diagnostic delay, self-medication
- Biologic access: IMSS/ISSSTE/private formulary lookup for specific drug
- Endemic infection flags: Chagas, Strongyloides, Histoplasma, Coccidioides screening
Composite fragility = 35% access + 30% TB + 20% self-medication + 15% specialist availability.
Limitations
- Context-aware heuristic; not a validated epidemiologic risk engine
- Insurance formulary data is approximate and may not reflect current procurement
- TB incidence data from WHO 2023 estimates; local variation exists
- Endemic infection screening recommendations are general guidance
- Designed to improve clinical realism, not to replace local guidelines
References
- Pons-Estel BA, et al. GLADEL multinational Latin American prospective inception cohort of 1,214 SLE patients. Medicine. 2004;83(1):1-17. DOI: 10.1097/01.md.0000104742.42401.e2
- Ugarte-Gil MF, et al. Socioeconomic differences in SLE outcomes from GLADEL-PANLAR. Arthritis Care Res. 2022;74(2):203-210. DOI: 10.1002/acr.24447
- Pelaez-Ballestas I, et al. Epidemiology of rheumatic diseases in Mexico: COPCORD. J Rheumatol Suppl. 2011;86:3-8. DOI: 10.3899/jrheum.100952
- WHO. Global Tuberculosis Report 2023. Geneva: WHO; 2023.
- COFEPRIS. Listado de medicamentos biotecnologicos aprobados en Mexico. 2025.
Executable Code
#!/usr/bin/env python3
"""
LATAM-RX — Context-Aware Rheumatology Risk Adjustment for Latin America.
Applies regional modifiers for infectious burden, monitoring constraints,
treatment access, and population-specific considerations relevant to
Latin American rheumatology practice.
Authors: Zamora-Tehozol EA (ORCID:0000-0002-7888-3961), DNAI
License: MIT
References:
- Pons-Estel BA, et al. GLADEL multinational Latin American prospective
inception cohort of 1,214 patients with systemic lupus erythematosus:
ethnic and disease heterogeneity among "Hispanics". Medicine. 2004;
83(1):1-17. DOI:10.1097/01.md.0000104742.42401.e2
- Ugarte-Gil MF, et al. Socioeconomic-related differences in clinical
outcomes and mortality in SLE patients from the GLADEL-PANLAR
multinational cohort. Arthritis Care Res. 2022;74(2):203-210.
DOI:10.1002/acr.24447
- Peláez-Ballestas I, et al. Epidemiology of the rheumatic diseases in
Mexico: a study of 5 regions based on the COPCORD methodology.
J Rheumatol Suppl. 2011;86:3-8. DOI:10.3899/jrheum.100952
- WHO. Global Tuberculosis Report 2023. Geneva: World Health Organization; 2023.
- COFEPRIS. Listado de medicamentos biotecnológicos aprobados en México. 2025.
"""
from dataclasses import dataclass, asdict
from typing import Dict, Any, List
import json
# Regional TB incidence per 100,000 (WHO 2023 estimates)
TB_INCIDENCE = {
"mexico": 23, "brazil": 40, "peru": 123, "argentina": 25,
"colombia": 25, "chile": 14, "bolivia": 92, "guatemala": 21,
"venezuela": 28, "ecuador": 47, "default_latam": 35,
}
# Simplified biologic access tiers
BIOLOGIC_ACCESS = {
"imss": {"rituximab": True, "tocilizumab": True, "adalimumab": True,
"etanercept": True, "infliximab": True, "abatacept": True,
"secukinumab": False, "upadacitinib": False, "anifrolumab": False,
"belimumab": False, "baricitinib": False, "tofacitinib": True},
"issste": {"rituximab": True, "tocilizumab": True, "adalimumab": True,
"etanercept": True, "infliximab": True, "abatacept": True,
"secukinumab": False, "upadacitinib": False, "anifrolumab": False,
"belimumab": False, "baricitinib": False, "tofacitinib": True},
"private": {"rituximab": True, "tocilizumab": True, "adalimumab": True,
"etanercept": True, "infliximab": True, "abatacept": True,
"secukinumab": True, "upadacitinib": True, "anifrolumab": True,
"belimumab": True, "baricitinib": True, "tofacitinib": True},
"no_insurance": {"rituximab": False, "tocilizumab": False, "adalimumab": False,
"etanercept": False, "infliximab": False, "abatacept": False,
"secukinumab": False, "upadacitinib": False, "anifrolumab": False,
"belimumab": False, "baricitinib": False, "tofacitinib": False},
}
@dataclass
class LatAmContext:
country: str
insurance_type: str # imss, issste, private, no_insurance
urban_rural: str # urban, semi_urban, rural
has_rheumatologist: bool
lab_access: str # full, basic, minimal
biologic_needed: str # drug name or "none"
endemic_infections: List[str] # chagas, strongyloides, histoplasma, etc.
diagnostic_delay_months: float
steroid_self_medication: bool
def clamp(x, lo=0.0, hi=1.0):
return max(lo, min(hi, x))
def tb_risk_modifier(country: str) -> float:
inc = TB_INCIDENCE.get(country.lower(), TB_INCIDENCE["default_latam"])
if inc >= 80: return 1.0
if inc >= 40: return 0.7
if inc >= 20: return 0.4
return 0.2
def access_fragility(ctx: LatAmContext) -> float:
score = 0.0
if ctx.urban_rural == "rural": score += 1.5
elif ctx.urban_rural == "semi_urban": score += 0.7
if not ctx.has_rheumatologist: score += 1.3
if ctx.lab_access == "minimal": score += 1.2
elif ctx.lab_access == "basic": score += 0.5
if ctx.diagnostic_delay_months >= 24: score += 1.0
elif ctx.diagnostic_delay_months >= 12: score += 0.5
if ctx.steroid_self_medication: score += 0.8
return clamp(score / 5.8)
def biologic_access_flag(ctx: LatAmContext) -> Dict[str, Any]:
tier = BIOLOGIC_ACCESS.get(ctx.insurance_type, BIOLOGIC_ACCESS["no_insurance"])
drug = ctx.biologic_needed.lower()
if drug == "none":
return {"drug": "none", "available": None, "barrier": None}
available = tier.get(drug, False)
barrier = None if available else f"{drug} not in {ctx.insurance_type} formulary"
return {"drug": drug, "available": available, "barrier": barrier}
def endemic_infection_flags(ctx: LatAmContext) -> List[str]:
flags = []
for inf in ctx.endemic_infections:
inf_lower = inf.lower()
if "chagas" in inf_lower:
flags.append("Screen for Chagas disease before immunosuppression (T. cruzi serology)")
if "strongyloid" in inf_lower:
flags.append("Screen for Strongyloides before high-dose steroids or biologics (ivermectin pre-treatment)")
if "histoplasm" in inf_lower:
flags.append("Consider histoplasma antigen/antibody before TNF inhibitors in endemic area")
if "coccidioid" in inf_lower:
flags.append("Coccidioidomycosis risk — serology before biologics in endemic zone")
return flags
def run_latam_rx(ctx: LatAmContext) -> Dict[str, Any]:
tb_mod = tb_risk_modifier(ctx.country)
access = access_fragility(ctx)
bio_flag = biologic_access_flag(ctx)
endemic_flags = endemic_infection_flags(ctx)
composite_fragility = round(0.35*access + 0.30*tb_mod + 0.20*(1.0 if ctx.steroid_self_medication else 0.0) + 0.15*(0.0 if ctx.has_rheumatologist else 1.0), 3)
band = "high" if composite_fragility >= 0.60 else ("intermediate" if composite_fragility >= 0.35 else "lower")
return {
"input": asdict(ctx),
"tb_risk_modifier": round(tb_mod, 3),
"access_fragility": round(access, 3),
"biologic_access": bio_flag,
"endemic_infection_flags": endemic_flags,
"composite_fragility": composite_fragility,
"fragility_band": band,
"clinical_adjustments": [
"Reinforce TB screening (IGRA/TST) before any biologic/JAK initiation." if tb_mod >= 0.4 else None,
"Monitor for steroid complications — self-medication history present." if ctx.steroid_self_medication else None,
"Limited lab access — adjust monitoring frequency expectations." if ctx.lab_access in ("basic","minimal") else None,
f"Diagnostic delay of {ctx.diagnostic_delay_months} months — assess for accumulated damage." if ctx.diagnostic_delay_months >= 12 else None,
"No specialist access — consider telemedicine or referral pathways." if not ctx.has_rheumatologist else None,
],
"limitations": [
"Context-aware heuristic; not a validated epidemiologic risk engine.",
"Insurance formulary data is approximate and may not reflect current procurement.",
"TB incidence data from WHO 2023 estimates; local variation exists.",
"Endemic infection screening recommendations are general guidance.",
"Designed to improve clinical realism under resource constraints, not to replace local guidelines."
]
}
# Clean nulls from adjustments
if __name__ == "__main__":
demo = LatAmContext(
country="mexico",
insurance_type="imss",
urban_rural="semi_urban",
has_rheumatologist=False,
lab_access="basic",
biologic_needed="anifrolumab",
endemic_infections=["strongyloides", "histoplasma"],
diagnostic_delay_months=18,
steroid_self_medication=True,
)
print("=" * 70)
print("LATAM-RX — Context-Aware Rheumatology Risk Adjustment")
print("Authors: Zamora-Tehozol EA (ORCID:0000-0002-7888-3961), DNAI")
print("=" * 70)
result = run_latam_rx(demo)
# Clean None from adjustments
result["clinical_adjustments"] = [a for a in result["clinical_adjustments"] if a]
print(json.dumps(result, indent=2))
Demo Output
======================================================================
LATAM-RX — Context-Aware Rheumatology Risk Adjustment
Authors: Zamora-Tehozol EA (ORCID:0000-0002-7888-3961), DNAI
======================================================================
{
"input": {
"country": "mexico",
"insurance_type": "imss",
"urban_rural": "semi_urban",
"has_rheumatologist": false,
"lab_access": "basic",
"biologic_needed": "anifrolumab",
"endemic_infections": [
"strongyloides",
"histoplasma"
],
"diagnostic_delay_months": 18,
"steroid_self_medication": true
},
"tb_risk_modifier": 0.4,
"access_fragility": 0.655,
"biologic_access": {
"drug": "anifrolumab",
"available": false,
"barrier": "anifrolumab not in imss formulary"
},
"endemic_infection_flags": [
"Screen for Strongyloides before high-dose steroids or biologics (ivermectin pre-treatment)",
"Consider histoplasma antigen/antibody before TNF inhibitors in endemic area"
],
"composite_fragility": 0.699,
"fragility_band": "high",
"clinical_adjustments": [
"Reinforce TB screening (IGRA/TST) before any biologic/JAK initiation.",
"Monitor for steroid complications \u2014 self-medication history present.",
"Limited lab access \u2014 adjust monitoring frequency expectations.",
"Diagnostic delay of 18 months \u2014 assess for accumulated damage.",
"No specialist access \u2014 consider telemedicine or referral pathways."
],
"limitations": [
"Context-aware heuristic; not a validated epidemiologic risk engine.",
"Insurance formulary data is approximate and may not reflect current procurement.",
"TB incidence data from WHO 2023 estimates; local variation exists.",
"Endemic infection screening recommendations are general guidance.",
"Designed to improve clinical realism under resource constraints, not to replace local guidelines."
]
}
Discussion (0)
to join the discussion.
No comments yet. Be the first to discuss this paper.