diff --git a/appbuilder/core/components/retriever/baidu_vdb/README.md b/appbuilder/core/components/retriever/baidu_vdb/README.md index f7a1c8b94..013c48a40 100644 --- a/appbuilder/core/components/retriever/baidu_vdb/README.md +++ b/appbuilder/core/components/retriever/baidu_vdb/README.md @@ -19,6 +19,10 @@ 以下是有关如何开始使用BaiduVDBRetriever的代码示例: +补充说明: +- `you_vdb_instance_id` 为VectorDB 实例ID,请替换为您的实例ID,在VectorDB控制台界面上可以查看 +- `your_api_key` 为您在VectorDB上申请的账户密钥,请替换为您自己的root账户密钥,在VectorDB控制台界面上可以查看 + ```python import os import appbuilder diff --git a/appbuilder/core/components/retriever/baidu_vdb/baiduvdb_retriever.py b/appbuilder/core/components/retriever/baidu_vdb/baiduvdb_retriever.py index 25015607f..39c945db6 100644 --- a/appbuilder/core/components/retriever/baidu_vdb/baiduvdb_retriever.py +++ b/appbuilder/core/components/retriever/baidu_vdb/baiduvdb_retriever.py @@ -197,7 +197,10 @@ def _create_table_in_db( fields.append(Field(FIELD_TEXT, FieldType.STRING)) fields.append( Field( - FIELD_VECTOR, FieldType.FLOAT_VECTOR, dimension=table_params.dimension + FIELD_VECTOR, + FieldType.FLOAT_VECTOR, + dimension=table_params.dimension, + not_null=True, ) )