TsgcAIOpenAIEmbeddings › Events › OnCreateEmbeddingsStop
Fired once when the batch of embeddings has finished.
property OnCreateEmbeddingsStop: TsgcOpenAICreateEmbeddingsStop;
// TsgcOpenAICreateEmbeddingsStop = procedure(Sender: TObject) of object
—
Triggered once at the end of a call to CreateEmbeddings or CreateEmbeddingsFromFile, after the last chunk has been processed and the database storage has been closed. It fires in a finally block, so it is raised both on a successful run and when an exception aborts the batch; it is the right place to hide a progress dialog or reset UI state.
procedure TForm1.oEmbeddingsCreateEmbeddingsStop(Sender: TObject);
begin
ProgressBar1.Position := ProgressBar1.Max;
Status.Caption := 'Embeddings batch completed';
end;