hotfix on MediCopilot Business Operation configuration
Our project, Iris-MediCoPilot, is designed to optimize patient clinical outcomes by reducing hospitalization time and supporting the development of resident and novice physicians. Additionally, it contributes to reducing financial waste in the healthcare system by improving the monitoring of pregnant patients, thereby decreasing risks and enhancing their safety.
To achieve this, patients can conveniently describe their symptoms through a user-friendly Telegram bot. The project then leverages a comprehensive medical database to analyze the information. Additionally, the bot strategically asks clarifying questions to gather further details and refine the potential diagnosis. If the Iris-MediCoPilot identifies a potential health risk, it will advise the patient to seek medical attention at a hospital. Furthermore, the conversation history is automatically forwarded to a doctor acting as a “co-pilot” or “sidekick,” providing valuable insights to support physician decision-making.
This project leverages cutting-edge technologies to streamline patient care and support physicians. Here’s a breakdown of the process:
User-Friendly Patient Interaction:
Patients conveniently report symptoms through a Telegram bot.
Intelligent Symptom Analysis:
The system utilizes a vector search database to analyze the reported symptoms. This database efficiently retrieves similar cases based on underlying semantic relationships.
RAG (Retrieval-Augmented Generation) technology empowers the system to access and integrate relevant medical knowledge from a supplementary knowledge base.
Prompt engineering techniques, including role-playing and prompt chaining, guide Large Language Models (LLMs) like ChatGPT 3.5 to ask clarifying questions and delve deeper into the patient’s situation.
Refining the Diagnosis:
LLMs analyze the extracted features from the vector search and the retrieved medical knowledge.
To compensate for the LLM’s potential lack of specialized medical knowledge, the system provides contextually embedded information to guide their responses.
In this initial version, synthetic data based on common pregnancy risks and diseases is used to train the LLMs.
Risk Assessment and Recommendation:
Based on the analysis, the system assesses potential health risks.
If a risk is identified, the patient is advised to seek medical attention at a hospital.
The conversation history is automatically forwarded to a doctor acting as a “co-pilot” or “sidekick” to provide additional insights and support their decision-making.
This combined approach aims to improve the accuracy of diagnoses, reduce unnecessary hospitalizations, and enhance patient care.
Make sure you have git and Docker desktop installed.
To utilize the Large Language Model (LLM) service, you’ll need an API key. Currently, the project supports OpenAI’s LLM service.
Obtain your OpenAI API key by creating an account on their platform.
Environment variables are used to store sensitive information like API keys and tokens. These variables need to be set before building the Docker image.
There are two ways to configure these variables:
When launching the Docker container, you can set the OPENAI_KEY
and TELEGRAM_TOKEN
the environment variables using the -e flag:
# OpenAI API key
export OPENAI_KEY=$OPENAI_KEY
# Telegram bot Token
export TELEGRAM_TOKEN=$TELEGRAM_TOKEN
Clone/git pull the repo into any local directory
$ git clone https://github.com/musketeers-br/iris-medicopilot.git
Open the terminal in this directory and run:
$ docker-compose build
$ docker-compose up -d
Open IRIS installation with IPM client installed. Call in any namespace:
USER>zpm "install iris-medicopilot"
Or call the following for installing programmatically:
set sc=$zpm("install iris-medicopilot")
This section outlines the steps to set up and run the service in production.
As with any new technology, there are limitations to consider:
Experimental Phase:
The project is currently undergoing testing and refinement. It’s important to acknowledge that the system might generate inaccurate or unexpected results. Our primary focus at this stage is to validate the core concept of using LLMs to aid healthcare professionals.
Limited Data Complexity:
Up to this point, the project has primarily focused on working with basic and well-defined structured data. Integrating more intricate and nuanced data types requires further development.
Data Privacy and Security:
This initial version does not comprehensively address crucial aspects of data privacy and security. These are critical considerations that will be addressed in future research and development phases.
We are committed to responsible development and will prioritize these limitations in future iterations of the project.
This application uses: