Inspiration

Matching patients to clinical trials is still slow, manual, and inefficient—especially for emerging nano-pharma treatments. We were inspired by the potential of LLMs and modular agent frameworks like MCP (Model Context Protocol) to bridge the gap between symptoms, biomarkers, and live trial availability—faster than ever before.


What it does

TrialMCP takes a user's symptoms as input, extracts medical concepts (using BioClinicalBERT), maps them to relevant biomarkers, and matches those to live clinical trials via real-time integrations with ClinicalTrials.gov, DrugBank, and more. It shows:

  • A transparent chain-of-thought for how it made each match
  • Citations from tools and scientific sources
  • An intuitive frontend for exploring model behavior and interacting with results

How we built it

  • Used BioClinicalBERT to extract symptoms and convert them into OMOP-standardized medical terms
  • Built a TrialGPT+MCP agent to orchestrate tools like DrugBank lookup, Trial search, and compliance auditing
  • Integrated ClinicalTrials.gov, DrugBank, and OpenTargets via custom MCP tool wrappers
  • Created a Next.js frontend to demo TrialMCP's capabilities with graphs, visualizations, and an explainable interface
  • Used FastAPI + FastMCP to host the backend as a microservice
  • Implemented HIPAA/GDPR compliance automation via redaction tools and blockchain-based audit trails

Challenges we ran into

  • Adapting TrialGPT's prompt-based design into an MCP-compatible orchestration framework
  • Getting high-quality mappings between patient-language symptoms and biomarkers with trial relevance
  • Ensuring explainability without overwhelming users—designing UI that balances complexity with clarity
  • Handling real-time API calls while maintaining chain-of-thought observability and output traceability
  • Ensuring the system was modular and extensible, without overengineering during a short hackathon window

Accomplishments that we're proud of

  • Built the world’s most transparent symptom-to-trial matcher, with chain-of-thought + citation trails
  • Enhanced state-of-the-art TrialGPT with modularity, observability, and real-world APIs
  • Created a full-stack prototype in under 6 hours, combining LLMs, MCP, healthcare ontologies, and rich UX
  • Demonstrated significant improvements in trial relevancy, cutting matching noise and surfacing rare trial fits

What I learned

  • How to integrate LLMs with biomedical ontologies and real-world constraints
  • The power of modular tool orchestration (MCP) for explainable, composable AI
  • How to make AI models not only powerful, but trustworthy, transparent, and compliant
  • Designing an interface that helps both patients and researchers understand what's going on under the hood

What's next for TrialMCP

  • Add support for EMRs, genomics, and patient registry uploads
  • Work with nano-pharma companies to improve trial targeting and feasibility scoring
  • Expand our tool library with eligibility parsers, genomics matchers, and IRB-aware filters
  • Publish our findings and open source key parts of the platform
  • Explore commercial pilot programs with CROs, pharma sponsors, and digital health providers

Built With

Share this project:

Updates