AbstractWritableContentElementRepository

Convenience base class for WritableRagService implementations.

Inheritors

Constructors

Link copied to clipboard
constructor(chunkerConfig: ContentChunker.Config)

Functions

Link copied to clipboard
abstract fun count(): Int

Return the total number of content elements in the repository

Link copied to clipboard
abstract fun findById(id: String): ContentElement?
Link copied to clipboard
abstract fun findChunksById(chunkIds: List<String>): List<Chunk>
Link copied to clipboard
abstract fun findChunksForEntity(entityId: String): List<Chunk>
Link copied to clipboard
abstract fun onNewRetrievables(retrievables: List<Retrievable>)

The Retrievables have been saved to the store, but Retrievables are special, and we probably want to embed them

Link copied to clipboard
open fun provision()

Provision this rag service if necessary

Link copied to clipboard
abstract fun save(element: ContentElement): ContentElement
Link copied to clipboard

Will call save on the root and all descendants. The database only needs to store each descendant and link by id, rather than otherwise consider the entire structure.