OSS-first docs
These docs teach the open system first: contracts, generated surfaces, runtimes, governance, and incremental adoption. Studio shows up as the operating layer on top, not as the source of truth.
Supabase integration for embedding storage and vector similarity search using pgvector.
Source Definition
export const supabaseVectorIntegrationSpec = defineIntegration({
meta: {
key: 'vectordb.supabase',
version: '1.0.0',
category: 'vector-db',
title: 'Supabase Vector Database (pgvector)',
description:
'Supabase integration for embedding storage and vector similarity search using pgvector.',
domain: 'ai',
owners: ['platform.ai'],
tags: ['vector-db', 'supabase', 'pgvector'],
stability: StabilityEnum.Beta,
},
supportedModes: ['managed', 'byok'],
transports: [
{ type: 'rest' },
{ type: 'sdk', packageName: '@supabase/supabase-js' },
],
preferredTransport: 'rest',
supportedAuthMethods: [{ type: 'api-key' }, { type: 'bearer' }],
capabilities: {
provides: [
{ key: 'vector-db.search', version: '1.0.0' },
{ key: 'vector-db.storage', version: '1.0.0' },
],
requires: [
{
key: 'ai.embeddings',
optional: true,
reason:
'Required when vectors are generated by a hosted embedding provider.',
},
],
},
configSchema: {
schema: {
type: 'object',
properties: {
schema: {
type: 'string',
description:
'Schema name containing the pgvector table (default: public).',
},
table: {
type: 'string',
description:
'Table used to store vectors and metadata (default: contractspec_vectors).',
},
createTableIfMissing: {
type: 'boolean',
description:
'Automatically create pgvector extension and table when first writing vectors.',
},
distanceMetric: {
type: 'string',
enum: ['cosine', 'l2', 'inner_product'],
description: 'Distance metric used for nearest-neighbor search.',
},
},
},
example: {
schema: 'public',
table: 'contractspec_vectors',
createTableIfMissing: true,
distanceMetric: 'cosine',
},
},
secretSchema: {
schema: {
type: 'object',
required: ['databaseUrl'],
properties: {
databaseUrl: {
type: 'string',
description:
'Supabase Postgres connection string with privileges to read/write vector rows.',
},
},
},
example: {
databaseUrl:
'postgresql://postgres.[project-ref]:password@aws-0-region.pooler.supabase.com:6543/postgres',
},
},
healthCheck: {
method: 'ping',
timeoutMs: 5000,
},
docsUrl: 'https://supabase.com/docs/guides/ai/vector-columns',
byokSetup: {
setupInstructions:
'Create or reuse a Supabase project, enable pgvector, and provide a Postgres connection string with read/write access to the target vector table.',
keyRotationSupported: true,
quotaTrackingSupported: false,
},
});