Versions in this module Expand all Collapse all v0 v0.2.0 Jan 21, 2026 v0.1.0 Jan 21, 2026 Changes in this version + type ChunksDBHandler struct + func NewChunksDBHandler(db *helper.Database, edgesHandler *EdgesDBHandler, embeddingDim int, ...) (*ChunksDBHandler, error) + func (h *ChunksDBHandler) ChangeIndexType(ctx context.Context, indexType string, params map[string]interface{}) error + func (h *ChunksDBHandler) CreateTable(embeddingDim int) error + func (h *ChunksDBHandler) DeleteChunk(id uuid.UUID) error + func (h *ChunksDBHandler) InsertChunk(chunk *model.Chunk) error + func (h *ChunksDBHandler) SelectAllChunksByDocument(documentRID uuid.UUID) ([]*model.Chunk, error) + func (h *ChunksDBHandler) SelectAllChunksByPathAncestor(path string) ([]*model.Chunk, error) + func (h *ChunksDBHandler) SelectAllChunksByPathDescendant(path string) ([]*model.Chunk, error) + func (h *ChunksDBHandler) SelectChunk(id uuid.UUID) (*model.Chunk, error) + func (h *ChunksDBHandler) SelectChunksBySimilarity(embedding []float32, limit int, threshold float64, documentRIDs []uuid.UUID) ([]*model.Chunk, error) + func (h *ChunksDBHandler) SelectChunksBySimilarityWithContext(embedding []float32, limit int, includeAncestors bool, includeDescendants bool, ...) ([]*model.Chunk, error) + func (h *ChunksDBHandler) SelectSiblingChunks(path string) ([]*model.Chunk, error) + func (h *ChunksDBHandler) UpdateChunkEmbedding(id uuid.UUID, embedding []float32) error + type ChunksDBHandlerFunctions interface + DeleteChunk func(id uuid.UUID) error + InsertChunk func(chunk *model.Chunk) error + SelectAllChunksByDocument func(documentRID uuid.UUID) ([]*model.Chunk, error) + SelectAllChunksByPathAncestor func(path string) ([]*model.Chunk, error) + SelectAllChunksByPathDescendant func(path string) ([]*model.Chunk, error) + SelectChunk func(id uuid.UUID) (*model.Chunk, error) + SelectChunksBySimilarity func(embedding []float32, limit int, threshold float64, documentRIDs []uuid.UUID) ([]*model.Chunk, error) + SelectChunksBySimilarityWithContext func(embedding []float32, limit int, includeAncestors bool, includeDescendants bool, ...) ([]*model.Chunk, error) + UpdateChunkEmbedding func(id uuid.UUID, embedding []float32) error + type DocumentsDBHandler struct + func NewDocumentsDBHandler(db *helper.Database, force bool) (*DocumentsDBHandler, error) + func (h *DocumentsDBHandler) CreateTable() error + func (h *DocumentsDBHandler) DeleteDocument(rid uuid.UUID) error + func (h *DocumentsDBHandler) InsertDocument(doc *model.Document) error + func (h *DocumentsDBHandler) SelectAllDocuments(lastCreatedAt *time.Time, limit int) ([]*model.Document, error) + func (h *DocumentsDBHandler) SelectDocument(rid uuid.UUID) (*model.Document, error) + func (h *DocumentsDBHandler) SelectDocumentsBySearch(searchTerm string, limit int) ([]*model.Document, error) + func (h *DocumentsDBHandler) UpdateDocument(doc *model.Document) error + type DocumentsDBHandlerFunctions interface + DeleteDocument func(rid uuid.UUID) error + InsertDocument func(doc *model.Document) error + SelectAllDocuments func(lastCreatedAt *time.Time, limit int) ([]*model.Document, error) + SelectDocument func(rid uuid.UUID) (*model.Document, error) + SelectDocumentsBySearch func(searchTerm string, limit int) ([]*model.Document, error) + UpdateDocument func(doc *model.Document) error + type EdgesDBHandler struct + func NewEdgesDBHandler(db *helper.Database, force bool) (*EdgesDBHandler, error) + func (h *EdgesDBHandler) CreateTable() error + func (h *EdgesDBHandler) DeleteEdge(id uuid.UUID) error + func (h *EdgesDBHandler) InsertEdge(edge *model.Edge) error + func (h *EdgesDBHandler) SelectEdge(id uuid.UUID) (*model.Edge, error) + func (h *EdgesDBHandler) SelectEdgesConnectedToChunk(chunkID uuid.UUID, edgeType *model.EdgeType) ([]*model.EdgeConnection, error) + func (h *EdgesDBHandler) SelectEdgesFromChunk(chunkID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + func (h *EdgesDBHandler) SelectEdgesFromEntity(entityID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + func (h *EdgesDBHandler) SelectEdgesToChunk(chunkID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + func (h *EdgesDBHandler) SelectEdgesToEntity(entityID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + func (h *EdgesDBHandler) TraverseBFSFromChunk(startChunkID uuid.UUID, maxDepth int, edgeType *model.EdgeType) ([]*model.TraversalNode, error) + func (h *EdgesDBHandler) UpdateEdgeWeight(id uuid.UUID, weight float64) error + type EdgesDBHandlerFunctions interface + DeleteEdge func(id uuid.UUID) error + InsertEdge func(edge *model.Edge) error + SelectEdge func(id uuid.UUID) (*model.Edge, error) + SelectEdgesConnectedToChunk func(chunkID uuid.UUID, edgeType *model.EdgeType) ([]*model.EdgeConnection, error) + SelectEdgesFromChunk func(chunkID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + SelectEdgesFromEntity func(entityID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + SelectEdgesToChunk func(chunkID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + SelectEdgesToEntity func(entityID uuid.UUID, edgeType *model.EdgeType) ([]*model.Edge, error) + TraverseBFSFromChunk func(startChunkID uuid.UUID, maxDepth int, edgeType *model.EdgeType) ([]*model.TraversalNode, error) + UpdateEdgeWeight func(id uuid.UUID, weight float64) error + type EntitiesDBHandler struct + func NewEntitiesDBHandler(db *helper.Database, force bool) (*EntitiesDBHandler, error) + func (h *EntitiesDBHandler) CreateTable() error + func (h *EntitiesDBHandler) DeleteEntity(id uuid.UUID) error + func (h *EntitiesDBHandler) GetChunksForEntity(ctx context.Context, entityID string) ([]*model.Chunk, error) + func (h *EntitiesDBHandler) GetEntity(ctx context.Context, id string) (*model.Entity, error) + func (h *EntitiesDBHandler) InsertEntity(entity *model.Entity) error + func (h *EntitiesDBHandler) SelectChunksMentioningEntity(entityID uuid.UUID) ([]*model.ChunkMention, error) + func (h *EntitiesDBHandler) SelectEntitiesBySearch(searchTerm string, entityType *string, limit int) ([]*model.Entity, error) + func (h *EntitiesDBHandler) SelectEntitiesByType(entityType string, limit int) ([]*model.Entity, error) + func (h *EntitiesDBHandler) SelectEntity(id uuid.UUID) (*model.Entity, error) + func (h *EntitiesDBHandler) SelectEntityByName(name string, entityType string) (*model.Entity, error) + func (h *EntitiesDBHandler) UpdateEntityMetadata(id uuid.UUID, metadata model.Metadata) error + type EntitiesDBHandlerFunctions interface + DeleteEntity func(id uuid.UUID) error + InsertEntity func(entity *model.Entity) error + SelectChunksMentioningEntity func(entityID uuid.UUID) ([]*model.ChunkMention, error) + SelectEntitiesBySearch func(searchTerm string, entityType *string, limit int) ([]*model.Entity, error) + SelectEntitiesByType func(entityType string, limit int) ([]*model.Entity, error) + SelectEntity func(id uuid.UUID) (*model.Entity, error) + SelectEntityByName func(name string, entityType string) (*model.Entity, error) + UpdateEntityMetadata func(id uuid.UUID, metadata map[string]interface{}) error