# prasanthikuruba/streamlitprojs architecture

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

- Interactive diagram: https://gitdiagram.com/prasanthikuruba/streamlitprojs
- Repository: https://github.com/prasanthikuruba/streamlitprojs

## Overview

This repository is a collection of small, independent Streamlit examples rather than one integrated application. Users interact with each app directly: the examples either display widgets, calculate and show a result, open an uploaded image, or send an image and prompt to Gemini. The configuration example loads values from a local .env file and prints them. Source excerpts show these app-level behaviors; no shared routing or application layer is evident.

Main entry points: [`GenAI_ImageDescribing/GenerateContentOfImage.py`](https://github.com/prasanthikuruba/streamlitprojs/blob/main/GenAI_ImageDescribing/GenerateContentOfImage.py) (Image Q&A), [`FileUpload/fileUploadndDisplay.py`](https://github.com/prasanthikuruba/streamlitprojs/blob/main/FileUpload/fileUploadndDisplay.py) (Image Viewer), [`EnvConfig/main.py`](https://github.com/prasanthikuruba/streamlitprojs/blob/main/EnvConfig/main.py) (Environment Reader), [`MyFirstApp/ex1.py`](https://github.com/prasanthikuruba/streamlitprojs/blob/main/MyFirstApp/ex1.py) (Widget Demo)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_intro["Streamlit Introduction"]
  node_first_app["Widget Demo<br/>[ex1.py]"]
end

subgraph group_calculators["Calculator Demos"]
  node_add_simple["Addition Calculator<br/>[SimpleUIAddCalc.py]"]
  node_add_redesign["Styled Addition<br/>[RedesignAddCalc.py]"]
  node_four_simple["Four-Operation Calculator"]
  node_four_redesign["Styled Calculator"]
end

subgraph group_images["Image Apps"]
  node_file_upload["Image Viewer"]
  node_image_describer["Image Q&amp;A"]
end

subgraph group_config["Configuration Demo"]
  node_env_app["Environment Reader<br/>[main.py]"]
  node_env_file["Environment Values<br/>[.env]"]
end

node_user(("User"))
node_pillow["Pillow"]
node_gemini["Gemini API"]
node_dotenv["python-dotenv"]

node_user -->|"uses widgets"| node_first_app
node_first_app -->|"displays UI"| node_user
node_user -->|"enters numbers"| node_add_simple
node_add_simple -->|"shows sum"| node_user
node_user -->|"enters numbers"| node_add_redesign
node_add_redesign -->|"shows sum"| node_user
node_user -->|"selects operation"| node_four_simple
node_four_simple -->|"shows result"| node_user
node_user -->|"selects operation"| node_four_redesign
node_four_redesign -->|"shows result"| node_user
node_user -->|"uploads image"| node_file_upload
node_file_upload -->|"opens image"| node_pillow
node_file_upload -->|"displays image"| node_user
node_user -->|"uploads image"| node_image_describer
node_image_describer -->|"opens image"| node_pillow
node_image_describer -->|"sends image prompt"| node_gemini
node_gemini -->|"returns description"| node_image_describer
node_image_describer -->|"shows response"| node_user
node_env_app -->|"loads variables"| node_dotenv
node_dotenv -->|"reads values"| node_env_file
node_env_app -->|"prints values"| node_user

click node_first_app "https://github.com/prasanthikuruba/streamlitprojs/blob/main/MyFirstApp/ex1.py"
click node_add_simple "https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleAddCalc/SimpleUIAddCalc.py"
click node_add_redesign "https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleAddCalc/RedesignAddCalc.py"
click node_four_simple "https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleCalcWithFourArhtimeticOperators/SimpleUIWith4Operators.py"
click node_four_redesign "https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleCalcWithFourArhtimeticOperators/RedesignUIWith4Operators.py"
click node_file_upload "https://github.com/prasanthikuruba/streamlitprojs/blob/main/FileUpload/fileUploadndDisplay.py"
click node_image_describer "https://github.com/prasanthikuruba/streamlitprojs/blob/main/GenAI_ImageDescribing/GenerateContentOfImage.py"
click node_env_app "https://github.com/prasanthikuruba/streamlitprojs/blob/main/EnvConfig/main.py"
click node_env_file "https://github.com/prasanthikuruba/streamlitprojs/blob/main/EnvConfig/.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_first_app,node_user toneBlue
class node_add_simple,node_add_redesign,node_four_simple,node_four_redesign toneAmber
class node_file_upload,node_image_describer,node_gemini toneMint
class node_env_app,node_env_file toneRose
class node_pillow,node_dotenv toneIndigo
```

## Components

### Streamlit Introduction

- [Widget Demo](https://github.com/prasanthikuruba/streamlitprojs/blob/main/MyFirstApp/ex1.py): `MyFirstApp/ex1.py`

### Calculator Demos

- [Addition Calculator](https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleAddCalc/SimpleUIAddCalc.py): `SimpleAddCalc/SimpleUIAddCalc.py`
- [Styled Addition](https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleAddCalc/RedesignAddCalc.py): `SimpleAddCalc/RedesignAddCalc.py`
- [Four-Operation Calculator](https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleCalcWithFourArhtimeticOperators/SimpleUIWith4Operators.py): `SimpleCalcWithFourArhtimeticOperators/SimpleUIWith4Operators.py`
- [Styled Calculator](https://github.com/prasanthikuruba/streamlitprojs/blob/main/SimpleCalcWithFourArhtimeticOperators/RedesignUIWith4Operators.py): `SimpleCalcWithFourArhtimeticOperators/RedesignUIWith4Operators.py`

### Image Apps

- [Image Viewer](https://github.com/prasanthikuruba/streamlitprojs/blob/main/FileUpload/fileUploadndDisplay.py): `FileUpload/fileUploadndDisplay.py`
- [Image Q&A](https://github.com/prasanthikuruba/streamlitprojs/blob/main/GenAI_ImageDescribing/GenerateContentOfImage.py): `GenAI_ImageDescribing/GenerateContentOfImage.py`

### Configuration Demo

- [Environment Reader](https://github.com/prasanthikuruba/streamlitprojs/blob/main/EnvConfig/main.py): `EnvConfig/main.py`
- [Environment Values](https://github.com/prasanthikuruba/streamlitprojs/blob/main/EnvConfig/.env): `EnvConfig/.env`

### Other components

- **User**
- **Pillow**
- **Gemini API**
- **python-dotenv**

## Connections

- User → Widget Demo: uses widgets
- Widget Demo → User: displays UI
- User → Addition Calculator: enters numbers
- Addition Calculator → User: shows sum
- User → Styled Addition: enters numbers
- Styled Addition → User: shows sum
- User → Four-Operation Calculator: selects operation
- Four-Operation Calculator → User: shows result
- User → Styled Calculator: selects operation
- Styled Calculator → User: shows result
- User → Image Viewer: uploads image
- Image Viewer → Pillow: opens image
- Image Viewer → User: displays image
- User → Image Q&A: uploads image
- Image Q&A → Pillow: opens image
- Image Q&A → Gemini API: sends image prompt
- Gemini API → Image Q&A: returns description
- Image Q&A → User: shows response
- Environment Reader → python-dotenv: loads variables
- python-dotenv → Environment Values: reads values
- Environment Reader → User: prints values
