mirror of
https://github.com/pgvector/pgvector.git
synced 2026-06-06 05:51:21 +08:00
Moved scaling section [skip ci]
This commit is contained in:
22
README.md
22
README.md
@@ -744,6 +744,17 @@ REINDEX INDEX CONCURRENTLY index_name;
|
||||
VACUUM table_name;
|
||||
```
|
||||
|
||||
## Scaling
|
||||
|
||||
Scale vertically by increasing memory, CPU, and storage on a single instance. Use existing tools to [tune parameters](#tuning) and [monitor performance](#monitoring).
|
||||
|
||||
For a smaller working set:
|
||||
|
||||
1. Use the `halfvec` type instead of `vector` for tables
|
||||
2. Use [binary quantization](#binary-quantization) for indexes (with re-ranking for search)
|
||||
|
||||
Scale horizontally with [replicas](https://www.postgresql.org/docs/current/hot-standby.html), or use [Citus](https://github.com/citusdata/citus) or another approach for sharding ([example](https://github.com/pgvector/pgvector-python/blob/master/examples/citus/example.py)).
|
||||
|
||||
## Monitoring
|
||||
|
||||
Monitor performance with [pg_stat_statements](https://www.postgresql.org/docs/current/pgstatstatements.html) (be sure to add it to `shared_preload_libraries`).
|
||||
@@ -769,17 +780,6 @@ SELECT ...
|
||||
COMMIT;
|
||||
```
|
||||
|
||||
## Scaling
|
||||
|
||||
Scale vertically by increasing memory, CPU, and storage on a single instance. Use existing tools to [tune parameters](#tuning) and [monitor performance](#monitoring).
|
||||
|
||||
For a smaller working set:
|
||||
|
||||
1. Use the `halfvec` type instead of `vector` for tables
|
||||
2. Use [binary quantization](#binary-quantization) for indexes (with re-ranking for search)
|
||||
|
||||
Scale horizontally with [replicas](https://www.postgresql.org/docs/current/hot-standby.html), or use [Citus](https://github.com/citusdata/citus) or another approach for sharding ([example](https://github.com/pgvector/pgvector-python/blob/master/examples/citus/example.py)).
|
||||
|
||||
## Languages
|
||||
|
||||
Use pgvector from any language with a Postgres client. You can even generate and store vectors in one language and query them in another.
|
||||
|
||||
Reference in New Issue
Block a user