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
7380f1b0
Commit
7380f1b0
authored
Nov 27, 2024
by
alex yao
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'task/1004454' into 'release'
Task/1004454 See merge request
!8
parents
cdbc964a
68777b48
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
1034 additions
and
574 deletions
+1034
-574
pom.xml
pom.xml
+6
-1
AgentApplicationInfoConvert.java
...gent_application/convert/AgentApplicationInfoConvert.java
+33
-4
BizAgentApplicationPublishConvert.java
...pplication/convert/BizAgentApplicationPublishConvert.java
+30
-4
AgentApplicationVoiceConfig.java
...agent_application/domain/AgentApplicationVoiceConfig.java
+30
-0
AgentApplicationInfoDto.java
...om/poc/agent_application/dto/AgentApplicationInfoDto.java
+22
-13
BizAgentApplicationInfoEntity.java
...ent_application/entity/BizAgentApplicationInfoEntity.java
+18
-0
BizAgentApplicationPublishEntity.java
..._application/entity/BizAgentApplicationPublishEntity.java
+12
-0
VoiceConfig.java
...java/cn/com/poc/agent_application/entity/VoiceConfig.java
+31
-0
BizAgentApplicationInfoModel.java
...agent_application/model/BizAgentApplicationInfoModel.java
+319
-273
BizAgentApplicationPublishModel.java
...nt_application/model/BizAgentApplicationPublishModel.java
+295
-249
AgentApplicationInfoQuery.sql
...poc/agent_application/query/AgentApplicationInfoQuery.sql
+1
-0
AgentApplicationInfoQueryItem.java
...gent_application/query/AgentApplicationInfoQueryItem.java
+13
-0
BizAgentApplicationPublishService.java
...pplication/service/BizAgentApplicationPublishService.java
+1
-1
BizAgentApplicationInfoServiceImpl.java
...tion/service/impl/BizAgentApplicationInfoServiceImpl.java
+9
-2
BizAgentApplicationPublishServiceImpl.java
...n/service/impl/BizAgentApplicationPublishServiceImpl.java
+1
-3
AgentApplicationService.java
.../cn/com/poc/expose/aggregate/AgentApplicationService.java
+18
-0
AgentApplicationServiceImpl.java
...oc/expose/aggregate/impl/AgentApplicationServiceImpl.java
+33
-0
AgentApplicationRest.java
...ain/java/cn/com/poc/expose/rest/AgentApplicationRest.java
+14
-0
AgentApplicationRestImpl.java
...cn/com/poc/expose/rest/impl/AgentApplicationRestImpl.java
+16
-1
AgentApplicationConsumerServiceImpl.java
...age/service/impl/AgentApplicationConsumerServiceImpl.java
+0
-2
AgentApplicationInfoTest.java
src/test/java/cn/com/poc/AgentApplicationInfoTest.java
+132
-21
No files found.
pom.xml
View file @
7380f1b0
...
@@ -151,7 +151,12 @@
...
@@ -151,7 +151,12 @@
<version>
4.12
</version>
<version>
4.12
</version>
<scope>
test
</scope>
<scope>
test
</scope>
</dependency>
</dependency>
<dependency>
<groupId>
org.mockito
</groupId>
<artifactId>
mockito-core
</artifactId>
<version>
3.7.7
</version>
<scope>
test
</scope>
</dependency>
<dependency>
<dependency>
<groupId>
org.springframework
</groupId>
<groupId>
org.springframework
</groupId>
<artifactId>
spring-test
</artifactId>
<artifactId>
spring-test
</artifactId>
...
...
src/main/java/cn/com/poc/agent_application/convert/AgentApplicationInfoConvert.java
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
convert
;
package
cn
.
com
.
poc
.
agent_application
.
convert
;
import
cn.com.poc.agent_application.domain.AgentApplicationBaseInfo
;
import
cn.com.poc.agent_application.domain.*
;
import
cn.com.poc.agent_application.domain.AgentApplicationCommConfig
;
import
cn.com.poc.agent_application.domain.AgentApplicationCommModelConfig
;
import
cn.com.poc.agent_application.domain.AgentApplicationKnowledgeConfig
;
import
cn.com.poc.agent_application.dto.AgentApplicationInfoDto
;
import
cn.com.poc.agent_application.dto.AgentApplicationInfoDto
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationInfoEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationInfoEntity
;
import
cn.com.poc.agent_application.entity.Variable
;
import
cn.com.poc.agent_application.entity.Variable
;
import
cn.com.poc.agent_application.entity.VoiceConfig
;
import
cn.com.poc.agent_application.model.BizAgentApplicationInfoModel
;
import
cn.com.poc.agent_application.model.BizAgentApplicationInfoModel
;
import
cn.com.poc.agent_application.query.AgentApplicationInfoQueryItem
;
import
cn.com.poc.agent_application.query.AgentApplicationInfoQueryItem
;
import
cn.com.poc.agent_application.query.PublishAgentApplicationQueryItem
;
import
cn.com.poc.agent_application.query.PublishAgentApplicationQueryItem
;
import
cn.com.poc.common.constant.CommonConstant
;
import
cn.com.poc.common.utils.JsonUtils
;
import
cn.com.poc.common.utils.JsonUtils
;
import
cn.com.poc.expose.dto.SearchAgentApplicationDto
;
import
cn.com.poc.expose.dto.SearchAgentApplicationDto
;
import
cn.hutool.core.util.ObjectUtil
;
import
cn.hutool.core.util.ObjectUtil
;
...
@@ -72,6 +71,10 @@ public class AgentApplicationInfoConvert {
...
@@ -72,6 +71,10 @@ public class AgentApplicationInfoConvert {
if
(
StringUtils
.
isNotBlank
(
model
.
getUnitIds
()))
{
if
(
StringUtils
.
isNotBlank
(
model
.
getUnitIds
()))
{
entity
.
setUnitIds
(
JsonUtils
.
deSerialize
(
model
.
getUnitIds
(),
String
[].
class
));
entity
.
setUnitIds
(
JsonUtils
.
deSerialize
(
model
.
getUnitIds
(),
String
[].
class
));
}
}
if
(
StringUtils
.
isNotBlank
(
model
.
getVoiceConfig
()))
{
VoiceConfig
voiceConfig
=
JsonUtils
.
deSerialize
(
model
.
getVoiceConfig
(),
VoiceConfig
.
class
);
entity
.
setVoiceConfig
(
voiceConfig
);
}
entity
.
setIsDeleted
(
model
.
getIsDeleted
());
entity
.
setIsDeleted
(
model
.
getIsDeleted
());
entity
.
setCreator
(
model
.
getCreator
());
entity
.
setCreator
(
model
.
getCreator
());
entity
.
setCreatedTime
(
model
.
getCreatedTime
());
entity
.
setCreatedTime
(
model
.
getCreatedTime
());
...
@@ -114,6 +117,9 @@ public class AgentApplicationInfoConvert {
...
@@ -114,6 +117,9 @@ public class AgentApplicationInfoConvert {
if
(
ArrayUtils
.
isNotEmpty
(
entity
.
getUnitIds
()))
{
if
(
ArrayUtils
.
isNotEmpty
(
entity
.
getUnitIds
()))
{
model
.
setUnitIds
(
JsonUtil
.
toJson
(
entity
.
getUnitIds
()));
model
.
setUnitIds
(
JsonUtil
.
toJson
(
entity
.
getUnitIds
()));
}
}
if
(
ObjectUtil
.
isNotEmpty
(
entity
.
getVoiceConfig
()))
{
model
.
setVoiceConfig
(
JsonUtils
.
serialize
(
entity
.
getVoiceConfig
()));
}
model
.
setIsDeleted
(
entity
.
getIsDeleted
());
model
.
setIsDeleted
(
entity
.
getIsDeleted
());
model
.
setCreator
(
entity
.
getCreator
());
model
.
setCreator
(
entity
.
getCreator
());
model
.
setCreatedTime
(
entity
.
getCreatedTime
());
model
.
setCreatedTime
(
entity
.
getCreatedTime
());
...
@@ -154,11 +160,21 @@ public class AgentApplicationInfoConvert {
...
@@ -154,11 +160,21 @@ public class AgentApplicationInfoConvert {
commModelConfig
.
setTemperature
(
entity
.
getTemperature
());
commModelConfig
.
setTemperature
(
entity
.
getTemperature
());
commModelConfig
.
setCommunicationTurn
(
entity
.
getCommunicationTurn
());
commModelConfig
.
setCommunicationTurn
(
entity
.
getCommunicationTurn
());
AgentApplicationVoiceConfig
voiceConfig
=
new
AgentApplicationVoiceConfig
();
if
(
ObjectUtil
.
isNotEmpty
(
entity
.
getVoiceConfig
()))
{
voiceConfig
.
setDefaultOpen
(
entity
.
getVoiceConfig
().
getDefaultOpen
());
voiceConfig
.
setTimbreId
(
entity
.
getVoiceConfig
().
getTimbreId
());
}
else
{
voiceConfig
.
setDefaultOpen
(
CommonConstant
.
YOrN
.
N
);
voiceConfig
.
setTimbreId
(
StringUtils
.
EMPTY
);
}
AgentApplicationInfoDto
dto
=
new
AgentApplicationInfoDto
();
AgentApplicationInfoDto
dto
=
new
AgentApplicationInfoDto
();
dto
.
setBaseInfo
(
baseInfo
);
dto
.
setBaseInfo
(
baseInfo
);
dto
.
setCommConfig
(
commConfig
);
dto
.
setCommConfig
(
commConfig
);
dto
.
setKnowledgeConfig
(
knowledgeConfig
);
dto
.
setKnowledgeConfig
(
knowledgeConfig
);
dto
.
setCommModelConfig
(
commModelConfig
);
dto
.
setCommModelConfig
(
commModelConfig
);
dto
.
setVoiceConfig
(
voiceConfig
);
dto
.
setUnitIds
(
entity
.
getUnitIds
());
dto
.
setUnitIds
(
entity
.
getUnitIds
());
dto
.
setCreator
(
entity
.
getCreator
());
dto
.
setCreator
(
entity
.
getCreator
());
dto
.
setCreatedTime
(
entity
.
getCreatedTime
());
dto
.
setCreatedTime
(
entity
.
getCreatedTime
());
...
@@ -204,6 +220,16 @@ public class AgentApplicationInfoConvert {
...
@@ -204,6 +220,16 @@ public class AgentApplicationInfoConvert {
entity
.
setCommunicationTurn
(
dto
.
getCommModelConfig
().
getCommunicationTurn
());
entity
.
setCommunicationTurn
(
dto
.
getCommModelConfig
().
getCommunicationTurn
());
}
}
VoiceConfig
voiceConfig
=
new
VoiceConfig
();
if
(
ObjectUtil
.
isNotEmpty
(
dto
.
getVoiceConfig
()))
{
voiceConfig
.
setDefaultOpen
(
dto
.
getVoiceConfig
().
getDefaultOpen
());
voiceConfig
.
setTimbreId
(
dto
.
getVoiceConfig
().
getTimbreId
());
}
else
{
voiceConfig
.
setDefaultOpen
(
CommonConstant
.
YOrN
.
N
);
voiceConfig
.
setTimbreId
(
StringUtils
.
EMPTY
);
}
entity
.
setVoiceConfig
(
voiceConfig
);
entity
.
setUnitIds
(
dto
.
getUnitIds
());
entity
.
setUnitIds
(
dto
.
getUnitIds
());
entity
.
setCreator
(
dto
.
getCreator
());
entity
.
setCreator
(
dto
.
getCreator
());
entity
.
setCreatedTime
(
dto
.
getCreatedTime
());
entity
.
setCreatedTime
(
dto
.
getCreatedTime
());
...
@@ -248,6 +274,9 @@ public class AgentApplicationInfoConvert {
...
@@ -248,6 +274,9 @@ public class AgentApplicationInfoConvert {
if
(
StringUtils
.
isNotBlank
(
infoQueryItem
.
getUnitIds
()))
{
if
(
StringUtils
.
isNotBlank
(
infoQueryItem
.
getUnitIds
()))
{
entity
.
setUnitIds
(
JsonUtils
.
deSerialize
(
infoQueryItem
.
getUnitIds
(),
String
[].
class
));
entity
.
setUnitIds
(
JsonUtils
.
deSerialize
(
infoQueryItem
.
getUnitIds
(),
String
[].
class
));
}
}
if
(
StringUtils
.
isNotBlank
(
infoQueryItem
.
getVoiceConfig
()))
{
entity
.
setVoiceConfig
(
JsonUtils
.
deSerialize
(
infoQueryItem
.
getVoiceConfig
(),
VoiceConfig
.
class
));
}
entity
.
setIsDeleted
(
infoQueryItem
.
getIsDeleted
());
entity
.
setIsDeleted
(
infoQueryItem
.
getIsDeleted
());
entity
.
setCreator
(
infoQueryItem
.
getCreator
());
entity
.
setCreator
(
infoQueryItem
.
getCreator
());
entity
.
setCreatedTime
(
infoQueryItem
.
getCreatedTime
());
entity
.
setCreatedTime
(
infoQueryItem
.
getCreatedTime
());
...
...
src/main/java/cn/com/poc/agent_application/convert/BizAgentApplicationPublishConvert.java
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
convert
;
package
cn
.
com
.
poc
.
agent_application
.
convert
;
import
cn.com.poc.agent_application.domain.AgentApplicationBaseInfo
;
import
cn.com.poc.agent_application.domain.*
;
import
cn.com.poc.agent_application.domain.AgentApplicationCommConfig
;
import
cn.com.poc.agent_application.domain.AgentApplicationCommModelConfig
;
import
cn.com.poc.agent_application.domain.AgentApplicationKnowledgeConfig
;
import
cn.com.poc.agent_application.dto.BizAgentApplicationPublishDto
;
import
cn.com.poc.agent_application.dto.BizAgentApplicationPublishDto
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity
;
import
cn.com.poc.agent_application.entity.Variable
;
import
cn.com.poc.agent_application.entity.Variable
;
import
cn.com.poc.agent_application.entity.VoiceConfig
;
import
cn.com.poc.agent_application.model.BizAgentApplicationPublishModel
;
import
cn.com.poc.agent_application.model.BizAgentApplicationPublishModel
;
import
cn.com.poc.common.constant.CommonConstant
;
import
cn.com.poc.common.utils.JsonUtils
;
import
cn.com.poc.common.utils.JsonUtils
;
import
cn.hutool.core.util.ObjectUtil
;
import
cn.hutool.core.util.ObjectUtil
;
import
com.fasterxml.jackson.core.type.TypeReference
;
import
com.fasterxml.jackson.core.type.TypeReference
;
...
@@ -58,6 +57,10 @@ public class BizAgentApplicationPublishConvert {
...
@@ -58,6 +57,10 @@ public class BizAgentApplicationPublishConvert {
if
(
StringUtils
.
isNotBlank
(
model
.
getUnitIds
()))
{
if
(
StringUtils
.
isNotBlank
(
model
.
getUnitIds
()))
{
entity
.
setUnitIds
(
JsonUtils
.
deSerialize
(
model
.
getUnitIds
(),
String
[].
class
));
entity
.
setUnitIds
(
JsonUtils
.
deSerialize
(
model
.
getUnitIds
(),
String
[].
class
));
}
}
if
(
StringUtils
.
isNotBlank
(
model
.
getVoiceConfig
()))
{
VoiceConfig
voiceConfig
=
JsonUtils
.
deSerialize
(
model
.
getVoiceConfig
(),
VoiceConfig
.
class
);
entity
.
setVoiceConfig
(
voiceConfig
);
}
entity
.
setIsDeleted
(
model
.
getIsDeleted
());
entity
.
setIsDeleted
(
model
.
getIsDeleted
());
entity
.
setCreator
(
model
.
getCreator
());
entity
.
setCreator
(
model
.
getCreator
());
entity
.
setCreatedTime
(
model
.
getCreatedTime
());
entity
.
setCreatedTime
(
model
.
getCreatedTime
());
...
@@ -97,6 +100,10 @@ public class BizAgentApplicationPublishConvert {
...
@@ -97,6 +100,10 @@ public class BizAgentApplicationPublishConvert {
if
(
ArrayUtils
.
isNotEmpty
(
entity
.
getUnitIds
()))
{
if
(
ArrayUtils
.
isNotEmpty
(
entity
.
getUnitIds
()))
{
model
.
setUnitIds
(
JsonUtil
.
toJson
(
entity
.
getUnitIds
()));
model
.
setUnitIds
(
JsonUtil
.
toJson
(
entity
.
getUnitIds
()));
}
}
if
(
ObjectUtil
.
isNotEmpty
(
entity
.
getVoiceConfig
()))
{
model
.
setVoiceConfig
(
JsonUtils
.
serialize
(
entity
.
getVoiceConfig
()));
}
model
.
setIsDeleted
(
entity
.
getIsDeleted
());
model
.
setIsDeleted
(
entity
.
getIsDeleted
());
model
.
setCreator
(
entity
.
getCreator
());
model
.
setCreator
(
entity
.
getCreator
());
model
.
setCreatedTime
(
entity
.
getCreatedTime
());
model
.
setCreatedTime
(
entity
.
getCreatedTime
());
...
@@ -136,10 +143,21 @@ public class BizAgentApplicationPublishConvert {
...
@@ -136,10 +143,21 @@ public class BizAgentApplicationPublishConvert {
commModelConfig
.
setTemperature
(
entity
.
getTemperature
());
commModelConfig
.
setTemperature
(
entity
.
getTemperature
());
commModelConfig
.
setCommunicationTurn
(
entity
.
getCommunicationTurn
());
commModelConfig
.
setCommunicationTurn
(
entity
.
getCommunicationTurn
());
AgentApplicationVoiceConfig
voiceConfig
=
new
AgentApplicationVoiceConfig
();
if
(
ObjectUtil
.
isNotEmpty
(
entity
.
getVoiceConfig
()))
{
voiceConfig
.
setDefaultOpen
(
entity
.
getVoiceConfig
().
getDefaultOpen
());
voiceConfig
.
setTimbreId
(
entity
.
getVoiceConfig
().
getTimbreId
());
}
else
{
voiceConfig
.
setDefaultOpen
(
CommonConstant
.
YOrN
.
N
);
voiceConfig
.
setTimbreId
(
StringUtils
.
EMPTY
);
}
dto
.
setBaseInfo
(
baseInfo
);
dto
.
setBaseInfo
(
baseInfo
);
dto
.
setCommConfig
(
commConfig
);
dto
.
setCommConfig
(
commConfig
);
dto
.
setKnowledgeConfig
(
knowledgeConfig
);
dto
.
setKnowledgeConfig
(
knowledgeConfig
);
dto
.
setCommModelConfig
(
commModelConfig
);
dto
.
setCommModelConfig
(
commModelConfig
);
dto
.
setVoiceConfig
(
voiceConfig
);
dto
.
setUnitIds
(
entity
.
getUnitIds
());
dto
.
setUnitIds
(
entity
.
getUnitIds
());
dto
.
setCreator
(
entity
.
getCreator
());
dto
.
setCreator
(
entity
.
getCreator
());
dto
.
setCreatedTime
(
entity
.
getCreatedTime
());
dto
.
setCreatedTime
(
entity
.
getCreatedTime
());
...
@@ -185,6 +203,14 @@ public class BizAgentApplicationPublishConvert {
...
@@ -185,6 +203,14 @@ public class BizAgentApplicationPublishConvert {
entity
.
setTemperature
(
dto
.
getCommModelConfig
().
getTemperature
());
entity
.
setTemperature
(
dto
.
getCommModelConfig
().
getTemperature
());
}
}
VoiceConfig
voiceConfig
=
new
VoiceConfig
();
if
(
ObjectUtil
.
isNotEmpty
(
dto
.
getVoiceConfig
()))
{
voiceConfig
.
setDefaultOpen
(
dto
.
getVoiceConfig
().
getDefaultOpen
());
voiceConfig
.
setTimbreId
(
dto
.
getVoiceConfig
().
getTimbreId
());
}
else
{
voiceConfig
.
setDefaultOpen
(
CommonConstant
.
YOrN
.
N
);
voiceConfig
.
setTimbreId
(
StringUtils
.
EMPTY
);
}
entity
.
setUnitIds
(
dto
.
getUnitIds
());
entity
.
setUnitIds
(
dto
.
getUnitIds
());
entity
.
setCreator
(
dto
.
getCreator
());
entity
.
setCreator
(
dto
.
getCreator
());
entity
.
setCreatedTime
(
dto
.
getCreatedTime
());
entity
.
setCreatedTime
(
dto
.
getCreatedTime
());
...
...
src/main/java/cn/com/poc/agent_application/domain/AgentApplicationVoiceConfig.java
0 → 100644
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
domain
;
public
class
AgentApplicationVoiceConfig
{
/**
* 是否默认开启 Y-是 N-否
*/
private
String
defaultOpen
;
/**
* 音色ID
*/
private
String
timbreId
;
public
String
getDefaultOpen
()
{
return
defaultOpen
;
}
public
void
setDefaultOpen
(
String
defaultOpen
)
{
this
.
defaultOpen
=
defaultOpen
;
}
public
String
getTimbreId
()
{
return
timbreId
;
}
public
void
setTimbreId
(
String
timbreId
)
{
this
.
timbreId
=
timbreId
;
}
}
src/main/java/cn/com/poc/agent_application/dto/AgentApplicationInfoDto.java
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
dto
;
package
cn
.
com
.
poc
.
agent_application
.
dto
;
import
cn.com.poc.agent_application.domain.AgentApplicationBaseInfo
;
import
cn.com.poc.agent_application.domain.*
;
import
cn.com.poc.agent_application.domain.AgentApplicationCommConfig
;
import
cn.com.poc.agent_application.domain.AgentApplicationCommModelConfig
;
import
cn.com.poc.agent_application.domain.AgentApplicationKnowledgeConfig
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.fasterxml.jackson.annotation.JsonInclude
;
import
com.fasterxml.jackson.annotation.JsonInclude
;
...
@@ -21,6 +18,8 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
...
@@ -21,6 +18,8 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
private
AgentApplicationCommModelConfig
commModelConfig
;
private
AgentApplicationCommModelConfig
commModelConfig
;
private
AgentApplicationVoiceConfig
voiceConfig
;
public
AgentApplicationBaseInfo
getBaseInfo
()
{
public
AgentApplicationBaseInfo
getBaseInfo
()
{
return
baseInfo
;
return
baseInfo
;
}
}
...
@@ -53,6 +52,14 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
...
@@ -53,6 +52,14 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
this
.
commModelConfig
=
commModelConfig
;
this
.
commModelConfig
=
commModelConfig
;
}
}
public
AgentApplicationVoiceConfig
getVoiceConfig
()
{
return
voiceConfig
;
}
public
void
setVoiceConfig
(
AgentApplicationVoiceConfig
voiceConfig
)
{
this
.
voiceConfig
=
voiceConfig
;
}
/**
/**
* unit_ids
* unit_ids
* 组件ID
* 组件ID
...
@@ -113,7 +120,7 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
...
@@ -113,7 +120,7 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
/**
/**
* isCollect
* isCollect
* 当前用户是否收藏 1、Y 是 2、N 否
* 当前用户是否收藏 1、Y 是 2、N 否
*
*
/
*/
private
String
isCollect
;
private
String
isCollect
;
public
String
getIsCollect
()
{
public
String
getIsCollect
()
{
...
@@ -124,29 +131,31 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
...
@@ -124,29 +131,31 @@ public class AgentApplicationInfoDto implements java.io.Serializable {
this
.
isCollect
=
isCollect
;
this
.
isCollect
=
isCollect
;
}
}
/** agent_publish_id
/**
*发布应用的ID
* agent_publish_id
* 发布应用的ID
*/
*/
private
java
.
lang
.
Integer
agentPublishId
;
private
java
.
lang
.
Integer
agentPublishId
;
public
java
.
lang
.
Integer
getAgentPublishId
(){
public
java
.
lang
.
Integer
getAgentPublishId
()
{
return
this
.
agentPublishId
;
return
this
.
agentPublishId
;
}
}
public
void
setAgentPublishId
(
java
.
lang
.
Integer
agentPublishId
){
public
void
setAgentPublishId
(
java
.
lang
.
Integer
agentPublishId
)
{
this
.
agentPublishId
=
agentPublishId
;
this
.
agentPublishId
=
agentPublishId
;
}
}
/** is_sale
/**
*是否上架应用 1、Y 是 2、N 否
* is_sale
* 是否上架应用 1、Y 是 2、N 否
*/
*/
private
java
.
lang
.
String
isSale
;
private
java
.
lang
.
String
isSale
;
public
java
.
lang
.
String
getIsSale
(){
public
java
.
lang
.
String
getIsSale
()
{
return
this
.
isSale
;
return
this
.
isSale
;
}
}
public
void
setIsSale
(
java
.
lang
.
String
isSale
){
public
void
setIsSale
(
java
.
lang
.
String
isSale
)
{
this
.
isSale
=
isSale
;
this
.
isSale
=
isSale
;
}
}
...
...
src/main/java/cn/com/poc/agent_application/entity/BizAgentApplicationInfoEntity.java
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
entity
;
package
cn
.
com
.
poc
.
agent_application
.
entity
;
import
cn.com.poc.agent_application.domain.AgentApplicationVoiceConfig
;
import
javax.persistence.Column
;
import
javax.persistence.Column
;
import
java.util.Arrays
;
import
java.util.Arrays
;
import
java.util.List
;
import
java.util.List
;
...
@@ -329,6 +331,22 @@ public class BizAgentApplicationInfoEntity {
...
@@ -329,6 +331,22 @@ public class BizAgentApplicationInfoEntity {
this
.
isDocumentParsing
=
isDocumentParsing
;
this
.
isDocumentParsing
=
isDocumentParsing
;
}
}
/**
* voice_config
* 声音配置 defaultOpen- 是否默认开启 timbreId-音色
*/
private
VoiceConfig
voiceConfig
;
public
VoiceConfig
getVoiceConfig
()
{
return
voiceConfig
;
}
public
void
setVoiceConfig
(
VoiceConfig
voiceConfig
)
{
this
.
voiceConfig
=
voiceConfig
;
}
/**
/**
* is_deleted
* is_deleted
* 是否删除 1、Y 是 2、N 否
* 是否删除 1、Y 是 2、N 否
...
...
src/main/java/cn/com/poc/agent_application/entity/BizAgentApplicationPublishEntity.java
View file @
7380f1b0
...
@@ -330,6 +330,18 @@ public class BizAgentApplicationPublishEntity {
...
@@ -330,6 +330,18 @@ public class BizAgentApplicationPublishEntity {
this
.
isDocumentParsing
=
isDocumentParsing
;
this
.
isDocumentParsing
=
isDocumentParsing
;
}
}
/**
* voice_config
*/
private
VoiceConfig
voiceConfig
;
public
VoiceConfig
getVoiceConfig
()
{
return
voiceConfig
;
}
public
void
setVoiceConfig
(
VoiceConfig
voiceConfig
)
{
this
.
voiceConfig
=
voiceConfig
;
}
/**
/**
* is_deleted
* is_deleted
...
...
src/main/java/cn/com/poc/agent_application/entity/VoiceConfig.java
0 → 100644
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
entity
;
public
class
VoiceConfig
{
/**
* 是否默认开启 Y-是 N-否
*/
private
String
defaultOpen
;
/**
* 音色ID
*/
private
String
timbreId
;
public
String
getDefaultOpen
()
{
return
defaultOpen
;
}
public
void
setDefaultOpen
(
String
defaultOpen
)
{
this
.
defaultOpen
=
defaultOpen
;
}
public
String
getTimbreId
()
{
return
timbreId
;
}
public
void
setTimbreId
(
String
timbreId
)
{
this
.
timbreId
=
timbreId
;
}
}
src/main/java/cn/com/poc/agent_application/model/BizAgentApplicationInfoModel.java
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
model
;
package
cn
.
com
.
poc
.
agent_application
.
model
;
import
java.io.Serializable
;
import
java.io.Serializable
;
import
cn.com.yict.framemax.data.model.BaseModelClass
;
import
cn.com.yict.framemax.data.model.BaseModelClass
;
import
javax.persistence.Column
;
import
javax.persistence.Column
;
import
javax.persistence.Entity
;
import
javax.persistence.Entity
;
import
javax.persistence.Table
;
import
javax.persistence.Table
;
import
javax.persistence.Id
;
import
javax.persistence.Id
;
import
org.hibernate.annotations.DynamicInsert
;
import
org.hibernate.annotations.DynamicInsert
;
import
org.hibernate.annotations.DynamicUpdate
;
import
org.hibernate.annotations.DynamicUpdate
;
import
javax.persistence.Version
;
import
javax.persistence.Version
;
import
javax.persistence.GeneratedValue
;
import
javax.persistence.GeneratedValue
;
import
javax.persistence.GenerationType
;
import
javax.persistence.GenerationType
;
...
@@ -23,473 +27,515 @@ import javax.persistence.GenerationType;
...
@@ -23,473 +27,515 @@ import javax.persistence.GenerationType;
public
class
BizAgentApplicationInfoModel
extends
BaseModelClass
implements
Serializable
{
public
class
BizAgentApplicationInfoModel
extends
BaseModelClass
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
/** id
/**
*自增ID
* id
*/
* 自增ID
*/
private
java
.
lang
.
Integer
id
;
private
java
.
lang
.
Integer
id
;
@Column
(
name
=
"id"
,
length
=
10
)
@Column
(
name
=
"id"
,
length
=
10
)
@Id
@GeneratedValue
(
strategy
=
GenerationType
.
AUTO
)
@Id
public
java
.
lang
.
Integer
getId
(){
@GeneratedValue
(
strategy
=
GenerationType
.
AUTO
)
public
java
.
lang
.
Integer
getId
()
{
return
this
.
id
;
return
this
.
id
;
}
}
public
void
setId
(
java
.
lang
.
Integer
id
){
public
void
setId
(
java
.
lang
.
Integer
id
)
{
this
.
id
=
id
;
this
.
id
=
id
;
super
.
addValidField
(
"id"
);
super
.
addValidField
(
"id"
);
}
}
/** member_id
/**
*创建应用的用户ID
* member_id
*/
* 创建应用的用户ID
*/
private
java
.
lang
.
Integer
memberId
;
private
java
.
lang
.
Integer
memberId
;
@Column
(
name
=
"member_id"
,
length
=
10
)
@Column
(
name
=
"member_id"
,
length
=
10
)
public
java
.
lang
.
Integer
getMemberId
(){
public
java
.
lang
.
Integer
getMemberId
()
{
return
this
.
memberId
;
return
this
.
memberId
;
}
}
public
void
setMemberId
(
java
.
lang
.
Integer
memberId
){
public
void
setMemberId
(
java
.
lang
.
Integer
memberId
)
{
this
.
memberId
=
memberId
;
this
.
memberId
=
memberId
;
super
.
addValidField
(
"memberId"
);
super
.
addValidField
(
"memberId"
);
}
}
/** agent_id
/**
*agent应用ID
* agent_id
*/
* agent应用ID
*/
private
java
.
lang
.
String
agentId
;
private
java
.
lang
.
String
agentId
;
@Column
(
name
=
"agent_id"
,
length
=
200
)
@Column
(
name
=
"agent_id"
,
length
=
200
)
public
java
.
lang
.
String
getAgentId
(){
public
java
.
lang
.
String
getAgentId
()
{
return
this
.
agentId
;
return
this
.
agentId
;
}
}
public
void
setAgentId
(
java
.
lang
.
String
agentId
){
public
void
setAgentId
(
java
.
lang
.
String
agentId
)
{
this
.
agentId
=
agentId
;
this
.
agentId
=
agentId
;
super
.
addValidField
(
"agentId"
);
super
.
addValidField
(
"agentId"
);
}
}
/** agent_avatar
/**
*应用头像ICON地址
* agent_avatar
*/
* 应用头像ICON地址
*/
private
java
.
lang
.
String
agentAvatar
;
private
java
.
lang
.
String
agentAvatar
;
@Column
(
name
=
"agent_avatar"
,
length
=
200
)
@Column
(
name
=
"agent_avatar"
,
length
=
200
)
public
java
.
lang
.
String
getAgentAvatar
(){
public
java
.
lang
.
String
getAgentAvatar
()
{
return
this
.
agentAvatar
;
return
this
.
agentAvatar
;
}
}
public
void
setAgentAvatar
(
java
.
lang
.
String
agentAvatar
){
public
void
setAgentAvatar
(
java
.
lang
.
String
agentAvatar
)
{
this
.
agentAvatar
=
agentAvatar
;
this
.
agentAvatar
=
agentAvatar
;
super
.
addValidField
(
"agentAvatar"
);
super
.
addValidField
(
"agentAvatar"
);
}
}
/** agent_title
/**
*应用标题
* agent_title
*/
* 应用标题
*/
private
java
.
lang
.
String
agentTitle
;
private
java
.
lang
.
String
agentTitle
;
@Column
(
name
=
"agent_title"
,
length
=
50
)
@Column
(
name
=
"agent_title"
,
length
=
50
)
public
java
.
lang
.
String
getAgentTitle
(){
public
java
.
lang
.
String
getAgentTitle
()
{
return
this
.
agentTitle
;
return
this
.
agentTitle
;
}
}
public
void
setAgentTitle
(
java
.
lang
.
String
agentTitle
){
public
void
setAgentTitle
(
java
.
lang
.
String
agentTitle
)
{
this
.
agentTitle
=
agentTitle
;
this
.
agentTitle
=
agentTitle
;
super
.
addValidField
(
"agentTitle"
);
super
.
addValidField
(
"agentTitle"
);
}
}
/** agent_desc
/**
*应用描述
* agent_desc
*/
* 应用描述
*/
private
java
.
lang
.
String
agentDesc
;
private
java
.
lang
.
String
agentDesc
;
@Column
(
name
=
"agent_desc"
,
length
=
100
)
@Column
(
name
=
"agent_desc"
,
length
=
100
)
public
java
.
lang
.
String
getAgentDesc
(){
public
java
.
lang
.
String
getAgentDesc
()
{
return
this
.
agentDesc
;
return
this
.
agentDesc
;
}
}
public
void
setAgentDesc
(
java
.
lang
.
String
agentDesc
){
public
void
setAgentDesc
(
java
.
lang
.
String
agentDesc
)
{
this
.
agentDesc
=
agentDesc
;
this
.
agentDesc
=
agentDesc
;
super
.
addValidField
(
"agentDesc"
);
super
.
addValidField
(
"agentDesc"
);
}
}
/** agent_system
/**
*角色指令
* agent_system
*/
* 角色指令
*/
private
java
.
lang
.
String
agentSystem
;
private
java
.
lang
.
String
agentSystem
;
@Column
(
name
=
"agent_system"
,
length
=
2147483647
)
@Column
(
name
=
"agent_system"
,
length
=
2147483647
)
public
java
.
lang
.
String
getAgentSystem
(){
public
java
.
lang
.
String
getAgentSystem
()
{
return
this
.
agentSystem
;
return
this
.
agentSystem
;
}
}
public
void
setAgentSystem
(
java
.
lang
.
String
agentSystem
){
public
void
setAgentSystem
(
java
.
lang
.
String
agentSystem
)
{
this
.
agentSystem
=
agentSystem
;
this
.
agentSystem
=
agentSystem
;
super
.
addValidField
(
"agentSystem"
);
super
.
addValidField
(
"agentSystem"
);
}
}
/** agent_publish_status
/**
*应用发布状态 草稿-draft 发布-publish
* agent_publish_status
*/
* 应用发布状态 草稿-draft 发布-publish
*/
private
java
.
lang
.
String
agentPublishStatus
;
private
java
.
lang
.
String
agentPublishStatus
;
@Column
(
name
=
"agent_publish_status"
,
length
=
10
)
@Column
(
name
=
"agent_publish_status"
,
length
=
10
)
public
java
.
lang
.
String
getAgentPublishStatus
(){
public
java
.
lang
.
String
getAgentPublishStatus
()
{
return
this
.
agentPublishStatus
;
return
this
.
agentPublishStatus
;
}
}
public
void
setAgentPublishStatus
(
java
.
lang
.
String
agentPublishStatus
){
public
void
setAgentPublishStatus
(
java
.
lang
.
String
agentPublishStatus
)
{
this
.
agentPublishStatus
=
agentPublishStatus
;
this
.
agentPublishStatus
=
agentPublishStatus
;
super
.
addValidField
(
"agentPublishStatus"
);
super
.
addValidField
(
"agentPublishStatus"
);
}
}
/** publish_time
/**
*发布时间
* publish_time
*/
* 发布时间
*/
private
java
.
util
.
Date
publishTime
;
private
java
.
util
.
Date
publishTime
;
@Column
(
name
=
"publish_time"
,
length
=
19
)
@Column
(
name
=
"publish_time"
,
length
=
19
)
public
java
.
util
.
Date
getPublishTime
(){
public
java
.
util
.
Date
getPublishTime
()
{
return
this
.
publishTime
;
return
this
.
publishTime
;
}
}
public
void
setPublishTime
(
java
.
util
.
Date
publishTime
){
public
void
setPublishTime
(
java
.
util
.
Date
publishTime
)
{
this
.
publishTime
=
publishTime
;
this
.
publishTime
=
publishTime
;
super
.
addValidField
(
"publishTime"
);
super
.
addValidField
(
"publishTime"
);
}
}
/** preamble
/**
*开场白
* preamble
*/
* 开场白
*/
private
java
.
lang
.
String
preamble
;
private
java
.
lang
.
String
preamble
;
@Column
(
name
=
"preamble"
,
length
=
2147483647
)
@Column
(
name
=
"preamble"
,
length
=
2147483647
)
public
java
.
lang
.
String
getPreamble
(){
public
java
.
lang
.
String
getPreamble
()
{
return
this
.
preamble
;
return
this
.
preamble
;
}
}
public
void
setPreamble
(
java
.
lang
.
String
preamble
){
public
void
setPreamble
(
java
.
lang
.
String
preamble
)
{
this
.
preamble
=
preamble
;
this
.
preamble
=
preamble
;
super
.
addValidField
(
"preamble"
);
super
.
addValidField
(
"preamble"
);
}
}
/** featured_questions
/**
*推荐问
* featured_questions
*/
* 推荐问
*/
private
java
.
lang
.
String
featuredQuestions
;
private
java
.
lang
.
String
featuredQuestions
;
@Column
(
name
=
"featured_questions"
,
length
=
1073741824
)
@Column
(
name
=
"featured_questions"
,
length
=
1073741824
)
public
java
.
lang
.
String
getFeaturedQuestions
(){
public
java
.
lang
.
String
getFeaturedQuestions
()
{
return
this
.
featuredQuestions
;
return
this
.
featuredQuestions
;
}
}
public
void
setFeaturedQuestions
(
java
.
lang
.
String
featuredQuestions
){
public
void
setFeaturedQuestions
(
java
.
lang
.
String
featuredQuestions
)
{
this
.
featuredQuestions
=
featuredQuestions
;
this
.
featuredQuestions
=
featuredQuestions
;
super
.
addValidField
(
"featuredQuestions"
);
super
.
addValidField
(
"featuredQuestions"
);
}
}
/** communication_turn
/**
*对话上下文保存轮次 0-100
* communication_turn
*/
* 对话上下文保存轮次 0-100
*/
private
java
.
lang
.
Integer
communicationTurn
;
private
java
.
lang
.
Integer
communicationTurn
;
@Column
(
name
=
"communication_turn"
,
length
=
10
)
@Column
(
name
=
"communication_turn"
,
length
=
10
)
public
java
.
lang
.
Integer
getCommunicationTurn
(){
public
java
.
lang
.
Integer
getCommunicationTurn
()
{
return
this
.
communicationTurn
;
return
this
.
communicationTurn
;
}
}
public
void
setCommunicationTurn
(
java
.
lang
.
Integer
communicationTurn
){
public
void
setCommunicationTurn
(
java
.
lang
.
Integer
communicationTurn
)
{
this
.
communicationTurn
=
communicationTurn
;
this
.
communicationTurn
=
communicationTurn
;
super
.
addValidField
(
"communicationTurn"
);
super
.
addValidField
(
"communicationTurn"
);
}
}
/** continuous_question_status
/**
*追问状态 默认-default 自定义-customizable 关闭-close
* continuous_question_status
*/
* 追问状态 默认-default 自定义-customizable 关闭-close
*/
private
java
.
lang
.
String
continuousQuestionStatus
;
private
java
.
lang
.
String
continuousQuestionStatus
;
@Column
(
name
=
"continuous_question_status"
,
length
=
15
)
@Column
(
name
=
"continuous_question_status"
,
length
=
15
)
public
java
.
lang
.
String
getContinuousQuestionStatus
(){
public
java
.
lang
.
String
getContinuousQuestionStatus
()
{
return
this
.
continuousQuestionStatus
;
return
this
.
continuousQuestionStatus
;
}
}
public
void
setContinuousQuestionStatus
(
java
.
lang
.
String
continuousQuestionStatus
){
public
void
setContinuousQuestionStatus
(
java
.
lang
.
String
continuousQuestionStatus
)
{
this
.
continuousQuestionStatus
=
continuousQuestionStatus
;
this
.
continuousQuestionStatus
=
continuousQuestionStatus
;
super
.
addValidField
(
"continuousQuestionStatus"
);
super
.
addValidField
(
"continuousQuestionStatus"
);
}
}
/** continuous_question_system
/**
*追问prompt
* continuous_question_system
*/
* 追问prompt
*/
private
java
.
lang
.
String
continuousQuestionSystem
;
private
java
.
lang
.
String
continuousQuestionSystem
;
@Column
(
name
=
"continuous_question_system"
,
length
=
2147483647
)
@Column
(
name
=
"continuous_question_system"
,
length
=
2147483647
)
public
java
.
lang
.
String
getContinuousQuestionSystem
(){
public
java
.
lang
.
String
getContinuousQuestionSystem
()
{
return
this
.
continuousQuestionSystem
;
return
this
.
continuousQuestionSystem
;
}
}
public
void
setContinuousQuestionSystem
(
java
.
lang
.
String
continuousQuestionSystem
){
public
void
setContinuousQuestionSystem
(
java
.
lang
.
String
continuousQuestionSystem
)
{
this
.
continuousQuestionSystem
=
continuousQuestionSystem
;
this
.
continuousQuestionSystem
=
continuousQuestionSystem
;
super
.
addValidField
(
"continuousQuestionSystem"
);
super
.
addValidField
(
"continuousQuestionSystem"
);
}
}
/** continuous_question_turn
/**
*追问轮次 1-5
* continuous_question_turn
*/
* 追问轮次 1-5
*/
private
java
.
lang
.
Integer
continuousQuestionTurn
;
private
java
.
lang
.
Integer
continuousQuestionTurn
;
@Column
(
name
=
"continuous_question_turn"
,
length
=
10
)
@Column
(
name
=
"continuous_question_turn"
,
length
=
10
)
public
java
.
lang
.
Integer
getContinuousQuestionTurn
(){
public
java
.
lang
.
Integer
getContinuousQuestionTurn
()
{
return
this
.
continuousQuestionTurn
;
return
this
.
continuousQuestionTurn
;
}
}
public
void
setContinuousQuestionTurn
(
java
.
lang
.
Integer
continuousQuestionTurn
){
public
void
setContinuousQuestionTurn
(
java
.
lang
.
Integer
continuousQuestionTurn
)
{
this
.
continuousQuestionTurn
=
continuousQuestionTurn
;
this
.
continuousQuestionTurn
=
continuousQuestionTurn
;
super
.
addValidField
(
"continuousQuestionTurn"
);
super
.
addValidField
(
"continuousQuestionTurn"
);
}
}
/** knowledge_ids
/**
*知识库ID
* knowledge_ids
*/
* 知识库ID
*/
private
java
.
lang
.
String
knowledgeIds
;
private
java
.
lang
.
String
knowledgeIds
;
@Column
(
name
=
"knowledge_ids"
,
length
=
1073741824
)
@Column
(
name
=
"knowledge_ids"
,
length
=
1073741824
)
public
java
.
lang
.
String
getKnowledgeIds
(){
public
java
.
lang
.
String
getKnowledgeIds
()
{
return
this
.
knowledgeIds
;
return
this
.
knowledgeIds
;
}
}
public
void
setKnowledgeIds
(
java
.
lang
.
String
knowledgeIds
){
public
void
setKnowledgeIds
(
java
.
lang
.
String
knowledgeIds
)
{
this
.
knowledgeIds
=
knowledgeIds
;
this
.
knowledgeIds
=
knowledgeIds
;
super
.
addValidField
(
"knowledgeIds"
);
super
.
addValidField
(
"knowledgeIds"
);
}
}
/** large_model
/**
*问答模型
* large_model
*/
* 问答模型
*/
private
java
.
lang
.
String
largeModel
;
private
java
.
lang
.
String
largeModel
;
@Column
(
name
=
"large_model"
,
length
=
25
)
@Column
(
name
=
"large_model"
,
length
=
25
)
public
java
.
lang
.
String
getLargeModel
(){
public
java
.
lang
.
String
getLargeModel
()
{
return
this
.
largeModel
;
return
this
.
largeModel
;
}
}
public
void
setLargeModel
(
java
.
lang
.
String
largeModel
){
public
void
setLargeModel
(
java
.
lang
.
String
largeModel
)
{
this
.
largeModel
=
largeModel
;
this
.
largeModel
=
largeModel
;
super
.
addValidField
(
"largeModel"
);
super
.
addValidField
(
"largeModel"
);
}
}
/** top_p
/**
*对话模型 多样性 [0-1.00]
* top_p
*/
* 对话模型 多样性 [0-1.00]
*/
private
java
.
lang
.
Float
topP
;
private
java
.
lang
.
Float
topP
;
@Column
(
name
=
"top_p"
,
length
=
12
)
@Column
(
name
=
"top_p"
,
length
=
12
)
public
java
.
lang
.
Float
getTopP
(){
public
java
.
lang
.
Float
getTopP
()
{
return
this
.
topP
;
return
this
.
topP
;
}
}
public
void
setTopP
(
java
.
lang
.
Float
topP
){
public
void
setTopP
(
java
.
lang
.
Float
topP
)
{
this
.
topP
=
topP
;
this
.
topP
=
topP
;
super
.
addValidField
(
"topP"
);
super
.
addValidField
(
"topP"
);
}
}
/**
/*
* temperature
* temperature
*对话模型 温度 [0-1.00]
*
对话模型 温度 [0-1.00]
*/
*/
private
java
.
lang
.
Float
temperature
;
private
java
.
lang
.
Float
temperature
;
@Column
(
name
=
"temperature"
,
length
=
12
)
@Column
(
name
=
"temperature"
,
length
=
12
)
public
java
.
lang
.
Float
getTemperature
(){
public
java
.
lang
.
Float
getTemperature
()
{
return
this
.
temperature
;
return
this
.
temperature
;
}
}
public
void
setTemperature
(
java
.
lang
.
Float
temperature
){
public
void
setTemperature
(
java
.
lang
.
Float
temperature
)
{
this
.
temperature
=
temperature
;
this
.
temperature
=
temperature
;
super
.
addValidField
(
"temperature"
);
super
.
addValidField
(
"temperature"
);
}
}
/**
* unit_ids
/** unit_ids
* 组件ID
*组件ID
*/
*/
private
java
.
lang
.
String
unitIds
;
private
java
.
lang
.
String
unitIds
;
@Column
(
name
=
"unit_ids"
,
length
=
1073741824
)
@Column
(
name
=
"unit_ids"
,
length
=
1073741824
)
public
java
.
lang
.
String
getUnitIds
(){
public
java
.
lang
.
String
getUnitIds
()
{
return
this
.
unitIds
;
return
this
.
unitIds
;
}
}
public
void
setUnitIds
(
java
.
lang
.
String
unitIds
){
public
void
setUnitIds
(
java
.
lang
.
String
unitIds
)
{
this
.
unitIds
=
unitIds
;
this
.
unitIds
=
unitIds
;
super
.
addValidField
(
"unitIds"
);
super
.
addValidField
(
"unitIds"
);
}
}
/** variable_structure
/**
*变量结构
* variable_structure
* 变量结构
*/
*/
private
java
.
lang
.
String
variableStructure
;
private
java
.
lang
.
String
variableStructure
;
@Column
(
name
=
"variable_structure"
,
length
=
2147483647
)
@Column
(
name
=
"variable_structure"
,
length
=
2147483647
)
public
java
.
lang
.
String
getVariableStructure
(){
public
java
.
lang
.
String
getVariableStructure
()
{
return
this
.
variableStructure
;
return
this
.
variableStructure
;
}
}
public
void
setVariableStructure
(
java
.
lang
.
String
variableStructure
){
public
void
setVariableStructure
(
java
.
lang
.
String
variableStructure
)
{
this
.
variableStructure
=
variableStructure
;
this
.
variableStructure
=
variableStructure
;
super
.
addValidField
(
"variableStructure"
);
super
.
addValidField
(
"variableStructure"
);
}
}
/** is_long_memory
/**
*是否开启长期记忆 1、Y 是 2、N 否
* is_long_memory
* 是否开启长期记忆 1、Y 是 2、N 否
*/
*/
private
java
.
lang
.
String
isLongMemory
;
private
java
.
lang
.
String
isLongMemory
;
@Column
(
name
=
"is_long_memory"
,
length
=
1
)
@Column
(
name
=
"is_long_memory"
,
length
=
1
)
public
java
.
lang
.
String
getIsLongMemory
(){
public
java
.
lang
.
String
getIsLongMemory
()
{
return
this
.
isLongMemory
;
return
this
.
isLongMemory
;
}
}
public
void
setIsLongMemory
(
java
.
lang
.
String
isLongMemory
){
public
void
setIsLongMemory
(
java
.
lang
.
String
isLongMemory
)
{
this
.
isLongMemory
=
isLongMemory
;
this
.
isLongMemory
=
isLongMemory
;
super
.
addValidField
(
"isLongMemory"
);
super
.
addValidField
(
"isLongMemory"
);
}
}
/** is_document_parsing
/**
*是否开启文档解析 1、Y 是 2、N 否
* is_document_parsing
* 是否开启文档解析 1、Y 是 2、N 否
*/
*/
private
java
.
lang
.
String
isDocumentParsing
;
private
java
.
lang
.
String
isDocumentParsing
;
@Column
(
name
=
"is_document_parsing"
,
length
=
1
)
@Column
(
name
=
"is_document_parsing"
,
length
=
1
)
public
java
.
lang
.
String
getIsDocumentParsing
(){
public
java
.
lang
.
String
getIsDocumentParsing
()
{
return
this
.
isDocumentParsing
;
return
this
.
isDocumentParsing
;
}
}
public
void
setIsDocumentParsing
(
java
.
lang
.
String
isDocumentParsing
){
public
void
setIsDocumentParsing
(
java
.
lang
.
String
isDocumentParsing
)
{
this
.
isDocumentParsing
=
isDocumentParsing
;
this
.
isDocumentParsing
=
isDocumentParsing
;
super
.
addValidField
(
"isDocumentParsing"
);
super
.
addValidField
(
"isDocumentParsing"
);
}
}
/**
* voice_config
* 声音配置 defaultOpen-是否默认开启 timbreId-音色
*/
private
java
.
lang
.
String
voiceConfig
;
/** is_deleted
@Column
(
name
=
"voice_config"
,
length
=
2147483647
)
*是否删除 1、Y 是 2、N 否
public
java
.
lang
.
String
getVoiceConfig
()
{
*/
return
this
.
voiceConfig
;
}
public
void
setVoiceConfig
(
String
voiceConfig
)
{
this
.
voiceConfig
=
voiceConfig
;
super
.
addValidField
(
"voiceConfig"
);
}
/**
* is_deleted
* 是否删除 1、Y 是 2、N 否
*/
private
java
.
lang
.
String
isDeleted
;
private
java
.
lang
.
String
isDeleted
;
@Column
(
name
=
"is_deleted"
,
length
=
1
)
@Column
(
name
=
"is_deleted"
,
length
=
1
)
public
java
.
lang
.
String
getIsDeleted
(){
public
java
.
lang
.
String
getIsDeleted
()
{
return
this
.
isDeleted
;
return
this
.
isDeleted
;
}
}
public
void
setIsDeleted
(
java
.
lang
.
String
isDeleted
){
public
void
setIsDeleted
(
java
.
lang
.
String
isDeleted
)
{
this
.
isDeleted
=
isDeleted
;
this
.
isDeleted
=
isDeleted
;
super
.
addValidField
(
"isDeleted"
);
super
.
addValidField
(
"isDeleted"
);
}
}
/** CREATOR
/**
*创建人
* CREATOR
*/
* 创建人
*/
private
java
.
lang
.
String
creator
;
private
java
.
lang
.
String
creator
;
@Column
(
name
=
"CREATOR"
,
length
=
225
)
@Column
(
name
=
"CREATOR"
,
length
=
225
)
public
java
.
lang
.
String
getCreator
(){
public
java
.
lang
.
String
getCreator
()
{
return
this
.
creator
;
return
this
.
creator
;
}
}
public
void
setCreator
(
java
.
lang
.
String
creator
){
public
void
setCreator
(
java
.
lang
.
String
creator
)
{
this
.
creator
=
creator
;
this
.
creator
=
creator
;
super
.
addValidField
(
"creator"
);
super
.
addValidField
(
"creator"
);
}
}
/** CREATED_TIME
/**
*创建时间
* CREATED_TIME
*/
* 创建时间
*/
private
java
.
util
.
Date
createdTime
;
private
java
.
util
.
Date
createdTime
;
@Column
(
name
=
"CREATED_TIME"
,
length
=
19
)
@Column
(
name
=
"CREATED_TIME"
,
length
=
19
)
public
java
.
util
.
Date
getCreatedTime
(){
public
java
.
util
.
Date
getCreatedTime
()
{
return
this
.
createdTime
;
return
this
.
createdTime
;
}
}
public
void
setCreatedTime
(
java
.
util
.
Date
createdTime
){
public
void
setCreatedTime
(
java
.
util
.
Date
createdTime
)
{
this
.
createdTime
=
createdTime
;
this
.
createdTime
=
createdTime
;
super
.
addValidField
(
"createdTime"
);
super
.
addValidField
(
"createdTime"
);
}
}
/** MODIFIER
/**
*修改人
* MODIFIER
*/
* 修改人
*/
private
java
.
lang
.
String
modifier
;
private
java
.
lang
.
String
modifier
;
@Column
(
name
=
"MODIFIER"
,
length
=
225
)
@Column
(
name
=
"MODIFIER"
,
length
=
225
)
public
java
.
lang
.
String
getModifier
(){
public
java
.
lang
.
String
getModifier
()
{
return
this
.
modifier
;
return
this
.
modifier
;
}
}
public
void
setModifier
(
java
.
lang
.
String
modifier
){
public
void
setModifier
(
java
.
lang
.
String
modifier
)
{
this
.
modifier
=
modifier
;
this
.
modifier
=
modifier
;
super
.
addValidField
(
"modifier"
);
super
.
addValidField
(
"modifier"
);
}
}
/** MODIFIED_TIME
/**
*修改时间
* MODIFIED_TIME
*/
* 修改时间
*/
private
java
.
util
.
Date
modifiedTime
;
private
java
.
util
.
Date
modifiedTime
;
@Column
(
name
=
"MODIFIED_TIME"
,
length
=
19
)
@Column
(
name
=
"MODIFIED_TIME"
,
length
=
19
)
public
java
.
util
.
Date
getModifiedTime
(){
public
java
.
util
.
Date
getModifiedTime
()
{
return
this
.
modifiedTime
;
return
this
.
modifiedTime
;
}
}
public
void
setModifiedTime
(
java
.
util
.
Date
modifiedTime
){
public
void
setModifiedTime
(
java
.
util
.
Date
modifiedTime
)
{
this
.
modifiedTime
=
modifiedTime
;
this
.
modifiedTime
=
modifiedTime
;
super
.
addValidField
(
"modifiedTime"
);
super
.
addValidField
(
"modifiedTime"
);
}
}
/** SYS_VERSION
/**
*乐观锁,版本号
* SYS_VERSION
*/
* 乐观锁,版本号
*/
private
java
.
lang
.
Integer
sysVersion
;
private
java
.
lang
.
Integer
sysVersion
;
@Column
(
name
=
"SYS_VERSION"
,
length
=
10
)
@Column
(
name
=
"SYS_VERSION"
,
length
=
10
)
@Version
@Version
public
java
.
lang
.
Integer
getSysVersion
(){
public
java
.
lang
.
Integer
getSysVersion
()
{
return
this
.
sysVersion
;
return
this
.
sysVersion
;
}
}
public
void
setSysVersion
(
java
.
lang
.
Integer
sysVersion
){
public
void
setSysVersion
(
java
.
lang
.
Integer
sysVersion
)
{
this
.
sysVersion
=
sysVersion
;
this
.
sysVersion
=
sysVersion
;
super
.
addValidField
(
"sysVersion"
);
super
.
addValidField
(
"sysVersion"
);
}
}
}
}
\ No newline at end of file
src/main/java/cn/com/poc/agent_application/model/BizAgentApplicationPublishModel.java
View file @
7380f1b0
package
cn
.
com
.
poc
.
agent_application
.
model
;
package
cn
.
com
.
poc
.
agent_application
.
model
;
import
java.io.Serializable
;
import
java.io.Serializable
;
import
cn.com.yict.framemax.data.model.BaseModelClass
;
import
cn.com.yict.framemax.data.model.BaseModelClass
;
import
javax.persistence.Column
;
import
javax.persistence.Column
;
import
javax.persistence.Entity
;
import
javax.persistence.Entity
;
import
javax.persistence.Table
;
import
javax.persistence.Table
;
import
javax.persistence.Id
;
import
javax.persistence.Id
;
import
org.hibernate.annotations.DynamicInsert
;
import
org.hibernate.annotations.DynamicInsert
;
import
org.hibernate.annotations.DynamicUpdate
;
import
org.hibernate.annotations.DynamicUpdate
;
import
javax.persistence.Version
;
import
javax.persistence.Version
;
import
javax.persistence.GeneratedValue
;
import
javax.persistence.GeneratedValue
;
import
javax.persistence.GenerationType
;
import
javax.persistence.GenerationType
;
...
@@ -23,435 +27,477 @@ import javax.persistence.GenerationType;
...
@@ -23,435 +27,477 @@ import javax.persistence.GenerationType;
public
class
BizAgentApplicationPublishModel
extends
BaseModelClass
implements
Serializable
{
public
class
BizAgentApplicationPublishModel
extends
BaseModelClass
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
/** id
/**
*自增ID
* id
*/
* 自增ID
*/
private
java
.
lang
.
Integer
id
;
private
java
.
lang
.
Integer
id
;
@Column
(
name
=
"id"
,
length
=
10
)
@Column
(
name
=
"id"
,
length
=
10
)
@Id
@GeneratedValue
(
strategy
=
GenerationType
.
AUTO
)
@Id
public
java
.
lang
.
Integer
getId
(){
@GeneratedValue
(
strategy
=
GenerationType
.
AUTO
)
public
java
.
lang
.
Integer
getId
()
{
return
this
.
id
;
return
this
.
id
;
}
}
public
void
setId
(
java
.
lang
.
Integer
id
){
public
void
setId
(
java
.
lang
.
Integer
id
)
{
this
.
id
=
id
;
this
.
id
=
id
;
super
.
addValidField
(
"id"
);
super
.
addValidField
(
"id"
);
}
}
/** member_id
/**
*创建应用的用户ID
* member_id
*/
* 创建应用的用户ID
*/
private
java
.
lang
.
Integer
memberId
;
private
java
.
lang
.
Integer
memberId
;
@Column
(
name
=
"member_id"
,
length
=
10
)
@Column
(
name
=
"member_id"
,
length
=
10
)
public
java
.
lang
.
Integer
getMemberId
(){
public
java
.
lang
.
Integer
getMemberId
()
{
return
this
.
memberId
;
return
this
.
memberId
;
}
}
public
void
setMemberId
(
java
.
lang
.
Integer
memberId
){
public
void
setMemberId
(
java
.
lang
.
Integer
memberId
)
{
this
.
memberId
=
memberId
;
this
.
memberId
=
memberId
;
super
.
addValidField
(
"memberId"
);
super
.
addValidField
(
"memberId"
);
}
}
/** agent_id
/**
*agent应用ID
* agent_id
*/
* agent应用ID
*/
private
java
.
lang
.
String
agentId
;
private
java
.
lang
.
String
agentId
;
@Column
(
name
=
"agent_id"
,
length
=
200
)
@Column
(
name
=
"agent_id"
,
length
=
200
)
public
java
.
lang
.
String
getAgentId
(){
public
java
.
lang
.
String
getAgentId
()
{
return
this
.
agentId
;
return
this
.
agentId
;
}
}
public
void
setAgentId
(
java
.
lang
.
String
agentId
){
public
void
setAgentId
(
java
.
lang
.
String
agentId
)
{
this
.
agentId
=
agentId
;
this
.
agentId
=
agentId
;
super
.
addValidField
(
"agentId"
);
super
.
addValidField
(
"agentId"
);
}
}
/** agent_avatar
/**
*应用头像ICON地址
* agent_avatar
*/
* 应用头像ICON地址
*/
private
java
.
lang
.
String
agentAvatar
;
private
java
.
lang
.
String
agentAvatar
;
@Column
(
name
=
"agent_avatar"
,
length
=
200
)
@Column
(
name
=
"agent_avatar"
,
length
=
200
)
public
java
.
lang
.
String
getAgentAvatar
(){
public
java
.
lang
.
String
getAgentAvatar
()
{
return
this
.
agentAvatar
;
return
this
.
agentAvatar
;
}
}
public
void
setAgentAvatar
(
java
.
lang
.
String
agentAvatar
){
public
void
setAgentAvatar
(
java
.
lang
.
String
agentAvatar
)
{
this
.
agentAvatar
=
agentAvatar
;
this
.
agentAvatar
=
agentAvatar
;
super
.
addValidField
(
"agentAvatar"
);
super
.
addValidField
(
"agentAvatar"
);
}
}
/** agent_title
/**
*应用标题
* agent_title
*/
* 应用标题
*/
private
java
.
lang
.
String
agentTitle
;
private
java
.
lang
.
String
agentTitle
;
@Column
(
name
=
"agent_title"
,
length
=
50
)
@Column
(
name
=
"agent_title"
,
length
=
50
)
public
java
.
lang
.
String
getAgentTitle
(){
public
java
.
lang
.
String
getAgentTitle
()
{
return
this
.
agentTitle
;
return
this
.
agentTitle
;
}
}
public
void
setAgentTitle
(
java
.
lang
.
String
agentTitle
){
public
void
setAgentTitle
(
java
.
lang
.
String
agentTitle
)
{
this
.
agentTitle
=
agentTitle
;
this
.
agentTitle
=
agentTitle
;
super
.
addValidField
(
"agentTitle"
);
super
.
addValidField
(
"agentTitle"
);
}
}
/** agent_desc
/**
*应用描述
* agent_desc
*/
* 应用描述
*/
private
java
.
lang
.
String
agentDesc
;
private
java
.
lang
.
String
agentDesc
;
@Column
(
name
=
"agent_desc"
,
length
=
100
)
@Column
(
name
=
"agent_desc"
,
length
=
100
)
public
java
.
lang
.
String
getAgentDesc
(){
public
java
.
lang
.
String
getAgentDesc
()
{
return
this
.
agentDesc
;
return
this
.
agentDesc
;
}
}
public
void
setAgentDesc
(
java
.
lang
.
String
agentDesc
){
public
void
setAgentDesc
(
java
.
lang
.
String
agentDesc
)
{
this
.
agentDesc
=
agentDesc
;
this
.
agentDesc
=
agentDesc
;
super
.
addValidField
(
"agentDesc"
);
super
.
addValidField
(
"agentDesc"
);
}
}
/** agent_system
/**
*角色指令
* agent_system
*/
* 角色指令
*/
private
java
.
lang
.
String
agentSystem
;
private
java
.
lang
.
String
agentSystem
;
@Column
(
name
=
"agent_system"
,
length
=
2147483647
)
@Column
(
name
=
"agent_system"
,
length
=
2147483647
)
public
java
.
lang
.
String
getAgentSystem
(){
public
java
.
lang
.
String
getAgentSystem
()
{
return
this
.
agentSystem
;
return
this
.
agentSystem
;
}
}
public
void
setAgentSystem
(
java
.
lang
.
String
agentSystem
){
public
void
setAgentSystem
(
java
.
lang
.
String
agentSystem
)
{
this
.
agentSystem
=
agentSystem
;
this
.
agentSystem
=
agentSystem
;
super
.
addValidField
(
"agentSystem"
);
super
.
addValidField
(
"agentSystem"
);
}
}
/** preamble
/**
*开场白
* preamble
*/
* 开场白
*/
private
java
.
lang
.
String
preamble
;
private
java
.
lang
.
String
preamble
;
@Column
(
name
=
"preamble"
,
length
=
2147483647
)
@Column
(
name
=
"preamble"
,
length
=
2147483647
)
public
java
.
lang
.
String
getPreamble
(){
public
java
.
lang
.
String
getPreamble
()
{
return
this
.
preamble
;
return
this
.
preamble
;
}
}
public
void
setPreamble
(
java
.
lang
.
String
preamble
){
public
void
setPreamble
(
java
.
lang
.
String
preamble
)
{
this
.
preamble
=
preamble
;
this
.
preamble
=
preamble
;
super
.
addValidField
(
"preamble"
);
super
.
addValidField
(
"preamble"
);
}
}
/** variable_structure
/**
*变量结构
* variable_structure
* 变量结构
*/
*/
private
java
.
lang
.
String
variableStructure
;
private
java
.
lang
.
String
variableStructure
;
@Column
(
name
=
"variable_structure"
,
length
=
2147483647
)
@Column
(
name
=
"variable_structure"
,
length
=
2147483647
)
public
java
.
lang
.
String
getVariableStructure
(){
public
java
.
lang
.
String
getVariableStructure
()
{
return
this
.
variableStructure
;
return
this
.
variableStructure
;
}
}
public
void
setVariableStructure
(
java
.
lang
.
String
variableStructure
){
public
void
setVariableStructure
(
java
.
lang
.
String
variableStructure
)
{
this
.
variableStructure
=
variableStructure
;
this
.
variableStructure
=
variableStructure
;
super
.
addValidField
(
"variableStructure"
);
super
.
addValidField
(
"variableStructure"
);
}
}
/** featured_questions
/**
*推荐问
* featured_questions
*/
* 推荐问
*/
private
java
.
lang
.
String
featuredQuestions
;
private
java
.
lang
.
String
featuredQuestions
;
@Column
(
name
=
"featured_questions"
,
length
=
1073741824
)
@Column
(
name
=
"featured_questions"
,
length
=
1073741824
)
public
java
.
lang
.
String
getFeaturedQuestions
(){
public
java
.
lang
.
String
getFeaturedQuestions
()
{
return
this
.
featuredQuestions
;
return
this
.
featuredQuestions
;
}
}
public
void
setFeaturedQuestions
(
java
.
lang
.
String
featuredQuestions
){
public
void
setFeaturedQuestions
(
java
.
lang
.
String
featuredQuestions
)
{
this
.
featuredQuestions
=
featuredQuestions
;
this
.
featuredQuestions
=
featuredQuestions
;
super
.
addValidField
(
"featuredQuestions"
);
super
.
addValidField
(
"featuredQuestions"
);
}
}
/** communication_turn
/**
*对话上下文保存轮次 0-100
* communication_turn
*/
* 对话上下文保存轮次 0-100
*/
private
java
.
lang
.
Integer
communicationTurn
;
private
java
.
lang
.
Integer
communicationTurn
;
@Column
(
name
=
"communication_turn"
,
length
=
10
)
@Column
(
name
=
"communication_turn"
,
length
=
10
)
public
java
.
lang
.
Integer
getCommunicationTurn
(){
public
java
.
lang
.
Integer
getCommunicationTurn
()
{
return
this
.
communicationTurn
;
return
this
.
communicationTurn
;
}
}
public
void
setCommunicationTurn
(
java
.
lang
.
Integer
communicationTurn
){
public
void
setCommunicationTurn
(
java
.
lang
.
Integer
communicationTurn
)
{
this
.
communicationTurn
=
communicationTurn
;
this
.
communicationTurn
=
communicationTurn
;
super
.
addValidField
(
"communicationTurn"
);
super
.
addValidField
(
"communicationTurn"
);
}
}
/** continuous_question_status
/**
*追问状态 默认-default 自定义-customizable 关闭-close
* continuous_question_status
*/
* 追问状态 默认-default 自定义-customizable 关闭-close
*/
private
java
.
lang
.
String
continuousQuestionStatus
;
private
java
.
lang
.
String
continuousQuestionStatus
;
@Column
(
name
=
"continuous_question_status"
,
length
=
15
)
@Column
(
name
=
"continuous_question_status"
,
length
=
15
)
public
java
.
lang
.
String
getContinuousQuestionStatus
(){
public
java
.
lang
.
String
getContinuousQuestionStatus
()
{
return
this
.
continuousQuestionStatus
;
return
this
.
continuousQuestionStatus
;
}
}
public
void
setContinuousQuestionStatus
(
java
.
lang
.
String
continuousQuestionStatus
){
public
void
setContinuousQuestionStatus
(
java
.
lang
.
String
continuousQuestionStatus
)
{
this
.
continuousQuestionStatus
=
continuousQuestionStatus
;
this
.
continuousQuestionStatus
=
continuousQuestionStatus
;
super
.
addValidField
(
"continuousQuestionStatus"
);
super
.
addValidField
(
"continuousQuestionStatus"
);
}
}
/** continuous_question_system
/**
*追问prompt
* continuous_question_system
*/
* 追问prompt
*/
private
java
.
lang
.
String
continuousQuestionSystem
;
private
java
.
lang
.
String
continuousQuestionSystem
;
@Column
(
name
=
"continuous_question_system"
,
length
=
2147483647
)
@Column
(
name
=
"continuous_question_system"
,
length
=
2147483647
)
public
java
.
lang
.
String
getContinuousQuestionSystem
(){
public
java
.
lang
.
String
getContinuousQuestionSystem
()
{
return
this
.
continuousQuestionSystem
;
return
this
.
continuousQuestionSystem
;
}
}
public
void
setContinuousQuestionSystem
(
java
.
lang
.
String
continuousQuestionSystem
){
public
void
setContinuousQuestionSystem
(
java
.
lang
.
String
continuousQuestionSystem
)
{
this
.
continuousQuestionSystem
=
continuousQuestionSystem
;
this
.
continuousQuestionSystem
=
continuousQuestionSystem
;
super
.
addValidField
(
"continuousQuestionSystem"
);
super
.
addValidField
(
"continuousQuestionSystem"
);
}
}
/** continuous_question_turn
/**
*追问轮次 1-5
* continuous_question_turn
*/
* 追问轮次 1-5
*/
private
java
.
lang
.
Integer
continuousQuestionTurn
;
private
java
.
lang
.
Integer
continuousQuestionTurn
;
@Column
(
name
=
"continuous_question_turn"
,
length
=
10
)
@Column
(
name
=
"continuous_question_turn"
,
length
=
10
)
public
java
.
lang
.
Integer
getContinuousQuestionTurn
(){
public
java
.
lang
.
Integer
getContinuousQuestionTurn
()
{
return
this
.
continuousQuestionTurn
;
return
this
.
continuousQuestionTurn
;
}
}
public
void
setContinuousQuestionTurn
(
java
.
lang
.
Integer
continuousQuestionTurn
){
public
void
setContinuousQuestionTurn
(
java
.
lang
.
Integer
continuousQuestionTurn
)
{
this
.
continuousQuestionTurn
=
continuousQuestionTurn
;
this
.
continuousQuestionTurn
=
continuousQuestionTurn
;
super
.
addValidField
(
"continuousQuestionTurn"
);
super
.
addValidField
(
"continuousQuestionTurn"
);
}
}
/** knowledge_ids
/**
*知识库ID
* knowledge_ids
*/
* 知识库ID
*/
private
java
.
lang
.
String
knowledgeIds
;
private
java
.
lang
.
String
knowledgeIds
;
@Column
(
name
=
"knowledge_ids"
,
length
=
1073741824
)
@Column
(
name
=
"knowledge_ids"
,
length
=
1073741824
)
public
java
.
lang
.
String
getKnowledgeIds
(){
public
java
.
lang
.
String
getKnowledgeIds
()
{
return
this
.
knowledgeIds
;
return
this
.
knowledgeIds
;
}
}
public
void
setKnowledgeIds
(
java
.
lang
.
String
knowledgeIds
){
public
void
setKnowledgeIds
(
java
.
lang
.
String
knowledgeIds
)
{
this
.
knowledgeIds
=
knowledgeIds
;
this
.
knowledgeIds
=
knowledgeIds
;
super
.
addValidField
(
"knowledgeIds"
);
super
.
addValidField
(
"knowledgeIds"
);
}
}
/** large_model
/**
*问答模型
* large_model
*/
* 问答模型
*/
private
java
.
lang
.
String
largeModel
;
private
java
.
lang
.
String
largeModel
;
@Column
(
name
=
"large_model"
,
length
=
25
)
@Column
(
name
=
"large_model"
,
length
=
25
)
public
java
.
lang
.
String
getLargeModel
(){
public
java
.
lang
.
String
getLargeModel
()
{
return
this
.
largeModel
;
return
this
.
largeModel
;
}
}
public
void
setLargeModel
(
java
.
lang
.
String
largeModel
){
public
void
setLargeModel
(
java
.
lang
.
String
largeModel
)
{
this
.
largeModel
=
largeModel
;
this
.
largeModel
=
largeModel
;
super
.
addValidField
(
"largeModel"
);
super
.
addValidField
(
"largeModel"
);
}
}
/** top_p
/**
*对话模型 多样性 [0-1.00]
* top_p
*/
* 对话模型 多样性 [0-1.00]
*/
private
java
.
lang
.
Float
topP
;
private
java
.
lang
.
Float
topP
;
@Column
(
name
=
"top_p"
,
length
=
12
)
@Column
(
name
=
"top_p"
,
length
=
12
)
public
java
.
lang
.
Float
getTopP
(){
public
java
.
lang
.
Float
getTopP
()
{
return
this
.
topP
;
return
this
.
topP
;
}
}
public
void
setTopP
(
java
.
lang
.
Float
topP
){
public
void
setTopP
(
java
.
lang
.
Float
topP
)
{
this
.
topP
=
topP
;
this
.
topP
=
topP
;
super
.
addValidField
(
"topP"
);
super
.
addValidField
(
"topP"
);
}
}
/** temperature
/**
*对话模型 温度 [0-1.00]
* temperature
* 对话模型 温度 [0-1.00]
*/
*/
private
java
.
lang
.
Float
temperature
;
private
java
.
lang
.
Float
temperature
;
@Column
(
name
=
"temperature"
,
length
=
12
)
@Column
(
name
=
"temperature"
,
length
=
12
)
public
java
.
lang
.
Float
getTemperature
(){
public
java
.
lang
.
Float
getTemperature
()
{
return
this
.
temperature
;
return
this
.
temperature
;
}
}
public
void
setTemperature
(
java
.
lang
.
Float
temperature
){
public
void
setTemperature
(
java
.
lang
.
Float
temperature
)
{
this
.
temperature
=
temperature
;
this
.
temperature
=
temperature
;
super
.
addValidField
(
"temperature"
);
super
.
addValidField
(
"temperature"
);
}
}
/**
/*
* unit_ids
* unit_ids
*
组件ID
*
组件ID
*/
*/
private
java
.
lang
.
String
unitIds
;
private
java
.
lang
.
String
unitIds
;
@Column
(
name
=
"unit_ids"
,
length
=
1073741824
)
@Column
(
name
=
"unit_ids"
,
length
=
1073741824
)
public
java
.
lang
.
String
getUnitIds
(){
public
java
.
lang
.
String
getUnitIds
()
{
return
this
.
unitIds
;
return
this
.
unitIds
;
}
}
public
void
setUnitIds
(
java
.
lang
.
String
unitIds
){
public
void
setUnitIds
(
java
.
lang
.
String
unitIds
)
{
this
.
unitIds
=
unitIds
;
this
.
unitIds
=
unitIds
;
super
.
addValidField
(
"unitIds"
);
super
.
addValidField
(
"unitIds"
);
}
}
/** is_long_memory
/**
*是否开启长期记忆 1、Y 是 2、N 否
* is_long_memory
* 是否开启长期记忆 1、Y 是 2、N 否
*/
*/
private
java
.
lang
.
String
isLongMemory
;
private
java
.
lang
.
String
isLongMemory
;
@Column
(
name
=
"is_long_memory"
,
length
=
1
)
@Column
(
name
=
"is_long_memory"
,
length
=
1
)
public
java
.
lang
.
String
getIsLongMemory
(){
public
java
.
lang
.
String
getIsLongMemory
()
{
return
this
.
isLongMemory
;
return
this
.
isLongMemory
;
}
}
public
void
setIsLongMemory
(
java
.
lang
.
String
isLongMemory
){
public
void
setIsLongMemory
(
java
.
lang
.
String
isLongMemory
)
{
this
.
isLongMemory
=
isLongMemory
;
this
.
isLongMemory
=
isLongMemory
;
super
.
addValidField
(
"isLongMemory"
);
super
.
addValidField
(
"isLongMemory"
);
}
}
private
java
.
lang
.
String
isDocumentParsing
;
private
java
.
lang
.
String
isDocumentParsing
;
@Column
(
name
=
"is_document_parsing"
,
length
=
1
)
@Column
(
name
=
"is_document_parsing"
,
length
=
1
)
public
java
.
lang
.
String
getIsDocumentParsing
(){
public
java
.
lang
.
String
getIsDocumentParsing
()
{
return
this
.
isDocumentParsing
;
return
this
.
isDocumentParsing
;
}
}
public
void
setIsDocumentParsing
(
java
.
lang
.
String
isDocumentParsing
){
public
void
setIsDocumentParsing
(
java
.
lang
.
String
isDocumentParsing
)
{
this
.
isDocumentParsing
=
isDocumentParsing
;
this
.
isDocumentParsing
=
isDocumentParsing
;
super
.
addValidField
(
"isDocumentParsing"
);
super
.
addValidField
(
"isDocumentParsing"
);
}
}
/**
* voice_config
* 声音配置 default_open-是否默认开启 timbre_id-音色
*/
private
java
.
lang
.
String
voiceConfig
;
@Column
(
name
=
"voice_config"
,
length
=
2147483647
)
public
java
.
lang
.
String
getVoiceConfig
()
{
return
this
.
voiceConfig
;
}
public
void
setVoiceConfig
(
String
voiceConfig
)
{
this
.
voiceConfig
=
voiceConfig
;
super
.
addValidField
(
"voiceConfig"
);
}
/** is_deleted
*是否删除 1、Y 是 2、N 否
/**
*/
* is_deleted
* 是否删除 1、Y 是 2、N 否
*/
private
java
.
lang
.
String
isDeleted
;
private
java
.
lang
.
String
isDeleted
;
@Column
(
name
=
"is_deleted"
,
length
=
1
)
@Column
(
name
=
"is_deleted"
,
length
=
1
)
public
java
.
lang
.
String
getIsDeleted
(){
public
java
.
lang
.
String
getIsDeleted
()
{
return
this
.
isDeleted
;
return
this
.
isDeleted
;
}
}
public
void
setIsDeleted
(
java
.
lang
.
String
isDeleted
){
public
void
setIsDeleted
(
java
.
lang
.
String
isDeleted
)
{
this
.
isDeleted
=
isDeleted
;
this
.
isDeleted
=
isDeleted
;
super
.
addValidField
(
"isDeleted"
);
super
.
addValidField
(
"isDeleted"
);
}
}
/** CREATOR
/**
*创建人
* CREATOR
*/
* 创建人
*/
private
java
.
lang
.
String
creator
;
private
java
.
lang
.
String
creator
;
@Column
(
name
=
"CREATOR"
,
length
=
225
)
@Column
(
name
=
"CREATOR"
,
length
=
225
)
public
java
.
lang
.
String
getCreator
(){
public
java
.
lang
.
String
getCreator
()
{
return
this
.
creator
;
return
this
.
creator
;
}
}
public
void
setCreator
(
java
.
lang
.
String
creator
){
public
void
setCreator
(
java
.
lang
.
String
creator
)
{
this
.
creator
=
creator
;
this
.
creator
=
creator
;
super
.
addValidField
(
"creator"
);
super
.
addValidField
(
"creator"
);
}
}
/** CREATED_TIME
/**
*创建时间
* CREATED_TIME
*/
* 创建时间
*/
private
java
.
util
.
Date
createdTime
;
private
java
.
util
.
Date
createdTime
;
@Column
(
name
=
"CREATED_TIME"
,
length
=
19
)
@Column
(
name
=
"CREATED_TIME"
,
length
=
19
)
public
java
.
util
.
Date
getCreatedTime
(){
public
java
.
util
.
Date
getCreatedTime
()
{
return
this
.
createdTime
;
return
this
.
createdTime
;
}
}
public
void
setCreatedTime
(
java
.
util
.
Date
createdTime
){
public
void
setCreatedTime
(
java
.
util
.
Date
createdTime
)
{
this
.
createdTime
=
createdTime
;
this
.
createdTime
=
createdTime
;
super
.
addValidField
(
"createdTime"
);
super
.
addValidField
(
"createdTime"
);
}
}
/** MODIFIER
/**
*修改人
* MODIFIER
*/
* 修改人
*/
private
java
.
lang
.
String
modifier
;
private
java
.
lang
.
String
modifier
;
@Column
(
name
=
"MODIFIER"
,
length
=
225
)
@Column
(
name
=
"MODIFIER"
,
length
=
225
)
public
java
.
lang
.
String
getModifier
(){
public
java
.
lang
.
String
getModifier
()
{
return
this
.
modifier
;
return
this
.
modifier
;
}
}
public
void
setModifier
(
java
.
lang
.
String
modifier
){
public
void
setModifier
(
java
.
lang
.
String
modifier
)
{
this
.
modifier
=
modifier
;
this
.
modifier
=
modifier
;
super
.
addValidField
(
"modifier"
);
super
.
addValidField
(
"modifier"
);
}
}
/** MODIFIED_TIME
/**
*修改时间
* MODIFIED_TIME
*/
* 修改时间
*/
private
java
.
util
.
Date
modifiedTime
;
private
java
.
util
.
Date
modifiedTime
;
@Column
(
name
=
"MODIFIED_TIME"
,
length
=
19
)
@Column
(
name
=
"MODIFIED_TIME"
,
length
=
19
)
public
java
.
util
.
Date
getModifiedTime
(){
public
java
.
util
.
Date
getModifiedTime
()
{
return
this
.
modifiedTime
;
return
this
.
modifiedTime
;
}
}
public
void
setModifiedTime
(
java
.
util
.
Date
modifiedTime
){
public
void
setModifiedTime
(
java
.
util
.
Date
modifiedTime
)
{
this
.
modifiedTime
=
modifiedTime
;
this
.
modifiedTime
=
modifiedTime
;
super
.
addValidField
(
"modifiedTime"
);
super
.
addValidField
(
"modifiedTime"
);
}
}
/** SYS_VERSION
/**
*乐观锁,版本号
* SYS_VERSION
*/
* 乐观锁,版本号
*/
private
java
.
lang
.
Integer
sysVersion
;
private
java
.
lang
.
Integer
sysVersion
;
@Column
(
name
=
"SYS_VERSION"
,
length
=
10
)
@Column
(
name
=
"SYS_VERSION"
,
length
=
10
)
@Version
@Version
public
java
.
lang
.
Integer
getSysVersion
(){
public
java
.
lang
.
Integer
getSysVersion
()
{
return
this
.
sysVersion
;
return
this
.
sysVersion
;
}
}
public
void
setSysVersion
(
java
.
lang
.
Integer
sysVersion
){
public
void
setSysVersion
(
java
.
lang
.
Integer
sysVersion
)
{
this
.
sysVersion
=
sysVersion
;
this
.
sysVersion
=
sysVersion
;
super
.
addValidField
(
"sysVersion"
);
super
.
addValidField
(
"sysVersion"
);
}
}
}
}
\ No newline at end of file
src/main/java/cn/com/poc/agent_application/query/AgentApplicationInfoQuery.sql
View file @
7380f1b0
...
@@ -22,6 +22,7 @@ select distinct
...
@@ -22,6 +22,7 @@ select distinct
variable_structure
,
variable_structure
,
is_long_memory
,
is_long_memory
,
is_document_parsing
,
is_document_parsing
,
voice_config
,
is_deleted
,
is_deleted
,
CREATOR
,
CREATOR
,
CREATED_TIME
,
CREATED_TIME
,
...
...
src/main/java/cn/com/poc/agent_application/query/AgentApplicationInfoQueryItem.java
View file @
7380f1b0
...
@@ -363,6 +363,19 @@ public class AgentApplicationInfoQueryItem extends BaseItemClass implements Seri
...
@@ -363,6 +363,19 @@ public class AgentApplicationInfoQueryItem extends BaseItemClass implements Seri
this
.
isDocumentParsing
=
isDocumentParsing
;
this
.
isDocumentParsing
=
isDocumentParsing
;
}
}
/**
* voice_config
*/
private
java
.
lang
.
String
voiceConfig
;
@Column
(
name
=
"voice_config"
)
public
java
.
lang
.
String
getVoiceConfig
()
{
return
this
.
voiceConfig
;
}
public
void
setVoiceConfig
(
java
.
lang
.
String
voiceConfig
)
{
this
.
voiceConfig
=
voiceConfig
;
}
/**
/**
* is_deleted
* is_deleted
...
...
src/main/java/cn/com/poc/agent_application/service/BizAgentApplicationPublishService.java
View file @
7380f1b0
...
@@ -12,7 +12,7 @@ public interface BizAgentApplicationPublishService extends BaseService {
...
@@ -12,7 +12,7 @@ public interface BizAgentApplicationPublishService extends BaseService {
BizAgentApplicationPublishEntity
get
(
java
.
lang
.
Integer
id
)
throws
Exception
;
BizAgentApplicationPublishEntity
get
(
java
.
lang
.
Integer
id
)
throws
Exception
;
BizAgentApplicationPublishEntity
getByAgentId
(
String
agentId
)
throws
Exception
;
BizAgentApplicationPublishEntity
getByAgentId
(
String
agentId
);
List
<
BizAgentApplicationPublishEntity
>
findByExample
(
BizAgentApplicationPublishEntity
example
,
PagingInfo
pagingInfo
)
throws
Exception
;
List
<
BizAgentApplicationPublishEntity
>
findByExample
(
BizAgentApplicationPublishEntity
example
,
PagingInfo
pagingInfo
)
throws
Exception
;
...
...
src/main/java/cn/com/poc/agent_application/service/impl/BizAgentApplicationInfoServiceImpl.java
View file @
7380f1b0
...
@@ -213,8 +213,15 @@ public class BizAgentApplicationInfoServiceImpl extends BaseServiceImpl
...
@@ -213,8 +213,15 @@ public class BizAgentApplicationInfoServiceImpl extends BaseServiceImpl
if
(
entity
.
getTemperature
()
!=
null
)
{
if
(
entity
.
getTemperature
()
!=
null
)
{
Assert
.
isTrue
(
entity
.
getTemperature
()
>
0
&&
entity
.
getTemperature
()
<=
1.0
,
"temperature is error,must greater than 0, less than or equal to 1.9"
);
Assert
.
isTrue
(
entity
.
getTemperature
()
>
0
&&
entity
.
getTemperature
()
<=
1.0
,
"temperature is error,must greater than 0, less than or equal to 1.9"
);
}
}
model
.
setIsDocumentParsing
(
entity
.
getIsDocumentParsing
());
if
(
entity
.
getVoiceConfig
()
!=
null
)
{
model
.
setIsLongMemory
(
entity
.
getIsLongMemory
());
model
.
setVoiceConfig
(
JsonUtils
.
serialize
(
entity
.
getVoiceConfig
()));
}
if
(
StringUtils
.
isNotBlank
(
entity
.
getIsDocumentParsing
()))
{
model
.
setIsDocumentParsing
(
entity
.
getIsDocumentParsing
());
}
if
(
StringUtils
.
isNotBlank
(
entity
.
getIsLongMemory
()))
{
model
.
setIsLongMemory
(
entity
.
getIsLongMemory
());
}
model
.
setTemperature
(
entity
.
getTemperature
());
model
.
setTemperature
(
entity
.
getTemperature
());
model
.
setTopP
(
entity
.
getTopP
());
model
.
setTopP
(
entity
.
getTopP
());
model
.
setContinuousQuestionStatus
(
entity
.
getContinuousQuestionStatus
());
model
.
setContinuousQuestionStatus
(
entity
.
getContinuousQuestionStatus
());
...
...
src/main/java/cn/com/poc/agent_application/service/impl/BizAgentApplicationPublishServiceImpl.java
View file @
7380f1b0
...
@@ -14,8 +14,6 @@ import cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity;
...
@@ -14,8 +14,6 @@ import cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity;
import
cn.com.poc.agent_application.convert.BizAgentApplicationPublishConvert
;
import
cn.com.poc.agent_application.convert.BizAgentApplicationPublishConvert
;
import
cn.com.poc.agent_application.repository.BizAgentApplicationPublishRepository
;
import
cn.com.poc.agent_application.repository.BizAgentApplicationPublishRepository
;
import
cn.com.yict.framemax.data.model.PagingInfo
;
import
cn.com.yict.framemax.data.model.PagingInfo
;
import
cn.hutool.core.bean.BeanUtil
;
import
org.apache.commons.beanutils.BeanUtils
;
import
org.apache.commons.lang3.ArrayUtils
;
import
org.apache.commons.lang3.ArrayUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
...
@@ -52,7 +50,7 @@ public class BizAgentApplicationPublishServiceImpl extends BaseServiceImpl
...
@@ -52,7 +50,7 @@ public class BizAgentApplicationPublishServiceImpl extends BaseServiceImpl
}
}
@Override
@Override
public
BizAgentApplicationPublishEntity
getByAgentId
(
String
agentId
)
throws
Exception
{
public
BizAgentApplicationPublishEntity
getByAgentId
(
String
agentId
)
{
Assert
.
notNull
(
agentId
);
Assert
.
notNull
(
agentId
);
BizAgentApplicationPublishModel
model
=
new
BizAgentApplicationPublishModel
();
BizAgentApplicationPublishModel
model
=
new
BizAgentApplicationPublishModel
();
model
.
setAgentId
(
agentId
);
model
.
setAgentId
(
agentId
);
...
...
src/main/java/cn/com/poc/expose/aggregate/AgentApplicationService.java
View file @
7380f1b0
...
@@ -2,6 +2,7 @@ package cn.com.poc.expose.aggregate;
...
@@ -2,6 +2,7 @@ package cn.com.poc.expose.aggregate;
import
cn.com.poc.agent_application.query.MemberCollectQueryItem
;
import
cn.com.poc.agent_application.query.MemberCollectQueryItem
;
import
cn.com.yict.framemax.data.model.PagingInfo
;
import
cn.com.yict.framemax.data.model.PagingInfo
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
javax.servlet.http.HttpServletResponse
;
import
javax.servlet.http.HttpServletResponse
;
import
java.util.List
;
import
java.util.List
;
...
@@ -46,4 +47,21 @@ public interface AgentApplicationService {
...
@@ -46,4 +47,21 @@ public interface AgentApplicationService {
*/
*/
List
<
MemberCollectQueryItem
>
getCollectedApplications
(
Long
memberId
,
PagingInfo
pagingInfo
);
List
<
MemberCollectQueryItem
>
getCollectedApplications
(
Long
memberId
,
PagingInfo
pagingInfo
);
/**
* 获取用户在当前应用的自动播放配置
*
* @param memberId 用户ID
* @param agentId 应用ID
*/
String
autoPlayByAgentId
(
Long
memberId
,
String
agentId
);
/**
* 设置用户在当前应用的自动播放配置
*
* @param memberId 用户ID
* @param agentId 应用ID
* @param autoPlay 自动播放配置 Y/N
*/
String
enableAutoPlay
(
Long
memberId
,
String
agentId
,
String
autoPlay
);
}
}
src/main/java/cn/com/poc/expose/aggregate/impl/AgentApplicationServiceImpl.java
View file @
7380f1b0
...
@@ -6,6 +6,7 @@ import cn.com.poc.agent_application.constant.AgentApplicationGCConfigConstants;
...
@@ -6,6 +6,7 @@ import cn.com.poc.agent_application.constant.AgentApplicationGCConfigConstants;
import
cn.com.poc.agent_application.entity.BizAgentApplicationDialoguesRecordEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationDialoguesRecordEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationGcConfigEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationGcConfigEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity
;
import
cn.com.poc.agent_application.entity.VoiceConfig
;
import
cn.com.poc.agent_application.query.MemberCollectQueryCondition
;
import
cn.com.poc.agent_application.query.MemberCollectQueryCondition
;
import
cn.com.poc.agent_application.query.MemberCollectQueryItem
;
import
cn.com.poc.agent_application.query.MemberCollectQueryItem
;
import
cn.com.poc.agent_application.service.BizAgentApplicationDialoguesRecordService
;
import
cn.com.poc.agent_application.service.BizAgentApplicationDialoguesRecordService
;
...
@@ -62,6 +63,11 @@ public class AgentApplicationServiceImpl implements AgentApplicationService {
...
@@ -62,6 +63,11 @@ public class AgentApplicationServiceImpl implements AgentApplicationService {
*/
*/
final
private
String
MEMBER_RECOMMEND_QUESTIONS_LAST
=
AGENT_APPLICATION_RECOMMEND_QUESTIONS
+
"MEMBER_LAST:"
;
final
private
String
MEMBER_RECOMMEND_QUESTIONS_LAST
=
AGENT_APPLICATION_RECOMMEND_QUESTIONS
+
"MEMBER_LAST:"
;
/**
* 应用自动播放Key
*/
final
private
String
AGENT_APPLICATION_AUTO_PLAY
=
"AGENT_APPLICATION_AUTO_PLAY:"
;
@Resource
@Resource
private
BizMemberAgentApplicationCollectService
bizMemberAgentApplicationCollectService
;
private
BizMemberAgentApplicationCollectService
bizMemberAgentApplicationCollectService
;
...
@@ -266,6 +272,33 @@ public class AgentApplicationServiceImpl implements AgentApplicationService {
...
@@ -266,6 +272,33 @@ public class AgentApplicationServiceImpl implements AgentApplicationService {
return
memberCollectQueryItems
;
return
memberCollectQueryItems
;
}
}
@Override
public
String
autoPlayByAgentId
(
Long
memberId
,
String
agentId
)
{
String
result
=
CommonConstant
.
YOrN
.
N
;
String
redisKey
=
AGENT_APPLICATION_RECOMMEND_QUESTIONS
+
memberId
+
":"
+
agentId
;
if
(
redisService
.
hasKey
(
redisKey
))
{
result
=
(
String
)
redisService
.
get
(
redisKey
);
}
else
{
BizAgentApplicationPublishEntity
publishEntity
=
bizAgentApplicationPublishService
.
getByAgentId
(
agentId
);
if
(
publishEntity
==
null
)
{
throw
new
I18nMessageException
(
"exception/application.does.not.exist"
);
}
VoiceConfig
voiceConfig
=
publishEntity
.
getVoiceConfig
();
if
(
voiceConfig
!=
null
)
{
String
isAutoPlay
=
voiceConfig
.
getDefaultOpen
();
result
=
isAutoPlay
;
}
redisService
.
set
(
redisKey
,
result
,
30
*
60
*
60
*
24
);
}
return
result
;
}
@Override
public
String
enableAutoPlay
(
Long
memberId
,
String
agentId
,
String
autoPlay
)
{
String
redisKey
=
AGENT_APPLICATION_RECOMMEND_QUESTIONS
+
memberId
+
":"
+
agentId
;
redisService
.
set
(
redisKey
,
autoPlay
,
30
*
60
*
60
*
24
);
return
autoPlay
;
}
private
void
createCNQuestion
()
{
private
void
createCNQuestion
()
{
Message
message
=
new
Message
();
Message
message
=
new
Message
();
...
...
src/main/java/cn/com/poc/expose/rest/AgentApplicationRest.java
View file @
7380f1b0
...
@@ -86,4 +86,18 @@ public interface AgentApplicationRest extends BaseRest {
...
@@ -86,4 +86,18 @@ public interface AgentApplicationRest extends BaseRest {
*/
*/
List
<
DialoguesContextDto
>
getDialogueContext
(
@RequestParam
String
dialogueId
)
throws
Exception
;
List
<
DialoguesContextDto
>
getDialogueContext
(
@RequestParam
String
dialogueId
)
throws
Exception
;
/**
* 获取用户在当前应用的自动播放配置
*
* @param agentId 应用ID
*/
String
autoPlayByAgentId
(
@RequestParam
String
agentId
);
/**
* 设置用户在当前应用的自动播放配置
*
* @param agentId 应用ID
* @param autoPlay 自动播放配置 Y/N
*/
String
enableAutoPlay
(
@RequestParam
String
agentId
,
@RequestParam
String
autoPlay
);
}
}
src/main/java/cn/com/poc/expose/rest/impl/AgentApplicationRestImpl.java
View file @
7380f1b0
package
cn
.
com
.
poc
.
expose
.
rest
.
impl
;
package
cn
.
com
.
poc
.
expose
.
rest
.
impl
;
import
cn.com.poc.agent_application.aggregate.AgentApplicationInfoService
;
import
cn.com.poc.agent_application.aggregate.AgentApplicationInfoService
;
import
cn.com.poc.agent_application.aggregate.AgentApplicationMallService
;
import
cn.com.poc.agent_application.convert.AgentApplicationInfoConvert
;
import
cn.com.poc.agent_application.convert.AgentApplicationInfoConvert
;
import
cn.com.poc.agent_application.convert.BizAgentApplicationPublishConvert
;
import
cn.com.poc.agent_application.convert.BizAgentApplicationPublishConvert
;
import
cn.com.poc.agent_application.dto.AgentApplicationCreateContinueQuesDto
;
import
cn.com.poc.agent_application.dto.AgentApplicationCreateContinueQuesDto
;
...
@@ -232,4 +231,20 @@ public class AgentApplicationRestImpl implements AgentApplicationRest {
...
@@ -232,4 +231,20 @@ public class AgentApplicationRestImpl implements AgentApplicationRest {
}
}
return
null
;
return
null
;
}
}
@Override
public
String
autoPlayByAgentId
(
String
agentId
)
{
Assert
.
notBlank
(
agentId
);
UserBaseEntity
currentUser
=
BlContext
.
getCurrentUser
();
return
agentApplicationService
.
autoPlayByAgentId
(
currentUser
.
getUserId
(),
agentId
);
}
@Override
public
String
enableAutoPlay
(
String
agentId
,
String
autoPlay
)
{
Assert
.
notBlank
(
agentId
);
Assert
.
notBlank
(
autoPlay
);
Assert
.
isTrue
(
CommonConstant
.
YOrN
.
N
.
equals
(
autoPlay
)
||
CommonConstant
.
YOrN
.
Y
.
equals
(
autoPlay
));
UserBaseEntity
currentUser
=
BlContext
.
getCurrentUser
();
return
agentApplicationService
.
enableAutoPlay
(
currentUser
.
getUserId
(),
agentId
,
autoPlay
);
}
}
}
src/main/java/cn/com/poc/message/service/impl/AgentApplicationConsumerServiceImpl.java
View file @
7380f1b0
...
@@ -2,12 +2,10 @@ package cn.com.poc.message.service.impl;
...
@@ -2,12 +2,10 @@ package cn.com.poc.message.service.impl;
import
cn.com.poc.agent_application.aggregate.AgentApplicationMallService
;
import
cn.com.poc.agent_application.aggregate.AgentApplicationMallService
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity
;
import
cn.com.poc.agent_application.entity.BizAgentApplicationPublishEntity
;
import
cn.com.poc.agent_application.service.BizAgentApplicationDialoguesRecordService
;
import
cn.com.poc.agent_application.service.BizAgentApplicationPublishService
;
import
cn.com.poc.agent_application.service.BizAgentApplicationPublishService
;
import
cn.com.poc.message.entity.AgentApplicationClickEventMessage
;
import
cn.com.poc.message.entity.AgentApplicationClickEventMessage
;
import
cn.com.poc.message.service.AgentApplicationConsumerService
;
import
cn.com.poc.message.service.AgentApplicationConsumerService
;
import
cn.com.poc.message.topic.AgentApplicationTopic
;
import
cn.com.poc.message.topic.AgentApplicationTopic
;
import
cn.com.yict.framemax.core.service.BaseService
;
import
cn.com.yict.framemax.tumbleweed.client.annotation.Consumer
;
import
cn.com.yict.framemax.tumbleweed.client.annotation.Consumer
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
...
...
src/test/java/cn/com/poc/AgentApplicationInfoTest.java
View file @
7380f1b0
...
@@ -2,29 +2,31 @@ package cn.com.poc;
...
@@ -2,29 +2,31 @@ package cn.com.poc;
import
cn.com.poc.agent_application.aggregate.AgentApplicationInfoService
;
import
cn.com.poc.agent_application.aggregate.AgentApplicationInfoService
;
import
cn.com.poc.agent_application.entity.Variable
;
import
cn.com.poc.agent_application.utils.AgentApplicationTools
;
import
cn.com.poc.common.service.RedisService
;
import
cn.com.poc.common.service.RedisService
;
import
cn.com.poc.common.utils.BlContext
;
import
cn.com.poc.expose.aggregate.AgentApplicationService
;
import
cn.com.poc.expose.aggregate.AgentApplicationService
;
import
cn.com.poc.thirdparty.resource.demand.ai.aggregate.DemandKnowledgeService
;
import
cn.com.poc.thirdparty.resource.demand.ai.function.html_reader.HtmlReaderFunction
;
import
cn.com.poc.thirdparty.resource.demand.ai.function.long_memory.SetLongMemoryConstants
;
import
cn.com.poc.thirdparty.resource.demand.ai.function.memory_variable_writer.MemoryVariableWriter
;
import
cn.com.poc.thirdparty.resource.demand.ai.function.value_memory.GetValueMemory
;
import
cn.com.poc.thirdparty.resource.demand.ai.function.value_memory.SetValueMemoryConstants
;
import
cn.com.yict.framemax.core.spring.SingleContextInitializer
;
import
cn.com.yict.framemax.core.spring.SingleContextInitializer
;
import
cn.com.yict.framemax.security.oauth.support.UsernameOauthTokenAuthenticationToken
;
import
com.google.common.collect.Lists
;
import
com.google.common.collect.Lists
;
import
org.apache.commons.collections4.ListUtils
;
import
io.github.furstenheim.*
;
import
org.apache.commons.collections4.CollectionUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.junit.Test
;
import
org.junit.Test
;
import
org.junit.runner.RunWith
;
import
org.junit.runner.RunWith
;
import
org.springframework.security.core.context.SecurityContext
;
import
org.springframework.security.core.context.SecurityContextHolder
;
import
org.springframework.security.core.context.SecurityContextImpl
;
import
org.springframework.test.context.ContextConfiguration
;
import
org.springframework.test.context.ContextConfiguration
;
import
org.springframework.test.context.junit4.SpringJUnit4ClassRunner
;
import
org.springframework.test.context.junit4.SpringJUnit4ClassRunner
;
import
org.springframework.test.context.web.WebAppConfiguration
;
import
org.springframework.test.context.web.WebAppConfiguration
;
import
javax.annotation.Resource
;
import
javax.annotation.Resource
;
import
java.io.FileOutputStream
;
import
java.io.IOException
;
import
java.io.InputStream
;
import
java.io.InputStreamReader
;
import
java.net.URL
;
import
java.net.URLConnection
;
import
java.util.*
;
import
java.util.*
;
import
java.util.stream.Collectors
;
@RunWith
(
SpringJUnit4ClassRunner
.
class
)
@RunWith
(
SpringJUnit4ClassRunner
.
class
)
@ContextConfiguration
(
initializers
=
SingleContextInitializer
.
class
)
@ContextConfiguration
(
initializers
=
SingleContextInitializer
.
class
)
...
@@ -43,8 +45,48 @@ public class AgentApplicationInfoTest {
...
@@ -43,8 +45,48 @@ public class AgentApplicationInfoTest {
@Test
@Test
public
void
del
()
{
public
void
del
()
{
String
contentKey
=
SetValueMemoryConstants
.
REDIS_PREFIX
;
}
redisService
.
del
(
contentKey
);
@Test
public
void
html2MD
()
throws
IOException
{
// 创建资源符对象
URL
url
=
new
URL
(
"https://blog.csdn.net/jxlhljh/article/details/124506103"
);
// 创建连接
URLConnection
conn
=
url
.
openConnection
();
// 获取输入流
InputStream
inputStream
=
conn
.
getInputStream
();
// 缓冲区,读取输入流内容,64KB
char
[]
buffer
=
new
char
[
1024
*
64
];
int
len
;
StringBuilder
sb
=
new
StringBuilder
();
// 转换为字符流
InputStreamReader
isr
=
new
InputStreamReader
(
inputStream
);
// 循环读取
while
((
len
=
isr
.
read
(
buffer
))
!=
-
1
)
{
sb
.
append
(
buffer
,
0
,
len
);
}
// System.out.println(sb.toString());
// 关闭资源
inputStream
.
close
();
isr
.
close
();
String
htmlStr
=
sb
.
toString
();
OptionsBuilder
optionsBuilder
=
OptionsBuilder
.
anOptions
();
Options
options
=
optionsBuilder
.
withBr
(
"-"
)
.
withLinkStyle
(
LinkStyle
.
REFERENCED
)
.
withLinkReferenceStyle
(
LinkReferenceStyle
.
SHORTCUT
)
// more options
.
build
();
CopyDown
converter
=
new
CopyDown
(
options
);
String
markdownText
=
converter
.
convert
(
htmlStr
);
FileOutputStream
fileOutputStream
=
new
FileOutputStream
(
"D:\\test.md"
);
fileOutputStream
.
write
(
markdownText
.
getBytes
());
fileOutputStream
.
flush
();
fileOutputStream
.
close
();
// System.out.println(markdownText);
}
}
...
@@ -80,14 +122,83 @@ public class AgentApplicationInfoTest {
...
@@ -80,14 +122,83 @@ public class AgentApplicationInfoTest {
@Test
@Test
public
void
getValueMemory
()
{
public
void
getValueMemory
()
{
String
agentId
=
"d56d9a6a90ed435d831f84bc1af50547"
;
}
String
contentKey
=
SetValueMemoryConstants
.
REDIS_PREFIX
+
agentId
+
":"
+
"204"
;
System
.
out
.
println
(
redisService
.
hmget
(
contentKey
));
@Test
// Set<Object> keySet = result.keySet();
public
void
getFunctionConfig
()
{
// for (Object key : keySet) {
// Object value = result.get(key);
System
.
out
.
println
(
new
HtmlReaderFunction
().
getLLMConfig
());
// System.out.println("key:" + key + ",value:" + value);
}
// }
@Test
public
void
updateStructVariable
()
{
String
agentId
=
"1"
;
List
<
Variable
>
originals
=
null
;
List
<
Variable
>
transformed
=
null
;
String
identifier
=
AgentApplicationTools
.
identifier
(
agentId
,
agentId
);
if
(
CollectionUtils
.
isEmpty
(
transformed
))
{
// 清除所有字段
MemoryVariableWriter
.
clean
(
identifier
);
}
// 原【变量记忆】为空,则不需要处理
if
(
originals
==
null
)
{
return
;
}
// 1. 获取需要删除的字段集合
// 2. 获取需要更新值的字段集合
Set
<
String
>
delKeys
=
new
HashSet
<>();
Set
<
String
>
updateKeys
=
new
HashSet
<>();
for
(
Variable
variable
:
originals
)
{
String
key
=
variable
.
getKey
();
boolean
needDel
=
transformed
.
stream
().
noneMatch
(
v
->
v
.
getKey
().
equals
(
key
));
if
(
needDel
)
{
delKeys
.
add
(
key
);
}
boolean
needUpdate
=
transformed
.
stream
().
anyMatch
(
v
->
v
.
getKey
().
equals
(
key
));
if
(
needUpdate
)
{
Optional
<
Variable
>
target
=
transformed
.
stream
().
filter
(
v
->
v
.
getKey
().
equals
(
key
)).
findFirst
();
if
(
StringUtils
.
isBlank
(
target
.
get
().
getVariableDefault
()))
{
continue
;
}
Map
<
Object
,
Object
>
map
=
MemoryVariableWriter
.
get
(
identifier
);
String
value
=
map
.
get
(
key
).
toString
();
if
(
StringUtils
.
isBlank
(
value
))
{
updateKeys
.
add
(
key
);
}
}
}
// 3. 获取需要新增的字段集合
Set
<
String
>
addKeys
=
new
HashSet
<>();
for
(
Variable
variable
:
transformed
)
{
String
key
=
variable
.
getKey
();
boolean
needAdd
=
originals
.
stream
().
noneMatch
(
v
->
v
.
getKey
().
equals
(
key
));
if
(
needAdd
)
{
addKeys
.
add
(
key
);
}
}
// 删除
if
(!
delKeys
.
isEmpty
())
{
MemoryVariableWriter
.
delItem
(
identifier
,
delKeys
.
toArray
(
new
String
[
0
]));
}
if
(!
addKeys
.
isEmpty
())
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
for
(
String
key
:
addKeys
)
{
Variable
variable
=
transformed
.
stream
().
filter
(
v
->
v
.
getKey
().
equals
(
key
)).
findFirst
().
get
();
map
.
put
(
variable
.
getKey
(),
variable
.
getVariableDefault
());
}
MemoryVariableWriter
.
addItem
(
identifier
,
map
);
}
if
(!
updateKeys
.
isEmpty
())
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
for
(
String
key
:
updateKeys
)
{
Variable
variable
=
transformed
.
stream
().
filter
(
v
->
v
.
getKey
().
equals
(
key
)).
findFirst
().
get
();
map
.
put
(
variable
.
getKey
(),
variable
.
getVariableDefault
());
}
MemoryVariableWriter
.
addItem
(
identifier
,
map
);
}
}
}
}
}
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