Files

54 lines
1.5 KiB
C#

namespace MarketAlly.GitCommitEditor.Models;
/// <summary>
/// Result of batch AI suggestion generation.
/// </summary>
public class BatchSuggestionResult
{
/// <summary>
/// All analyses that were processed.
/// </summary>
public IReadOnlyList<CommitAnalysis> Analyses { get; init; } = Array.Empty<CommitAnalysis>();
/// <summary>
/// Number of commits that got successful AI suggestions.
/// </summary>
public int SuccessCount { get; init; }
/// <summary>
/// Number of commits where AI failed to generate a different suggestion.
/// </summary>
public int FailedCount { get; init; }
/// <summary>
/// Details of each failure for logging/display.
/// </summary>
public IReadOnlyList<SuggestionFailure> Failures { get; init; } = Array.Empty<SuggestionFailure>();
}
/// <summary>
/// Details of a single suggestion failure.
/// </summary>
public class SuggestionFailure
{
/// <summary>
/// The commit hash (short form).
/// </summary>
public string CommitHash { get; init; } = string.Empty;
/// <summary>
/// The original message that couldn't be improved.
/// </summary>
public string OriginalMessage { get; init; } = string.Empty;
/// <summary>
/// Why the suggestion failed.
/// </summary>
public string Reason { get; init; } = string.Empty;
/// <summary>
/// Raw AI response for debugging (if available).
/// </summary>
public string? RawResponse { get; init; }
}