Las métricas de usabilidad incluyen métricas que te ayudan a comprender el estado de la utilización del índice, como la configuración del índice y la cantidad de análisis del índice.
Nombre de la métrica
Tipo de datos
Descripción
relid
OID
Identificador único de la tabla que contiene el índice de vectores
indexrelid
OID
Identificador único del índice de vectores
schemaname
NAME
Nombre del esquema propietario del índice
relname
NAME
Nombre de la tabla que contiene el índice
indexrelname
NAME
Nombre del índice
indextype
NAME
Es el tipo de índice. Este valor siempre se establece en alloydb_scann.
indexconfig
TEXT[]
Es la configuración, como el recuento de hojas y el cuantificador, que se definió para el índice cuando se creó.
indexsize
TEXT
Tamaño del índice
indexscan
BIGINT
Cantidad de análisis de índice iniciados en el índice
partitioncount
BIGINT
Es la cantidad de particiones (nodos hoja) en el árbol.
Métricas de ajuste
Las métricas de ajuste proporcionan estadísticas sobre la optimización actual del índice, lo que te permite aplicar recomendaciones para mejorar el rendimiento de las consultas.
Nombre de la métrica
Tipo de datos
Descripción
insertcount
BIGINT
Cantidad de operaciones de inserción en el índice. Esta métrica también incluye la cantidad de filas que existían antes de que se creara el índice.
updatecount
BIGINT
Cantidad de operaciones de actualización en el índice. Esta métrica no tiene en cuenta las actualizaciones de HOT.
deletecount
BIGINT
Cantidad de operaciones de eliminación en el índice.
distribution
JSONB
Son las distribuciones de vectores en todas las particiones del índice.
En los siguientes campos, se muestra la distribución:
maximum (INT8): Es la cantidad máxima de vectores en todas las particiones.
minimum (INT8): Es la cantidad mínima de vectores en todas las particiones.
average (FLOAT) : Es la cantidad promedio de vectores en todas las particiones.
outliers (INT8[]): Son los valores atípicos principales en todas las particiones. Este valor muestra los 20 valores atípicos principales.
Nota: Debido a las características inherentes del algoritmo de agrupamiento K-means, siempre habrá cierto grado de varianza en la distribución de los vectores en las particiones, incluso cuando se cree el índice inicialmente.
Ajuste de la recomendación según las métricas
Mutación
Las métricas insertcount, updatecount y deletecount juntas muestran los cambios o las mutaciones en el vector del índice.
El índice se crea con una cantidad específica de vectores y particiones. Cuando se realizan operaciones como insertar, actualizar o borrar en el índice de vectores, solo se ven afectadas las particiones iniciales en las que residen los vectores. Por lo tanto, la cantidad de vectores en cada partición fluctúa con el tiempo, lo que puede afectar la recuperación, las QPS o ambas.
Si, con el tiempo, tienes problemas de lentitud o precisión, como un QPS bajo o una recuperación deficiente, en tus búsquedas de ANN, considera revisar estas métricas. Una gran cantidad de mutaciones en relación con la cantidad total de vectores podría indicar la necesidad de volver a indexar.
Distribución
La métrica distribution muestra las distribuciones de vectores en todas las particiones.
Cuando creas un índice, este se crea con una cantidad específica de vectores y particiones fijas. El proceso de partición y la distribución posterior se realizan en función de esta consideración. Si se agregan vectores adicionales, se particionan entre las particiones existentes, lo que genera una distribución diferente en comparación con la distribución cuando se creó el índice. Dado que la distribución final no considera todos los vectores de forma simultánea, es posible que se vean afectados el recall, las QPS o ambos.
Si observas una disminución gradual en el rendimiento de tus búsquedas de ANN, como tiempos de respuesta más lentos o una menor precisión en los resultados (medida por QPS o recuperación), considera revisar esta métrica y volver a indexar.
[[["Fácil de comprender","easyToUnderstand","thumb-up"],["Resolvió mi problema","solvedMyProblem","thumb-up"],["Otro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Información o código de muestra incorrectos","incorrectInformationOrSampleCode","thumb-down"],["Faltan la información o los ejemplos que necesito","missingTheInformationSamplesINeed","thumb-down"],["Problema de traducción","translationIssue","thumb-down"],["Otro","otherDown","thumb-down"]],["Última actualización: 2025-09-05 (UTC)"],[],[],null,["# Vector index metrics\n\nSelect a documentation version: 16.8.0keyboard_arrow_down\n\n- [Current (16.8.0)](/alloydb/omni/current/docs/reference/vector-index-metrics)\n- [16.8.0](/alloydb/omni/16.8.0/docs/reference/vector-index-metrics)\n- [16.3.0](/alloydb/omni/16.3.0/docs/reference/vector-index-metrics)\n- [15.12.0](/alloydb/omni/15.12.0/docs/reference/vector-index-metrics)\n- [15.7.1](/alloydb/omni/15.7.1/docs/reference/vector-index-metrics)\n- [15.7.0](/alloydb/omni/15.7.0/docs/reference/vector-index-metrics)\n\n\u003cbr /\u003e\n\nThis page lists the metrics related to the vector indexes that you generate in AlloyDB Omni. You can view these metrics using the `pg_stat_ann_indexes` view that is available when you install [the `alloydb_scann` extension](/alloydb/omni/16.8.0/docs/store-index-query-vectors).\n\n\u003cbr /\u003e\n\nFor more information about viewing the metrics, see [View vector index metrics](/alloydb/omni/16.8.0/docs/tune-indexes#vector-index-metrics).\n\nUsability metrics\n-----------------\n\nThe usability metrics include metrics that help you understand the state of\nindex utilization with metrics, such as index configuration and number of index\nscans.\n\nTuning metrics\n--------------\n\nTuning metrics provide insights into your current index optimization, allowing you to apply recommendations for faster query performance.\n\n### Tuning recommendation based on the metrics\n\nMutation\n: The `insertcount`, `updatecount`,\n and `deletecount` metrics together show the changes or mutations in\n the vector for the index.\n: The index is created with a specific number of vectors and partitions. When operations such as insert, update, or delete are performed on the vector index, it only affects the initial set of partitions where the vectors reside. Consequently, the number of vectors in each partition fluctuates over time, potentially impacting recall, QPS, or both.\n: If you encounter slowness or accuracy issues such as low QPS or poor recall, in your ANN search queries over time, then consider reviewing these metrics. A high number of mutations relative to the total number of vectors could indicate the need for reindexing.\n\nDistribution\n: The `distribution` metric shows the vector distributions across all partitions.\n: When you create an index, it is created with a specific number of vectors and fixed partitions. The partitioning process and subsequent distribution occurs based on this consideration. If additional vectors are added, they are partitioned among the existing partitions, resulting in a different distribution compared to the distribution when the index was created. Since the final distribution does not consider all vectors simultaneously, the recall, QPS, or both might be affected.\n: If you observe a gradual decline in the performance of your ANN search queries, such as slower response times or reduced accuracy in the results (measured by QPS or recall), then consider checking this metric and reindexing."]]