# sujithreddy-47/hybrid-lora-domainadaptation-gpt2 architecture

> Architecture diagram of the GitHub repository sujithreddy-47/hybrid-lora-domainadaptation-gpt2, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-17). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2
- Repository: https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2

## Overview

This is an academic NLP research project for comparing LoRA, DyLoRA, DC-LoRA, and their hybrid on sequential IMDb-to-Yelp adaptation of GPT-2. The documented workflow runs Domain A training, continues on Domain B, repeats across seeds, and evaluates retention, forgetting, accuracy, latency, and memory. The notebook is the documented execution surface; results and visualizations are saved artifacts. No notebook source was available, so relationships below rely only on README statements and do not claim implementation details beyond them.

Main entry points: [`dyloRA-dcLoRA-gpt2-project/code file.ipynb`](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb) (Project notebook), [`dyloRA-dcLoRA-gpt2-project/results`](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/tree/main/dyloRA-dcLoRA-gpt2-project/results) (Result files), [`dyloRA-dcLoRA-gpt2-project/images`](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/tree/main/dyloRA-dcLoRA-gpt2-project/images) (Image outputs)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_training["Training workflow"]
  node_notebook["Project notebook<br/>[code file.ipynb]"]
  node_gpt2["GPT-2"]
  node_imdb[("IMDb domain")]
  node_yelp[("Yelp domain")]
  node_seed_runs["Multi-seed runs<br/>[code file.ipynb]"]
end

subgraph group_methods["Adaptation methods"]
  node_lora["LoRA<br/>[code file.ipynb]"]
  node_dylora["DyLoRA<br/>[code file.ipynb]"]
  node_dclora["DC-LoRA<br/>[code file.ipynb]"]
  node_hybrid["Hybrid method<br/>[code file.ipynb]"]
end

subgraph group_analysis["Evaluation and analysis"]
  node_metrics["Evaluation metrics<br/>[code file.ipynb]"]
  node_profiling["Latency and memory<br/>[code file.ipynb]"]
  node_visualization["Visualizations<br/>[code file.ipynb]"]
end

subgraph group_artifacts["Saved outputs"]
  node_results["Result files"]
  node_images["Image outputs"]
end

node_researcher(("Researcher"))

node_researcher -->|"runs"| node_notebook
node_notebook -->|"fine-tunes"| node_gpt2
node_notebook -->|"trains on"| node_imdb
node_notebook -->|"continues on"| node_yelp
node_notebook -->|"applies"| node_lora
node_notebook -->|"applies"| node_dylora
node_notebook -->|"applies"| node_dclora
node_notebook -->|"applies"| node_hybrid
node_notebook -->|"repeats across"| node_seed_runs
node_notebook -->|"computes"| node_metrics
node_notebook -->|"profiles"| node_profiling
node_notebook -->|"creates"| node_visualization
node_notebook -->|"saves"| node_results
node_visualization -->|"produces"| node_images

click node_notebook "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_lora "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_dylora "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_dclora "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_hybrid "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_seed_runs "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_metrics "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_profiling "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_visualization "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb"
click node_results "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/tree/main/dyloRA-dcLoRA-gpt2-project/results"
click node_images "https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/tree/main/dyloRA-dcLoRA-gpt2-project/images"

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_notebook,node_gpt2,node_imdb,node_yelp,node_seed_runs toneBlue
class node_lora,node_dylora,node_dclora,node_hybrid toneAmber
class node_metrics,node_profiling,node_visualization toneMint
class node_results,node_images toneRose
class node_researcher toneIndigo
```

## Components

### Training workflow

- [Project notebook](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`
- **GPT-2**
- **IMDb domain**
- **Yelp domain**
- [Multi-seed runs](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`

### Adaptation methods

- [LoRA](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`
- [DyLoRA](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`
- [DC-LoRA](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`
- [Hybrid method](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`

### Evaluation and analysis

- [Evaluation metrics](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`
- [Latency and memory](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`
- [Visualizations](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/blob/main/dyloRA-dcLoRA-gpt2-project/code%20file.ipynb): `dyloRA-dcLoRA-gpt2-project/code file.ipynb`

### Saved outputs

- [Result files](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/tree/main/dyloRA-dcLoRA-gpt2-project/results): `dyloRA-dcLoRA-gpt2-project/results`
- [Image outputs](https://github.com/sujithreddy-47/hybrid-lora-domainadaptation-gpt2/tree/main/dyloRA-dcLoRA-gpt2-project/images): `dyloRA-dcLoRA-gpt2-project/images`

### Other components

- **Researcher**

## Connections

- Researcher → Project notebook: runs (evidence: `README.md`)
- Project notebook → GPT-2: fine-tunes (evidence: `README.md`)
- Project notebook → IMDb domain: trains on (evidence: `README.md`)
- Project notebook → Yelp domain: continues on (evidence: `README.md`)
- Project notebook → LoRA: applies (evidence: `README.md`)
- Project notebook → DyLoRA: applies (evidence: `README.md`)
- Project notebook → DC-LoRA: applies (evidence: `README.md`)
- Project notebook → Hybrid method: applies (evidence: `README.md`)
- Project notebook → Multi-seed runs: repeats across (evidence: `README.md`)
- Project notebook → Evaluation metrics: computes (evidence: `README.md`)
- Project notebook → Latency and memory: profiles (evidence: `README.md`)
- Project notebook → Visualizations: creates (evidence: `README.md`)
- Project notebook → Result files: saves (evidence: `README.md`)
- Visualizations → Image outputs: produces (evidence: `README.md`)
