Skip to main content

knowledgeGraph

@codebolt/codeboltjs


Variable: knowledgeGraph

const knowledgeGraph: {
addEdge: (instanceId: string, edge: CreateKGEdgeParams) => Promise<KGEdgeResponse>;
addEdges: (instanceId: string, edges: CreateKGEdgeParams[]) => Promise<KGEdgeListResponse>;
addMemoryRecord: (instanceId: string, record: CreateKGMemoryRecordParams) => Promise<KGMemoryRecordResponse>;
addMemoryRecords: (instanceId: string, records: CreateKGMemoryRecordParams[]) => Promise<KGMemoryRecordListResponse>;
createInstance: (config: CreateKGInstanceParams) => Promise<KGInstanceResponse>;
createInstanceTemplate: (config: CreateKGInstanceTemplateParams) => Promise<KGInstanceTemplateResponse>;
createView: (config: CreateKGViewParams) => Promise<KGViewResponse>;
createViewTemplate: (config: CreateKGViewTemplateParams) => Promise<KGViewTemplateResponse>;
deleteEdge: (instanceId: string, edgeId: string) => Promise<KGDeleteResponse>;
deleteInstance: (instanceId: string) => Promise<KGDeleteResponse>;
deleteInstanceTemplate: (templateId: string) => Promise<KGDeleteResponse>;
deleteMemoryRecord: (instanceId: string, recordId: string) => Promise<KGDeleteResponse>;
deleteView: (viewId: string) => Promise<KGDeleteResponse>;
deleteViewTemplate: (templateId: string) => Promise<KGDeleteResponse>;
executeView: (viewId: string) => Promise<KGViewExecuteResponse>;
getInstance: (instanceId: string) => Promise<KGInstanceResponse>;
getInstanceTemplate: (templateId: string) => Promise<KGInstanceTemplateResponse>;
getMemoryRecord: (instanceId: string, recordId: string) => Promise<KGMemoryRecordResponse>;
getViewTemplate: (templateId: string) => Promise<KGViewTemplateResponse>;
listEdges: (instanceId: string, filters?: ListKGEdgesParams) => Promise<KGEdgeListResponse>;
listInstances: (templateId?: string) => Promise<KGInstanceListResponse>;
listInstanceTemplates: () => Promise<KGInstanceTemplateListResponse>;
listMemoryRecords: (instanceId: string, filters?: ListKGMemoryRecordsParams) => Promise<KGMemoryRecordListResponse>;
listViews: (instanceId: string) => Promise<KGViewListResponse>;
listViewTemplates: (applicableTemplateId?: string) => Promise<KGViewTemplateListResponse>;
updateInstanceTemplate: (templateId: string, updates: Partial<CreateKGInstanceTemplateParams>) => Promise<KGInstanceTemplateResponse>;
updateMemoryRecord: (instanceId: string, recordId: string, updates: Partial<CreateKGMemoryRecordParams>) => Promise<KGMemoryRecordResponse>;
updateViewTemplate: (templateId: string, updates: Partial<CreateKGViewTemplateParams>) => Promise<KGViewTemplateResponse>;
};

Defined in: packages/codeboltjs/src/modules/knowledgeGraph.ts:33

Type Declaration

