From efe7c4ba0a8bbf1ea59306e3eacb73f2f7a12f14 Mon Sep 17 00:00:00 2001 From: Codex Automation Date: Wed, 3 Jun 2026 07:17:00 +0200 Subject: [PATCH] Change English profile hotkey --- .../AsrDiagnosticEndpointTests.cs | 2 +- ...edSpeechRecognitionPipelineFactoryTests.cs | 2 +- .../LaunchProfileOptionsProviderTests.cs | 40 +++++++++++++++++-- .../RecordingCoordinatorTests.cs | 2 +- MeetingAssistant.Tests/TaskbarIconTests.cs | 8 ++-- MeetingAssistant/appsettings.json | 2 +- docs/meeting-assistant-configuration.md | 2 +- openspec/specs/meeting-session/spec.md | 4 +- 8 files changed, 48 insertions(+), 14 deletions(-) diff --git a/MeetingAssistant.Tests/AsrDiagnosticEndpointTests.cs b/MeetingAssistant.Tests/AsrDiagnosticEndpointTests.cs index 2c3bfec..c677285 100644 --- a/MeetingAssistant.Tests/AsrDiagnosticEndpointTests.cs +++ b/MeetingAssistant.Tests/AsrDiagnosticEndpointTests.cs @@ -42,7 +42,7 @@ public sealed class AsrDiagnosticEndpointTests configuration.AddInMemoryCollection(new Dictionary { ["MeetingAssistant:FunAsr:Backend:Enabled"] = "false", - ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+E", + ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+L", ["MeetingAssistant:LaunchProfiles:english:AzureSpeech:Language"] = "en-US" }); }); diff --git a/MeetingAssistant.Tests/ConfiguredSpeechRecognitionPipelineFactoryTests.cs b/MeetingAssistant.Tests/ConfiguredSpeechRecognitionPipelineFactoryTests.cs index 29dc452..b796922 100644 --- a/MeetingAssistant.Tests/ConfiguredSpeechRecognitionPipelineFactoryTests.cs +++ b/MeetingAssistant.Tests/ConfiguredSpeechRecognitionPipelineFactoryTests.cs @@ -46,7 +46,7 @@ public sealed class ConfiguredSpeechRecognitionPipelineFactoryTests { ["MeetingAssistant:Recording:TranscriptionProvider"] = "capturing", ["MeetingAssistant:Agent:Model"] = "default-model", - ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+E", + ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+L", ["MeetingAssistant:LaunchProfiles:english:Recording:TranscriptionProvider"] = "capturing", ["MeetingAssistant:LaunchProfiles:english:Agent:Model"] = "english-model" }) diff --git a/MeetingAssistant.Tests/LaunchProfileOptionsProviderTests.cs b/MeetingAssistant.Tests/LaunchProfileOptionsProviderTests.cs index bce8fb4..a39d570 100644 --- a/MeetingAssistant.Tests/LaunchProfileOptionsProviderTests.cs +++ b/MeetingAssistant.Tests/LaunchProfileOptionsProviderTests.cs @@ -33,7 +33,7 @@ public sealed class LaunchProfileOptionsProviderTests ["MeetingAssistant:AzureSpeech:Region"] = "germanywestcentral", ["MeetingAssistant:AzureSpeech:Language"] = "de-DE", ["MeetingAssistant:AzureSpeech:AutoDetectLanguages:0"] = "de-DE", - ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+E", + ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+L", ["MeetingAssistant:LaunchProfiles:english:AzureSpeech:Language"] = "en-US", ["MeetingAssistant:LaunchProfiles:english:AzureSpeech:AutoDetectLanguages:0"] = "en-US" }); @@ -41,13 +41,23 @@ public sealed class LaunchProfileOptionsProviderTests var profile = provider.GetRequiredProfile("english"); Assert.Equal("english", profile.Name); - Assert.Equal("Ctrl+Alt+E", profile.Options.Hotkey.Toggle); + Assert.Equal("Ctrl+Alt+L", profile.Options.Hotkey.Toggle); Assert.Equal("azure-speech", profile.Options.Recording.TranscriptionProvider); Assert.Equal("germanywestcentral", profile.Options.AzureSpeech.Region); Assert.Equal("en-US", profile.Options.AzureSpeech.Language); Assert.Equal(["en-US"], profile.Options.AzureSpeech.AutoDetectLanguages); } + [Fact] + public void CheckedInEnglishProfileUsesLanguageHotkey() + { + var provider = CreateProviderFromAppsettings(); + + var profile = provider.GetRequiredProfile("english"); + + Assert.Equal("Ctrl+Alt+L", profile.Options.Hotkey.Toggle); + } + [Fact] public void DuplicateProfileHotkeysAreRejected() { @@ -69,7 +79,7 @@ public sealed class LaunchProfileOptionsProviderTests ["MeetingAssistant:Hotkey:Toggle"] = "Ctrl+Alt+M", ["MeetingAssistant:Hotkey:Abort"] = "Ctrl+Alt+Z", ["MeetingAssistant:Screenshots:Hotkey"] = "Ctrl+Alt+S", - ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+E", + ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+L", ["MeetingAssistant:LaunchProfiles:english:Hotkey:Abort"] = "Ctrl+Alt+Shift+D", ["MeetingAssistant:LaunchProfiles:english:Screenshots:Hotkey"] = "Ctrl+Alt+Shift+S" }); @@ -136,4 +146,28 @@ public sealed class LaunchProfileOptionsProviderTests .Build(); return new ConfigurationLaunchProfileOptionsProvider(configuration); } + + private static ConfigurationLaunchProfileOptionsProvider CreateProviderFromAppsettings() + { + var root = FindRepositoryRoot(); + var configuration = new ConfigurationBuilder() + .AddJsonFile(Path.Combine(root, "MeetingAssistant", "appsettings.json"), optional: false) + .Build(); + return new ConfigurationLaunchProfileOptionsProvider(configuration); + } + + private static string FindRepositoryRoot() + { + for (var directory = new DirectoryInfo(AppContext.BaseDirectory); + directory is not null; + directory = directory.Parent) + { + if (File.Exists(Path.Combine(directory.FullName, "MeetingAssistant.slnx"))) + { + return directory.FullName; + } + } + + throw new InvalidOperationException("Could not locate MeetingAssistant.slnx from the test output folder."); + } } diff --git a/MeetingAssistant.Tests/RecordingCoordinatorTests.cs b/MeetingAssistant.Tests/RecordingCoordinatorTests.cs index 6cefde5..af9d00e 100644 --- a/MeetingAssistant.Tests/RecordingCoordinatorTests.cs +++ b/MeetingAssistant.Tests/RecordingCoordinatorTests.cs @@ -1987,7 +1987,7 @@ public sealed class RecordingCoordinatorTests ["MeetingAssistant:Vault:SummariesFolder"] = "Summaries", ["MeetingAssistant:Recording:TemporaryRecordingsFolder"] = Path.Combine(defaultRoot, "Recordings"), ["MeetingAssistant:Agent:Model"] = "default-summary-model", - ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+E", + ["MeetingAssistant:LaunchProfiles:english:Hotkey:Toggle"] = "Ctrl+Alt+L", ["MeetingAssistant:LaunchProfiles:english:Vault:BaseFolder"] = englishRoot, ["MeetingAssistant:LaunchProfiles:english:Recording:TemporaryRecordingsFolder"] = Path.Combine(englishRoot, "Recordings"), ["MeetingAssistant:LaunchProfiles:english:Agent:Model"] = "english-summary-model" diff --git a/MeetingAssistant.Tests/TaskbarIconTests.cs b/MeetingAssistant.Tests/TaskbarIconTests.cs index f726ed0..acd8f08 100644 --- a/MeetingAssistant.Tests/TaskbarIconTests.cs +++ b/MeetingAssistant.Tests/TaskbarIconTests.cs @@ -13,7 +13,7 @@ public sealed class TaskbarIconTests { var menu = MeetingTaskbarMenuBuilder.Build( Status(), - [Profile("default", "Ctrl+Alt+M"), Profile("english", "Ctrl+Alt+E")]); + [Profile("default", "Ctrl+Alt+M"), Profile("english", "Ctrl+Alt+L")]); Assert.Equal(RecordingProcessState.Idle, menu.State); Assert.Contains(menu.Items, item => @@ -26,7 +26,7 @@ public sealed class TaskbarIconTests Assert.Contains(menu.Items, item => item.Action == MeetingTaskbarAction.StartRecording && item.ProfileName == "english" && - item.Text == "Start meeting recording (english)\tCtrl+Alt+E"); + item.Text == "Start meeting recording (english)\tCtrl+Alt+L"); Assert.DoesNotContain(menu.Items, item => item.Action == MeetingTaskbarAction.StopRecording); Assert.DoesNotContain(menu.Items, item => item.Action == MeetingTaskbarAction.AbortRecording); } @@ -36,7 +36,7 @@ public sealed class TaskbarIconTests { var menu = MeetingTaskbarMenuBuilder.Build( Status(isRecording: true, state: RecordingProcessState.Recording, profile: "default"), - [Profile("default", "Ctrl+Alt+M"), Profile("english", "Ctrl+Alt+E"), Profile("french", "Ctrl+Alt+F")]); + [Profile("default", "Ctrl+Alt+M"), Profile("english", "Ctrl+Alt+L"), Profile("french", "Ctrl+Alt+F")]); Assert.Equal(RecordingProcessState.Recording, menu.State); Assert.Contains(menu.Items, item => item.Action == MeetingTaskbarAction.StopRecording); @@ -44,7 +44,7 @@ public sealed class TaskbarIconTests Assert.Contains(menu.Items, item => item.Action == MeetingTaskbarAction.SwitchProfile && item.ProfileName == "english" && - item.Text == "Switch to english\tCtrl+Alt+E"); + item.Text == "Switch to english\tCtrl+Alt+L"); Assert.Contains(menu.Items, item => item.Action == MeetingTaskbarAction.SwitchProfile && item.ProfileName == "french" && diff --git a/MeetingAssistant/appsettings.json b/MeetingAssistant/appsettings.json index 00b221e..f648fb6 100644 --- a/MeetingAssistant/appsettings.json +++ b/MeetingAssistant/appsettings.json @@ -182,7 +182,7 @@ "LaunchProfiles": { "english": { "Hotkey": { - "Toggle": "Ctrl+Alt+E" + "Toggle": "Ctrl+Alt+L" }, "AzureSpeech": { "Language": "en-US", diff --git a/docs/meeting-assistant-configuration.md b/docs/meeting-assistant-configuration.md index de18916..75dcb71 100644 --- a/docs/meeting-assistant-configuration.md +++ b/docs/meeting-assistant-configuration.md @@ -64,7 +64,7 @@ This example is abbreviated so the most common shape is readable. The checked-in "LaunchProfiles": { "english": { "Hotkey": { - "Toggle": "Ctrl+Alt+E" + "Toggle": "Ctrl+Alt+L" }, "AzureSpeech": { "Language": "en-US", diff --git a/openspec/specs/meeting-session/spec.md b/openspec/specs/meeting-session/spec.md index d32d205..b2c9a37 100644 --- a/openspec/specs/meeting-session/spec.md +++ b/openspec/specs/meeting-session/spec.md @@ -228,10 +228,10 @@ Meeting Assistant SHALL provide a diagnostic endpoint that opens the workflow ru #### Scenario: Tray menu shows configured profile hotkeys - **GIVEN** the `default` launch profile uses `Ctrl+Alt+M` -- **AND** the `english` launch profile uses `Ctrl+Alt+E` +- **AND** the `english` launch profile uses `Ctrl+Alt+L` - **WHEN** the user opens the tray icon menu while Meeting Assistant is idle - **THEN** the menu includes a start item for `default` showing `Ctrl+Alt+M` -- **AND** the menu includes a start item for `english` showing `Ctrl+Alt+E` +- **AND** the menu includes a start item for `english` showing `Ctrl+Alt+L` #### Scenario: Rules editor can be opened diagnostically - **WHEN** a diagnostic caller requests the workflow rules editor to open