# vikramadityatheking/legacy-codebase-modernizer architecture

> Architecture diagram of the GitHub repository vikramadityatheking/legacy-codebase-modernizer, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-14). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/vikramadityatheking/legacy-codebase-modernizer
- Repository: https://github.com/vikramadityatheking/legacy-codebase-modernizer

## Overview

This repository is a browser-hosted legacy-code modernization demo. A user supplies or selects legacy source, the UI classifies it, and a documented four-agent workflow extracts business logic, generates Python/FastAPI, reviews security, and validates parity. Security findings can return the candidate to the Architect for revision. The UI presents generated code and review artifacts alongside architecture, metrics, evaluation, and deliverables tabs. The README is the only available relationship evidence; implementation details and internal call paths in index.html could not be verified.

Main entry points: [`index.html`](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html) (Code workspace), [`samples`](https://github.com/vikramadityatheking/legacy-codebase-modernizer/tree/main/samples) (Legacy sample library)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workspace["Browser workspace"]
  node_workspace["Code workspace<br/>[index.html]"]
  node_classifier["Source classifier<br/>[index.html]"]
  node_dashboard["Results dashboard<br/>[index.html]"]
end

subgraph group_agents["Modernization agents"]
  node_archeologist["Archeologist<br/>[index.html]"]
  node_logicmap["Structured logic map<br/>[index.html]"]
  node_architect["Architect<br/>[index.html]"]
  node_modernized["Python / FastAPI output<br/>[index.html]"]
end

subgraph group_review["Review and results"]
  node_warden["Security Warden<br/>[index.html]"]
  node_securityfindings["Security findings<br/>[index.html]"]
  node_critic["Validation Critic<br/>[index.html]"]
  node_validation["Parity and drift review<br/>[index.html]"]
  node_artifacts["Review artifacts<br/>[index.html]"]
  node_metrics["Metrics and evaluation<br/>[index.html]"]
  node_deliverables["Deliverables tab<br/>[index.html]"]
end

subgraph group_integrations["Model and inputs"]
  node_samples["Legacy sample library"]
  node_gemini["Gemini API"]
end

node_user(("User"))

node_user -->|"provides source"| node_workspace
node_samples -->|"loads sample"| node_workspace
node_workspace -->|"classifies source"| node_classifier
node_classifier -->|"routes source"| node_archeologist
node_archeologist -->|"extracts rules"| node_logicmap
node_logicmap -->|"hands off"| node_architect
node_architect -->|"generates code"| node_modernized
node_modernized -->|"submits candidate"| node_warden
node_warden -->|"produces review"| node_securityfindings
node_securityfindings -->|"returns for remediation"| node_architect
node_modernized -->|"reviews revised output"| node_critic
node_critic -->|"checks parity"| node_validation
node_modernized -->|"surfaces output"| node_dashboard
node_securityfindings -->|"surfaces review"| node_artifacts
node_validation -->|"surfaces review"| node_artifacts
node_dashboard -->|"shows metrics"| node_metrics
node_dashboard -->|"shows deliverables"| node_deliverables
node_workspace -->|"calls generateContent"| node_gemini
node_workspace -->|"refreshes models"| node_gemini

click node_workspace "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_classifier "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_archeologist "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_logicmap "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_architect "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_modernized "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_warden "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_securityfindings "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_critic "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_validation "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_dashboard "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_artifacts "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_metrics "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_deliverables "https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html"
click node_samples "https://github.com/vikramadityatheking/legacy-codebase-modernizer/tree/main/samples"

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_workspace,node_classifier,node_dashboard,node_user toneBlue
class node_archeologist,node_logicmap,node_architect,node_modernized toneAmber
class node_warden,node_securityfindings,node_critic,node_validation,node_artifacts,node_metrics,node_deliverables toneMint
class node_samples,node_gemini toneRose
```

## Components

### Browser workspace

- [Code workspace](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Source classifier](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Results dashboard](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`

### Modernization agents

- [Archeologist](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Structured logic map](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Architect](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Python / FastAPI output](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`

### Review and results

- [Security Warden](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Security findings](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Validation Critic](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Parity and drift review](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Review artifacts](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Metrics and evaluation](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`
- [Deliverables tab](https://github.com/vikramadityatheking/legacy-codebase-modernizer/blob/main/index.html): `index.html`

### Model and inputs

- [Legacy sample library](https://github.com/vikramadityatheking/legacy-codebase-modernizer/tree/main/samples): `samples`
- **Gemini API**

### Other components

- **User**

## Connections

- User → Code workspace: provides source (evidence: `README.md`)
- Legacy sample library → Code workspace: loads sample (evidence: `README.md`)
- Code workspace → Source classifier: classifies source (evidence: `README.md`)
- Source classifier → Archeologist: routes source (evidence: `README.md`)
- Archeologist → Structured logic map: extracts rules (evidence: `README.md`)
- Structured logic map → Architect: hands off (evidence: `README.md`)
- Architect → Python / FastAPI output: generates code (evidence: `README.md`)
- Python / FastAPI output → Security Warden: submits candidate (evidence: `README.md`)
- Security Warden → Security findings: produces review (evidence: `README.md`)
- Security findings → Architect: returns for remediation (evidence: `README.md`)
- Python / FastAPI output → Validation Critic: reviews revised output (evidence: `README.md`)
- Validation Critic → Parity and drift review: checks parity (evidence: `README.md`)
- Python / FastAPI output → Results dashboard: surfaces output (evidence: `README.md`)
- Security findings → Review artifacts: surfaces review (evidence: `README.md`)
- Parity and drift review → Review artifacts: surfaces review (evidence: `README.md`)
- Results dashboard → Metrics and evaluation: shows metrics (evidence: `README.md`)
- Results dashboard → Deliverables tab: shows deliverables (evidence: `README.md`)
- Code workspace → Gemini API: calls generateContent (evidence: `README.md`)
- Code workspace → Gemini API: refreshes models (evidence: `README.md`)
