Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
poc-fe
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-fe
Commits
3e5e4c1a
Commit
3e5e4c1a
authored
Dec 04, 2024
by
nick zheng
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'beta' into 'master'
fix: 已发送的提问再添加音色不显示音频加载&AI自动配置失败后停止其他生成 See merge request
!103
parents
de8310fd
42029a86
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
14 deletions
+15
-14
footer-input.vue
...ts/agent-config/agent-preview/components/footer-input.vue
+5
-5
message-item.vue
...ts/agent-config/agent-preview/components/message-item.vue
+1
-5
agent-setting.vue
...g/components/agent-config/agent-setting/agent-setting.vue
+8
-4
conversation.d.ts
types/conversation.d.ts
+1
-0
No files found.
src/views/personal-space/personal-app-setting/components/agent-config/agent-preview/components/footer-input.vue
View file @
3e5e4c1a
...
@@ -86,10 +86,6 @@ const isUploadFileDisabled = computed(() => {
...
@@ -86,10 +86,6 @@ const isUploadFileDisabled = computed(() => {
return
uploadFileList
.
value
.
length
===
1
return
uploadFileList
.
value
.
length
===
1
})
})
const
isEnableVoice
=
computed
(()
=>
{
return
!!
personalAppConfigStore
.
voiceConfig
.
timbreId
})
const
uploadFileIcon
=
(
type
:
string
)
=>
{
const
uploadFileIcon
=
(
type
:
string
)
=>
{
return
`https://gsst-poe-sit.gz.bcebos.com/icon/
${
type
}
.svg`
return
`https://gsst-poe-sit.gz.bcebos.com/icon/
${
type
}
.svg`
}
}
...
@@ -124,6 +120,7 @@ function messageItemFactory(): ConversationMessageItem {
...
@@ -124,6 +120,7 @@ function messageItemFactory(): ConversationMessageItem {
isVoiceLoading
:
false
,
isVoiceLoading
:
false
,
isVoicePlaying
:
false
,
isVoicePlaying
:
false
,
voiceFragmentUrlList
:
[],
voiceFragmentUrlList
:
[],
isVoiceEnabled
:
false
,
}
}
}
}
...
@@ -188,12 +185,15 @@ function handleMessageSend() {
...
@@ -188,12 +185,15 @@ function handleMessageSend() {
sentenceSpeechException
.
value
=
false
sentenceSpeechException
.
value
=
false
messageAudioLoading
.
value
=
false
messageAudioLoading
.
value
=
false
const
isVoiceEnabled
=
!!
personalAppConfigStore
.
voiceConfig
.
timbreId
emit
(
'addMessageItem'
,
latestAssistantMessageKey
,
{
emit
(
'addMessageItem'
,
latestAssistantMessageKey
,
{
...
messageItemFactory
(),
...
messageItemFactory
(),
role
:
'assistant'
,
role
:
'assistant'
,
isTextContentLoading
:
true
,
isTextContentLoading
:
true
,
isAnswerResponseLoading
:
true
,
isAnswerResponseLoading
:
true
,
isVoiceLoading
:
true
,
isVoiceLoading
:
true
,
isVoiceEnabled
,
})
})
emit
(
'updatePageScroll'
)
emit
(
'updatePageScroll'
)
...
@@ -231,7 +231,7 @@ function handleMessageSend() {
...
@@ -231,7 +231,7 @@ function handleMessageSend() {
''
,
''
,
)
)
if
(
!
sentenceExtractCheckEnabled
.
value
&&
is
EnableVoice
.
value
)
{
if
(
!
sentenceExtractCheckEnabled
.
value
&&
is
VoiceEnabled
)
{
sentenceExtract
(
latestAssistantMessageKey
)
sentenceExtract
(
latestAssistantMessageKey
)
sentenceExtractCheckEnabled
.
value
=
true
sentenceExtractCheckEnabled
.
value
=
true
messageAudioLoading
.
value
=
true
messageAudioLoading
.
value
=
true
...
...
src/views/personal-space/personal-app-setting/components/agent-config/agent-preview/components/message-item.vue
View file @
3e5e4c1a
...
@@ -31,10 +31,6 @@ const assistantAvatar = computed(() => {
...
@@ -31,10 +31,6 @@ const assistantAvatar = computed(() => {
return
personalAppConfigStore
.
baseInfo
.
agentAvatar
return
personalAppConfigStore
.
baseInfo
.
agentAvatar
})
})
const
timbreEnabled
=
computed
(()
=>
{
return
!!
personalAppConfigStore
.
voiceConfig
.
timbreId
})
const
isShowAudioControl
=
computed
(()
=>
{
const
isShowAudioControl
=
computed
(()
=>
{
return
props
.
role
===
'assistant'
&&
!
props
.
messageItem
.
isVoiceLoading
return
props
.
role
===
'assistant'
&&
!
props
.
messageItem
.
isVoiceLoading
})
})
...
@@ -44,7 +40,7 @@ const isPlayableAudio = computed(() => {
...
@@ -44,7 +40,7 @@ const isPlayableAudio = computed(() => {
})
})
const
isShowVoiceLoading
=
computed
(()
=>
{
const
isShowVoiceLoading
=
computed
(()
=>
{
return
props
.
role
===
'assistant'
&&
props
.
messageItem
.
isVoiceLoading
&&
timbreEnabled
.
value
return
props
.
role
===
'assistant'
&&
props
.
messageItem
.
isVoiceLoading
&&
props
.
messageItem
.
isVoiceEnabled
})
})
function
handleAudioControl
()
{
function
handleAudioControl
()
{
...
...
src/views/personal-space/personal-app-setting/components/agent-config/agent-setting/agent-setting.vue
View file @
3e5e4c1a
...
@@ -251,10 +251,14 @@ async function handleSettingAgent(autoConfigInputValue: string) {
...
@@ -251,10 +251,14 @@ async function handleSettingAgent(autoConfigInputValue: string) {
handleAIGeneratePreamble
(),
handleAIGeneratePreamble
(),
handleAIGenerateFeaturedQuestions
(),
handleAIGenerateFeaturedQuestions
(),
handleAIGenerateAgentSystem
(),
handleAIGenerateAgentSystem
(),
]).
finally
(()
=>
{
])
isFullScreenLoading
.
value
=
false
.
finally
(()
=>
{
emitter
?.
emit
(
'resetAgent'
)
isFullScreenLoading
.
value
=
false
})
emitter
?.
emit
(
'resetAgent'
)
})
.
catch
(()
=>
{
handleStopGenerate
()
})
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
isFullScreenLoading
.
value
=
false
isFullScreenLoading
.
value
=
false
...
...
types/conversation.d.ts
View file @
3e5e4c1a
...
@@ -8,4 +8,5 @@ declare interface ConversationMessageItem {
...
@@ -8,4 +8,5 @@ declare interface ConversationMessageItem {
isVoiceLoading
:
boolean
isVoiceLoading
:
boolean
isVoicePlaying
:
boolean
isVoicePlaying
:
boolean
voiceFragmentUrlList
:
string
[]
voiceFragmentUrlList
:
string
[]
isVoiceEnabled
?:
boolean
}
}
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