Skip to content

Commit 371de3e

Browse files
authored
docs(qdrant): no longer needs to manually create Qdrant collection (#582)
1 parent b4c8d40 commit 371de3e

File tree

2 files changed

+3
-34
lines changed

2 files changed

+3
-34
lines changed

examples/image_search/README.md

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -14,28 +14,13 @@ We appreciate a star ⭐ at [CocoIndex Github](https://github.com/cocoindex-io/c
1414
- Qdrant for Vector Storage
1515
- FastApi for backend
1616

17-
1817
## Setup
1918
- Make sure Postgres and Qdrant are running
2019
```
2120
docker run -d -p 6334:6334 -p 6333:6333 qdrant/qdrant
2221
export COCOINDEX_DATABASE_URL="postgres://cocoindex:cocoindex@localhost/cocoindex"
2322
```
2423

25-
- Create Qdrant Collection
26-
```
27-
curl -X PUT 'http://localhost:6333/collections/image_search' \
28-
-H 'Content-Type: application/json' \
29-
-d '{
30-
"vectors": {
31-
"embedding": {
32-
"size": 768,
33-
"distance": "Cosine"
34-
}
35-
}
36-
}'
37-
```
38-
3924
## Run
4025
- Install dependencies:
4126
```

examples/text_embedding_qdrant/README.md

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ We appreciate a star ⭐ at [CocoIndex Github](https://github.com/cocoindex-io/c
1919
### Query
2020
We use Qdrant client to query the index, and reuse the embedding operation in the indexing flow.
2121

22-
2322
## Pre-requisites
2423

2524
- [Install Postgres](https://cocoindex.io/docs/getting_started/installation#-install-postgres) if you don't have one. Although the target store is Qdrant, CocoIndex uses Postgress to track the data lineage for incremental processing.
@@ -30,24 +29,6 @@ We use Qdrant client to query the index, and reuse the embedding operation in th
3029
docker run -d -p 6334:6334 -p 6333:6333 qdrant/qdrant
3130
```
3231

33-
- [Create a collection](https://qdrant.tech/documentation/concepts/vectors/#named-vectors) to export the embeddings to.
34-
35-
```bash
36-
curl -X PUT \
37-
'http://localhost:6333/collections/cocoindex' \
38-
--header 'Content-Type: application/json' \
39-
--data-raw '{
40-
"vectors": {
41-
"text_embedding": {
42-
"size": 384,
43-
"distance": "Cosine"
44-
}
45-
}
46-
}'
47-
```
48-
49-
You can view the collections and data with the Qdrant dashboard at <http://localhost:6333/dashboard>.
50-
5132
## Run
5233

5334
- Install dependencies:
@@ -62,6 +43,9 @@ We use Qdrant client to query the index, and reuse the embedding operation in th
6243
cocoindex setup main.py
6344
```
6445

46+
It will automatically create a collection in Qdrant.
47+
You can view the collections and data with the Qdrant dashboard at <http://localhost:6333/dashboard>.
48+
6549
- Update index:
6650

6751
```bash

0 commit comments

Comments
 (0)