{
  "endpoint": "https://jetbase-production.up.railway.app/mcp/clinical",
  "protocol_version": "2025-11-25",
  "tools": [
    {
      "name": "audit_trial_matrix",
      "title": "Audit an ingested trial matrix",
      "description": "Audit original CSV/TSV source bytes, observed endpoint coverage, finite values, anonymous row identity and temporal seals. A passed audit is a data integrity result; it does not authorize clinical efficacy claims.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "matrix_id": {
            "enum": [
              "RRMS-1740",
              "REMY-VEP-001",
              "GOAU-199-001",
              "DISCOVERY"
            ]
          },
          "run_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "source_doi_or_url": {
            "type": "string",
            "minLength": 1,
            "maxLength": 2048
          },
          "expected_source_sha256": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "columns_present": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 160
            },
            "maxItems": 512,
            "uniqueItems": true
          },
          "substrate_gate": {
            "type": "object",
            "properties": {
              "metric_name": {
                "enum": [
                  "prnfl_thickness_um",
                  "gcipl_thickness_um",
                  "none"
                ]
              },
              "min_threshold_um": {
                "type": "number",
                "minimum": 0
              }
            },
            "required": [
              "metric_name"
            ],
            "additionalProperties": false
          },
          "allow_synthetic_padding": {
            "const": false,
            "default": false
          },
          "intended_classification": {
            "enum": [
              "remyelination",
              "axonal_injury_suppression",
              "functional_rehab",
              "exploratory_biomarker"
            ]
          },
          "protocol_details": {
            "type": "object",
            "properties": {
              "endpoint_columns": {
                "type": "array",
                "items": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 160
                },
                "maxItems": 512,
                "uniqueItems": true
              },
              "identity_columns": {
                "type": "array",
                "items": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 160
                },
                "maxItems": 512,
                "uniqueItems": true
              },
              "max_missing_fraction": {
                "type": "number",
                "minimum": 0,
                "maximum": 1
              },
              "require_frozen_baseline": {
                "type": "boolean"
              },
              "prospective_required": {
                "type": "boolean"
              }
            },
            "required": [
              "endpoint_columns",
              "identity_columns"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "matrix_id",
          "run_id",
          "columns_present",
          "substrate_gate",
          "intended_classification",
          "protocol_details"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "matrix_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "run_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "validation_status": {
            "type": "boolean"
          },
          "audit_status": {
            "enum": [
              "PASS_WITH_RESTRICTIONS",
              "REJECTED"
            ]
          },
          "source_sha256": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "gating_verdict": {
            "type": "object",
            "properties": {
              "substrate_gate_passed": {
                "type": "boolean"
              },
              "synthetic_padding_detected": {
                "const": false
              },
              "vep_clock_present": {
                "type": "boolean"
              }
            },
            "required": [
              "substrate_gate_passed",
              "synthetic_padding_detected",
              "vep_clock_present"
            ],
            "additionalProperties": false
          },
          "permissible_classification": {
            "enum": [
              "functional_rehab_source_review",
              "exploratory_biomarker_source_review",
              "none"
            ]
          },
          "prohibited_claims": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "validation_report": {
            "type": "object",
            "properties": {
              "cryptographic_hash": {
                "type": "string",
                "pattern": "^[a-f0-9]{64}$"
              },
              "canonical_json": {
                "type": "string"
              },
              "event_sha256": {
                "type": "string",
                "pattern": "^[a-f0-9]{64}$"
              },
              "invariants_checked": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string"
                    },
                    "status": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "name",
                    "status",
                    "message"
                  ],
                  "additionalProperties": false
                }
              },
              "row_count": {
                "type": [
                  "integer",
                  "null"
                ]
              },
              "scope": {
                "const": "SOURCE_MATRIX_INTEGRITY"
              },
              "clinical_claims_allowed": {
                "const": false
              }
            },
            "required": [
              "cryptographic_hash",
              "canonical_json",
              "event_sha256",
              "invariants_checked",
              "row_count",
              "scope",
              "clinical_claims_allowed"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "matrix_id",
          "run_id",
          "validation_status",
          "audit_status",
          "source_sha256",
          "gating_verdict",
          "permissible_classification",
          "prohibited_claims",
          "validation_report"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      }
    },
    {
      "name": "verify_dosimetric_vector",
      "title": "Verify units and declared dosimetric bounds",
      "description": "Check six caller-supplied research quantities against explicit caller-declared bounds: SPECT uptake (%ID/g), absorbed dose (Gy), thermal dose (CEM43 min), X-ray dose enhancement (ratio), histology volume (mm3), and normal-tissue dose (Gy). These are not interchangeable with biomarker endpoints or the normalized P3Q carrier. This is not a treatment safety approval.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "treatment_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "radionuclide": {
            "enum": [
              "199Au_pure",
              "198Au_199Au_mixed",
              "90Y",
              "186Re",
              "169Er"
            ]
          },
          "radionuclidic_purity_percent": {
            "type": "number",
            "minimum": 0,
            "maximum": 100
          },
          "state_vector": {
            "type": "object",
            "properties": {
              "u_spect_percent_id_g": {
                "type": "number",
                "minimum": 0
              },
              "absorbed_dose_gy": {
                "type": "number",
                "minimum": 0
              },
              "cem43_thermal_minutes": {
                "type": "number",
                "minimum": 0
              },
              "def_xray_ratio": {
                "type": "number",
                "minimum": 1
              },
              "v_histology_mm3": {
                "type": "number",
                "minimum": 0
              },
              "t_normal_tissue_gy": {
                "type": "number",
                "minimum": 0
              }
            },
            "required": [
              "u_spect_percent_id_g",
              "absorbed_dose_gy",
              "cem43_thermal_minutes",
              "t_normal_tissue_gy"
            ],
            "additionalProperties": false
          },
          "tissue_target": {
            "enum": [
              "glioblastoma_margin",
              "tnbc_micro_metastases",
              "rheumatoid_synovium",
              "vulnerable_plaque",
              "pancreatic_stroma"
            ]
          },
          "protocol_details": {
            "type": "object",
            "properties": {
              "protocol_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 160,
                "pattern": "^[A-Za-z0-9_.:-]+$"
              },
              "maximums": {
                "type": "object",
                "properties": {
                  "u_spect_percent_id_g": {
                    "type": "number",
                    "minimum": 0
                  },
                  "absorbed_dose_gy": {
                    "type": "number",
                    "minimum": 0
                  },
                  "cem43_thermal_minutes": {
                    "type": "number",
                    "minimum": 0
                  },
                  "def_xray_ratio": {
                    "type": "number",
                    "minimum": 1
                  },
                  "v_histology_mm3": {
                    "type": "number",
                    "minimum": 0
                  },
                  "t_normal_tissue_gy": {
                    "type": "number",
                    "minimum": 0
                  }
                },
                "required": [],
                "additionalProperties": false
              },
              "minimum_radionuclidic_purity_percent": {
                "type": "number",
                "minimum": 0,
                "maximum": 100
              }
            },
            "required": [
              "protocol_id",
              "maximums",
              "minimum_radionuclidic_purity_percent"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "treatment_id",
          "radionuclide",
          "radionuclidic_purity_percent",
          "state_vector",
          "tissue_target"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "treatment_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "verification_status": {
            "type": "boolean"
          },
          "boundary_invariant_status": {
            "enum": [
              "WITHIN_DECLARED_BOUNDS",
              "REJECTED",
              "UNVERIFIED"
            ]
          },
          "error_message": {
            "type": "string"
          },
          "invariant_violations": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "details": {
                  "type": "string"
                }
              },
              "required": [
                "name",
                "details"
              ],
              "additionalProperties": false
            }
          },
          "cryptographic_hash": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "canonical_json": {
            "type": "string"
          },
          "event_sha256": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "scope": {
            "const": "UNITS_AND_CALLER_DECLARED_BOUNDS"
          },
          "input_is_caller_supplied": {
            "const": true
          },
          "clinical_claims_allowed": {
            "const": false
          }
        },
        "required": [
          "treatment_id",
          "verification_status",
          "boundary_invariant_status",
          "error_message",
          "invariant_violations",
          "cryptographic_hash",
          "canonical_json",
          "event_sha256",
          "scope",
          "input_is_caller_supplied",
          "clinical_claims_allowed"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      }
    },
    {
      "name": "freeze_baseline_hash",
      "title": "Freeze a source-derived baseline",
      "description": "Freeze selected baseline columns from an already ingested source. Follow-up, outcome, change and delta columns are rejected. An existing seal cannot be replaced. Caller timestamps cannot backdate the server freeze or make retrospective evidence prospective.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "registry_id": {
            "enum": [
              "RRMS-1740",
              "REMY-VEP-001",
              "GOAU-199-001",
              "DISCOVERY"
            ]
          },
          "run_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "columns": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 160
            },
            "maxItems": 512,
            "uniqueItems": true,
            "minItems": 1
          },
          "identity_columns": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 160
            },
            "maxItems": 512,
            "uniqueItems": true
          },
          "expected_source_sha256": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "baseline_payload_raw": {
            "type": "string",
            "minLength": 1,
            "maxLength": 900000
          },
          "payload_encoding": {
            "enum": [
              "utf8",
              "base64"
            ]
          },
          "nonce": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "predicted_deltas": {
            "type": "object",
            "properties": {
              "target_metric": {
                "type": "string",
                "minLength": 1
              },
              "values": {
                "type": "array",
                "items": {
                  "type": "number"
                },
                "minItems": 1,
                "maxItems": 100000
              }
            },
            "required": [
              "target_metric",
              "values"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "registry_id",
          "run_id",
          "columns",
          "nonce"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "registry_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "run_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "hash": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "status": {
            "const": "BASELINE_FROZEN"
          },
          "freeze_status": {
            "const": "LOCKED"
          },
          "message": {
            "type": "string"
          },
          "source_sha256": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "frozen_at": {
            "type": "string"
          },
          "prediction_seal_hash": {
            "type": [
              "string",
              "null"
            ]
          },
          "unseal_permitted": {
            "const": false
          },
          "prospective_eligible": {
            "type": "boolean"
          },
          "clinical_claims_allowed": {
            "const": false
          }
        },
        "required": [
          "registry_id",
          "run_id",
          "hash",
          "status",
          "freeze_status",
          "message",
          "source_sha256",
          "frozen_at",
          "prediction_seal_hash",
          "unseal_permitted",
          "prospective_eligible",
          "clinical_claims_allowed"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      }
    },
    {
      "name": "ingest_trial_payload",
      "title": "Validate and triage a trial record",
      "description": "Check an anonymous structured record against an NCT identifier, caller-declared cohort arms and unit-specific numerical bounds. Quarantine seals retain only the input hash and rule codes, never the original sensitive record. Identifier scanning does not certify HIPAA compliance or treatment safety.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "record": {
            "type": "object",
            "maxProperties": 64
          },
          "trace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "protocol_details": {
            "type": "object",
            "properties": {
              "protocol_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 160,
                "pattern": "^[A-Za-z0-9_.:-]+$"
              },
              "allowed_arms": {
                "type": "array",
                "items": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 160
                },
                "maxItems": 32,
                "uniqueItems": true,
                "minItems": 1
              },
              "biomarker_bounds": {
                "type": "object",
                "minProperties": 1,
                "maxProperties": 64,
                "additionalProperties": {
                  "type": "object",
                  "properties": {
                    "min": {
                      "type": "number"
                    },
                    "max": {
                      "type": "number"
                    },
                    "unit": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 40
                    }
                  },
                  "required": [
                    "min",
                    "max",
                    "unit"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "protocol_id",
              "allowed_arms",
              "biomarker_bounds"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "record",
          "trace_id",
          "protocol_details"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "trace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[A-Za-z0-9_.:-]+$"
          },
          "projection_state": {
            "enum": [
              "ADMISSIBLE",
              "QUARANTINED"
            ]
          },
          "input_sha256": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "violations": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "disposition": {
            "enum": [
              "MANIFOLD_QUARANTINE",
              "PROTOCOL_DATA_ADMISSION"
            ]
          },
          "processed_payload": {
            "type": [
              "object",
              "null"
            ]
          },
          "scope": {
            "const": "DATA_SCHEMA_AND_CALLER_PROTOCOL_CHECKS"
          },
          "hipaa_compliance_certified": {
            "const": false
          },
          "clinical_claims_allowed": {
            "const": false
          },
          "cryptographic_hash": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          },
          "canonical_json": {
            "type": "string"
          },
          "event_sha256": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$"
          }
        },
        "required": [
          "trace_id",
          "projection_state",
          "input_sha256",
          "violations",
          "disposition",
          "processed_payload",
          "scope",
          "hipaa_compliance_certified",
          "clinical_claims_allowed",
          "cryptographic_hash",
          "canonical_json",
          "event_sha256"
        ],
        "additionalProperties": false,
        "$schema": "https://json-schema.org/draft/2020-12/schema"
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      }
    }
  ]
}
