conductor-remote 1.113.0 → 1.114.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{PierrePatch-awVutyVW.js → PierrePatch-BZ_MYB7X.js} +1 -1
- package/dist/assets/{index-DDm_FLf-.js → index-6mx-rmpo.js} +2 -2
- package/dist/index.html +1 -1
- package/dist/sw.js +1 -1
- package/dist-node/src/voice/broker.js +27 -8
- package/dist-node/src/voice/config.js +1 -1
- package/docs/voice-setup.md +10 -4
- package/package.json +1 -1
package/dist/index.html
CHANGED
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
<title>Conductor Remote</title>
|
|
26
26
|
<!-- Runs before the module bundle so it can catch a stale shell that fails to boot. -->
|
|
27
27
|
<script src="/self-heal.js"></script>
|
|
28
|
-
<script type="module" crossorigin src="/assets/index-
|
|
28
|
+
<script type="module" crossorigin src="/assets/index-6mx-rmpo.js"></script>
|
|
29
29
|
<link rel="stylesheet" crossorigin href="/assets/index-MmdttBBU.css">
|
|
30
30
|
<link rel="manifest" href="/manifest.webmanifest"></head>
|
|
31
31
|
<body>
|
package/dist/sw.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise(s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()}).then(()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e}));self.define=(n,r)=>{const l=e||("document"in self?document.currentScript.src:"")||location.href;if(s[l])return;let o={};const t=e=>i(e,l),a={module:{uri:l},exports:o,require:t};s[l]=Promise.all(n.map(e=>a[e]||t(e))).then(e=>(r(...e),o))}}define(["./workbox-dcde9eb3"],function(e){"use strict";importScripts("/push-sw.js"),self.addEventListener("message",e=>{e.data&&"SKIP_WAITING"===e.data.type&&self.skipWaiting()}),e.clientsClaim(),e.precacheAndRoute([{url:"self-heal.js",revision:"49bd63adb25a09341f8d2610e8bd3c76"},{url:"push-sw.js",revision:"e7ef44deca46c0539e6ff7bba5eb815e"},{url:"index.html",revision:"
|
|
1
|
+
if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise(s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()}).then(()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e}));self.define=(n,r)=>{const l=e||("document"in self?document.currentScript.src:"")||location.href;if(s[l])return;let o={};const t=e=>i(e,l),a={module:{uri:l},exports:o,require:t};s[l]=Promise.all(n.map(e=>a[e]||t(e))).then(e=>(r(...e),o))}}define(["./workbox-dcde9eb3"],function(e){"use strict";importScripts("/push-sw.js"),self.addEventListener("message",e=>{e.data&&"SKIP_WAITING"===e.data.type&&self.skipWaiting()}),e.clientsClaim(),e.precacheAndRoute([{url:"self-heal.js",revision:"49bd63adb25a09341f8d2610e8bd3c76"},{url:"push-sw.js",revision:"e7ef44deca46c0539e6ff7bba5eb815e"},{url:"index.html",revision:"33ec766840b9ba6b36da40b0906cc885"},{url:"assets/workbox-window.prod.es5-BBnX5xw4.js",revision:null},{url:"assets/pierre-shiki-wasm-C8ETeZem.js",revision:null},{url:"assets/pierre-light-480U9XYS.js",revision:null},{url:"assets/pierre-dark-CyvmCCZW.js",revision:null},{url:"assets/index-MmdttBBU.css",revision:null},{url:"assets/index-6mx-rmpo.js",revision:null},{url:"assets/PierrePatch-BZ_MYB7X.js",revision:null},{url:"apple-touch-icon.png",revision:"1127bb396b4648add53dce3f22c92aee"},{url:"icon-192.png",revision:"c5e01ac58768627e18ee7b8b6a9239ef"},{url:"icon-512.png",revision:"a40638c55e310312457a621c9a0002c8"},{url:"icon-maskable-512.png",revision:"a9b0d962686287452216492cd2247499"},{url:"icon.svg",revision:"c1aee186821798733dd477e69a0ef243"},{url:"manifest.webmanifest",revision:"cf88fbc5755108a7fe0616fa160a8a15"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("/index.html"),{denylist:[/^\/api\//]})),e.registerRoute(({url:e})=>e.pathname.startsWith("/assets/diff-syntax/"),new e.CacheFirst({cacheName:"diff-syntax",plugins:[new e.ExpirationPlugin({maxEntries:32,maxAgeSeconds:31536e3})]}),"GET")});
|
|
@@ -28,9 +28,28 @@ export function buildAcceptBody(input) {
|
|
|
28
28
|
]
|
|
29
29
|
};
|
|
30
30
|
}
|
|
31
|
-
|
|
31
|
+
// USD per million tokens: https://developers.openai.com/api/docs/models/gpt-realtime-2.1
|
|
32
|
+
// Mini remains configurable: https://developers.openai.com/api/docs/models/gpt-realtime-2.1-mini
|
|
33
|
+
const REALTIME_RATES = new Map([
|
|
34
|
+
[
|
|
35
|
+
'gpt-realtime-2.1',
|
|
36
|
+
{
|
|
37
|
+
text: { input: 4, cached: 0.4, output: 24 },
|
|
38
|
+
audio: { input: 32, cached: 0.4, output: 64 }
|
|
39
|
+
}
|
|
40
|
+
],
|
|
41
|
+
[
|
|
42
|
+
'gpt-realtime-2.1-mini',
|
|
43
|
+
{
|
|
44
|
+
text: { input: 0.6, cached: 0.06, output: 2.4 },
|
|
45
|
+
audio: { input: 10, cached: 0.3, output: 20 }
|
|
46
|
+
}
|
|
47
|
+
]
|
|
48
|
+
]);
|
|
49
|
+
/** USD estimate from the configured model's published text and audio rates. */
|
|
32
50
|
export function estimateRealtimeCost(model, usage) {
|
|
33
|
-
|
|
51
|
+
const rates = REALTIME_RATES.get(model);
|
|
52
|
+
if (!rates)
|
|
34
53
|
return null;
|
|
35
54
|
const input = usage.input_token_details ?? {};
|
|
36
55
|
const output = usage.output_token_details ?? {};
|
|
@@ -38,12 +57,12 @@ export function estimateRealtimeCost(model, usage) {
|
|
|
38
57
|
const cachedAudio = input.cached_tokens_details?.audio_tokens ?? 0;
|
|
39
58
|
const uncachedText = Math.max(0, (input.text_tokens ?? 0) - cachedText);
|
|
40
59
|
const uncachedAudio = Math.max(0, (input.audio_tokens ?? 0) - cachedAudio);
|
|
41
|
-
return ((uncachedText *
|
|
42
|
-
cachedText *
|
|
43
|
-
uncachedAudio *
|
|
44
|
-
cachedAudio *
|
|
45
|
-
(output.text_tokens ?? 0) *
|
|
46
|
-
(output.audio_tokens ?? 0) *
|
|
60
|
+
return ((uncachedText * rates.text.input +
|
|
61
|
+
cachedText * rates.text.cached +
|
|
62
|
+
uncachedAudio * rates.audio.input +
|
|
63
|
+
cachedAudio * rates.audio.cached +
|
|
64
|
+
(output.text_tokens ?? 0) * rates.text.output +
|
|
65
|
+
(output.audio_tokens ?? 0) * rates.audio.output) /
|
|
47
66
|
1_000_000);
|
|
48
67
|
}
|
|
49
68
|
function defaultSocket(url, headers) {
|
package/docs/voice-setup.md
CHANGED
|
@@ -235,14 +235,20 @@ Search uses `GET /api/voice/search?q=…&limit=12&offset=0`, optionally with `ca
|
|
|
235
235
|
|
|
236
236
|
### Cost
|
|
237
237
|
|
|
238
|
-
The default is `gpt-realtime-2.1
|
|
238
|
+
The default is `gpt-realtime-2.1`. Existing installations keep their saved model; switch them with:
|
|
239
|
+
|
|
240
|
+
```bash
|
|
241
|
+
conductor-remote config set voice.model gpt-realtime-2.1
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
This restarts the relay; start a new call to use the new model. OpenAI currently publishes these per-million-token prices for GPT-Realtime-2.1:
|
|
239
245
|
|
|
240
246
|
| Modality | Input | Cached input | Output |
|
|
241
247
|
| --- | ---: | ---: | ---: |
|
|
242
|
-
| Text | $
|
|
243
|
-
| Audio | $
|
|
248
|
+
| Text | $4.00 | $0.40 | $24.00 |
|
|
249
|
+
| Audio | $32.00 | $0.40 | $64.00 |
|
|
244
250
|
|
|
245
|
-
The broker logs actual token usage and an estimate for every completed response. Use those lines for this workflow's real per-call cost; Twilio phone-number and PSTN charges are separate and depend on the account/country. The rate source is the [GPT-Realtime-2.1 Mini model
|
|
251
|
+
The broker logs actual token usage and an estimate for every completed response. Use those lines for this workflow's real per-call cost; Twilio phone-number and PSTN charges are separate and depend on the account/country. The rate source is the [GPT-Realtime-2.1 model page](https://developers.openai.com/api/docs/models/gpt-realtime-2.1). `gpt-realtime-2.1-mini` remains available through `voice.model`, with its own cost estimates using the [Mini model rates](https://developers.openai.com/api/docs/models/gpt-realtime-2.1-mini).
|
|
246
252
|
|
|
247
253
|
### Disable or rotate
|
|
248
254
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "conductor-remote",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.114.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"packageManager": "yarn@4.15.0",
|
|
6
6
|
"description": "Phone control panel for local Conductor agents. Reads ride SQLite + git; prompts ride Conductor's own dispatch path.",
|