From aa892ede191deb977e0a17bdc966faed479c010d Mon Sep 17 00:00:00 2001 From: openclaw Date: Mon, 23 Mar 2026 16:48:24 +0000 Subject: [PATCH] feat(graph): add GraphNode, GraphEdge, GraphGroup, GraphView domain entities Co-Authored-By: Claude Opus 4.6 --- backend/app/modules/graph/domain/entities.py | 31 ++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/backend/app/modules/graph/domain/entities.py b/backend/app/modules/graph/domain/entities.py index e69de29..e1582f4 100644 --- a/backend/app/modules/graph/domain/entities.py +++ b/backend/app/modules/graph/domain/entities.py @@ -0,0 +1,31 @@ +from dataclasses import dataclass + + +@dataclass +class GraphNode: + id: str + type: str # capability, module, entity, integration, ... + label: str + status: str # FileStatus or "unknown" + group_id: str + + +@dataclass +class GraphEdge: + source: str + target: str + relation: str # traces_to, depends_on, owns, integrates_with, ... + + +@dataclass +class GraphGroup: + id: str + label: str + layer: str # business, application, data, technology, cross-layer + + +@dataclass +class GraphView: + nodes: list[GraphNode] + edges: list[GraphEdge] + groups: list[GraphGroup]