# webis-de/bea24-essay-feedback-generation architecture

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

- Interactive diagram: https://gitdiagram.com/webis-de/bea24-essay-feedback-generation
- Repository: https://github.com/webis-de/bea24-essay-feedback-generation

## Overview

##### Project type and purpose
- This is a research‐oriented codebase and data corpus for “Exploring LLM Prompting Strategies for Joint Essay Scoring and Feedback Generation.”
- It provides a pipeline to create datasets, invoke LLMs with different prompt strategies, score essays, generate feedback, and evaluate results.

##### File structure
- Top‐level:
- README.md – high‐level description and citation info
- code/ – all Python modules and Jupyter notebooks
- In code/:
- Dataset Creation.ipynb & analysis.py – data preparation & exploratory analyses
- main.py – orchestrates end‐to‐end experiments
- llm_functions.py & prompts.py – LLM API wrappers and prompt templates
- evaluation_helpers.py, helpfulness_evaluation.py & Evaluations.ipynb – metric computation and evaluation notebooks
- essay_meta_data.py – essay metadata extraction and management
- No frontend or database; this is a modular Python pipeline relying on external LLM APIs.

##### README for additional insights
- Dependencies implied: Python, Jupyter, LLM API client (e.g., OpenAI SDK), typical data science libs

##### Elements
- Clear component labels (e.g., “Dataset Prep”, “Prompt Builder”)
- Data modules (blue)
- Core logic/orchestrator (green)
- External services (orange)
- Analysis/evaluation (purple)

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Data Ingestion & Preparation
    subgraph "Data Ingestion & Preparation"
        direction TB
        DataIngest["Dataset Creation.ipynb"]:::data
        EssayMeta["essay_meta_data.py"]:::data
    end

    %% Core Logic & Orchestrator
    subgraph "Core Logic"
        direction TB
        Orchestrator["main.py"]:::core
        PromptModule["prompts.py"]:::core
        ScoringFeedback["Scoring & Feedback\n(llm_functions.py)"]:::core
    end

    %% External Service
    LLMService["External LLM API"]:::external

    %% Evaluation Module
    subgraph "Evaluation Module"
        direction TB
        EvalHelpers["evaluation_helpers.py"]:::eval
        HelpfulnessEval["helpfulness_evaluation.py"]:::eval
    end

    %% Analysis & Visualization
    subgraph "Analysis & Visualization"
        direction TB
        AnalysisPy["analysis.py"]:::eval
        EvalNotebook["Evaluations.ipynb"]:::eval
    end

    %% Data Flow
    DataIngest -->|ingests data| Orchestrator
    EssayMeta -->|provides metadata| Orchestrator

    Orchestrator -->|builds prompts| PromptModule
    PromptModule -->|sends prompt| LLMService
    LLMService -->|returns raw output| ScoringFeedback
    ScoringFeedback -->|generates scores & feedback| EvalHelpers
    HelpfulnessEval -->|computes helpfulness| EvalHelpers
    EvalHelpers -->|produces metrics| AnalysisPy
    EvalNotebook -->|visualizes results| AnalysisPy

    %% Click Events
    click DataIngest "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/Dataset Creation.ipynb"
    click EssayMeta "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/essay_meta_data.py"
    click Orchestrator "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/main.py"
    click PromptModule "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/prompts.py"
    click ScoringFeedback "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/llm_functions.py"
    click LLMService "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/llm_functions.py"
    click EvalHelpers "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/evaluation_helpers.py"
    click HelpfulnessEval "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/helpfulness_evaluation.py"
    click AnalysisPy "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/analysis.py"
    click EvalNotebook "https://github.com/webis-de/bea24-essay-feedback-generation/blob/main/code/Evaluations.ipynb"

    %% Styles
    classDef data fill:#ADD8E6,stroke:#333,stroke-width:1px;
    classDef core fill:#90EE90,stroke:#333,stroke-width:1px;
    classDef external fill:#FFA500,stroke:#333,stroke-width:1px;
    classDef eval fill:#DDA0DD,stroke:#333,stroke-width:1px;
```
