# venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator architecture

> Architecture diagram of the GitHub repository venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-08-14). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator
- Repository: https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator

## Overview

#### Purpose
This repository is a lecture voice-to-notes generator. It accepts recorded lecture media, converts speech to text, and is intended to produce study-oriented outputs such as concise notes, quizzes, or flashcards using AI services.

#### Application Entry Points
- Backend service entry point: `backend/app.py`
- Frontend browser entry point: `frontend/src/main.jsx`, which mounts the main UI in `frontend/src/App.jsx`
- The frontend is a Vite-based client application, configured by `frontend/vite.config.js`.
- A standalone sample-media generator exists at `create_sample_lecture.py`.

#### Frontend Interaction Layer
The browser UI is concentrated in `frontend/src/App.jsx`, with styling in `frontend/src/App.css` and `frontend/src/index.css`. This layer is responsible for the user-facing workflow: selecting/uploading lecture audio or video, initiating backend processing, and presenting generated results. It should remain separated from speech recognition, AI generation, and persistence concerns.

#### Backend Processing Boundary
`backend/app.py` is the central server boundary between the client and AI/media-processing pipeline. It likely owns HTTP request handling, upload acceptance, orchestration of transcription and note-generation steps, and response serialization. Backend dependencies are declared in `backend/requirements.txt`; these determine the actual server framework, speech-to-text, and generative-AI integrations.

#### Media Ingestion and Storage
Uploaded lecture media is stored under `backend/uploads/`, demonstrated by `backend/uploads/WIN_20260212_19_42_19_Pro.mp4`. Sample inputs at repository root (`sample_lecture.mp3`, `sample_lecture.wav`) support local development and pipeline validation. Media files are an important boundary: uploads should be treated as untrusted input and processed independently from persistent note records.

#### Persistence
SQLite database artifacts appear in both backend and root instance locations:
- `backend/instance/voice_to_notes.db`
- `backend/voice_to_notes.db`
- `instance/voice_to_notes.db`

These indicate local relational persistence for uploaded lectures, transcripts, generated notes, or request metadata. The duplicate locations suggest application-instance configuration or historical database copies; deployment should establish one authoritative database path.

#### Core End-to-End Flow
1. The Vite frontend (`frontend/src/App.jsx`) submits lecture media to the backend.
2. `backend/app.py` receives and stores the upload in `backend/uploads/`.
3. The backend invokes speech-to-text AI to derive a transcript.
4. The transcript is passed to generative AI to create structured study material.
5. Generated content and related metadata can be persisted in SQLite and returned to the frontend for display.

#### Runtime and External Dependencies
The system spans a JavaScript/Vite browser runtime (`frontend/package.json`) and a Python backend runtime (`backend/requirements.txt`). It depends architecturally on external AI capabilities for transcription and generative summarization, with environment-based secrets/configuration implied by `.env`. Local filesystem storage and SQLite are the included infrastructure; no separate cloud, queue, or container infrastructure is present in the tree.