NameTypeDescriptionDefined in
addEdge()(instanceId: string, edge: CreateKGEdgeParams) => Promise<KGEdgeResponse>Add an edge to an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:287
addEdges()(instanceId: string, edges: CreateKGEdgeParams[]) => Promise<KGEdgeListResponse>Add multiple edges to an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:303
addMemoryRecord()(instanceId: string, record: CreateKGMemoryRecordParams) => Promise<KGMemoryRecordResponse>Add a memory record to an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:186
addMemoryRecords()(instanceId: string, records: CreateKGMemoryRecordParams[]) => Promise<KGMemoryRecordListResponse>Add multiple memory records to an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:202
createInstance()(config: CreateKGInstanceParams) => Promise<KGInstanceResponse>Create a new knowledge graph instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:121
createInstanceTemplate()(config: CreateKGInstanceTemplateParams) => Promise<KGInstanceTemplateResponse>Create a new instance templatepackages/codeboltjs/src/modules/knowledgeGraph.ts:42
createView()(config: CreateKGViewParams) => Promise<KGViewResponse>Create a viewpackages/codeboltjs/src/modules/knowledgeGraph.ts:434
createViewTemplate()(config: CreateKGViewTemplateParams) => Promise<KGViewTemplateResponse>Create a view templatepackages/codeboltjs/src/modules/knowledgeGraph.ts:354
deleteEdge()(instanceId: string, edgeId: string) => Promise<KGDeleteResponse>Delete an edgepackages/codeboltjs/src/modules/knowledgeGraph.ts:335
deleteInstance()(instanceId: string) => Promise<KGDeleteResponse>Delete an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:166
deleteInstanceTemplate()(templateId: string) => Promise<KGDeleteResponse>Delete an instance templatepackages/codeboltjs/src/modules/knowledgeGraph.ts:102
deleteMemoryRecord()(instanceId: string, recordId: string) => Promise<KGDeleteResponse>Delete a memory recordpackages/codeboltjs/src/modules/knowledgeGraph.ts:267
deleteView()(viewId: string) => Promise<KGDeleteResponse>Delete a viewpackages/codeboltjs/src/modules/knowledgeGraph.ts:479
deleteViewTemplate()(templateId: string) => Promise<KGDeleteResponse>Delete a view templatepackages/codeboltjs/src/modules/knowledgeGraph.ts:415
executeView()(viewId: string) => Promise<KGViewExecuteResponse>Execute a view querypackages/codeboltjs/src/modules/knowledgeGraph.ts:464
getInstance()(instanceId: string) => Promise<KGInstanceResponse>Get an instance by IDpackages/codeboltjs/src/modules/knowledgeGraph.ts:136
getInstanceTemplate()(templateId: string) => Promise<KGInstanceTemplateResponse>Get an instance template by IDpackages/codeboltjs/src/modules/knowledgeGraph.ts:57
getMemoryRecord()(instanceId: string, recordId: string) => Promise<KGMemoryRecordResponse>Get a memory record by IDpackages/codeboltjs/src/modules/knowledgeGraph.ts:218
getViewTemplate()(templateId: string) => Promise<KGViewTemplateResponse>Get a view template by IDpackages/codeboltjs/src/modules/knowledgeGraph.ts:369
listEdges()(instanceId: string, filters?: ListKGEdgesParams) => Promise<KGEdgeListResponse>List edges in an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:319
listInstances()(templateId?: string) => Promise<KGInstanceListResponse>List instances, optionally filtered by templatepackages/codeboltjs/src/modules/knowledgeGraph.ts:151
listInstanceTemplates()() => Promise<KGInstanceTemplateListResponse>List all instance templatespackages/codeboltjs/src/modules/knowledgeGraph.ts:71
listMemoryRecords()(instanceId: string, filters?: ListKGMemoryRecordsParams) => Promise<KGMemoryRecordListResponse>List memory records in an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:234
listViews()(instanceId: string) => Promise<KGViewListResponse>List views for an instancepackages/codeboltjs/src/modules/knowledgeGraph.ts:449
listViewTemplates()(applicableTemplateId?: string) => Promise<KGViewTemplateListResponse>List view templatespackages/codeboltjs/src/modules/knowledgeGraph.ts:384
updateInstanceTemplate()(templateId: string, updates: Partial<CreateKGInstanceTemplateParams>) => Promise<KGInstanceTemplateResponse>Update an instance templatepackages/codeboltjs/src/modules/knowledgeGraph.ts:87
updateMemoryRecord()(instanceId: string, recordId: string, updates: Partial<CreateKGMemoryRecordParams>) => Promise<KGMemoryRecordResponse>Update a memory recordpackages/codeboltjs/src/modules/knowledgeGraph.ts:251
updateViewTemplate()(templateId: string, updates: Partial<CreateKGViewTemplateParams>) => Promise<KGViewTemplateResponse>Update a view templatepackages/codeboltjs/src/modules/knowledgeGraph.ts:400