Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yd-ai
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xingmin
yd-ai
Commits
1f4a3464
Commit
1f4a3464
authored
Apr 23, 2026
by
zhangxingmin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
push
parent
68dd03d6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
yd-ai-api/src/main/java/com/yd/ai/api/service/impl/ApiAiStreamServiceImpl.java
+2
-2
yd-ai-service/pom.xml
+1
-1
No files found.
yd-ai-api/src/main/java/com/yd/ai/api/service/impl/ApiAiStreamServiceImpl.java
View file @
1f4a3464
...
@@ -75,13 +75,13 @@ public class ApiAiStreamServiceImpl implements ApiAiStreamService {
...
@@ -75,13 +75,13 @@ public class ApiAiStreamServiceImpl implements ApiAiStreamService {
throw
e
;
throw
e
;
}
}
// 正常调用大模型流式接口(使用 Qwen3
.6-Plus
模型)
// 正常调用大模型流式接口(使用 Qwen3
-Max
模型)
Generation
gen
=
new
Generation
();
Generation
gen
=
new
Generation
();
Message
systemMsg
=
Message
.
builder
().
role
(
Role
.
SYSTEM
.
getValue
()).
content
(
"You are a helpful assistant."
).
build
();
Message
systemMsg
=
Message
.
builder
().
role
(
Role
.
SYSTEM
.
getValue
()).
content
(
"You are a helpful assistant."
).
build
();
Message
userMsg
=
Message
.
builder
().
role
(
Role
.
USER
.
getValue
()).
content
(
question
).
build
();
Message
userMsg
=
Message
.
builder
().
role
(
Role
.
USER
.
getValue
()).
content
(
question
).
build
();
GenerationParam
param
=
GenerationParam
.
builder
()
GenerationParam
param
=
GenerationParam
.
builder
()
.
apiKey
(
"sk-d6551c67cfbe4a759a78dc3625729291"
)
// 请使用安全的密钥管理方式
.
apiKey
(
"sk-d6551c67cfbe4a759a78dc3625729291"
)
// 请使用安全的密钥管理方式
.
model
(
"qwen3
.6-plus"
)
// 模型改为 qwen3.6-plus
.
model
(
"qwen3
-max"
)
// 模型改为 qwen3-max(千问3旗舰版)
.
messages
(
Arrays
.
asList
(
systemMsg
,
userMsg
))
.
messages
(
Arrays
.
asList
(
systemMsg
,
userMsg
))
.
resultFormat
(
GenerationParam
.
ResultFormat
.
MESSAGE
)
.
resultFormat
(
GenerationParam
.
ResultFormat
.
MESSAGE
)
.
incrementalOutput
(
true
)
.
incrementalOutput
(
true
)
...
...
yd-ai-service/pom.xml
View file @
1f4a3464
...
@@ -62,7 +62,7 @@
...
@@ -62,7 +62,7 @@
<dependency>
<dependency>
<groupId>
com.alibaba
</groupId>
<groupId>
com.alibaba
</groupId>
<artifactId>
dashscope-sdk-java
</artifactId>
<artifactId>
dashscope-sdk-java
</artifactId>
<version>
2.22.1
4
</version>
<version>
2.22.1
5
</version>
<scope>
compile
</scope>
<scope>
compile
</scope>
</dependency>
</dependency>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment