feat: trying to create clips...probs a waste of time grrrrrrr
This commit is contained in:
@@ -63,7 +63,7 @@ public sealed class GeminiAnalyzer(
|
||||
.Parts?.FirstOrDefault()?
|
||||
.Text;
|
||||
|
||||
var clips = JsonSerializer.Deserialize<List<ShortClip>>(candidatesText ?? string.Empty);
|
||||
var clips = JsonSerializer.Deserialize<List<ShortCandidate>>(candidatesText ?? string.Empty);
|
||||
return new TranscriptAnalysis(clips ?? []);
|
||||
}
|
||||
}
|
||||
|
||||
+2
-2
@@ -3,9 +3,9 @@ using System.Text.Json.Serialization;
|
||||
namespace StreamShorts.Library.Analysis;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a short clip derived from a transcript
|
||||
/// Represents a short candidate derived from a transcript.
|
||||
/// </summary>
|
||||
public record ShortClip(
|
||||
public record ShortCandidate(
|
||||
[property: JsonPropertyName("title")]
|
||||
string Title,
|
||||
[property: JsonPropertyName("description")]
|
||||
@@ -3,10 +3,10 @@ namespace StreamShorts.Library.Analysis;
|
||||
/// <summary>
|
||||
/// Represents the analysis of a transcript, containing short clips derived from the transcript.
|
||||
/// </summary>
|
||||
public sealed class TranscriptAnalysis(IEnumerable<ShortClip> shortClips)
|
||||
public sealed class TranscriptAnalysis(IEnumerable<ShortCandidate> candidates)
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the short clips derived from the transcript.
|
||||
/// </summary>
|
||||
public IEnumerable<ShortClip> ShortClips { get; init; } = shortClips;
|
||||
public IEnumerable<ShortCandidate> Candidates { get; init; } = candidates;
|
||||
}
|
||||
Reference in New Issue
Block a user