You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/vectorchord/getting-started/overview.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,7 +37,7 @@ docker run \
37
37
--name vectorchord-demo \
38
38
-e POSTGRES_PASSWORD=mysecretpassword \
39
39
-p 5432:5432 \
40
-
-d tensorchord/vchord-postgres:pg18-v1.0.0
40
+
-d tensorchord/vchord-postgres:pg18-v1.1.0
41
41
```
42
42
> In addition to the base image with the VectorChord extension, we provide an all-in-one image, `tensorchord/vchord-suite:pg18-latest`. This comprehensive image includes all official TensorChord extensions. Developers should select an image tag that is compatible with their extension's version, as indicated in [the support matrix](https://github.com/tensorchord/VectorChord-images?tab=readme-ov-file#support-matrix).
Search parameters are typically configured via GUCs. VectorChord also offers an alternative method, allowing these parameters to be attached directly to an index instead of a session or transaction. In other words, you can store them as part of the index's storage parameters.
4
+
5
+
You could set `probes` at index building using the following syntax.
6
+
7
+
```sql
8
+
CREATEINDEXitems_embedding_idxON items USING vchordrq (embedding vector_l2_ops) WITH (options = $$
9
+
build.internal.lists = [1000]
10
+
$$, probes ='10');
11
+
```
12
+
13
+
You can now perform searches without setting GUCs:
14
+
15
+
```sql
16
+
--- probes = '10'
17
+
SELECT*FROM items ORDER BY embedding <->'[3,1,2]'LIMIT5;
18
+
```
19
+
20
+
If the index is already built, you can set `probes` like this:
21
+
22
+
```sql
23
+
ALTERINDEX items_embedding_idx SET (probes ='100');
24
+
```
25
+
26
+
You can still set GUCs for search parameters. When you do so, the GUCs take precedence over the index storage parameters. This allows you to temporarily override these settings for the current session or transaction without locking the index.
27
+
28
+
```sql
29
+
SETvchordrq.probes TO '100';
30
+
--- probes = '100'
31
+
SELECT*FROM items ORDER BY embedding <->'[3,1,2]'LIMIT5;
32
+
```
33
+
34
+
This syntax is useful in the following situations:
35
+
36
+
* When there are multiple indexes.
37
+
* When you prefer not to set GUCs.
38
+
* When you want to configure search parameters offline.
39
+
40
+
As long as GUCs are set, even at the system level or database level, they will override the index settings. So, to avoid hard-to-detect issues, we recommend using only one method to set search parameters, either via GUCs or via index storage parameters.
41
+
42
+
Not all parameters support this feature. See [Reference](#reference) for all supported parameters.
43
+
44
+
## Reference {#reference}
45
+
46
+
### Index Storage Parameters <badgetype="info"text="vchordrq" />
Copy file name to clipboardExpand all lines: src/vectorchord/usage/graph-index.md
+13-5Lines changed: 13 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -56,12 +56,18 @@ The following table lists all available operator classes supported by `vchordg`.
56
56
|`halfvec_l2_ops`| index works for `halfvec` type and Euclidean distance |`<->(halfvec,halfvec)`|`<<->>(halfvec,halfvec)`|
57
57
|`halfvec_ip_ops`| index works for `halfvec` type and negative inner product |`<#>(halfvec,halfvec)`|`<<#>>(halfvec,halfvec)`|
58
58
|`halfvec_cosine_ops`| index works for `halfvec` type and cosine distance |`<=>(halfvec,halfvec)`|`<<=>>(halfvec,halfvec)`|
59
+
|`rabitq8_l2_ops`| index works for `rabitq8` type and Euclidean distance |`<->(rabitq8,rabitq8)`|`<<->>(rabitq8,rabitq8)`|
60
+
|`rabitq8_ip_ops`| index works for `rabitq8` type and negative inner product |`<#>(rabitq8,rabitq8)`|`<<#>>(rabitq8,rabitq8)`|
61
+
|`rabitq8_cosine_ops`| index works for `rabitq8` type and cosine distance |`<=>(rabitq8,rabitq8)`|`<<=>>(rabitq8,rabitq8)`|
62
+
|`rabitq4_l2_ops`| index works for `rabitq4` type and Euclidean distance |`<->(rabitq4,rabitq4)`|`<<->>(rabitq4,rabitq4)`|
63
+
|`rabitq4_ip_ops`| index works for `rabitq4` type and negative inner product |`<#>(rabitq4,rabitq4)`|`<<#>>(rabitq4,rabitq4)`|
64
+
|`rabitq4_cosine_ops`| index works for `rabitq4` type and cosine distance |`<=>(rabitq4,rabitq4)`|`<<=>>(rabitq4,rabitq4)`|
59
65
60
-
`<<->>`, `<<#>>`, `<<=>>` are operators defined by VectorChord.
66
+
`<<->>`, `<<#>>`, `<<=>>` are operators defined by VectorChord. For more information about `<<->>`, `<<#>>`, `<<=>>`, refer to [Similarity Filter](range-query).
61
67
62
-
For more information about `<<->>`, `<<#>>`, `<<=>>`, refer to [Similarity Filter](range-query).
68
+
`rabitq8`, `rabitq4` are types defined by VectorChord. For more information about `rabitq8`, `rabitq4`, refer to [Quantization Types](quantization-types).
63
69
64
-
All operator classes are available since version `0.3.0`.
70
+
The first 6 operator classes are available since version `0.5.0`, and the last 6 operator classes are available since version `1.1.0`.
- Description: The size of the dynamic list containing the nearest neighbors in search. The larger `vchordg.ef_search` is, the better the recall, but the worse the QPS. `vchordg.ef_search` corresponds to $\text{ef}$ in HNSW and DiskANN.
128
134
- Type: integer
129
-
- Default: `64`
135
+
- Default:
136
+
-`64`
137
+
- This parameter supports [fallback](fallback-parameters).
130
138
- Domain: `[1, 65535]`
131
139
- Example:
132
140
-`SET vchordg.ef_search = 64` indicates the size of the dynamic list containing the nearest neighbors is $64$ during search.
0 commit comments