Skip to main content
Vector columns are an opt-in organization feature. CharDB stores an opaque logical handle in SQLite and delivers the vector to Cloudflare Vectorize after the transaction commits.

Declare the vector

The property name supplies the SQL column name, so the string overload is unnecessary here.
src/schema.ts
Add the matching native binding to wrangler.toml, create the index, then prepare CharDB’s required metadata index.
wrangler.toml
Vectorize has no local emulator. remote = true makes local Wrangler development use the Cloudflare index.

Write and delete

Your application computes the embedding values. This release does not call an embedding model for you.
src/api.ts
Keep ctx.vector.delete() and the row deletion in the same mutation.
src/queries.ts
Search returns { rowPk, score }. CharDB rejects stale, cross-organization, and policy-hidden Vectorize results against SQLite. Delivery and deletion are eventually consistent. A settled vector change invalidates the matching live search query and causes it to refetch.