Add dictation and streamed read-aloud to the chat
- A mic in the composer records, transcribes with the bot's transcription model (api/admin/bots/transcribe) and writes the text into the input at the cursor to edit before sending. Escape cancels; recordings aren't stored. - Every bot message has a read-aloud button that plays GET api/admin/bots/speak-message, streamed from the provider as the audio is made, so it starts in a couple of seconds. One message plays at a time; only the user's own sessions can be read. - Both buttons stay visible but disabled while the bot has no model for them (bot_voice page prop). - Transcription and speech no longer pick free models automatically: they're not available until a model is picked, and Settings says so. Transcription lists speech-to-text models only, so the chat-model transcript path and its missing-audio check are gone. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
@@ -13,7 +13,8 @@ type Params = {
|
||||
* Whether a model can do a harness's job:
|
||||
* - text: reads and writes text, and calls tools (bots work through tools)
|
||||
* - vision: reads images, writes text
|
||||
* - transcription: a speech-to-text model, or a chat model that hears audio
|
||||
* - transcription: a speech-to-text model (never a chat model that hears
|
||||
* audio: free ones often drop it)
|
||||
* - speech: a text-to-speech model
|
||||
* - image: makes images
|
||||
*/
|
||||
@@ -31,10 +32,7 @@ export default function modelServesHarness({ model, harness }: Params) {
|
||||
return input.has("image") && output.has("text");
|
||||
|
||||
case "transcription":
|
||||
return (
|
||||
output.has("transcription") ||
|
||||
(input.has("audio") && output.has("text"))
|
||||
);
|
||||
return output.has("transcription");
|
||||
|
||||
case "speech":
|
||||
return output.has("speech");
|
||||
|
||||
Reference in New Issue
Block a user