@allmodels/dsh-speech 0.1.1 → 0.1.3
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/README.md +49 -9
- package/lib/client.js +1642 -159
- package/lib/index.d.ts +23 -2
- package/lib/index.js +685 -35
- package/package.json +9 -2
package/README.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# @allmodels/dsh-speech
|
|
2
2
|
|
|
3
|
-
Streaming microphone transcription for the DeepSeek Harness web client, powered by [AllModels.io](https://allmodels.io/).
|
|
3
|
+
Streaming microphone transcription and spoken answer summaries for the DeepSeek Harness web client, powered by [AllModels.io](https://allmodels.io/).
|
|
4
4
|
|
|
5
|
-
`@allmodels/dsh-speech` adds a microphone beside Send,
|
|
5
|
+
`@allmodels/dsh-speech` adds a microphone beside Send, live transcription, short spoken versions of completed answers, an AllModels account flow, and a dedicated Speech settings page. It is a standalone Cordis bundle and does not patch DeepSeek Harness.
|
|
6
6
|
|
|
7
7
|
## Compatibility
|
|
8
8
|
|
|
@@ -33,7 +33,7 @@ Or create a portable tarball:
|
|
|
33
33
|
|
|
34
34
|
```sh
|
|
35
35
|
pnpm pack
|
|
36
|
-
dsh plugin --profile web add ./allmodels-dsh-speech-0.1.
|
|
36
|
+
dsh plugin --profile web add ./allmodels-dsh-speech-0.1.2.tgz
|
|
37
37
|
```
|
|
38
38
|
|
|
39
39
|
Restart the profile after adding or removing the bundle.
|
|
@@ -54,9 +54,9 @@ See the [AllModels agentic setup documentation](https://docs.allmodels.io/agenti
|
|
|
54
54
|
1. Click the microphone next to Send.
|
|
55
55
|
2. Speak while the amplitude bar and partial transcription update.
|
|
56
56
|
3. While recording, choose **System default** or another input from the microphone selector beside TTFT. On a new chat, the selector appears beside the mode selector in the hero controls row.
|
|
57
|
-
4. Click Stop
|
|
57
|
+
4. Click Stop to finalize and leave the text as an editable draft, or click the Send arrow to finalize and send in one action. The Send arrow becomes available after speech text first appears.
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
Existing draft text is preserved and the transcript is appended. Composer editing remains locked while the microphone is active. Stop never sends; the recording Send arrow submits exactly once after finalization.
|
|
60
60
|
|
|
61
61
|
Only one microphone may be active at a time. Leaving the originating session immediately stops capture, closes the speech socket, clears the transient composer lock, and preserves the latest draft text.
|
|
62
62
|
|
|
@@ -75,6 +75,16 @@ The microphone selector is hidden on mobile layouts, where the browser's system-
|
|
|
75
75
|
|
|
76
76
|
Model and streaming details come from the [AllModels provider catalog](https://docs.allmodels.io/models) and [native streaming STT API](https://docs.allmodels.io/api-reference/native-tts/stt/nativeSttStream).
|
|
77
77
|
|
|
78
|
+
## Spoken summaries
|
|
79
|
+
|
|
80
|
+
For each newly completed answer, the plugin uses the exact LLM provider/model recorded on that answer to produce concise, plain, speakable prose without an arbitrary word limit. It begins streaming MP3 audio through a compatible AllModels TTS route as soon as validated audio chunks arrive. Answers already present when a session is first opened are not generated automatically, but their **Play summary** control prepares audio on demand.
|
|
81
|
+
|
|
82
|
+
Text-to-speech summaries and autoplay are enabled by default. Both are global plugin preferences in **Settings → Speech → Spoken summaries**, and autoplay is also available beside the latest spoken-summary player after its first use. Disabling text-to-speech summaries stops playback, cancels pending summary audio, suppresses interaction cues, and hides chat players while preserving the selected model, provider, voice, and autoplay preference.
|
|
83
|
+
|
|
84
|
+
One browser-global audio player arbitrates all sessions in the current Harness client. A newly prepared summary never interrupts audio already playing and is not queued to start later. Explicitly choosing **Play summary** stops the current summary and plays the selected one. Browser autoplay rejection leaves the waveform ready for a click. This arbitration does not cross browser tabs or windows.
|
|
85
|
+
|
|
86
|
+
The settings card selects a synchronous MP3 TTS model, a compatible provider, and a discovered voice. A saved compatible choice wins, followed by the provider catalog's advertised default and then the first compatible option.
|
|
87
|
+
|
|
78
88
|
## Operator configuration
|
|
79
89
|
|
|
80
90
|
The bundle row may be given composition-level defaults in a Harness patch:
|
|
@@ -88,16 +98,19 @@ The bundle row may be given composition-level defaults in a Harness patch:
|
|
|
88
98
|
baseURL: https://api.allmodels.io
|
|
89
99
|
lowBalanceUsd: 0.5
|
|
90
100
|
defaultTopUpUsd: 10
|
|
101
|
+
autoPlay: true
|
|
91
102
|
```
|
|
92
103
|
|
|
93
|
-
`baseURL` is deliberately operator-only; it is not editable in the browser. User
|
|
104
|
+
`baseURL` is deliberately operator-only; it is not editable in the browser. User STT and TTS choices plus the global autoplay preference are stored through the Harness settings service. Spoken summary text and audio are not stored.
|
|
94
105
|
|
|
95
106
|
## Privacy and session safety
|
|
96
107
|
|
|
97
108
|
- Audio is resampled in the browser and relayed through the local plugin host only while recording. It is never written to disk or retained for retry.
|
|
98
109
|
- API keys remain host-side in the Harness credential service and are inserted only into authenticated AllModels requests.
|
|
99
|
-
- Transcripts
|
|
110
|
+
- Transcripts remain in the browser's composer draft until the user uses the normal Send arrow or the recording Send arrow.
|
|
100
111
|
- The preferred microphone device ID is kept only in plugin-namespaced browser-local storage. It is not written to Harness sessions.
|
|
112
|
+
- Spoken summaries and MP3 Blob URLs exist only in browser memory. Pending requests are cancelled and Blob URLs are revoked when their UI or the plugin is disposed.
|
|
113
|
+
- Summarization and TTS requests contain prose, locale, and model routing only—never session IDs, message IDs, session paths, or conversation mutation commands.
|
|
101
114
|
- The host plugin does not inject Harness session services, import session packages, read session files, or write session files. A build check fails if a session/filesystem persistence dependency is introduced.
|
|
102
115
|
- The plugin's custom HTTP and WebSocket routes accept only same-origin loopback requests and enforce bounded request/frame sizes.
|
|
103
116
|
|
|
@@ -117,14 +130,41 @@ The only durable plugin data is its namespaced settings, credential, and browser
|
|
|
117
130
|
```sh
|
|
118
131
|
pnpm install
|
|
119
132
|
pnpm check
|
|
133
|
+
pnpm exec playwright install chromium
|
|
134
|
+
pnpm test:e2e
|
|
120
135
|
pnpm pack --dry-run
|
|
121
136
|
```
|
|
122
137
|
|
|
123
|
-
`pnpm check` runs the no-session-access boundary, TypeScript, unit/protocol tests, and both production bundles. Tests cover
|
|
138
|
+
`pnpm check` runs the no-session-access boundary, TypeScript, unit/protocol tests, and both production bundles. Tests cover both catalogs, summarizer routing and bounds, TTS response enforcement, history lifecycle, global playback arbitration, UI accessibility, route security, credential redaction, and the AllModels streaming wire mapping.
|
|
139
|
+
|
|
140
|
+
`pnpm test:e2e` builds and packs the plugin, installs that tarball into a disposable DeepSeek Harness `0.1.1-rc.2` web profile, launches a local AllModels HTTP/WebSocket mock, and runs the Chromium desktop and mobile suite with a generated virtual microphone. It covers first-run account UI, API-key connection, settings layout and persistence, balance/top-up, microphone placement, preparing/recording/finishing states, live partials and finals, waveform motion, composer locking, Stop-without-send, finish-and-send, Cancel, microphone selection, dark-mode menus, and mobile layout. The disposable profile and workspace are created below the operating system's temporary directory; the runner never opens or modifies the user's Harness profile or sessions.
|
|
141
|
+
|
|
142
|
+
For the optional live smoke test, put the following in a local `.secrets` file (which is gitignored), or export the variables normally:
|
|
143
|
+
|
|
144
|
+
```dotenv
|
|
145
|
+
ALLMODELS_API_KEY=...
|
|
146
|
+
DEEPSEEK_API_KEY=...
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
Then run `pnpm test:e2e:live`. The live test checks the environment-managed AllModels account, starts and stops a real streaming STT connection using the virtual microphone, sends a minimal DeepSeek request, and verifies microphone placement in both new-chat and existing-session layouts. It consumes a small amount of API balance. The coordinator removes both credentials from its ambient environment before starting build, package-manager, and Playwright children; only the isolated Harness process receives them. Live Harness output and Playwright traces, screenshots, videos, HTML reports, and artifact uploads are disabled so credentials cannot be reflected into CI diagnostics.
|
|
124
150
|
|
|
125
151
|
## Release
|
|
126
152
|
|
|
127
|
-
|
|
153
|
+
Every branch push and pull request to `main` runs the static/unit/package gates followed by the deterministic Playwright suite. A push to `main` additionally runs the live browser smoke test with the `ALLMODELS_API_KEY` and `DEEPSEEK_API_KEY` repository secrets. Secrets are never exposed to pull-request jobs.
|
|
154
|
+
|
|
155
|
+
After all jobs for a `main` push pass, the Release workflow checks out the exact tested commit and publishes its package version to npm with provenance if that version is not already present. It then tags the commit and creates the matching GitHub release. Before enabling this gate, configure both repository secrets and configure `allmodels-io/dsh-speech`'s `release.yml` workflow as the npm trusted publisher for `@allmodels/dsh-speech`. Increment `package.json` before merging a version intended for publication; already-published versions are safely skipped.
|
|
156
|
+
|
|
157
|
+
## Harness compatibility monitoring
|
|
158
|
+
|
|
159
|
+
GitHub Actions checks npm once per day for the most recently published `@deepseek-ai/dsh` version. It exits without installing browsers when that version is already tracked in `dsh-compatibility.json`, or when the same version already has an open compatibility issue or update pull request.
|
|
160
|
+
|
|
161
|
+
For a new version, the workflow updates the Harness peer/development dependency pins in an isolated checkout, installs that dependency set, runs the static and unit gates, packs the plugin into a disposable profile, and runs the desktop/mobile Chromium suite. It never receives the live AllModels or DeepSeek credentials.
|
|
162
|
+
|
|
163
|
+
- A failure creates one `dsh-compatibility` issue for that Harness version with a link to the failed run. Later daily checks do not duplicate it.
|
|
164
|
+
- A pass opens a reviewable pull request updating the tested version, peer dependencies, development dependencies, README, and lockfile. Merging remains manual.
|
|
165
|
+
- A manual run can target an explicit version or force a retest. When a forced retest fixes an open compatibility issue, the successful update pull request closes it.
|
|
166
|
+
|
|
167
|
+
Workflow-created pull requests require the repository’s **Settings → Actions → General → Allow GitHub Actions to create and approve pull requests** option. The compatibility workflow requests only the exact `contents`, `pull-requests`, and `issues` write permissions needed by its update job and contains no approval operation.
|
|
128
168
|
|
|
129
169
|
## License
|
|
130
170
|
|