fix: 答案不再包括思考过程;思考气泡和消息气泡不同时显示

This commit is contained in:
sophie committed 2026-04-17 10:58:09 +08:00
1 parent b0fda9f081
commit 9313ff769d
9 files changed
+74 -34

No files matched your search

+2 -2
View File
@@ -53,7 +53,7 @@ class DevelopmentConfig(Config):
DEBUG = True
SQLALCHEMY_DATABASE_URI = os.getenv(
'DATABASE_URL',
'postgresql://postgres:difyai123456@localhost:5432/hxops_db',
'postgresql://postgres:123456@8.152.207.171:5432/hxops_db',
)
@@ -61,7 +61,7 @@ class ProductionConfig(Config):
DEBUG = False
SQLALCHEMY_DATABASE_URI = os.getenv(
'DATABASE_URL',
'postgresql://postgres:difyai123456@localhost:5432/hxops_prod',
'postgresql://postgres:123456@8.152.207.171:5432/hxops_prod',
)
+3 -1
View File
@@ -129,7 +129,9 @@ class DifyService:
DifyService._collect_metadata(retriever_resources, attribution_parts, data)
elif event in ('message_end', 'agent_message', 'workflow_finished'):
if data.get('answer'):
# Keep metadata from non-message events, but avoid appending
# intermediate workflow/agent outputs into final user answer.
if event == 'message_end' and data.get('answer'):
full_answer.append(data.get('answer', ''))
DifyService._collect_metadata(retriever_resources, attribution_parts, data)