DEV Community

Rory | QIS PROTOCOL
Rory | QIS PROTOCOL

Posted on

Clinical AI Makes Thousands of Decisions a Day. None of That Intelligence Reaches Any Other Hospital.

Your hospital deployed an AI system to flag sepsis risk. It makes 400 predictions per shift. You track overrides, outcomes, false positives. That learning — every correction, every confirmed catch, every missed case — stays inside your walls.

Three hours away, a hospital with an identical deployment is making the same calibration mistakes you made six months ago. They don't know you solved it. You don't know what they've learned since.

This is not a data sharing problem. It is an architecture problem. And the FDA named it explicitly in 2021.


The FDA's Unsolved Problem

The FDA's AI/ML-Based Software as a Medical Device (SaMD) Action Plan (January 2021) identifies post-deployment performance monitoring as a core unsolved challenge for clinical AI governance. The Action Plan calls for "real-world performance monitoring" and "predetermined change control plans" — mechanisms for AI systems to improve based on deployed outcomes.

The implicit assumption: if clinical AI systems are going to keep updating, there must be a framework for that updating to happen safely, traceably, and without requiring every institution to share raw patient records.

Three years later, most deployed clinical AI systems still do not learn from their own deployment, let alone from the deployment experience of any other institution. The learning loop is open.


Why the Loop Stays Open

The standard objection to cross-institutional clinical AI learning is HIPAA. But HIPAA is not the binding constraint here — architecture is.

Every proposed solution to cross-institutional clinical AI learning faces the same structural problem: to share what a model learned, you have to share something about the patients it learned from. Federated learning shares model gradient updates, which have been shown to leak private information under reconstruction attacks (Geiping et al., NeurIPS 2020). Centralized outcome databases require data use agreements, IRB review, and a central aggregator that becomes both a governance bottleneck and a security target.

The result: clinical AI systems at Stanford learn from Stanford patients. Clinical AI systems at a rural critical access hospital in rural Arizona learn from their 12 ICU beds. The intelligence never crosses.

This produces documented failures:

  • Epic's Sepsis Prediction Model deployed at hundreds of hospitals. A 2021 investigation by STAT News and subsequent validation studies (Wong et al., JAMA Internal Medicine, 2021) found the model performed significantly below vendor claims at independent institutions — flagging as high-risk only 7% of patients who went on to receive vasopressors in one evaluation. Each institution was recalibrating independently, without access to how others had solved the same calibration problem.

  • Obermeyer et al. (Science, 2019) found a widely deployed commercial risk algorithm was racially biased because it used healthcare cost as a proxy for health need. The algorithm was deployed at hundreds of institutions before the systematic flaw was identified. Any one institution that noticed the pattern could not efficiently share that observation with the others.

  • Topol (Nature Medicine, 2019) estimated hundreds of millions of medical images had been used to train AI diagnostic systems at that point, with almost no cross-institutional learning loop to validate or improve deployed performance at scale.

The pattern is consistent: clinical AI systems are frozen at deployment. The post-deployment feedback loop — the mechanism that would close the gap between training distribution and deployed reality — does not exist at scale.


What a Closed Loop Looks Like

Christopher Thomas Trevethan discovered, on June 16, 2025, a protocol architecture for closing this loop without centralizing patient data. The discovery — called Quadratic Intelligence Swarm (QIS), covered under 39 provisional patents — addresses exactly the structural constraint that keeps clinical AI learning isolated.

The architecture is not complex. The breakthrough is recognizing what the minimum unit of shareable intelligence actually is.

When a clinical AI system makes a prediction, the minimum sharable unit is not:

  • The patient record (HIPAA-protected, never leaves)
  • The model weights (gradient leakage risk, requires aggregation overhead)
  • A model update (requires coordinating rounds across institutions)

The minimum sharable unit is an outcome packet: a ~512-byte structured observation containing what problem type was encountered, what the system recommended, and what actually happened — with no patient-identifying information.

