Ai Assistant
interface AiAssistant
Interface defining the contract for an AI Assistant. This interface declares the methods that any AI Assistant implementation must provide.
Properties
Functions
Link copied to clipboard
abstract suspend fun checkIfDocumentIsAlreadyIngested(documentId: String, fileHash: String): AiAssistantRemoteClient.AiAssistantResponse<None>
Checks if a document is already ingested by verifying its ID and file hash.
Link copied to clipboard
Emits a message to the server.
Link copied to clipboard
abstract suspend fun getSessionHistory(): AiAssistantRemoteClient.AiAssistantResponse<List<CompletionResponse>>
Retrieves the session history for a given session ID.
Link copied to clipboard
abstract suspend fun ingestDocument(dataProvider: DataProvider, jwt: String): AiAssistantRemoteClient.AiAssistantResponse<IngestionResponse>
Ingests a document by uploading it to the server.
Link copied to clipboard
abstract suspend fun initialize(dataProvider: DataProvider, documentIdentifiers: DocumentIdentifiers, withSessionHistory: Boolean = true)
Initializes the assistant with the given data.
Link copied to clipboard
Initializes a socket connection with the given text.
Link copied to clipboard
Updates the assistant with the latest data.