Skip to content

Commit

Permalink
fix: 修复工作流中,函数库使用知识库检索参数错误
Browse files Browse the repository at this point in the history
  • Loading branch information
shaohuzhang1 committed Sep 12, 2024
1 parent 2429149 commit 47d36fe
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,12 @@ def reset_paragraph(paragraph: Dict, embedding_list: List):
**paragraph,
'similarity': find_embedding.get('similarity'),
'is_hit_handling_method': find_embedding.get('similarity') > paragraph.get(
'directly_return_similarity') and paragraph.get('hit_handling_method') == 'directly_return'
'directly_return_similarity') and paragraph.get('hit_handling_method') == 'directly_return',
'update_time': paragraph.get('update_time').strftime("%Y-%m-%d %H:%M:%S"),
'create_time': paragraph.get('create_time').strftime("%Y-%m-%d %H:%M:%S"),
'id': str(paragraph.get('id')),
'dataset_id': str(paragraph.get('dataset_id')),
'document_id': str(paragraph.get('document_id'))
}

@staticmethod
Expand Down
2 changes: 2 additions & 0 deletions apps/common/constants/authentication_type.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ class AuthenticationType(Enum):
APPLICATION_ACCESS_TOKEN = "APPLICATION_ACCESS_TOKEN"
# key API
API_KEY = "API_KEY"
# 第三方对接
PLATFORM = 'PLATFORM'

0 comments on commit 47d36fe

Please sign in to comment.