Public Access
Add meeting assistant speech and summary automation
This commit is contained in:
@@ -46,6 +46,10 @@ public sealed class CompositeMeetingAudioSource : IMeetingAudioSource
|
||||
|
||||
await foreach (var sourceChunk in channel.Reader.ReadAllAsync(cancellationToken))
|
||||
{
|
||||
logger.LogDebug(
|
||||
"Captured {ByteCount} byte(s) from {SourceKind}",
|
||||
sourceChunk.Chunk.Pcm.Length,
|
||||
sourceChunk.Kind);
|
||||
if (sourceChunk.Kind == AudioSourceKind.Microphone)
|
||||
{
|
||||
pendingMicrophone = sourceChunk.Chunk;
|
||||
@@ -106,9 +110,21 @@ public sealed class CompositeMeetingAudioSource : IMeetingAudioSource
|
||||
ChannelWriter<SourceChunk> writer,
|
||||
CancellationToken cancellationToken)
|
||||
{
|
||||
await foreach (var chunk in source.CaptureAsync(cancellationToken))
|
||||
try
|
||||
{
|
||||
await writer.WriteAsync(new SourceChunk(kind, chunk), cancellationToken);
|
||||
await foreach (var chunk in source.CaptureAsync(cancellationToken))
|
||||
{
|
||||
await writer.WriteAsync(new SourceChunk(kind, chunk), cancellationToken);
|
||||
}
|
||||
}
|
||||
catch (OperationCanceledException) when (cancellationToken.IsCancellationRequested)
|
||||
{
|
||||
throw;
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
writer.TryComplete(new InvalidOperationException($"{kind} audio capture failed.", exception));
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user