Skip to content

Commit 4fc08bf

Browse files
authored
feat(aihubmix): add qwen3.7-plus/step-3.7-flash and fix hy3 reasoning control (#3427)
* fix(aihubmix): use reasoning_effort for hy3 thinking control aihubmix gateway rejects boolean `thinking` for Hunyuan (hy3) with 400: "cannot unmarshal bool into ... model.Thinking". The `thinking` field must be an object {type:enabled|disabled}, which a Dify yaml parameter rule cannot emit. Switch hy3.yaml from `thinking`(boolean) + `thinking_budget`(int) to a single `reasoning_effort` string parameter (none/low/medium/high, default none). Verified on aihubmix: all four values return 200; none disables thinking (reasoning_tokens=0), low/medium/high enable it. hy3 + reasoning_effort:high + json_schema end-to-end returns 200 with schema-conformant JSON. Per Tencent Hunyuan docs, hy3 reasoning_effort supports low/medium/high (default low); none is an aihubmix extension to turn thinking off. llm.py is unchanged. * feat(aihubmix): add qwen3.7-plus and step-3.7-flash models * chore(aihubmix): bump version to 0.0.38
1 parent 745a004 commit 4fc08bf

5 files changed

Lines changed: 106 additions & 29 deletions

File tree

models/aihubmix/manifest.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
version: 0.0.37
1+
version: 0.0.38
22
type: plugin
33
author: langgenius
44
name: aihubmix

models/aihubmix/models/llm/_position.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
- doubao-seed-2-1-turbo
1313
- grok-build-0.1
1414
- qwen3.7-max
15+
- qwen3.7-plus
1516
- gemini-3.5-flash
1617
- grok-4.3
1718
- gpt-5.5
@@ -102,6 +103,7 @@
102103
- coding-minimax-m2.7
103104
- coding-minimax-m2.7-highspeed
104105
- o3
106+
- step-3.7-flash
105107
- step-3.5-flash
106108
- glm-4.6
107109
- kimi-for-coding-free

models/aihubmix/models/llm/hy3.yaml

Lines changed: 15 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -11,34 +11,21 @@ model_properties:
1111
mode: chat
1212
context_size: 256000
1313
parameter_rules:
14-
- name: thinking
14+
- name: reasoning_effort
1515
label:
16-
zh_Hans: 推理模式
17-
en_US: Thinking Mode
18-
type: boolean
19-
default: false
16+
zh_Hans: 推理深度
17+
en_US: Reasoning Effort
18+
type: string
2019
required: false
20+
default: none
21+
options:
22+
- none
23+
- low
24+
- medium
25+
- high
2126
help:
22-
zh_Hans: 控制模型的推理能力。开启后使用深度推理模式。
23-
en_US: Controls the model's thinking capability. Enables deep reasoning when turned on.
24-
- name: thinking_budget
25-
label:
26-
zh_Hans: 推理预算
27-
en_US: Thinking Budget
28-
type: int
29-
default: 1024
30-
min: 0
31-
max: 32000
32-
required: false
33-
- name: temperature
34-
use_template: temperature
35-
- name: top_p
36-
use_template: top_p
37-
- name: max_tokens
38-
use_template: max_tokens
39-
default: 8192
40-
min: 1
41-
max: 128000
27+
zh_Hans: 控制推理深度。none 关闭思考;low 轻量推理(速度快,适合简单任务)、medium 平衡(适合日常适中复杂任务)、high 深度推理(延迟与成本最高,适合高难度数学/编程/复杂逻辑)。
28+
en_US: Controls reasoning depth. none disables thinking; low = lightweight (fast, simple tasks), medium = balanced (everyday tasks), high = deep reasoning (highest latency/cost, for hard math/coding/logic).
4229
- name: response_format
4330
label:
4431
zh_Hans: 回复格式
@@ -52,7 +39,7 @@ parameter_rules:
5239
- name: json_schema
5340
use_template: json_schema
5441
pricing:
55-
input: '0.1562'
56-
output: '0.6248'
57-
unit: '0.000001'
42+
input: "0.1562"
43+
output: "0.6248"
44+
unit: "0.000001"
5845
currency: USD
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
model: qwen3.7-plus
2+
label:
3+
en_US: Qwen3.7 Plus
4+
model_type: llm
5+
features:
6+
- agent-thought
7+
- tool-call
8+
- stream-tool-call
9+
- multi-tool-call
10+
- vision
11+
- video
12+
model_properties:
13+
mode: chat
14+
context_size: 1014784
15+
parameter_rules:
16+
- name: enable_thinking
17+
required: false
18+
type: boolean
19+
default: false
20+
label:
21+
zh_Hans: 深度思考
22+
en_US: Deep Thinking
23+
help:
24+
zh_Hans: 是否开启深度思考模式,开启后模型会先进行推理再给出回答。
25+
en_US: Whether to enable deep thinking mode. When enabled, the model will reason before answering.
26+
- name: response_format
27+
label:
28+
zh_Hans: 回复格式
29+
en_US: Response Format
30+
type: string
31+
required: false
32+
options:
33+
- text
34+
- json_object
35+
- json_schema
36+
- name: json_schema
37+
use_template: json_schema
38+
pricing:
39+
input: '2'
40+
output: '8'
41+
unit: '0.000001'
42+
currency: RMB
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
model: step-3.7-flash
2+
label:
3+
en_US: Step 3.7 Flash
4+
model_type: llm
5+
features:
6+
- agent-thought
7+
- tool-call
8+
- stream-tool-call
9+
- multi-tool-call
10+
- vision
11+
- video
12+
model_properties:
13+
mode: chat
14+
context_size: 262144
15+
parameter_rules:
16+
- name: reasoning_effort
17+
label:
18+
zh_Hans: 推理强度
19+
en_US: Reasoning Effort
20+
type: string
21+
required: false
22+
default: medium
23+
options:
24+
- low
25+
- medium
26+
- high
27+
help:
28+
zh_Hans: "根据任务复杂度选择合适档位。low 适合简单问答、摘要、改写、信息抽取;medium 默认推荐,适合一般推理和多步骤任务;high 适合复杂推理、数学、规划、代码分析。"
29+
en_US: "Select effort by task complexity. low: simple Q&A, summary, rewrite, extraction; medium: default for general reasoning and multi-step tasks; high: complex reasoning, math, planning, code analysis."
30+
- name: response_format
31+
label:
32+
zh_Hans: 回复格式
33+
en_US: Response Format
34+
type: string
35+
required: false
36+
options:
37+
- text
38+
- json_object
39+
- json_schema
40+
- name: json_schema
41+
use_template: json_schema
42+
pricing:
43+
input: '1.35'
44+
output: '8.1'
45+
unit: '0.000001'
46+
currency: RMB

0 commit comments

Comments
 (0)