Conceptual deck · QC'd build, October 2026

The Four-Tier Pipeline

Conceptual deck · QC'd build, October 2026 Companion to Deck B — Implementation Walkthrough and the runnable apps in ../.

1 — Scope

2 — A chain of contracts, not one model

3 — The four tiers, named and identified

TierProductWhat it is, in one lineHands forward
Tier 1eCRF intake / normalizer (the document-mode front-end is LiteParse, not exercised here)aligns each incoming row to its participant, copies the verbatim and every field through unchanged, and discovers which columns to scan by content — every non-numeric column — rather than a name-based rulethe untouched verbatim; the untouched free-text strings; the detected column list
Tier 2Cactus Needle3a Laddered Simple Attention Network on CPU/NPU that does Pydantic-schema entity extraction and encodes the verbatim to a 3072-dim unit vector (its own general-purpose embedding, not a biomedical encoder such as SapBERT), retrieving the nearest MedDRA terms from an HNSW inner-product graphcandidate terms with their full hierarchy path (LLT→PT→HLT→HLGT→SOC) + closeness numbers; identifier spans + type + in-field offsets
Tier 3Layaa non-autoregressive classifier (ModernBERT backbone + decision head) that answers fixed yes/no, rating and pick questions about a string in one pass (about 0.3 s per question on a 4-vCPU CPU, measured) and returns probabilities calibrated by a temperature fitted on labeled dataP(direct PHI), P(re-identification risk); the ambiguity scalar the coding re-ranker consumes
Tier 4XGBoosta boosted-tree ensemble (under 10 ms per record, measured) that reads only the named columns from Tiers 1–3 and applies an explicit, movable rule — re-rank + gate for coding, per-span redaction for PHIcoded fields + status; scrubbed field copies + per-row flag

4 — Tier 1 · eCRF intake & normalization

5 — Tier 2 · Cactus Needle3 — retrieval & extraction

6 — Tier 3 · Laya — context & calibration

7 — Tier 4 · XGBoost — the two decision heads

8 — Why the tiers are separate

9 — Governance and limits