Architecture
- High-level architecture: Diagrams and descriptions of the system architecture, including the backend, frontend, and any external services.
- Database schema: Details about the database design, including entity relationships.
High-Level Architecture
Overview
The architecture of your system can be described as a three-tier setup:
-
Frontend/API Layer: This layer serves as the interface for users or applications to interact with your system. It exposes a Swagger-based API that allows for operations like fetching and storing datasets from Hugging Face.
-
Backend/Business Logic Layer: This layer contains the logic for processing data, handling API requests, and communicating with external services (like Hugging Face) and the database.
-
Database Layer: Leveraging Neo4j, a graph-based database, this layer is responsible for persistently storing and managing datasets fetched from Hugging Face.
Diagram
Database Schema
Overview
The database schema reflects the structure of the data stored in Neo4j. Based on your provided models, it seems to focus on different datasets with relationships to other nodes for specific datasets.
-
Base Node -
HuggingFaceDataset
: Represents the basic dataset node with common properties likeuid
andcreated_at
. -
Inherited Nodes:
TreeOfKnowledgeDataset
: Inherits fromHuggingFaceDataset
, specific for storing question-answer pairs.HotpotQADataset
: Similar toTreeOfKnowledgeDataset
but includes additional context information.-
TimeQADataset
: Stores question and context, with a relationship toTimeQAAnswer
for storing answers. -
Related Node -
TimeQAAnswer
: Stores answer values and is related toTimeQADataset
.