# srisaravanan55/medicheck-ai architecture

> Architecture diagram of the GitHub repository srisaravanan55/medicheck-ai, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-19). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/srisaravanan55/medicheck-ai
- Repository: https://github.com/srisaravanan55/medicheck-ai

## Overview

This is a Flask medical self-care app: users submit symptoms for ranked condition matches and advice, with Tamil support; the app also exposes BMI, symptom-diary, history/analytics, and PDF-report capabilities. The sampled code shows symptom analysis translating and embedding input before searching an in-memory vector index. Other capabilities are visible only in partial excerpts, so their internal wiring is not asserted. The tree includes JSON state files and a browser page, but the excerpts do not establish how they connect to the routes.

Main entry points: [`app.py`](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py) (Flask app), [`index.html`](https://github.com/srisaravanan55/medicheck-ai/blob/main/index.html) (Web interface)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web application"]
  node_browser["Web interface<br/>[index.html]"]
  node_flask["Flask app<br/>[app.py]"]
end

subgraph group_medical["Medical matching"]
  node_analysis["Symptom analysis<br/>[app.py]"]
  node_translation["Tamil translation<br/>[app.py]"]
  node_encoder["Text embeddings<br/>[app.py]"]
  node_vector_db[("Vector search<br/>[app.py]")]
  node_knowledge["Medical knowledge<br/>[app.py]"]
end

subgraph group_records["Records and reports"]
  node_bmi["BMI assessment<br/>[app.py]"]
  node_diary["Symptom diary<br/>[app.py]"]
  node_history["History analytics<br/>[app.py]"]
  node_pdf["PDF reports<br/>[app.py]"]
end

node_user(("User"))

node_user -.->|"uses"| node_browser
node_browser -.->|"submits requests"| node_flask
node_flask -.->|"routes symptoms"| node_analysis
node_analysis -->|"translates input"| node_translation
node_analysis -->|"encodes input"| node_encoder
node_analysis -->|"searches matches"| node_vector_db
node_vector_db -->|"returns payloads"| node_knowledge
node_flask -.->|"provides assessment"| node_bmi
node_flask -.->|"provides diary"| node_diary
node_flask -.->|"provides analytics"| node_history
node_flask -.->|"generates reports"| node_pdf

click node_browser "https://github.com/srisaravanan55/medicheck-ai/blob/main/index.html"
click node_flask "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_analysis "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_translation "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_encoder "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_vector_db "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_knowledge "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_bmi "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_diary "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_history "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"
click node_pdf "https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_browser,node_flask,node_user toneBlue
class node_analysis,node_translation,node_encoder,node_vector_db,node_knowledge toneAmber
class node_bmi,node_diary,node_history,node_pdf toneMint
```

## Components

### Web application

- [Web interface](https://github.com/srisaravanan55/medicheck-ai/blob/main/index.html): `index.html`
- [Flask app](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`

### Medical matching

- [Symptom analysis](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`
- [Tamil translation](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`
- [Text embeddings](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`
- [Vector search](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`
- [Medical knowledge](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`

### Records and reports

- [BMI assessment](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`
- [Symptom diary](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`
- [History analytics](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`
- [PDF reports](https://github.com/srisaravanan55/medicheck-ai/blob/main/app.py): `app.py`

### Other components

- **User**

## Connections

- User → Web interface: uses
- Web interface → Flask app: submits requests
- Flask app → Symptom analysis: routes symptoms (evidence: `app.py`)
- Symptom analysis → Tamil translation: translates input (evidence: `app.py`)
- Symptom analysis → Text embeddings: encodes input (evidence: `app.py`)
- Symptom analysis → Vector search: searches matches (evidence: `app.py`)
- Vector search → Medical knowledge: returns payloads (evidence: `app.py`)
- Flask app → BMI assessment: provides assessment (evidence: `app.py`)
- Flask app → Symptom diary: provides diary (evidence: `app.py`)
- Flask app → History analytics: provides analytics (evidence: `app.py`)
- Flask app → PDF reports: generates reports (evidence: `app.py`)
