In highly regulated environments where clinical data confidentiality is paramount, traditional AI coding assistants like ChatGPT present two significant challenges: they require data exposure to external systems, and they lack context-specific knowledge of organizational data structures and standards. We present an innovative solution that bridges this gap: a secure, context-aware application that combines large language models (LLMs) with clinical data standards to assist R users in analyzing confidential healthcare data. Our package, built using the open-source project {gptstudio} and Apollo (an internal qualified LLM service) and deployed on Posit Workbench, has the ability to reference our organization’s clinical data standards and other internal documentation. This enables it to generate and execute R code that is precisely tailored to our data structures, variable definitions, and analytical requirements. The system can help the user perform various tasks including exploratory data analysis, data quality checks, putting together a first draft for a {teal} or DaVinci Shiny application, as well as generate TLGs for clinical reporting.

We will demonstrate how this tool serves dual purposes: accelerating the work of experienced R programmers while simultaneously functioning as an educational platform for R learners working with clinical data. Unlike generic AI coding assistants, our solution provides contextually relevant code suggestions that align with organizational standards and practices, all while maintaining data privacy and regulatory compliance. This presentation will showcase real-world applications, discuss the technical architecture, and explore how similar systems could be implemented in other organizations working with sensitive data.
Steven Brooks | Pietro Mascheroni | Xiecheng Gu
Boehringer Ingelheim | Boehringer Ingelheim | Boehringer Ingelheim
{meRlin} - context-aware AI assistant for clinical programming
In highly regulated environments where clinical data confidentiality is paramount, traditional AI coding assistants like ChatGPT present two significant challenges they require data exposure to external systems, and they lack context-specific knowledge of organizational data structures and standards. We present an innovative solution that bridges this gap a secure, context-aware application that combines large language models (LLMs) with clinical data standards to assist R users in analyzing confidential healthcare data. Our package, built using the open-source project  gptstudio  and Apollo (an internal qualified LLM service) and deployed on Posit Workbench, has the ability to reference our organization’s clinical data standards and other internal documentation. This enables it to generate and execute R code that is precisely tailored to our data structures, variable definitions, and analytical requirements. The system can help the user perform various tasks including exploratory data analysis, data quality checks, putting together a first draft for a  teal  or DaVinci Shiny application, as well as generate TLGs for clinical reporting.  We will demonstrate how this tool serves dual purposes accelerating the work of experienced R programmers while simultaneously functioning as an educational platform for R learners working with clinical data. Unlike generic AI coding assistants, our solution provides contextually relevant code suggestions that align with organizational standards and practices, all while maintaining data privacy and regulatory compliance. This presentation will showcase real-world applications, discuss the technical architecture, and explore how similar systems could be implemented in other organizations working with sensitive data.