Skip to content

Commit b06c4c0

Browse files
authored
Merge pull request #312 from modelstudioai/feat/update-omni-def-model
Update omni default model to qwen3.8-omni-flash
2 parents 0f870ab + dcdaf3e commit b06c4c0

5 files changed

Lines changed: 87 additions & 39 deletions

File tree

‎packages/commands/src/commands/config/shared.ts‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ export const UI_MODEL_DEFAULTS: Record<string, string> = {
8080
default_reference_to_video_model: "wan3.0-video",
8181
default_speech_model: "cosyvoice-v3-flash",
8282
default_speech_recognition_model: "fun-asr",
83-
default_omni_model: "qwen3.5-omni-plus",
83+
default_omni_model: "qwen3.8-omni-flash",
8484
};
8585

8686
/** One selectable model plus a short note on where the CLI uses it. */
@@ -131,7 +131,8 @@ export const UI_MODEL_CATALOG: Record<string, ModelOption[]> = {
131131
{ id: "qwen-audio-3.0-asr-flash", role: "Token Plan speech/recognize (ASR)" },
132132
],
133133
default_omni_model: [
134-
{ id: "qwen3.5-omni-plus", role: "omni/chat default" },
134+
{ id: "qwen3.8-omni-flash", role: "omni/chat default · --text-only" },
135+
{ id: "qwen3.5-omni-plus", role: "omni/chat · audio output path (without --text-only)" },
135136
{ id: "qwen3-vl-plus", role: "vision/describe · multimodal input" },
136137
],
137138
};

