EmbeddingsRepositoryImpl

internal class EmbeddingsRepositoryImpl(val rdsA1111: EmbeddingsDataSource.Remote.Automatic1111, val rdsSwarm: EmbeddingsDataSource.Remote.SwarmUi, val swarmSessionRemoteDataSource: SwarmUiModelsRemoteDataSource, val lds: EmbeddingsDataSource.Local, val preferenceManager: PreferenceManager, val sessionPreference: SessionPreference, val authorizationStore: AuthorizationStore) : EmbeddingsRepository(source)

Implements EmbeddingsRepository behavior in the SDAI data layer.

Author

Dmitriy Moroz

Constructors

Link copied to clipboard
constructor(rdsA1111: EmbeddingsDataSource.Remote.Automatic1111, rdsSwarm: EmbeddingsDataSource.Remote.SwarmUi, swarmSessionRemoteDataSource: SwarmUiModelsRemoteDataSource, lds: EmbeddingsDataSource.Local, preferenceManager: PreferenceManager, sessionPreference: SessionPreference, authorizationStore: AuthorizationStore)

Properties

Link copied to clipboard

Exposes the authorizationStore value used by the SDAI data layer.

Link copied to clipboard

Exposes the lds value used by the SDAI data layer.

Link copied to clipboard

Exposes the preferenceManager value used by the SDAI data layer.

Link copied to clipboard

Exposes the rdsA1111 value used by the SDAI data layer.

Link copied to clipboard

Exposes the rdsSwarm value used by the SDAI data layer.

Link copied to clipboard

Exposes the sessionPreference value used by the SDAI data layer.

Link copied to clipboard

Exposes the swarmSessionRemoteDataSource value used by the SDAI data layer.

Functions

Link copied to clipboard
open suspend override fun fetchAndGetEmbeddings(): List<Embedding>

Loads SDAI data through fetchAndGetEmbeddings.

Link copied to clipboard
open suspend override fun fetchEmbeddings()

Loads SDAI data through fetchEmbeddings.

Link copied to clipboard
private suspend fun fetchSwarmEmbeddings(): List<Embedding>

Loads SDAI data through fetchSwarmEmbeddings.

Link copied to clipboard
private suspend fun forceRenewSession(baseUrl: String, credentials: AuthorizationCredentials): String

Executes the forceRenewSession step in the SDAI data layer.

Link copied to clipboard
open suspend override fun getEmbeddings(): List<Embedding>

Loads SDAI data through getEmbeddings.

Link copied to clipboard
private suspend fun getSessionId(baseUrl: String, credentials: AuthorizationCredentials): String

Loads SDAI data through getSessionId.