From 49d088a3100f1ebb0e957882ff40e1e824cfcb0b Mon Sep 17 00:00:00 2001 From: Dooy Date: Tue, 31 Dec 2024 17:31:40 +0800 Subject: [PATCH] 2.22.9 --- package.json | 6 +++--- pnpm-lock.yaml | 9 +++++---- src-tauri/tauri.conf.json | 2 +- src/store/homeStore.ts | 1 + src/views/wav/realtime.vue | 8 +++++--- src/views/wav/wavSetting.vue | 9 +++++++++ 6 files changed, 24 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index 7ea0e0f64a..0f9445c787 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "chatgpt-web-midjourney-proxy", - "version": "2.22.8", + "version": "2.22.9", "private": false, "description": "ChatGPT Web Midjourney Proxy", "author": "Dooy ", @@ -51,12 +51,12 @@ "vue-waterfall-plugin-next": "^2.3.1" }, "devDependencies": { - "@openai/realtime-api-beta": "github:dooy/openai-realtime-api-beta", - "@openai/realtime-wavtools": "github:dooy/openai-realtime-wavtools", "@antfu/eslint-config": "^0.35.3", "@commitlint/cli": "^17.4.4", "@commitlint/config-conventional": "^17.4.4", "@iconify/vue": "^4.1.0", + "@openai/realtime-api-beta": "github:dooy/openai-realtime-api-beta", + "@openai/realtime-wavtools": "github:dooy/openai-realtime-wavtools", "@tauri-apps/cli": "^1.5.11", "@types/crypto-js": "^4.1.1", "@types/katex": "^0.16.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ffa5e3e5e1..478420029b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -77,7 +77,7 @@ devDependencies: version: 4.1.0(vue@3.2.47) '@openai/realtime-api-beta': specifier: github:dooy/openai-realtime-api-beta - version: github.com/dooy/openai-realtime-api-beta/97caf021ddccb2144b0a26c6ace43f323c732e0c + version: github.com/dooy/openai-realtime-api-beta/e76ff149959a2942c378f3d546ce9a3e33570673 '@openai/realtime-wavtools': specifier: github:dooy/openai-realtime-wavtools version: github.com/dooy/openai-realtime-wavtools/1f6584a52a68f048d76f0b3df523ca1533cae04d @@ -7236,6 +7236,7 @@ packages: /workbox-google-analytics@6.5.4: resolution: {integrity: sha512-8AU1WuaXsD49249Wq0B2zn4a/vvFfHkpcFfqAFHNHwln3jK9QUYmzdkKXGIZl9wyKNP+RRX30vcgcyWMcZ9VAg==} + deprecated: It is not compatible with newer versions of GA starting with v4, as long as you are using GAv3 it should be ok, but the package is not longer being maintained dependencies: workbox-background-sync: 6.5.4 workbox-core: 6.5.4 @@ -7409,10 +7410,10 @@ packages: engines: {node: '>=10'} dev: true - github.com/dooy/openai-realtime-api-beta/97caf021ddccb2144b0a26c6ace43f323c732e0c: - resolution: {tarball: https://codeload.github.com/dooy/openai-realtime-api-beta/tar.gz/97caf021ddccb2144b0a26c6ace43f323c732e0c} + github.com/dooy/openai-realtime-api-beta/e76ff149959a2942c378f3d546ce9a3e33570673: + resolution: {tarball: https://codeload.github.com/dooy/openai-realtime-api-beta/tar.gz/e76ff149959a2942c378f3d546ce9a3e33570673} name: '@openai/realtime-api-beta' - version: 0.0.0 + version: 0.0.3 dependencies: ws: 8.18.0 transitivePeerDependencies: diff --git a/src-tauri/tauri.conf.json b/src-tauri/tauri.conf.json index 13b26a89e0..bd7834f60e 100644 --- a/src-tauri/tauri.conf.json +++ b/src-tauri/tauri.conf.json @@ -8,7 +8,7 @@ }, "package": { "productName": "ChatGPT-MJ", - "version": "2.22.8" + "version": "2.22.9" }, "tauri": { "allowlist": { diff --git a/src/store/homeStore.ts b/src/store/homeStore.ts index abbac83fdf..4f991b752d 100644 --- a/src/store/homeStore.ts +++ b/src/store/homeStore.ts @@ -125,6 +125,7 @@ export interface gptServerType{ TAB_VIDEO?:string TTS_VOICE?:string REALTIME_SYSMSG?:string + REALTIME_MODEL?:string REALTIME_IS_WHISPER?:boolean TAB_MUSIC?:string diff --git a/src/views/wav/realtime.vue b/src/views/wav/realtime.vue index 8440bf008c..c2c2e56d0f 100644 --- a/src/views/wav/realtime.vue +++ b/src/views/wav/realtime.vue @@ -98,16 +98,18 @@ const go= async()=>{ ms.error("baseUrl is null"); return; } + //ms.info("go"); + //console.log("RealtimeClient", st.value.apikey ) + clientRef.value= new RealtimeClient( { apiKey:st.value.apikey, dangerouslyAllowAPIKeyInBrowser: true, baseUrl: st.value.baseUrl, - - + model: gptServerStore.myData.REALTIME_MODEL?gptServerStore.myData.REALTIME_MODEL: 'gpt-4o-realtime-preview-2024-10-01' } ) } - mlog("go", st.value.apikey ) + //mlog("go", st.value.apikey ) const client= clientRef.value const wavRecorder= wavRecorderRef.value const wavStreamPlayer= wavStreamPlayerRef.value diff --git a/src/views/wav/wavSetting.vue b/src/views/wav/wavSetting.vue index dd26b81691..0a91682f28 100644 --- a/src/views/wav/wavSetting.vue +++ b/src/views/wav/wavSetting.vue @@ -20,6 +20,11 @@ const voiceList= computed(()=>{ for(let o of "alloy,echo,shimmer".split(/[ ,]+/ig))rz.push({label:o,value:o}) return rz; }); +const modelList= computed(()=>{ + let rz=[]; //'alloy','shimmer','echo' + for(let o of "gpt-4o-realtime-preview-2024-12-17,gpt-4o-mini-realtime-preview-2024-12-17,gpt-4o-realtime-preview-2024-10-01".split(/[ ,]+/ig))rz.push({label:o,value:o}) + return rz; +});