‎packages/commands/src/commands/omni/chat.ts‎

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -141,8 +141,10 @@ export default defineCommand({
141141
type: "string",
142142
valueHint: "<model>",
143143
description: {
144-
"en-US": "Model ID (default: qwen3.5-omni-plus)",
145-
"zh-CN": "模型 ID(默认:qwen3.5-omni-plus)",
144+
"en-US":
145+
"Model ID (default: qwen3.8-omni-flash; when --model is omitted and --text-only is absent, auto-switches to qwen3.5-omni-plus for audio output)",
146+
"zh-CN":
147+
"模型 ID(默认:qwen3.8-omni-flash;省略 --model 且未带 --text-only 时,自动切换为支持音频输出的 qwen3.5-omni-plus)",
146148
},
147149
},
148150
system: {
@@ -275,12 +277,26 @@ export default defineCommand({
275277
// --- Parse messages ---
276278
const userMessages = flags.message ?? [];
277279

278-
const model = flags.model || settings.defaultOmniModel || "qwen3.5-omni-plus";
280+
// Default to flash; switch to plus when --model is omitted and --text-only is absent (flash has no audio out).
281+
const textOnly = flags.textOnly === true;
282+
let model = flags.model || settings.defaultOmniModel || "qwen3.8-omni-flash";
283+
if (!flags.model && !textOnly && model === "qwen3.8-omni-flash") {
284+
model = "qwen3.5-omni-plus";
285+
}
279286
const voice = flags.voice || "Tina";
280287
const audioFormat = flags.audioFormat || "wav";
281-
const textOnly = flags.textOnly === true;
282288
const format = settings.output;
283289

290+
// Explicit flash + audio path will be rejected by the server; warn locally without overriding --model.
291+
if (flags.model === "qwen3.8-omni-flash" && !textOnly) {
292+
ctx.output.warning({
293+
"en-US":
294+
"qwen3.8-omni-flash does not support audio output. Add --text-only, or omit --model to auto-switch to qwen3.5-omni-plus.",
295+
"zh-CN":
296+
"qwen3.8-omni-flash 不支持音频输出。请添加 --text-only,或省略 --model 以自动切换为 qwen3.5-omni-plus。",
297+
});
298+
}
299+
284300
// --- Build messages array ---
285301
const allMessages: ChatMessage[] = [];
286302
if (flags.system) {

‎packages/commands/tests/e2e/omni.e2e.test.ts‎

Lines changed: 36 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import {
88
parseStdoutJson,
99
runCommandHelp,
1010
runCommandE2e,
11+
runCommandInProcess,
1112
} from "./helpers.ts";
1213
import { OMNI_ROUTES } from "./topic-routes.ts";
1314

@@ -17,6 +18,36 @@ describe("e2e: omni", () => {
1718
expect(exitCode, stderr).toBe(0);
1819
expect(stderr).toMatch(/omni|--message|--audio|text-only/i);
1920
});
21+
22+
test("omni --dry-run 无 --model/--text-only 时自动切换为 qwen3.5-omni-plus 并带 audio modalities", async () => {
23+
const { stdout, stderr, exitCode } = await runCommandInProcess(
24+
OMNI_ROUTES,
25+
["omni", "--dry-run", "--message", "hi", "--output", "json"],
26+
{ DASHSCOPE_API_KEY: "" },
27+
);
28+
expect(exitCode, stderr).toBe(0);
29+
const data = parseStdoutJson<{
30+
request?: { model?: string; modalities?: string[]; audio?: unknown };
31+
}>(stdout);
32+
expect(data.request?.model).toBe("qwen3.5-omni-plus");
33+
expect(data.request?.modalities).toEqual(["text", "audio"]);
34+
expect(data.request?.audio).toBeTruthy();
35+
});
36+
37+
test("omni --dry-run 无 --model 且带 --text-only 时使用 qwen3.8-omni-flash 且无 modalities", async () => {
38+
const { stdout, stderr, exitCode } = await runCommandInProcess(
39+
OMNI_ROUTES,
40+
["omni", "--dry-run", "--text-only", "--message", "hi", "--output", "json"],
41+
{ DASHSCOPE_API_KEY: "" },
42+
);
43+
expect(exitCode, stderr).toBe(0);
44+
const data = parseStdoutJson<{
45+
request?: { model?: string; modalities?: string[]; audio?: unknown };
46+
}>(stdout);
47+
expect(data.request?.model).toBe("qwen3.8-omni-flash");
48+
expect(data.request?.modalities).toBeUndefined();
49+
expect(data.request?.audio).toBeUndefined();
50+
});
2051
});
2152

2253
describe.skipIf(!isBailianE2EMediaEnabled() || !isDashScopeE2EReady())(
@@ -38,7 +69,7 @@ describe.skipIf(!isBailianE2EMediaEnabled() || !isDashScopeE2EReady())(
3869
const { stderr, exitCode } = await runCommandE2e(OMNI_ROUTES, [
3970
"omni",
4071
"--model",
41-
"qwen3.5-omni-flash",
72+
"qwen3.8-omni-flash",
4273
]);
4374
expect(exitCode).toBe(2);
4475
expect(stderr).toMatch(/--message|Usage:/i);
@@ -48,7 +79,7 @@ describe.skipIf(!isBailianE2EMediaEnabled() || !isDashScopeE2EReady())(
4879
const { stderr, exitCode } = await runCommandE2e(OMNI_ROUTES, [
4980
"omni",
5081
"--model",
51-
"qwen3.5-omni-flash",
82+
"qwen3.8-omni-flash",
5283
"--audio",
5384
"https://example.com/sample.flac",
5485
"--text-only",
@@ -64,7 +95,7 @@ describe.skipIf(!isBailianE2EMediaEnabled() || !isDashScopeE2EReady())(
6495
"omni",
6596
"--dry-run",
6697
"--model",
67-
"qwen3.5-omni-flash",
98+
"qwen3.8-omni-flash",
6899
"--audio",
69100
"https://example.com/sample.wav",
70101
"--text-only",
@@ -95,7 +126,7 @@ describe.skipIf(!isBailianE2EMediaEnabled() || !isDashScopeE2EReady())(
95126
expect(audioPart?.input_audio?.format).toBe("wav");
96127
});
97128

98-
test("【qwen3.5-omni-flash】本地音频理解", async () => {
129+
test("【qwen3.8-omni-flash】本地音频理解", async () => {
99130
const outDir = makeE2eOutputDir(e2eLabelFromMetaUrl(import.meta.url));
100131
const clipText = "端到端Omni音频测试";
101132
const clipWav = join(outDir, "e2e-omni-input.wav");
@@ -121,7 +152,7 @@ describe.skipIf(!isBailianE2EMediaEnabled() || !isDashScopeE2EReady())(
121152
const omni = await runCommandE2e(OMNI_ROUTES, [
122153
"omni",
123154
"--model",
124-
"qwen3.5-omni-flash",
155+
"qwen3.8-omni-flash",
125156
"--audio",
126157
clipWav,
127158
"--text-only",

‎skills/bailian-gen/SKILL.md‎

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -35,17 +35,17 @@ BAILIAN_CALLER_TYPE=agent BAILIAN_CALLER_NAME=codex BAILIAN_SKILL_NAME=bailian-g
3535

3636
## When to use which command
3737

38-
| User intent | Command | Default model |
39-
| ---------------------------------------- | ----------------------------------------- | --------------------------------------------------- |
40-
| Text-to-image | `bl image generate` | `qwen-image-3.0` |
41-
| Image edit / multi-image merge | `bl image edit` (repeat `--image`) | `qwen-image-3.0` |
42-
| Text-to-video / image-to-video | `bl video generate` | `wan3.0-video` |
43-
| Video edit / style transfer | `bl video edit` | `happyhorse-1.0-video-edit` |
44-
| Reference-to-video + voice | `bl video ref` | `wan3.0-video` |
45-
| Speech synthesis (TTS / voiceover) | `bl speech synthesize` | `cosyvoice-v3-flash` |
46-
| Speech recognition (ASR / transcription) | `bl speech recognize` | `fun-asr` |
47-
| Image describe | `bl vision describe` | `qwen3-vl-plus`;宿主能做且未点名 → host-first |
48-
| Video / A-V understand | `bl vision describe --video` 或 `bl omni` | 视频理解默认走百炼;`omni` 默认 `qwen3.5-omni-plus` |
38+
| User intent | Command | Default model |
39+
| ---------------------------------------- | ----------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
40+
| Text-to-image | `bl image generate` | `qwen-image-3.0` |
41+
| Image edit / multi-image merge | `bl image edit` (repeat `--image`) | `qwen-image-3.0` |
42+
| Text-to-video / image-to-video | `bl video generate` | `wan3.0-video` |
43+
| Video edit / style transfer | `bl video edit` | `happyhorse-1.0-video-edit` |
44+
| Reference-to-video + voice | `bl video ref` | `wan3.0-video` |
45+
| Speech synthesis (TTS / voiceover) | `bl speech synthesize` | `cosyvoice-v3-flash` |
46+
| Speech recognition (ASR / transcription) | `bl speech recognize` | `fun-asr` |
47+
| Image describe | `bl vision describe` | `qwen3-vl-plus`;宿主能做且未点名 → host-first |
48+
| Video / A-V understand | `bl vision describe --video` 或 `bl omni` | 视频理解默认走百炼;`omni` 默认 `qwen3.8-omni-flash`,省略 `--model` 且无 `--text-only` 时自动切换 `qwen3.5-omni-plus` |
4949

5050
Unless the user explicitly specifies a model, omit `--model` and let the CLI use the active Profile’s default.
5151

‎skills/bailian-gen/reference/omni.md‎

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -24,23 +24,23 @@ Index: [index.md](index.md)
2424

2525
#### Flags
2626

27-
| Flag | Type | Required | Description |
28-
| ---------------------- | ------ | -------- | --------------------------------------------------------------------- |
29-
| `--message <text>` | array | no | Message text (repeatable, prefix role: to set role) |
30-
| `--model <model>` | string | no | Model ID (default: qwen3.5-omni-plus) |
31-
| `--system <text>` | string | no | System prompt |
32-
| `--image <url>` | array | no | Image URL or local file (repeatable) |
33-
| `--audio <url>` | array | no | Audio URL or local file (.wav/.mp3/.amr/.aac/.m4a/.ogg/.3gp/.3gpp) |
34-
| `--video <url>` | array | no | Video file URL / local path, or comma-separated frame URLs |
35-
| `--voice <voice>` | string | no | Output voice ID (default: Tina). Use --list-voices to see all options |
36-
| `--list-voices` | switch | no | List available output voices and exit |
37-
| `--audio-format <fmt>` | string | no | Audio output format (default: wav) |
38-
| `--audio-out <path>` | string | no | Save audio to file (default: auto-generate) |
39-
| `--text-only` | switch | no | Output text only, no audio generation |
40-
| `--max-tokens <n>` | number | no | Maximum tokens to generate |
41-
| `--temperature <n>` | number | no | Sampling temperature (0.0, 2.0] |
42-
| `--api-key <key>` | string | no | API key |
43-
| `--base-url <url>` | string | no | API base URL |
27+
| Flag | Type | Required | Description |
28+
| ---------------------- | ------ | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
29+
| `--message <text>` | array | no | Message text (repeatable, prefix role: to set role) |
30+
| `--model <model>` | string | no | Model ID (default: qwen3.8-omni-flash; when --model is omitted and --text-only is absent, auto-switches to qwen3.5-omni-plus for audio output) |
31+
| `--system <text>` | string | no | System prompt |
32+
| `--image <url>` | array | no | Image URL or local file (repeatable) |
33+
| `--audio <url>` | array | no | Audio URL or local file (.wav/.mp3/.amr/.aac/.m4a/.ogg/.3gp/.3gpp) |
34+
| `--video <url>` | array | no | Video file URL / local path, or comma-separated frame URLs |
35+
| `--voice <voice>` | string | no | Output voice ID (default: Tina). Use --list-voices to see all options |
36+
| `--list-voices` | switch | no | List available output voices and exit |
37+
| `--audio-format <fmt>` | string | no | Audio output format (default: wav) |
38+
| `--audio-out <path>` | string | no | Save audio to file (default: auto-generate) |
39+
| `--text-only` | switch | no | Output text only, no audio generation |
40+
| `--max-tokens <n>` | number | no | Maximum tokens to generate |
41+
| `--temperature <n>` | number | no | Sampling temperature (0.0, 2.0] |
42+
| `--api-key <key>` | string | no | API key |
43+
| `--base-url <url>` | string | no | API base URL |
4444

4545
#### Examples
4646

0 commit comments

Comments
 (0)