feat: Implement AI workload settings and enhance AI processing summaries
This commit is contained in:
parent
4230300518
commit
88c193549f
8 changed files with 326 additions and 28 deletions
|
|
@ -12,14 +12,31 @@ public sealed class AiExtractionRequest
|
|||
public bool IncludeThumbnails { get; init; }
|
||||
public required string ModelsFolderPath { get; init; }
|
||||
public bool UseGpu { get; init; }
|
||||
public int WorkloadLevel { get; init; } = 3;
|
||||
public string CsvOutputPath { get; init; } = string.Empty;
|
||||
}
|
||||
|
||||
public sealed record AiExtractionProgressUpdate(
|
||||
int TotalFiles,
|
||||
int ProcessedFiles,
|
||||
double PercentComplete,
|
||||
double AverageImagesPerSecond,
|
||||
int WorkloadLevel,
|
||||
int WorkerCount);
|
||||
|
||||
public sealed record AiExtractionRunSummary(
|
||||
int TotalFiles,
|
||||
int ProcessedFiles,
|
||||
int FailedFiles,
|
||||
double AverageImagesPerSecond,
|
||||
int WorkloadLevel,
|
||||
int WorkerCount);
|
||||
|
||||
public interface IAiExtractionService
|
||||
{
|
||||
Task RunAsync(
|
||||
Task<AiExtractionRunSummary> RunAsync(
|
||||
AiExtractionRequest request,
|
||||
CancellationToken token,
|
||||
Func<AiResultItem, Task> onResult,
|
||||
Func<double, Task> onProgress);
|
||||
Func<AiExtractionProgressUpdate, Task> onProgress);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue