Skip to content

Aniketsy/Health_AI_Platform

Repository files navigation

Health AI Platform

Features

  • Skin cancer detection using a trained Keras model
  • Mental health assessment and recommendations
  • Resource API for short videos (YouTube integration for skin cancer and mental health)

Skin Cancer Detection API

Model Setup

  1. Export your trained Keras model as skin_cancer_model.keras.
  2. Create a folder named ml-models at the root of your project.
  3. Place your model file at:
    ml-models/skin_cancer_model.keras
    

Backend API

  • Endpoint: POST /api/skin-assessment/detect
  • Request: Send a multipart/form-data POST request with an image file under the field name image.
  • Response:
    {
      "prediction": "benign", // or "malignant"
      "confidence": 0.87
    }
  • Example cURL:
    curl -X POST http://localhost:3000/api/skin-assessment/detect \
      -F "image=@/path/to/your/image.jpg"

YouTube Resource API

  • Endpoint: GET /api/resources
  • Returns a list of recent public YouTube videos about skin cancer or mental health (auto-fetched using the YouTube Data API).
  • To use, set your YouTube Data API key in pages/api/resources/index.ts.
  • Example response:
    [
      {
        "id": "QZCGhY5tZ0w",
        "title": "Skin Cancer Awareness",
        "description": "A short YouTube video about skin cancer signs and prevention.",
        "url": "https://www.youtube.com/watch?v=QZCGhY5tZ0w",
        "category": "skin-cancer",
        "tags": [],
        "thumbnail": "https://img.youtube.com/vi/QZCGhY5tZ0w/0.jpg",
        "author": "Skin Health Channel"
      }
    ]

Dependencies

  • @tensorflow/tfjs-node
  • sharp
  • formidable
  • node-fetch (for YouTube API)

Setup

  1. Install dependencies:
    npm install
  2. Add your Keras model as described above.
  3. (Optional) Add your YouTube Data API key for dynamic video resources.
  4. Start the development server:
    npm run dev

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published