Main entry points: [`backend/app.py`](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/backend/app.py) (Backend API & orchestrator), [`.env`](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/.env) (Environment secrets), [`frontend/src/App.jsx`](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/src/App.jsx) (Lecture workflow UI), [`frontend/src/main.jsx`](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/src/main.jsx) (Browser entry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Browser Client"]
  node_vite{{"Vite client runtime<br/>frontend build<br/>[vite.config.js]"}}
  node_main["Browser entry<br/>React bootstrap<br/>[main.jsx]"]
  node_ui["Lecture workflow UI<br/>React UI<br/>[App.jsx]"]
end

subgraph group_backend["Python Backend"]
  node_backend_app{{"Backend API &amp; orchestrator<br/>Python service<br/>[app.py]"}}
  node_backend_deps["Backend dependencies<br/>Python dependencies<br/>[requirements.txt]"]
  node_transcript["Lecture transcript<br/>pipeline artifact"]
  node_study_output["Structured study material<br/>pipeline artifact"]
end

subgraph group_storage["Local Storage"]
  node_uploads[("Uploaded lecture media<br/>filesystem uploads")]
  node_sqlite[("SQLite persistence<br/>relational database<br/>[voice_to_notes.db]")]
  node_sample_media["Sample lecture media<br/>development input<br/>[sample_lecture.mp3]"]
end

node_transcription{{"Speech-to-text AI<br/>external AI service"}}
node_generation{{"Study-material AI<br/>external AI service"}}
node_sample_generator["Sample lecture generator<br/>development utility"]
node_environment["Environment secrets<br/>runtime configuration<br/>[.env]"]

node_vite -->|"serves"| node_main
node_main -->|"mounts"| node_ui
node_ui -->|"uploads media / requests results"| node_backend_app
node_backend_deps -.->|"provides runtime integrations"| node_backend_app
node_backend_app -->|"stores upload"| node_uploads
node_uploads -->|"lecture media"| node_transcription
node_transcription -->|"produces"| node_transcript
node_transcript -->|"prompt input"| node_generation
node_generation -->|"produces"| node_study_output
node_backend_app -->|"persists metadata and outputs"| node_sqlite
node_study_output -->|"serialized response"| node_backend_app
node_backend_app -->|"study results"| node_ui
node_sample_generator -.->|"creates"| node_sample_media
node_sample_media -.->|"local pipeline input"| node_backend_app
node_environment -.->|"configures"| node_backend_app
node_environment -.->|"credentials"| node_transcription
node_environment -.->|"credentials"| node_generation

click node_vite "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/vite.config.js"
click node_main "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/src/main.jsx"
click node_ui "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/src/App.jsx"
click node_backend_app "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/backend/app.py"
click node_backend_deps "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/backend/requirements.txt"
click node_sqlite "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/backend/instance/voice_to_notes.db"
click node_sample_generator "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/create_sample_lecture.py"
click node_sample_media "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/sample_lecture.mp3"
click node_environment "https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/.env"

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_vite,node_main,node_ui toneBlue
class node_backend_app,node_backend_deps,node_transcript,node_study_output toneAmber
class node_uploads,node_sqlite,node_sample_media toneMint
class node_transcription,node_generation,node_sample_generator,node_environment toneNeutral
```

## Components

### Browser Client

- [Vite client runtime](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/vite.config.js): frontend build · `frontend/vite.config.js`
- [Browser entry](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/src/main.jsx): React bootstrap · `frontend/src/main.jsx`
- [Lecture workflow UI](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/frontend/src/App.jsx): React UI · Uploads media and presents study results. · `frontend/src/App.jsx`

### Python Backend

- [Backend API & orchestrator](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/backend/app.py): Python service · Accepts uploads and coordinates the AI pipeline. · `backend/app.py`
- [Backend dependencies](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/backend/requirements.txt): Python dependencies · `backend/requirements.txt`
- **Lecture transcript**: pipeline artifact
- **Structured study material**: pipeline artifact

### Local Storage

- **Uploaded lecture media**: filesystem uploads · Untrusted media is stored separately before processing.
- [SQLite persistence](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/backend/instance/voice_to_notes.db): relational database · One authoritative database location should be selected. · `backend/instance/voice_to_notes.db`
- [Sample lecture media](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/sample_lecture.mp3): development input · `sample_lecture.mp3`

### Other components

- **Speech-to-text AI**: external AI service
- **Study-material AI**: external AI service · Generates notes, quizzes, or flashcards.
- [Sample lecture generator](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/create_sample_lecture.py): development utility · `create_sample_lecture.py`
- [Environment secrets](https://github.com/venkatesh123-start/aicte-batch7--lecture-voice-to-notes-generator/blob/main/.env): runtime configuration · Supplies AI credentials and service configuration. · `.env`

## Connections

- Vite client runtime → Browser entry: serves
- Browser entry → Lecture workflow UI: mounts
- Lecture workflow UI → Backend API & orchestrator: uploads media / requests results
- Backend dependencies → Backend API & orchestrator: provides runtime integrations
- Backend API & orchestrator → Uploaded lecture media: stores upload
- Uploaded lecture media → Speech-to-text AI: lecture media
- Speech-to-text AI → Lecture transcript: produces
- Lecture transcript → Study-material AI: prompt input
- Study-material AI → Structured study material: produces
- Backend API & orchestrator → SQLite persistence: persists metadata and outputs
- Structured study material → Backend API & orchestrator: serialized response
- Backend API & orchestrator → Lecture workflow UI: study results
- Sample lecture generator → Sample lecture media: creates
- Sample lecture media → Backend API & orchestrator: local pipeline input
- Environment secrets → Backend API & orchestrator: configures
- Environment secrets → Speech-to-text AI: credentials
- Environment secrets → Study-material AI: credentials
