A Privacy-Preserving Medical AI Framework
PRIVATEMED is a medical AI model with dual-level explainability for privacy-preserving medical image analysis. The project integrates DeepSeek-VL2 with LoRA fine-tuning to create a powerful vision-language model specifically designed for medical applications.
PRIVATEMED is a medical AI model with dual-level explainability:
<think> tagsThis approach directly addresses the challenge of model opacity, fostering trust and enabling informed clinical oversight.
Architectural separation enhances privacy by design, preventing image data exposure during diagnostic inference.
Dual-level explainability through detailed descriptions and explicit reasoning process.
Efficient design enables local deployment within healthcare institution's secure environment.
Built using fine-tuned, publicly available open-source AI models for transparency and auditability.
A Vision Language Model (VLM), fine-tuned using advanced methods focused on descriptive quality, analyzes the input medical image. It generates an exhaustive, structured, and strictly objective textual description of all discernible visual findings.
A separate, computationally efficient Language Model (LLM) receives only the detailed textual description produced by Stage 1. Based exclusively on this rich text, the LLM performs diagnostic classification or assessment.
See PRIVATEMED in action with real medical imaging examples.
Detailed description and reasoning for a fundus photograph with features suggesting glaucoma.
View Example
Detailed description and reasoning for a chest X-ray showing various findings.
View ExampleDetailed reports on PRIVATEMED's methodology, results, and implications.
A Privacy-Preserving, Explainable Framework for Medical Image Analysis Using Fine-Tuned Open-Source Models via Decoupled Description and Inference
Read PaperDetailed performance metrics across different medical imaging tasks and datasets.
View AnalysisInformation about PRIVATEMED's compliance with privacy regulations and medical standards.
PRIVATEMED's architecture is designed with privacy as a core principle. The decoupled design ensures sensitive image data remains separate from the diagnostic inference process.
Learn MoreInformation about PRIVATEMED's adherence to medical AI standards and best practices for clinical applications.
Learn MoreTechnical documentation for MDR compliance, risk management, and performance verification in accordance with regulatory requirements for PRIVATEMED.
View Documentationgit clone https://github.com/samihalawa/2025_FINAL_APOLO_Modelo_Medico.git
cd 2025_FINAL_APOLO_Modelo_Medico
chmod +x setup_privatemed_deepseek.sh
./setup_privatemed_deepseek.sh
python packages/core/privatemed-inference/privatemed_deepseek_vl2_inference.py \
--base_model_path "deepseek-ai/deepseek-vl2-tiny" \
--images "resources/test-data/sample_xray.jpg" \
--output_file "privatemed_output.txt"