# sunkinani8-max/nexusops-ai architecture

> Architecture diagram of the GitHub repository sunkinani8-max/nexusops-ai, 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/sunkinani8-max/nexusops-ai
- Repository: https://github.com/sunkinani8-max/nexusops-ai

## Overview

NexusOps AI combines operational-request routing with a Java/Maven project analysis workspace. A user works through the React dashboard to create and track requests, connect a project, inspect its file-list signals, analyze build logs, request deterministic error explanations, and inspect public GitHub metadata. The FastAPI application owns these operations and persists requests, projects, and build runs through SQLAlchemy models. README documents the broader dashboard capabilities; source excerpts show the frontend API calls, backend analysis logic, persistence wiring, and GitHub API request.

Main entry points: [`backend/main.py`](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py) (FastAPI Operations), [`backend/database.py`](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/database.py) (SQLAlchemy Models), [`frontend/src/App.jsx`](https://github.com/sunkinani8-max/nexusops-ai/blob/main/frontend/src/App.jsx) (React Dashboard)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ui["Dashboard"]
  node_dashboard["React Dashboard<br/>[App.jsx]"]
end

subgraph group_workflow["Operations and Analysis"]
  node_api["FastAPI Operations<br/>[main.py]"]
  node_requests["Request Routing<br/>[main.py]"]
  node_projects["Project Connection<br/>[main.py]"]
  node_structure["Structure Analysis<br/>[main.py]"]
  node_builds["Build Analysis<br/>[main.py]"]
  node_explanations["Error Explanations<br/>[main.py]"]
end

subgraph group_persistence["Persistence"]
  node_models["SQLAlchemy Models<br/>[database.py]"]
  node_database[("SQL Database<br/>[database.py]")]
end

subgraph group_integrations["External Integration"]
  node_github["GitHub Inspection<br/>[main.py]"]
end

node_user(("Developer"))
node_github_api["GitHub REST API"]

node_user -->|"uses"| node_dashboard
node_dashboard -->|"calls API"| node_api
node_api -->|"routes requests"| node_requests
node_api -->|"routes projects"| node_projects
node_api -->|"analyzes files"| node_structure
node_api -->|"analyzes logs"| node_builds
node_api -->|"explains errors"| node_explanations
node_api -->|"inspects repositories"| node_github
node_requests -->|"persists requests"| node_models
node_projects -->|"persists projects"| node_models
node_builds -->|"persists runs"| node_models
node_models -->|"stores records"| node_database
node_github -->|"fetches metadata"| node_github_api

click node_dashboard "https://github.com/sunkinani8-max/nexusops-ai/blob/main/frontend/src/App.jsx"
click node_api "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py"
click node_requests "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py"
click node_projects "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py"
click node_structure "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py"
click node_builds "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py"
click node_explanations "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py"
click node_github "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py"
click node_models "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/database.py"
click node_database "https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/database.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_dashboard toneBlue
class node_api,node_requests,node_projects,node_structure,node_builds,node_explanations toneAmber
class node_models,node_database,node_github_api toneMint
class node_github toneRose
class node_user toneIndigo
```

## Components

### Dashboard

- [React Dashboard](https://github.com/sunkinani8-max/nexusops-ai/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`

### Operations and Analysis

- [FastAPI Operations](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py): `backend/main.py`
- [Request Routing](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py): `backend/main.py`
- [Project Connection](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py): `backend/main.py`
- [Structure Analysis](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py): `backend/main.py`
- [Build Analysis](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py): `backend/main.py`
- [Error Explanations](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py): `backend/main.py`

### Persistence

- [SQLAlchemy Models](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/database.py): `backend/database.py`
- [SQL Database](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/database.py): `backend/database.py`

### External Integration

- [GitHub Inspection](https://github.com/sunkinani8-max/nexusops-ai/blob/main/backend/main.py): `backend/main.py`

### Other components

- **Developer**
- **GitHub REST API**

## Connections

- Developer → React Dashboard: uses (evidence: `README.md`)
- React Dashboard → FastAPI Operations: calls API (evidence: `frontend/src/App.jsx`)
- FastAPI Operations → Request Routing: routes requests (evidence: `README.md`)
- FastAPI Operations → Project Connection: routes projects (evidence: `backend/main.py`)
- FastAPI Operations → Structure Analysis: analyzes files (evidence: `backend/main.py`)
- FastAPI Operations → Build Analysis: analyzes logs (evidence: `backend/main.py`)
- FastAPI Operations → Error Explanations: explains errors (evidence: `backend/main.py`)
- FastAPI Operations → GitHub Inspection: inspects repositories (evidence: `backend/main.py`)
- Request Routing → SQLAlchemy Models: persists requests (evidence: `README.md`)
- Project Connection → SQLAlchemy Models: persists projects (evidence: `backend/main.py`)
- Build Analysis → SQLAlchemy Models: persists runs (evidence: `backend/main.py`)
- SQLAlchemy Models → SQL Database: stores records (evidence: `backend/database.py`)
- GitHub Inspection → GitHub REST API: fetches metadata (evidence: `backend/main.py`)
