From c5a3146a8cb5909c2f0b3d4fa9c37a12c4ca0bcd Mon Sep 17 00:00:00 2001 From: knew Date: Tue, 29 Oct 2024 11:06:02 +0800 Subject: [PATCH] fix: modify the response of metadata in Dify retrieval api (#3076) ### What problem does this PR solve? Modify the response of metadata in Dify retrieval api resolve #2914 ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) --- api/apps/sdk/dify_retrieval.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/apps/sdk/dify_retrieval.py b/api/apps/sdk/dify_retrieval.py index ac839d30..ddb7fdf7 100644 --- a/api/apps/sdk/dify_retrieval.py +++ b/api/apps/sdk/dify_retrieval.py @@ -64,7 +64,7 @@ def retrieval(tenant_id): "content": c["content_ltks"], "score": c["similarity"], "title": c["docnm_kwd"], - "metadata": "" + "metadata": {} }) return jsonify({"records": records})