Surface unreadable vector stores as a repairable failure

This commit is contained in:
Thorsten Sommer committed 2026-09-18 13:49:01 +02:00
1 parent 79c094b660
commit d69304606c
5 files changed
+119 -7

No files matched your search

@@ -7,6 +7,10 @@ namespace AIStudio.Tools.Services;
/// CurrentFileBlock and CurrentFilePage are null rather than zero while nothing is known about
/// them: a file which is only about to start has no first block, and not every kind of document
/// has pages to count. Block numbers start at one, the way the page states them.
///
/// VectorStoreUnreadable says why a data source failed, not only that it did. The UI needs that
/// difference to offer the repair for this one case, and it is carried as its own flag so nothing
/// has to read it back out of the message in LastError.
/// </remarks>
public sealed record DataSourceEmbeddingStatus(
string DataSourceId,
@@ -21,7 +25,8 @@ public sealed record DataSourceEmbeddingStatus(
IReadOnlyList<DataSourceEmbeddingFailure> Failures,
int PermanentlySkippedFiles = 0,
int? CurrentFileBlock = null,
int? CurrentFilePage = null)
int? CurrentFilePage = null,
bool VectorStoreUnreadable = false)
{
private static string TB(string fallbackEN) => I18N.I.T(fallbackEN, typeof(DataSourceEmbeddingStatus).Namespace, nameof(DataSourceEmbeddingStatus));