GraphProvider
@daydreamsai/core / GraphProvider
Interface: GraphProvider
Defined in: packages/core/src/memory/types.ts:152
Graph storage provider
Extends
Methods
addEdge()
addEdge(
edge):Promise<string>
Defined in: packages/core/src/memory/types.ts:160
Parameters
edge
Returns
Promise<string>
addNode()
addNode(
node):Promise<string>
Defined in: packages/core/src/memory/types.ts:154
Parameters
node
Returns
Promise<string>
close()
close():
Promise<void>
Defined in: packages/core/src/memory/types.ts:78
Returns
Promise<void>
Inherited from
deleteEdge()
deleteEdge(
id):Promise<boolean>
Defined in: packages/core/src/memory/types.ts:165
Parameters
id
string
Returns
Promise<boolean>
deleteNode()
deleteNode(
id):Promise<boolean>
Defined in: packages/core/src/memory/types.ts:157
Parameters
id
string
Returns
Promise<boolean>
findNodes()
findNodes(
filter):Promise<GraphNode[]>
Defined in: packages/core/src/memory/types.ts:168
Parameters
filter
Returns
Promise<GraphNode[]>
getEdges()
getEdges(
nodeId,direction?):Promise<GraphEdge[]>
Defined in: packages/core/src/memory/types.ts:161
Parameters
nodeId
string
direction?
"out" | "in" | "both"
Returns
Promise<GraphEdge[]>
getNode()
getNode(
id):Promise<null|GraphNode>
Defined in: packages/core/src/memory/types.ts:155
Parameters
id
string
Returns
Promise<null | GraphNode>
health()
health():
Promise<HealthStatus>
Defined in: packages/core/src/memory/types.ts:79
Returns
Promise<HealthStatus>
Inherited from
initialize()
initialize():
Promise<void>
Defined in: packages/core/src/memory/types.ts:77
Returns
Promise<void>
Inherited from
shortestPath()
shortestPath(
from,to):Promise<null|GraphPath>
Defined in: packages/core/src/memory/types.ts:170
Parameters
from
string
to
string
Returns
Promise<null | GraphPath>
traverse()
traverse(
traversal):Promise<GraphPath[]>
Defined in: packages/core/src/memory/types.ts:169
Parameters
traversal
Returns
Promise<GraphPath[]>
updateNode()
updateNode(
id,updates):Promise<void>
Defined in: packages/core/src/memory/types.ts:156
Parameters
id
string
updates
Partial<GraphNode>
Returns
Promise<void>