# siddhant-5/researchflow architecture

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

- Interactive diagram: https://gitdiagram.com/siddhant-5/researchflow
- Repository: https://github.com/siddhant-5/researchflow

## Overview

This is a Streamlit research-paper evaluator: users upload a PDF, receive an LLM-generated structured review and publishability judgment, and—if publishable—a suggested conference. The main stages are PDF loading and chunking, per-chunk evaluation, aggregation and aspect summarization, then optional venue comparison; the UI offers PDF, JSON, and CSV downloads. Prompt-and-agent composition is the internal LLM layer. The README mentions optional database persistence, but the sampled source does not establish its implementation or wiring, so it is not mapped.

Main entry points: [`System.py`](https://github.com/siddhant-5/researchflow/blob/main/System.py) (Evaluation orchestration), [`app.py`](https://github.com/siddhant-5/researchflow/blob/main/app.py) (Streamlit app), [`Agents.py`](https://github.com/siddhant-5/researchflow/blob/main/Agents.py) (Agent builders), [`Utility.py`](https://github.com/siddhant-5/researchflow/blob/main/Utility.py) (Groq model setup)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["User interface"]
  node_app["Streamlit app<br/>[app.py]"]
  node_downloads["Report downloads<br/>[app.py]"]
end

subgraph group_evaluation["Paper evaluation"]
  node_pdf_handler["PDF loading<br/>[PDFManager.py]"]
  node_pdf_splitter["PDF chunking<br/>[PDFManager.py]"]
  node_classification["Evaluation orchestration<br/>[System.py]"]
  node_chunk_analysis["Chunk classification<br/>[System.py]"]
  node_structured_conversion["Structured evaluation<br/>[System.py]"]
  node_aggregation["Score aggregation<br/>[System.py]"]
  node_aspect_summary["Aspect summaries<br/>[System.py]"]
  node_paper_model["Paper evaluation model<br/>[Utility.py]"]
end

subgraph group_conference["Venue recommendation"]
  node_conference_system["Venue comparison<br/>[System.py]"]
  node_conference_context["Venue themes"]
  node_conference_model["Venue decision model<br/>[Utility.py]"]
end

subgraph group_llm_layer["LLM composition"]
  node_agents["Agent builders<br/>[Agents.py]"]
  node_prompts["Prompt templates<br/>[Prompts.py]"]
  node_model_manager["Groq model setup<br/>[Utility.py]"]
end

node_researcher(("Researcher"))
node_groq{{"Groq LLM"}}

node_researcher -->|"uploads PDF"| node_app
node_app -->|"starts evaluation"| node_classification
node_app -->|"creates model"| node_model_manager
node_app -->|"loads venue context"| node_conference_context
node_app -->|"requests recommendation"| node_conference_system
node_app -->|"formats results"| node_downloads
node_classification -->|"loads PDF"| node_pdf_handler
node_classification -->|"splits pages"| node_pdf_splitter
node_classification -->|"analyzes chunks"| node_chunk_analysis
node_classification -->|"converts analyses"| node_structured_conversion
node_classification -->|"aggregates evaluations"| node_aggregation
node_classification -->|"summarizes aspects"| node_aspect_summary
node_classification -->|"builds final result"| node_paper_model
node_chunk_analysis -->|"invokes classifier"| node_agents
node_structured_conversion -->|"invokes structured output"| node_agents
node_aspect_summary -->|"invokes summaries"| node_agents
node_agents -->|"composes prompts"| node_prompts
node_agents -->|"invokes model"| node_groq
node_model_manager -->|"configures client"| node_groq
node_conference_system -->|"invokes venue agents"| node_agents
node_conference_system -->|"returns decision"| node_conference_model
node_researcher -->|"downloads reports"| node_downloads

click node_app "https://github.com/siddhant-5/researchflow/blob/main/app.py"
click node_downloads "https://github.com/siddhant-5/researchflow/blob/main/app.py"
click node_pdf_handler "https://github.com/siddhant-5/researchflow/blob/main/PDFManager.py"
click node_pdf_splitter "https://github.com/siddhant-5/researchflow/blob/main/PDFManager.py"
click node_classification "https://github.com/siddhant-5/researchflow/blob/main/System.py"
click node_chunk_analysis "https://github.com/siddhant-5/researchflow/blob/main/System.py"
click node_structured_conversion "https://github.com/siddhant-5/researchflow/blob/main/System.py"
click node_aggregation "https://github.com/siddhant-5/researchflow/blob/main/System.py"
click node_aspect_summary "https://github.com/siddhant-5/researchflow/blob/main/System.py"
click node_paper_model "https://github.com/siddhant-5/researchflow/blob/main/Utility.py"
click node_conference_system "https://github.com/siddhant-5/researchflow/blob/main/System.py"
click node_conference_context "https://github.com/siddhant-5/researchflow/blob/main/ThemesAndContext.py"
click node_conference_model "https://github.com/siddhant-5/researchflow/blob/main/Utility.py"
click node_agents "https://github.com/siddhant-5/researchflow/blob/main/Agents.py"
click node_prompts "https://github.com/siddhant-5/researchflow/blob/main/Prompts.py"
click node_model_manager "https://github.com/siddhant-5/researchflow/blob/main/Utility.py"

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_app,node_downloads toneBlue
class node_pdf_handler,node_pdf_splitter,node_classification,node_chunk_analysis,node_structured_conversion,node_aggregation,node_aspect_summary,node_paper_model toneAmber
class node_conference_system,node_conference_context,node_conference_model toneMint
class node_agents,node_prompts,node_model_manager toneRose
class node_researcher,node_groq toneIndigo
```

## Components

### User interface

- [Streamlit app](https://github.com/siddhant-5/researchflow/blob/main/app.py): `app.py`
- [Report downloads](https://github.com/siddhant-5/researchflow/blob/main/app.py): `app.py`

### Paper evaluation

- [PDF loading](https://github.com/siddhant-5/researchflow/blob/main/PDFManager.py): `PDFManager.py`
- [PDF chunking](https://github.com/siddhant-5/researchflow/blob/main/PDFManager.py): `PDFManager.py`
- [Evaluation orchestration](https://github.com/siddhant-5/researchflow/blob/main/System.py): `System.py`
- [Chunk classification](https://github.com/siddhant-5/researchflow/blob/main/System.py): `System.py`
- [Structured evaluation](https://github.com/siddhant-5/researchflow/blob/main/System.py): `System.py`
- [Score aggregation](https://github.com/siddhant-5/researchflow/blob/main/System.py): `System.py`
- [Aspect summaries](https://github.com/siddhant-5/researchflow/blob/main/System.py): `System.py`
- [Paper evaluation model](https://github.com/siddhant-5/researchflow/blob/main/Utility.py): `Utility.py`

### Venue recommendation

- [Venue comparison](https://github.com/siddhant-5/researchflow/blob/main/System.py): `System.py`
- [Venue themes](https://github.com/siddhant-5/researchflow/blob/main/ThemesAndContext.py): `ThemesAndContext.py`
- [Venue decision model](https://github.com/siddhant-5/researchflow/blob/main/Utility.py): `Utility.py`

### LLM composition

- [Agent builders](https://github.com/siddhant-5/researchflow/blob/main/Agents.py): `Agents.py`
- [Prompt templates](https://github.com/siddhant-5/researchflow/blob/main/Prompts.py): `Prompts.py`
- [Groq model setup](https://github.com/siddhant-5/researchflow/blob/main/Utility.py): `Utility.py`

### Other components

- **Researcher**
- **Groq LLM**

## Connections

- Researcher → Streamlit app: uploads PDF
- Streamlit app → Evaluation orchestration: starts evaluation
- Streamlit app → Groq model setup: creates model
- Streamlit app → Venue themes: loads venue context
- Streamlit app → Venue comparison: requests recommendation
- Streamlit app → Report downloads: formats results
- Evaluation orchestration → PDF loading: loads PDF
- Evaluation orchestration → PDF chunking: splits pages
- Evaluation orchestration → Chunk classification: analyzes chunks
- Evaluation orchestration → Structured evaluation: converts analyses
- Evaluation orchestration → Score aggregation: aggregates evaluations
- Evaluation orchestration → Aspect summaries: summarizes aspects
- Evaluation orchestration → Paper evaluation model: builds final result
- Chunk classification → Agent builders: invokes classifier
- Structured evaluation → Agent builders: invokes structured output
- Aspect summaries → Agent builders: invokes summaries
- Agent builders → Prompt templates: composes prompts
- Agent builders → Groq LLM: invokes model
- Groq model setup → Groq LLM: configures client
- Venue comparison → Agent builders: invokes venue agents
- Venue comparison → Venue decision model: returns decision
- Researcher → Report downloads: downloads reports
