-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypes.ts
More file actions
52 lines (43 loc) · 1.15 KB
/
Copy pathtypes.ts
File metadata and controls
52 lines (43 loc) · 1.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
// This file will contain shared TypeScript types, interfaces, and enums
// to ensure type safety across the application.
export interface Property {
name: string;
type: string;
description?: string;
}
export interface NodeLabel {
label: string;
properties: Property[];
description?: string;
}
export interface RelationshipType {
id: string; // Unique ID, e.g. "Source_TYPE_Target"
type: string;
source: string; // The source node label
target: string; // The target node label
properties: Property[];
description?: string;
}
export interface GraphSchema {
nodes: NodeLabel[];
relationships: RelationshipType[];
}
// Sprint 4: Ontology and Health Checks
export interface Hierarchy {
subclass: string; // e.g., 'FictionBook'
superclass: string; // e.g., 'Book'
}
export interface Axiom {
source: string; // e.g., 'Book'
relationship: string; // e.g., 'WRITTEN_BY'
target: string; // e.g., 'Author'
}
export interface Ontology {
hierarchies: Hierarchy[];
axioms: Axiom[];
}
export interface HealthCheckIssue {
id: string; // ID of the node (label) or relationship (type)
type: 'node' | 'relationship';
message: string;
}