How 31133498/dermascanai works
Project type and purpose
• From the file tree and README, DermaScanAI is a single-page React application (frontend) that enables users to upload skin images and receive automated disease-detection results from an external AI service (EfficientNetB3-based).
File structure
• Top‐level files:
• .env, .gitignore, README.md – configuration and documentation
• package.json – lists React and build dependencies
• public/ – static assets (index.html, manifest.json) served by the web host
• src/ – application source code
• index.js, App.js – entry points for the React SPA
• components/ – React components organized by feature (MainPage, AIDoctorPage, DermaScan ScannerPage, AboutPage, Header)
• services/geminiService.js – abstraction layer for calling the remote AI inference API
README for additional insights
• DermaScan AI uses deep learning (transfer learning on EfficientNetB3) to analyze user-uploaded skin lesion images
• It’s intended for both end users and medical professionals
a. Main components:
1) Client (User’s Browser)
2) React SPA (served via a static host/CDN)
3) Service Layer (geminiService.js)
4) AI Inference Service (EfficientNetB3 model server or managed cloud AI endpoint)
5) (Optional) Persistence Layer (database or logging service for storing user sessions or results)
6) (Optional) CI/CD & Hosting Platform (e.g., Netlify, Vercel, GitHub Actions)
b. Relationships & data flow:
• Browser requests index.html + JS/CSS from the static host
• User interacts with React UI → selects or captures an image
• UI invokes geminiService.uploadImage(image)
• geminiService makes an HTTP POST to the AI Inference Service endpoint
• Inference Service loads the image, runs EfficientNetB3 classifier, returns prediction + confidence
• geminiService returns the result to the UI → React component updates state and renders the diagnosis
• (Optional) UI or service layer logs the transaction to the Persistence Layer
c. Architectural patterns & design principles:
• Single Page Application (SPA) for a seamless client experience
• Component‐based UI structure for maintainability
• Service abstraction layer separates UI from network logic
• Externalized AI inference as a microservice, enabling model updates without touching the client
d. Key technologies/frameworks:
• React (create-react-app) for building the SPA
• CSS modules for scoped styling per component
• geminiService.js as the API client (fetch or Axios under the hood)
• EfficientNetB3 model hosted on a Python/Flask or cloud function endpoint
• Optional: Node.js or serverless functions for handling uploads and pre/post‐processing