Skip to content

Commit

Permalink
finish cookbook
Browse files Browse the repository at this point in the history
  • Loading branch information
MrChengmo committed Mar 19, 2024
1 parent 5c70b2b commit 78a9f1c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
4 changes: 4 additions & 0 deletions appbuilder/core/components/retriever/baidu_vdb/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@

以下是有关如何开始使用BaiduVDBRetriever的代码示例:

补充说明:
- `you_vdb_instance_id` 为VectorDB 实例ID,请替换为您的实例ID,在VectorDB控制台界面上可以查看
- `your_api_key` 为您在VectorDB上申请的账户密钥,请替换为您自己的root账户密钥,在VectorDB控制台界面上可以查看

```python
import os
import appbuilder
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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,
)
)

Expand Down

0 comments on commit 78a9f1c

Please sign in to comment.