EU Parliament Monitor — API Documentation - v0.8.24
    Preparing search index...
    • Compute how interconnected a set of political risks are.

      Cascade potential between two risks is estimated by comparing their threat categories and numeric risk scores. Risks of the same category with high scores are considered more likely to cascade.

      Cascade score formula:

      • Same category: baseScore = 0.6 + (avgScore / 10) * 0.4
      • Different category: baseScore = 0.2 + (avgScore / 10) * 0.2

      The overall interconnection score is the mean of all pair cascade scores.

      Parameters

      • risks: readonly {
            riskId: string;
            category: PoliticalThreatCategory;
            numericScore: number;
        }[]

        Array of objects with riskId, category, and numericScore (0–10)

      Returns RiskInterconnection

      RiskInterconnection with cascade pairs and overall assessment