import { useEffect, useState } from 'react'; import { useNavigate } from 'react-router-dom'; import { api } from '../services/api'; import { Patient } from '../types'; import './PatientsPage.css'; export function PatientsPage() { const [patients, setPatients] = useState([]); const [loading, setLoading] = useState(true); const [showNewPatient, setShowNewPatient] = useState(false); const [newPatientName, setNewPatientName] = useState(''); const navigate = useNavigate(); useEffect(() => { loadPatients(); }, []); const loadPatients = () => { api.listPatients() .then(res => setPatients(res.patients)) .finally(() => setLoading(false)); }; const handleCreatePatient = async () => { if (!newPatientName.trim()) return; const { patient } = await api.createPatient(newPatientName.trim()); setPatients(prev => [...prev, patient]); setNewPatientName(''); setShowNewPatient(false); navigate(`/chat/${patient.id}`); }; const handleDeletePatient = async (e: React.MouseEvent, patientId: string) => { e.stopPropagation(); if (!confirm('Delete this patient and all their data?')) return; await api.deletePatient(patientId); setPatients(prev => prev.filter(p => p.id !== patientId)); }; if (loading) { return (
Loading...
); } return (
{/* Hero Section */}

SkinProAI

Multimodal dermatological analysis powered by MedGemma and intelligent tool orchestration.

{/* Existing patients */} {patients.length > 0 && (

Recent Patients

{patients.map(patient => (
navigate(`/chat/${patient.id}`)} >
{patient.name}
))}
)} {/* How It Works */}

How It Works

1

Upload

Capture or upload a dermatoscopic or clinical image of the lesion.

2

Analyze

MedGemma examines the image and coordinates specialist tools for deeper insight.

3

Track

Monitor lesions over time with side-by-side comparison and change detection.

{/* About */}

About SkinProAI

Built for the Kaggle MedGemma Multimodal Medical AI Competition, SkinProAI explores how a foundation medical vision-language model can be augmented with specialised tools to deliver richer clinical insight.

At its core sits Google's MedGemma 4B, a multimodal model fine-tuned for medical image understanding. Rather than relying on the model alone, SkinProAI connects it to a suite of external tools via the Model Context Protocol (MCP) — including MONET feature extraction, ConvNeXt classification, Grad-CAM attention maps, and clinical guideline retrieval — letting the model reason across multiple sources before presenting a synthesised assessment.

MedGemma 4B MCP Tools MONET ConvNeXt Grad-CAM RAG Guidelines
{/* Disclaimer */}

Research prototype only. SkinProAI is an educational project and competition entry. It is not a medical device and must not be used for clinical decision-making. Always consult a qualified healthcare professional for diagnosis and treatment.

{/* New Patient Modal */} {showNewPatient && (
setShowNewPatient(false)}>
e.stopPropagation()}>

New Patient

setNewPatientName(e.target.value)} onKeyDown={e => e.key === 'Enter' && handleCreatePatient()} autoFocus />
)}
); }