mirror of
https://github.com/farcasclaudiu/openclaw.git
synced 2026-06-28 23:02:02 +03:00
TTS: add missing OpenAI voices (ballad, cedar, juniper, marin, verse) (openclaw#11020) thanks @lailoo
Verified:
- pnpm install --frozen-lockfile
- pnpm build
- pnpm check
- pnpm test
Co-authored-by: ${pr_author_login} <${coauthor_email}>
Co-authored-by: ${tak_name} <${tak_email}>
This commit is contained in:
@@ -221,6 +221,7 @@ Docs: https://docs.openclaw.ai
|
|||||||
|
|
||||||
### Fixes
|
### Fixes
|
||||||
|
|
||||||
|
- TTS: add missing OpenAI voices (ballad, cedar, juniper, marin, verse) to the allowlist so they are recognized instead of silently falling back to Edge TTS. (#2393)
|
||||||
- Cron: scheduler reliability (timer drift, restart catch-up, lock contention, stale running markers). (#10776) Thanks @tyler6204.
|
- Cron: scheduler reliability (timer drift, restart catch-up, lock contention, stale running markers). (#10776) Thanks @tyler6204.
|
||||||
- Cron: store migration hardening (legacy field migration, parse error handling, explicit delivery mode persistence). (#10776) Thanks @tyler6204.
|
- Cron: store migration hardening (legacy field migration, parse error handling, explicit delivery mode persistence). (#10776) Thanks @tyler6204.
|
||||||
- Memory: set Voyage embeddings `input_type` for improved retrieval. (#10818) Thanks @mcinteerj.
|
- Memory: set Voyage embeddings `input_type` for improved retrieval. (#10818) Thanks @mcinteerj.
|
||||||
|
|||||||
@@ -97,6 +97,14 @@ describe("tts", () => {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("includes newer OpenAI voices (ballad, cedar, juniper, marin, verse) (#2393)", () => {
|
||||||
|
expect(isValidOpenAIVoice("ballad")).toBe(true);
|
||||||
|
expect(isValidOpenAIVoice("cedar")).toBe(true);
|
||||||
|
expect(isValidOpenAIVoice("juniper")).toBe(true);
|
||||||
|
expect(isValidOpenAIVoice("marin")).toBe(true);
|
||||||
|
expect(isValidOpenAIVoice("verse")).toBe(true);
|
||||||
|
});
|
||||||
|
|
||||||
it("rejects invalid voice names", () => {
|
it("rejects invalid voice names", () => {
|
||||||
expect(isValidOpenAIVoice("invalid")).toBe(false);
|
expect(isValidOpenAIVoice("invalid")).toBe(false);
|
||||||
expect(isValidOpenAIVoice("")).toBe(false);
|
expect(isValidOpenAIVoice("")).toBe(false);
|
||||||
|
|||||||
@@ -842,13 +842,18 @@ function isCustomOpenAIEndpoint(): boolean {
|
|||||||
export const OPENAI_TTS_VOICES = [
|
export const OPENAI_TTS_VOICES = [
|
||||||
"alloy",
|
"alloy",
|
||||||
"ash",
|
"ash",
|
||||||
|
"ballad",
|
||||||
|
"cedar",
|
||||||
"coral",
|
"coral",
|
||||||
"echo",
|
"echo",
|
||||||
"fable",
|
"fable",
|
||||||
|
"juniper",
|
||||||
|
"marin",
|
||||||
"onyx",
|
"onyx",
|
||||||
"nova",
|
"nova",
|
||||||
"sage",
|
"sage",
|
||||||
"shimmer",
|
"shimmer",
|
||||||
|
"verse",
|
||||||
] as const;
|
] as const;
|
||||||
|
|
||||||
type OpenAiTtsVoice = (typeof OPENAI_TTS_VOICES)[number];
|
type OpenAiTtsVoice = (typeof OPENAI_TTS_VOICES)[number];
|
||||||
|
|||||||
Reference in New Issue
Block a user