Inspiration

Every day, clinicians face a painful reality: their patients may qualify for life-changing clinical trials, but nobody has time to find them.

Manually screening ClinicalTrials.gov — over 500,000 registered studies — against a single patient's medical history can take hours. Most clinicians simply don't have those hours during a consultation. Patients miss trials. Trials miss patients. Research stalls.

We built TrialBridge to close that gap — automatically, in seconds, directly from the patient's existing FHIR record.

What it does

How we built it

TrialBridge is a SHARP-on-MCP compliant MCP server that connects to any FHIR-compatible EHR and matches patients to recruiting clinical trials on ClinicalTrials.gov — with no manual data entry required.

The agent reads the patient's active conditions, age, and sex directly from their FHIR record via secure context headers, then chains five specialized tools to deliver a clinician-ready match report in seconds:

  1. search_clinical_trials — searches ClinicalTrials.gov for recruiting trials matching the patient's live FHIR profile

  2. evaluate_trial_eligibility — evaluates a specific trial against the patient's conditions, medications, age, and sex — returning LIKELY ELIGIBLE, UNCERTAIN, or LIKELY INELIGIBLE with full reasoning

  3. get_trial_details — fetches complete trial protocol, eligibility criteria, outcomes, locations, and contact details by NCT ID

  4. explain_eligibility_criteria — translates dense clinical trial eligibility text into plain language any patient can understand

  5. summarize_match_report — generates a structured clinical handoff note with top candidates, trials needing more information, and recommended next steps

    Challenges we ran into

  6. FHIR condition resources from real EHRs include SNOMED CT qualifiers in display strings (e.g. "Hypertension (disorder)") that don't match how ClinicalTrials.gov describes conditions. We solved this with dynamic regex-based cleaning at runtime — no hardcoded medical terms anywhere in the codebase.

  • ClinicalTrials.gov age eligibility fields use inconsistent formats ("18 Years", "6 Months", "N/A") requiring a robust dynamic parser that handles all unit types and gracefully defaults to no limit when fields are missing.

  • The SHARP-on-MCP specification requires FHIR context discovery in the initialize response — implementing this correctly was critical for Prompt Opinion platform compatibility.

    Accomplishments that we're proud of

What we learned

  • The gap between "technically correct FHIR" and "practically useful FHIR" is significant — real EHR data is messier than the spec suggests
  • SHARP-on-MCP is a well-designed specification that makes healthcare agent interoperability genuinely achievable on open standards
  • Clinical trial eligibility criteria are written for regulators, not clinicians — the plain language translation tool addresses a real daily frustration for care teams ## What's next for Phoenix
  • Support for additional FHIR resources: MedicationStatement, AllergyIntolerance, Observation (lab values) for deeper eligibility screening
  • Geographic filtering to surface trials near the patient's location
  • Integration with SMART on FHIR launch for direct EHR embed
  • Expanded plain language glossary covering more disease domains
  • A2A agent wrapper enabling TrialBridge to participate in multi-agent orchestration workflows

Built With

Share this project:

Updates