Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
poc-api
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
poc
poc-api
Commits
49a6d0d2
Commit
49a6d0d2
authored
Jan 22, 2025
by
alex yao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:【多模态调试】修复配置对话轮次不生效
parent
d7416fe9
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
2 deletions
+16
-2
AgentApplicationPreviewDto.java
...poc/agent_application/dto/AgentApplicationPreviewDto.java
+13
-0
AgentApplicationInfoRestImpl.java
...t_application/rest/impl/AgentApplicationInfoRestImpl.java
+3
-2
No files found.
src/main/java/cn/com/poc/agent_application/dto/AgentApplicationPreviewDto.java
View file @
49a6d0d2
...
...
@@ -21,6 +21,11 @@ public class AgentApplicationPreviewDto implements Serializable {
private
List
<
String
>
fileUrls
;
/**
* 对话参考轮次
*/
private
Integer
communicationTurn
;
/**
* 渠道来源
*/
...
...
@@ -89,4 +94,12 @@ public class AgentApplicationPreviewDto implements Serializable {
public
void
setChannel
(
String
channel
)
{
this
.
channel
=
channel
;
}
public
Integer
getCommunicationTurn
()
{
return
communicationTurn
;
}
public
void
setCommunicationTurn
(
Integer
communicationTurn
)
{
this
.
communicationTurn
=
communicationTurn
;
}
}
src/main/java/cn/com/poc/agent_application/rest/impl/AgentApplicationInfoRestImpl.java
View file @
49a6d0d2
...
...
@@ -256,18 +256,19 @@ public class AgentApplicationInfoRestImpl implements AgentApplicationInfoRest {
Float
topP
=
dto
.
getTopP
()
==
null
?
infoEntity
.
getTopP
()
:
dto
.
getTopP
();
Float
temperature
=
dto
.
getTemperature
()
==
null
?
infoEntity
.
getTemperature
()
:
dto
.
getTemperature
();
String
agentSystem
=
StringUtils
.
isBlank
(
dto
.
getAgentSystem
())
?
infoEntity
.
getAgentSystem
()
:
dto
.
getAgentSystem
();
Integer
communicationTurn
=
dto
.
getCommunicationTurn
()
==
null
?
infoEntity
.
getCommunicationTurn
():
dto
.
getCommunicationTurn
();
// 判断是否调用function
//计算扣分数
CheckPluginUseEntity
checkPluginUseEntity
=
AgentApplicationTools
.
checkPluginUse
(
dto
.
getMessages
(),
tools
,
fileUrls
,
imageUrls
);
Long
pointDeductionNum
=
pointDeductionRulesService
.
calculatePointDeductionNum
(
model
,
infoEntity
.
getCommunicationTurn
()
,
checkPluginUseEntity
.
getDeductionTools
());
Long
pointDeductionNum
=
pointDeductionRulesService
.
calculatePointDeductionNum
(
model
,
communicationTurn
,
checkPluginUseEntity
.
getDeductionTools
());
AgentUseModifyEventInfo
agentUseModifyEventInfo
=
new
AgentUseModifyEventInfo
();
agentUseModifyEventInfo
.
setAgentId
(
agentId
);
agentUseModifyEventInfo
.
setIsPublish
(
CommonConstant
.
IsDeleted
.
N
);
reduceSn
=
memberEquityService
.
reducePoint
(
userBaseEntity
.
getUserId
(),
pointDeductionNum
,
ModifyEventEnum
.
use
,
agentUseModifyEventInfo
);
//调用应用服务
agentApplicationInfoService
.
callAgentApplication
(
agentId
,
dialogueId
,
model
,
agentSystem
,
kdIds
.
toArray
(
new
Integer
[
0
]),
infoEntity
.
getCommunicationTurn
()
,
topP
,
agentSystem
,
kdIds
.
toArray
(
new
Integer
[
0
]),
communicationTurn
,
topP
,
temperature
,
dto
.
getMessages
(),
tools
,
checkPluginUseEntity
.
getFunctionCallResult
(),
dto
.
getFileUrls
(),
true
,
imageUrls
,
httpServletResponse
);
//数据采集
if
(
StringUtils
.
isBlank
(
dto
.
getChannel
()))
{
...
...
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