# wikankun/mag-and-pie architecture

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

- Interactive diagram: https://gitdiagram.com/wikankun/mag-and-pie
- Repository: https://github.com/wikankun/mag-and-pie

## Overview

##### Main Components

A. Project Structure Layer
- Technical Assessment Module
- Case Study Module

B. Technical Module Components
- Tech_1 Component
- Main Logic Module
- Test Module
- Tech_2 Component
- Main Logic Module
- Test Module

C. Case Study Module Components
- Case_1 Component (Web Scraping System)
- Input Processing
- Scraper Engine
- Post-Processing
- Data Storage (CSV files)
- Case_2 Component

**[Technical Assessment Project]**

**[Technical]    [Case]**

**[Technical Module]**

- [Tech_1]
- Main Logic
- Unit Tests

- [Tech_2]
- Main Logic
- Unit Tests

**[Case Module]**

- [Case_1 (Web Scraper)]
- Input (input.csv)
- Scraper Engine
- Processing Pipeline
- Output (scrape_result.csv, post_process.csv)

- [Case_2]

##### Important Details to Highlight

- The project's modular structure
- Separation of technical exercises and case studies
- Test-driven development approach
- Data processing pipeline in Case 1
- File I/O operations and data transformations

## Diagram (Mermaid)

```mermaid
flowchart TB
    subgraph Project
        TechAssess[Technical Assessment Project]
    end

    subgraph TechnicalLayer[Technical Module]
        Tech1[Tech_1]
        Tech2[Tech_2]
        
        subgraph Tech1Components[Tech_1 Components]
            Tech1Main[Main Logic]
            Tech1Test[Unit Tests]
        end
        
        subgraph Tech2Components[Tech_2 Components]
            Tech2Main[Main Logic]
            Tech2Test[Unit Tests]
        end
    end

    subgraph CaseLayer[Case Module]
        Case1[Case_1]
        Case2[Case_2]
        
        subgraph Case1Components[Case_1 Web Scraper]
            InputCSV[(input.csv)]
            ScraperEngine[Scraper Engine]
            ProcessingPipeline[Processing Pipeline]
            ScrapeResult[(scrape_result.csv)]
            PostProcess[(post_process.csv)]
        end
    end

    %% Relationships
    TechAssess --> TechnicalLayer
    TechAssess --> CaseLayer
    
    %% Technical Module Relationships
    Tech1 --> Tech1Components
    Tech1Main --> Tech1Test
    Tech2 --> Tech2Components
    Tech2Main --> Tech2Test
    
    %% Case Module Relationships
    Case1 --> Case1Components
    InputCSV --> ScraperEngine
    ScraperEngine --> ProcessingPipeline
    ProcessingPipeline --> ScrapeResult
    ProcessingPipeline --> PostProcess

    %% Styling
    classDef default fill:#f9f9f9,stroke:#333,stroke-width:2px
    classDef module fill:#b8d4ff,stroke:#333
    classDef test fill:#90EE90,stroke:#333
    classDef storage fill:#FFE5CC,stroke:#333
    classDef process fill:#FFB366,stroke:#333
    
    class TechAssess module
    class Tech1,Tech2,Case1,Case2 module
    class Tech1Test,Tech2Test test
    class InputCSV,ScrapeResult,PostProcess storage
    class ScraperEngine,ProcessingPipeline process

    %% Click Events
    click TechnicalLayer "https://github.com/wikankun/mag-and-pie/tree/master//technical/"
    click CaseLayer "https://github.com/wikankun/mag-and-pie/tree/master//case/"
    click Tech1 "https://github.com/wikankun/mag-and-pie/tree/master//technical/tech_1/"
    click Tech1Main "https://github.com/wikankun/mag-and-pie/blob/master//technical/tech_1/main.py"
    click Tech1Test "https://github.com/wikankun/mag-and-pie/blob/master//technical/tech_1/test_tech_1.py"
    click Tech2 "https://github.com/wikankun/mag-and-pie/tree/master//technical/tech_2/"
    click Tech2Main "https://github.com/wikankun/mag-and-pie/blob/master//technical/tech_2/main.py"
    click Tech2Test "https://github.com/wikankun/mag-and-pie/blob/master//technical/tech_2/test_tech_2.py"
    click Case1 "https://github.com/wikankun/mag-and-pie/tree/master//case/case_1/"
    click ScraperEngine "https://github.com/wikankun/mag-and-pie/blob/master//case/case_1/scraper.py"
    click InputCSV "https://github.com/wikankun/mag-and-pie/blob/master//case/case_1/input.csv"
    click ScrapeResult "https://github.com/wikankun/mag-and-pie/blob/master//case/case_1/scrape_result.csv"
    click PostProcess "https://github.com/wikankun/mag-and-pie/blob/master//case/case_1/post_process.csv"
    click Case2 "https://github.com/wikankun/mag-and-pie/tree/master//case/case_2/"
```
