mirror of
https://github.com/moltbot/moltbot.git
synced 2026-04-21 13:44:03 +00:00
refactor: move voice-call realtime providers into extensions
This commit is contained in:
@@ -20,6 +20,8 @@ export function createTestPluginApi(api: TestPluginApiInput): OpenClawPluginApi
|
||||
registerCliBackend() {},
|
||||
registerProvider() {},
|
||||
registerSpeechProvider() {},
|
||||
registerRealtimeTranscriptionProvider() {},
|
||||
registerRealtimeVoiceProvider() {},
|
||||
registerMediaUnderstandingProvider() {},
|
||||
registerImageGenerationProvider() {},
|
||||
registerWebFetchProvider() {},
|
||||
|
||||
@@ -92,6 +92,8 @@ export const pluginRegistrationContractCases = {
|
||||
pluginId: "openai",
|
||||
providerIds: ["openai", "openai-codex"],
|
||||
speechProviderIds: ["openai"],
|
||||
realtimeTranscriptionProviderIds: ["openai"],
|
||||
realtimeVoiceProviderIds: ["openai"],
|
||||
mediaUnderstandingProviderIds: ["openai", "openai-codex"],
|
||||
imageGenerationProviderIds: ["openai"],
|
||||
cliBackendIds: ["codex-cli"],
|
||||
|
||||
@@ -13,6 +13,8 @@ type PluginRegistrationContractParams = {
|
||||
webFetchProviderIds?: string[];
|
||||
webSearchProviderIds?: string[];
|
||||
speechProviderIds?: string[];
|
||||
realtimeTranscriptionProviderIds?: string[];
|
||||
realtimeVoiceProviderIds?: string[];
|
||||
mediaUnderstandingProviderIds?: string[];
|
||||
imageGenerationProviderIds?: string[];
|
||||
cliBackendIds?: string[];
|
||||
@@ -122,6 +124,22 @@ export function describePluginRegistrationContract(params: PluginRegistrationCon
|
||||
});
|
||||
}
|
||||
|
||||
if (params.realtimeTranscriptionProviderIds) {
|
||||
it("keeps bundled realtime-transcription ownership explicit", () => {
|
||||
expect(findRegistration(params.pluginId).realtimeTranscriptionProviderIds).toEqual(
|
||||
params.realtimeTranscriptionProviderIds,
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
if (params.realtimeVoiceProviderIds) {
|
||||
it("keeps bundled realtime-voice ownership explicit", () => {
|
||||
expect(findRegistration(params.pluginId).realtimeVoiceProviderIds).toEqual(
|
||||
params.realtimeVoiceProviderIds,
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
if (params.mediaUnderstandingProviderIds) {
|
||||
it("keeps bundled media-understanding ownership explicit", () => {
|
||||
expect(findRegistration(params.pluginId).mediaUnderstandingProviderIds).toEqual(
|
||||
|
||||
@@ -110,6 +110,8 @@ function createTestRegistryForSetup(
|
||||
})),
|
||||
providers: [],
|
||||
speechProviders: [],
|
||||
realtimeTranscriptionProviders: [],
|
||||
realtimeVoiceProviders: [],
|
||||
mediaUnderstandingProviders: [],
|
||||
imageGenerationProviders: [],
|
||||
webFetchProviders: [],
|
||||
|
||||
Reference in New Issue
Block a user