From vanguard-frontier-agentic
Builds AI applications on AlloyDB for PostgreSQL using pgvector, hybrid search, AI SQL functions (ai_generate, ai_embed), and AlloyDB Omni edge runtime.
How this skill is triggered — by the user, by Claude, or both
Slash command
/vanguard-frontier-agentic:gcp-alloydb-ai-developerThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
AlloyDB AI is a collection of features built into AlloyDB for PostgreSQL that enables AI-powered search and SQL-native inference — including pgvector integration for vector similarity search, hybrid search combining vector + full-text BM25 scoring, AI SQL functions that invoke hosted models directly from SQL queries, and model endpoint management for custom or Vertex AI models.
AlloyDB AI is a collection of features built into AlloyDB for PostgreSQL that enables AI-powered search and SQL-native inference — including pgvector integration for vector similarity search, hybrid search combining vector + full-text BM25 scoring, AI SQL functions that invoke hosted models directly from SQL queries, and model endpoint management for custom or Vertex AI models.
<=>, <->, <#> operators; HNSW and IVFFlat index typesgoogle_ml.predict_row, google_ml.embedding, ai.generate_text, ai.classify, ai.score — invoke AI models from SQL without leaving the database-- Enable extensions
CREATE EXTENSION vector;
CREATE EXTENSION google_ml_integration;
-- Create table with embedding column
CREATE TABLE documents (
id BIGSERIAL PRIMARY KEY,
content TEXT,
embedding vector(768)
);
-- Generate embeddings using AlloyDB AI function
UPDATE documents
SET embedding = google_ml.embedding('text-embedding-004', content);
-- Vector similarity search
SELECT id, content, embedding <=> $1 AS distance
FROM documents
ORDER BY distance LIMIT 10;
-- Hybrid search (vector + BM25 full-text)
SELECT id, content,
(1 - (embedding <=> $1)) * 0.7 + ts_rank(to_tsvector(content), query) * 0.3 AS score
FROM documents, to_tsquery($2) query
WHERE to_tsvector(content) @@ query
ORDER BY score DESC LIMIT 10;
Load only when needed:
| Scenario | Trigger Keywords | Reference |
|---|---|---|
| Vector search setup | pgvector, embedding, similarity, HNSW, IVFFlat | references/vector-search.md |
| AI SQL functions | ai_generate, ai_classify, google_ml, predict_row | references/ai-functions.md |
| Hybrid search | hybrid, BM25, full-text, combined search | references/hybrid-search.md |
| Model endpoints | Vertex AI model, custom model, endpoint, model registry | references/model-endpoints.md |
| AlloyDB Omni | on-premises, edge, container, Omni | references/alloydb-omni.md |
| IAM & security | auth, service account, IAM, private IP, PSC | references/iam-security.md |
google_ml_integration extension must be enabled and the AlloyDB service account granted roles/aiplatform.user to call Vertex AI models from SQLRead-only planning and advisory. Do not modify production AlloyDB schemas, model endpoint registrations, or IAM bindings without explicit approval.
npx claudepluginhub raishin/vanguard-frontier-agentic --plugin vanguard-frontier-agenticConfigure pgvector extension for vector search in Supabase - includes embedding storage, HNSW/IVFFlat indexes, hybrid search setup, and AI-optimized query patterns. Use when setting up vector search, building RAG systems, configuring semantic search, creating embedding storage, or when user mentions pgvector, vector database, embeddings, semantic search, or hybrid search.
Sets up and optimizes production vector search workloads in Cloud SQL Postgres: define specs from intent, generate SQL for embeddings/indexes, and apply changes.
Guides vector database selection for embeddings and semantic search, compares managed options like Pinecone and self-hosted like pgvector/Milvus, explains ANN algorithms like HNSW.