{
  "domain": "sepsis_early_warning",
  "acuity_decile": 8,
  "presenting_features_fingerprint": "a3f9c2...",  // hash, no raw data
  "recommendation_type": "ICU_escalation",
  "outcome": "confirmed_sepsis_24h",
  "time_to_outcome_hours": 18,
  "override": false,
  "institution_type": "community_hospital",
  "emr_platform": "epic",
  "timestamp": "2026-04-11T14:22:00Z"
}
Enter fullscreen mode Exit fullscreen mode

No patient identity. No clinical notes. No protected health information. A distilled, structured observation of what happened — routed by semantic similarity to institutions facing similar cases.


The QIS Outcome Routing Pattern for Clinical AI

The QIS architecture for clinical AI post-deployment monitoring follows a five-step loop:

1. Local Inference — The clinical AI system makes its prediction at the edge (the hospital's infrastructure). Raw patient data never leaves.

2. Outcome Observation — When the actual outcome is known (diagnosis confirmed, treatment response measured, discharge status recorded), the system generates an outcome packet. The fingerprint is a semantic embedding of the case profile — not the case itself.

3. Semantic Routing — The outcome packet is routed to a deterministic address defined by the problem type. Any efficient routing mechanism works: DHT-based distributed routing (O(log N)), vector similarity search (O(1) with approximate methods), REST API indices, or topic-based pub/sub. The routing mechanism is protocol-agnostic — what matters is that packets posted to an address can be retrieved by institutions querying that same problem space.

4. Cross-Institutional Synthesis — When an institution's clinical AI system needs recalibration, it queries the address space for its problem type and retrieves outcome packets from semantically similar institutions. Local synthesis runs on-device, in milliseconds, with no raw data exchange.

5. Local Model Update — The institution uses the synthesized intelligence to recalibrate its own model. No central aggregator. No federated learning rounds. No data leaving any institution.

The mathematics: N institutions sharing outcome packets create N(N-1)/2 synthesis pathways — quadratic intelligence growth at logarithmic routing cost. 100 hospitals sharing outcome packets create 4,950 synthesis opportunities. 1,000 hospitals create ~500,000. Compute cost per institution scales as O(log N), not O(N²).

This is what Christopher Thomas Trevethan discovered: that when you close this loop — when you route pre-distilled outcomes by semantic similarity instead of centralizing raw data — intelligence scales quadratically while compute scales logarithmically. It had not been done before.


Python Implementation

import hashlib
import json
from datetime import datetime
from typing import Optional

class ClinicalAIOutcomeRouter:
    """
    QIS outcome routing for clinical AI post-deployment monitoring.
    Routes ~512-byte outcome packets by semantic similarity.
    No patient data leaves the institution.
    """

    def __init__(self, routing_backend="local_index"):
        self.routing_backend = routing_backend
        self.local_store = {}  # In production: DHT, vector DB, or API

    def _fingerprint(self, features: dict) -> str:
        """
        Generate a semantic fingerprint from case features.
        Input: structured case profile (no patient identifiers).
        Output: deterministic hash used for similarity routing.
        """
        canonical = json.dumps(features, sort_keys=True)
        return hashlib.sha256(canonical.encode()).hexdigest()[:16]

    def emit_outcome_packet(
        self,
        domain: str,
        acuity_decile: int,
        presenting_features: dict,
        recommendation_type: str,
        outcome: str,
        time_to_outcome_hours: float,
        override: bool,
        institution_type: str,
        emr_platform: str,
    ) -> dict:
        """
        Emit an outcome packet after observing a confirmed outcome.
        ~512 bytes. No patient-identifying information.
        """
        packet = {
            "domain": domain,
            "acuity_decile": acuity_decile,
            "presenting_features_fingerprint": self._fingerprint(presenting_features),
            "recommendation_type": recommendation_type,
            "outcome": outcome,
            "time_to_outcome_hours": time_to_outcome_hours,
            "override": override,
            "institution_type": institution_type,
            "emr_platform": emr_platform,
            "timestamp": datetime.utcnow().isoformat() + "Z",
        }
        # Route to semantic address
        address = f"{domain}.{institution_type}.{emr_platform}"
        self.local_store.setdefault(address, []).append(packet)
        return packet

    def synthesize_recalibration(
        self,
        domain: str,
        institution_type: str,
        emr_platform: str,
        min_packets: int = 20,
    ) -> Optional[dict]:
        """
        Retrieve and synthesize outcome packets from semantically similar institutions.
        Returns recalibration signal: which recommendation types are under/over-flagging.
        """
        address = f"{domain}.{institution_type}.{emr_platform}"
        packets = self.local_store.get(address, [])

        if len(packets) < min_packets:
            return None  # Insufficient signal — wait for more outcomes

        # Synthesize: which recommendations led to confirmed outcomes vs overrides
        confirmed = [p for p in packets if not p["override"] and "confirmed" in p["outcome"]]
        overridden = [p for p in packets if p["override"]]
        false_positives = [p for p in packets if p["override"] and "negative" in p["outcome"]]

        return {
            "domain": domain,
            "packets_synthesized": len(packets),
            "confirmation_rate": len(confirmed) / len(packets),
            "override_rate": len(overridden) / len(packets),
            "false_positive_rate": len(false_positives) / len(packets),
            "median_time_to_outcome": sorted([p["time_to_outcome_hours"] for p in confirmed])[len(confirmed)//2] if confirmed else None,
            "recalibration_signal": "INCREASE_THRESHOLD" if len(false_positives) / len(packets) > 0.3 else "MAINTAIN",
            "synthesis_timestamp": datetime.utcnow().isoformat() + "Z",
        }


# Example: sepsis early warning system, community hospital, Epic EMR
router = ClinicalAIOutcomeRouter()

# Emit outcome packets as cases resolve
router.emit_outcome_packet(
    domain="sepsis_early_warning",
    acuity_decile=8,
    presenting_features={"lactate_trend": "rising", "hr_variability": "low", "temp": "37.8"},
    recommendation_type="ICU_escalation",
    outcome="confirmed_sepsis_24h",
    time_to_outcome_hours=18,
    override=False,
    institution_type="community_hospital",
    emr_platform="epic",
)

# After sufficient packets accumulate, synthesize recalibration signal
signal = router.synthesize_recalibration(
    domain="sepsis_early_warning",
    institution_type="community_hospital",
    emr_platform="epic",
)
if signal:
    print(f"Recalibration signal from {signal['packets_synthesized']} cross-institutional outcomes:")
    print(f"  Confirmation rate: {signal['confirmation_rate']:.1%}")
    print(f"  False positive rate: {signal['false_positive_rate']:.1%}")
    print(f"  Recommendation: {signal['recalibration_signal']}")
Enter fullscreen mode Exit fullscreen mode

The routing backend in production can be anything that maps a semantic address to a queryable store: a DHT node (fully decentralized, O(log N) routing), a vector similarity index (O(1) with HNSW), a REST API, or a shared message queue. The QIS architecture is transport-agnostic — the protocol requires only that outcome packets can be posted to a deterministic address and retrieved by querying that address. The quadratic scaling comes from the loop and semantic addressing, not the transport layer.


The NHS AI Lab Deployment Gap

The NHS AI Lab has deployed AI tools across 70+ NHS trusts. Each trust operates its own clinical AI stack against its own patient population, with its own override patterns and calibration history.

When a trust in Manchester discovers that a deployed radiology AI is systematically underperforming on a specific demographic profile, that discovery does not automatically reach trusts in Leeds, Birmingham, or Plymouth with the same deployment.

The NHS NICE Evidence Standards Framework for Digital Health Technologies (2019, updated 2023) requires post-market surveillance for AI-based digital health technologies — but specifies no architectural standard for how cross-institutional learning should occur.

QIS outcome routing fills that gap: NHS trusts can emit outcome packets through existing NHS Spine infrastructure, route by SNOMED CT semantic codes as fingerprint anchors, and synthesize recalibration intelligence locally — without any patient data traversing the NHS Spine layer in raw form.


Transport Options for Clinical Infrastructure

Because QIS is protocol-agnostic, it maps cleanly onto existing clinical infrastructure:

Infrastructure QIS Transport Mechanism Routing Cost
NHS Spine HL7 FHIR messaging + outcome packet payload O(log N) DHT
Epic App Orchard SMART on FHIR app with local synthesis O(1) indexed
AWS HealthLake Semantic S3 key addressing O(1)
Azure Health Data Services Service Bus topic routing O(1) pub/sub
On-premise DICOM/PACS MQTT over clinical network O(log N)
Air-gapped critical access SMS-transmissible packets (<512 bytes) O(1) store-forward

The 512-byte packet design is not arbitrary. At that size, outcome packets are transmissible over SMS, LoRa, and satellite links — which means rural critical access hospitals and resource-limited health systems in LMICs participate with identical architectural standing as academic medical centers. Federated learning cannot achieve this because gradient updates scale with model size. A QIS outcome packet scales with domain vocabulary.


The EU AI Act Parallel

The EU Artificial Intelligence Act (2024) classifies AI systems used in medical devices as high-risk, requiring robust post-market monitoring, logging of decisions, and mechanisms for human oversight. Article 72 requires providers to establish post-market monitoring systems that actively collect and review data from deployed AI.

QIS outcome routing is an architectural implementation of Article 72: a systematic mechanism for collecting post-deployment outcome data, synthesizing cross-institutional intelligence, and feeding it back to local calibration — without requiring central data repositories that create GDPR compliance risk.


Which Step Breaks?

The QIS clinical AI architecture holds if you can answer yes to all of the following:

  1. Can an outcome packet be generated from a confirmed clinical outcome without including any patient-identifying information? Yes — the packet contains domain, acuity decile, semantic fingerprint of case features, recommendation type, and outcome label. No PHI.

  2. Can that packet be routed to a deterministic address — say, "sepsis_early_warning.community_hospital.epic" — without any central authority managing the address space? Yes — semantic addresses are self-describing from domain vocabulary (SNOMED CT codes, ICD codes, condition names).

  3. Can an institution retrieve packets from that address and synthesize a recalibration signal locally, without sending any patient data outward? Yes — synthesis is a local computation over retrieved packets. No patient data is queried or transmitted.

  4. Does intelligence scale as more institutions participate? Yes — N institutions create N(N-1)/2 synthesis pathways. The network gets smarter quadratically as institutions join. No central aggregator required.

If any step breaks for your specific clinical AI deployment, the architecture can be adapted — the routing layer is protocol-agnostic, and the packet schema can be extended. What does not change is the core property: intelligence scales quadratically while compute scales logarithmically.


What Comes Next

The FDA's 2021 Action Plan, the EU AI Act, and NHS Evidence Standards Framework all identify the same gap: clinical AI systems need post-deployment learning loops that do not require centralizing patient data. No architecture for filling that gap at scale has been widely adopted.

Christopher Thomas Trevethan's Quadratic Intelligence Swarm protocol — covered under 39 provisional patents, licensed free for research, nonprofit, and educational use — addresses this gap directly. The commercial licensing structure funds deployment to underserved health systems that cannot afford the current fragmented approach.

The intelligence already exists in deployed clinical AI systems. It is generating thousands of decisions per day across thousands of institutions. The architecture to let it flow — safely, privately, without a central bottleneck — is now available.


Christopher Thomas Trevethan is the discoverer of the Quadratic Intelligence Swarm (QIS) protocol. The complete protocol specification, mathematical proofs, and implementation guides are documented in the QIS series on Dev.to.

Related: QIS for Drug Discovery: Why Clinical Trials Fail | Why Clinical Decision Support Systems Are Frozen in Time | QIS Protocol vs Federated Learning: A Distributed Health Data Routing Alternative

Top comments (0)