Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
dify
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ai-tech
dify
Commits
b5953039
Unverified
Commit
b5953039
authored
Aug 29, 2023
by
Jyong
Committed by
GitHub
Aug 29, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
recreate qdrant vector (#1049)
Co-authored-by:
jyong
<
jyong@dify.ai
>
parent
a43e80dd
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
49 additions
and
47 deletions
+49
-47
commands.py
api/commands.py
+49
-47
No files found.
api/commands.py
View file @
b5953039
...
...
@@ -318,6 +318,8 @@ def create_qdrant_indexes():
page
+=
1
for
dataset
in
datasets
:
if
dataset
.
index_struct_dict
:
if
dataset
.
index_struct_dict
[
'type'
]
!=
'qdrant'
:
try
:
click
.
echo
(
'Create dataset qdrant index: {}'
.
format
(
dataset
.
id
))
try
:
...
...
@@ -351,13 +353,13 @@ def create_qdrant_indexes():
embeddings
=
embeddings
)
if
index
:
index
.
create_qdrant_dataset
(
dataset
)
index_struct
=
{
"type"
:
'qdrant'
,
"vector_store"
:
{
"class_prefix"
:
dataset
.
index_struct_dict
[
'vector_store'
][
'class_prefix'
]}
}
dataset
.
index_struct
=
json
.
dumps
(
index_struct
)
db
.
session
.
commit
()
index
.
create_qdrant_dataset
(
dataset
)
create_count
+=
1
else
:
click
.
echo
(
'passed.'
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment