Varbase AI VDB: MariaDB
The Varbase AI VDB: MariaDB recipe uses MariaDB's built-in vector type as the vector database for AI search. The vectors live in the site's own database, so no extra service is needed. A separate MariaDB server also works.
It is one of two vector database recipes for Varbase AI Search Base. Apply one of them, not both.
Recipe Type
Varbase AI
Drupal.org Project
https://www.drupal.org/project/varbase_ai_vdb_mariadb
What It Adds
Installs AI, AI Search and the MariaDB VDB Provider.
Keeps the provider on the site's own database connection.
Makes MariaDB the site's default vector database, which Varbase AI Search Base reads.
It does not create a search index. That is the job of Varbase AI Search Base.
Before You Apply
Apply Varbase AI Base first.
The database must run MariaDB 11.7 or later. DDEV with MariaDB 11.8 works. Check it at Administration \ Reports \ Status report.
Varbase Search Base must already be applied (a Varbase site has it). The provider fails on a search index with no server, which that recipe creates.
Installation
Add the recipe with Composer, then apply it with Drush:
Varbase AI Search Base stores its vectors in a database called varbase_ai_search. It must exist and the site's database user must have access to it. On DDEV:
On a hosted site, a database administrator does this step.
A Separate MariaDB Server
Use a separate server when the vectors should not share the site's database, for example for a high volume of vector writes.
Run MariaDB 11.7 or later on the server. Create a database, and a user with all privileges on that database only.
Add the connection to
settings.php, and read the values from the environment. A recipe cannot writesettings.php, and the password must never be stored in configuration:
Hosted Sites
A hosted database below MariaDB 11.7 has no vector type: the status report shows an error, and creating a collection fails. Upgrade the database service first. On most hosts an upgrade is one way, and a downgrade deletes the data, so back up before you upgrade.
Last updated