Set up pgvector for Monitoring

pgvector is an open-source extension for PostgreSQL that enables efficient storage and similarity search of high-dimensional vectors. It allows PostgreSQL to handle vector embeddings, making it ideal for machine learning applications such as recommendation systems, natural language processing, and computer vision. pgvector supports vector data types and similarity metrics, such as cosine, L2, and inner product.

Prerequisites

Ensure that:
  • The pg_stat_statements module is loaded and installed. The module must be loaded by adding pg_stat_statements to shared_preload_libraries in postgresql.conf, because it requires additional shared memory.
  • The vector extension is installed.
  • PostgreSQL >= 14

Enable PostgreSQL Vector Metrics

Use the following properties to enable vector metrics while launching the Database Agent:
Property Description
dbagent.postgres.vector.extension.metrics.enabled Enables the PostgreSQL vector metrics.
dbagent.postgres.vector.tables Specify the vector tables (comma separated) that you want to monitor.