Choose a source
Export a stable integer id and a fixed width vector from one completed run. The stock MCP server reads the prepared filesystem snapshot. Warehouse scan, storage and transfer charges apply when you export.
Google BigQuery
Parquet export
In GoogleSQL, project the ID and embedding from a partitioned table. Substitute your table, bucket, partition column and date. Use a fresh path in a bucket compatible with the dataset location. Download every output shard.
EXPORT DATA OPTIONS (
uri='gs://YOUR_BUCKET/rulake/run_001/part-*.parquet',
format='PARQUET', overwrite=false
) AS
SELECT id, embedding AS vector
FROM `YOUR_PROJECT.YOUR_DATASET.embeddings`
WHERE event_date = DATE '2026-11-01';
The importer converts BigQuery ARRAY<FLOAT64> to float32. Estimate the SELECT scan before running the export. Google export reference ↗
Snowflake
JSON export
On a warehouse, unload a VECTOR as an array in a JSON object. This preserves numeric components and explicit lowercase field names. Substitute a writable stage, fresh prefix and authorized table.
COPY INTO @YOUR_STAGE/rulake/run_001/
FROM (SELECT OBJECT_CONSTRUCT(
'id', id, 'vector', TO_ARRAY(embedding)
) FROM YOUR_DB.YOUR_SCHEMA.EMBEDDINGS)
FILE_FORMAT=(TYPE=JSON COMPRESSION=NONE);
Download the data shards and pass the newline delimited .json files to the importer. Snowflake vector unloading ↗
Amazon Athena / S3
Parquet export
Run UNLOAD into a new, empty S3 prefix. Apply the partition predicate for your table. Use the job’s data manifest to download exactly the data files it wrote.
UNLOAD (
SELECT id, embedding AS vector
FROM analytics.embeddings
WHERE event_date = DATE '2026-11-01'
) TO 's3://YOUR_BUCKET/rulake/run_001/'
WITH (format = 'PARQUET', compression = 'SNAPPY');
If the data objects have no extension, give their local copies a .parquet suffix. Athena UNLOAD reference ↗
Databricks / Delta Lake
Table version
Read a retained Delta version through Spark so updates and deletions are applied. Replace version 42 and the output location for each refresh.
rows = (spark.read.format("delta").option("versionAsOf", 42)
.table("catalog.schema.embeddings"))
(rows.selectExpr("id", "embedding AS vector").write
.mode("errorifexists").parquet("s3://YOUR_BUCKET/rulake/run_001"))
Download the resulting Parquet parts. Keep the source version with the export. Databricks table history ↗
Apache Iceberg
Snapshot ID
Choose a retained snapshot ID from the catalog. The Iceberg reader applies its manifest and delete files before writing the export.
rows = (spark.read.format("iceberg")
.option("snapshot-id", "10963874102873")
.load("catalog.db.embeddings"))
(rows.selectExpr("id", "embedding AS vector").write
.mode("errorifexists").parquet("s3://YOUR_BUCKET/rulake/run_001"))
Download only the parts from that export. Iceberg time travel ↗
Microsoft Fabric / OneLake
Lakehouse export
In a Spark notebook attached to your lakehouse, read a retained Delta version and write the projected columns under Files. Download the resulting parts from that directory.
rows = (spark.read.format("delta").option("versionAsOf", 42)
.load("Tables/embeddings"))
(rows.selectExpr("id", "embedding AS vector").write
.mode("errorifexists").parquet("Files/rulake/run_001"))
For a schema enabled lakehouse, use its full table path. Fabric lakehouse tables ↗
Parquet / Google Cloud Storage
File or Rust adapter
Local Parquet parts from the same completed export can go straight to the importer. It reads only id and vector. Signed nonnegative or unsigned integer IDs and float32 or float64 lists are supported.
Rust applications can also register one GCS Parquet object directly with GcsParquetBackend. That adapter takes INT64 IDs and float32 lists. Set the dimension explicitly for variable length lists. GCS adapter contract ↗
Prepare the file
Download the importer and sample to the same directory. The sample uses the same INT64 and float64 list types as the BigQuery example.
python -m pip install "pyarrow>=20" numpy
python prepare_snapshot.py sample.parquet -o sample.ruvec1
Expected output: 8 vectors, 4 dimensions, 216 bytes. For a warehouse export, pass all shards to one invocation. Use a new filename for each snapshot.
python prepare_snapshot.py run_001/*.parquet -o run_001.ruvec1
IDs must be unique across shards. The importer checks dimensions, nulls and finite float32 values before publishing the file. For Snowflake JSON use run_001/*.json and nonnegative signed 64 bit IDs.
Serve it with MCP
Place the sample config beside sample.ruvec1 and start the RuLake MCP binary from that directory. For another snapshot, update filename in the config and restart the server. Keep the prior file and config for rollback.
rulake-mcp stdio --config mcp.toml
Use your MCP client to call rulake_query with these arguments. For the sample, expect ID 101 first. The snapshot stays current through the export you selected. Repeat the export and import to include newer source rows.
{
"intent": "search",
"target": {"routes": [["lake", "embeddings"]]},
"search": {"vector": [1, 0, 0, 0], "k": 1}
}