# shivajaysaxena/infosysspringboard architecture

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

- Interactive diagram: https://gitdiagram.com/shivajaysaxena/infosysspringboard
- Repository: https://github.com/shivajaysaxena/infosysspringboard

## Overview

##### Project type and purpose
- This is a full-stack, single-page Streamlit application called “Real-Time AI Sales Call Assistant.”
- Purpose: capture live audio from a user’s microphone, run real-time speech-to-text, sentiment analysis, contextual product/spare-parts recommendations, analytics dashboard, and auto-generated reports.

##### File structure
Top-level files:
- app.py        → Streamlit entrypoint / UI layer
- assistant.py  → Core AI business logic (calls to Google Gemini, FAISS search, Pandas)
- requirements.txt / packages.txt → Dependencies
- phone_comparison.csv, spare_parts.csv → Data stores for recommendations
- uploads/      → Temporary storage of uploaded or streamed audio files

##### README for insights
- Tech stack: Streamlit (UI), SpeechRecognition (voice capture), Google Gemini AI (NLP), Pandas + FAISS (data & vector search), Plotly (charts), FPDF (PDF reports).

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Frontend Layer
    subgraph "Frontend Layer"
        UI["Streamlit UI"]:::frontend
    end

    %% Backend Core AI Engine
    subgraph "Backend Core AI Engine"
        Pre["Voice Capture Service\n(SpeechRecognition)"]:::backend
        NLP["NLP Adapter"]:::backend
        Rec["Recommendation Engine"]:::backend
        Sent["Sentiment Analyzer"]:::backend
        Report["Report Generator"]:::backend
    end

    %% Data Layer
    subgraph "Data Layer"
        phone["Phone Comparison CSV"]:::data
        spare["Spare Parts CSV"]:::data
        faiss["FAISS Index"]:::data
    end

    %% Temporary Storage
    uploads["/uploads (Temp Audio Store)"]:::data

    %% External Services
    gemini["Google Gemini API"]:::external

    %% Dependency Manifests
    deps1["requirements.txt"]:::data
    deps2["packages.txt"]:::data

    %% Data Flows
    UI -->|"record audio"| Pre
    Pre -->|"text transcript"| NLP
    NLP -->|"API request/response"| gemini
    gemini -->|"enriched text"| NLP
    NLP -->|"entities,intents"| Rec
    Rec -->|"vector search query"| faiss
    Rec -->|"lookup data"| phone
    Rec -->|"lookup data"| spare
    NLP -->|"text stream"| Sent
    Sent -->|"sentiment metrics"| UI
    Rec -->|"recommendations"| UI
    UI -->|"request report"| Report
    Report -->|"PDF report"| UI
    Pre -->|"save audio file"| uploads
    UI -->|"install deps"| deps1
    UI -->|"install deps"| deps2

    %% Click Events
    click UI "https://github.com/shivajaysaxena/infosysspringboard/blob/main/app.py"
    click Pre "https://github.com/shivajaysaxena/infosysspringboard/blob/main/app.py"
    click NLP "https://github.com/shivajaysaxena/infosysspringboard/blob/main/assistant.py"
    click Rec "https://github.com/shivajaysaxena/infosysspringboard/blob/main/assistant.py"
    click Sent "https://github.com/shivajaysaxena/infosysspringboard/blob/main/assistant.py"
    click Report "https://github.com/shivajaysaxena/infosysspringboard/blob/main/assistant.py"
    click phone "https://github.com/shivajaysaxena/infosysspringboard/blob/main/phone_comparison.csv"
    click spare "https://github.com/shivajaysaxena/infosysspringboard/blob/main/spare_parts.csv"
    click uploads "https://github.com/shivajaysaxena/infosysspringboard/tree/main/uploads/"
    click deps1 "https://github.com/shivajaysaxena/infosysspringboard/blob/main/requirements.txt"
    click deps2 "https://github.com/shivajaysaxena/infosysspringboard/blob/main/packages.txt"

    %% Styles
    classDef frontend fill:#DDEEFF,stroke:#3399FF
    classDef backend fill:#E0FFE0,stroke:#00AA00
    classDef data fill:#EEEEEE,stroke:#888888
    classDef external fill:#FFE0B2,stroke:#FF8800
```
