# rodzanto/agentic-ai-data-transform architecture

> Architecture diagram of the GitHub repository rodzanto/agentic-ai-data-transform, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-05-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/rodzanto/agentic-ai-data-transform
- Repository: https://github.com/rodzanto/agentic-ai-data-transform

## Overview

##### Project type and purpose
- From the file tree and README, this is a full-stack ETL system with an AI-powered natural language interface.
- Purpose: Allow users to upload structured data, issue plain-English transformation requests, and have the system generate and execute Athena SQL via an MCP bridge and Amazon Bedrock (Anthropic Claude).

##### File structure
- Top level:
- README.md – project overview and architecture description
- config.json – central configuration for S3 buckets, SQL templates, etc.
- claude_code_start.sh – bootstraps Bedrock/Claude context
- requirements.txt – Python dependencies (Streamlit, AWS SDK, MCP client)
- transactions.csv – sample dataset
- function_calling/ directory:
- streamlit_app.py – frontend UI and orchestration logic
- mcp_client_script.py – code that sends generated SQL from the AI agent to the MCP server
- No heavy microservice splits – single UI service, single MCP client, AWS services.

##### README for additional insights
- AWS services used:
- Amazon Bedrock (Anthropic Claude) as LLM orchestrator
- MCP server as “protocol adapter” for SQL calls
- Amazon Athena for query execution
- Amazon S3 for raw/processed data storage
- Streamlit for UI
- Workflow clearly spelled out in “Architecture Details” and “Workflow” sections.

##### Detail without over-splitting
- Five major components plus the user and configuration artifacts.

## Diagram (Mermaid)

```mermaid
flowchart TD
    User["User Browser"]:::external

    subgraph "Presentation Layer"
        Streamlit_App["Streamlit App"]:::frontend
    end

    subgraph "Orchestration Layer"
        Bedrock["Amazon Bedrock (Claude)"]:::orchestration
        MCP_Client["MCP Client"]:::orchestration
        MCP_Server["MCP Server"]:::orchestration
    end

    subgraph "Data Layer"
        S3["Amazon S3"]:::data
        Athena["Amazon Athena"]:::data
    end

    subgraph "Configuration & Artifacts"
        Config["config.json"]:::config
        LLM_Bootstrap["claude_code_start.sh"]:::config
        Requirements["requirements.txt"]:::config
        README["README.md"]:::config
        Sample_Data["transactions.csv"]:::config
        Function_Calling["function_calling/"]:::config
    end

    User -->|"upload CSV & NL query"| Streamlit_App
    Streamlit_App -->|"HTTP: NL prompt"| Bedrock
    Bedrock -->|"SQL plan"| Streamlit_App
    Streamlit_App -->|"invoke SQL"| MCP_Client
    MCP_Client -->|"forward SQL"| MCP_Server
    MCP_Server -->|"Execute SQL"| Athena
    Athena -->|"read raw data"| S3
    Athena -->|"write results"| S3
    MCP_Server -->|"query result metadata"| Streamlit_App
    Streamlit_App -->|"display results"| User

    Config --> Streamlit_App
    Requirements -.-> Streamlit_App
    LLM_Bootstrap -.-> Bedrock
    Function_Calling --> Streamlit_App
    README -.-> Config
    Sample_Data -.-> S3

    click Streamlit_App "https://github.com/rodzanto/agentic-ai-data-transform/blob/main/function_calling/streamlit_app.py"
    click MCP_Client "https://github.com/rodzanto/agentic-ai-data-transform/blob/main/function_calling/mcp_client_script.py"
    click LLM_Bootstrap "https://github.com/rodzanto/agentic-ai-data-transform/blob/main/claude_code_start.sh"
    click Config "https://github.com/rodzanto/agentic-ai-data-transform/blob/main/config.json"
    click README "https://github.com/rodzanto/agentic-ai-data-transform/blob/main/README.md"
    click Requirements "https://github.com/rodzanto/agentic-ai-data-transform/blob/main/requirements.txt"
    click Sample_Data "https://github.com/rodzanto/agentic-ai-data-transform/blob/main/transactions.csv"
    click Function_Calling "https://github.com/rodzanto/agentic-ai-data-transform/tree/main/function_calling/"

    classDef frontend fill:#D0E6FF,stroke:#0366d6,color:#0366d6
    classDef orchestration fill:#D6F5D6,stroke:#2c662d,color:#2c662d
    classDef data fill:#FFE5B4,stroke:#d97706,color:#d97706
    classDef config fill:#E8E8E8,stroke:#666666,color:#333333
    classDef external fill:#F0F0F0,stroke:#999999,color:#444444
```
