diff --git a/.github/workflows/extension_upgrade.yml b/.github/workflows/extension_upgrade.yml index 479a65e..48f9461 100644 --- a/.github/workflows/extension_upgrade.yml +++ b/.github/workflows/extension_upgrade.yml @@ -16,7 +16,7 @@ on: jobs: test: name: Upgrade Test - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 services: vector-serve: image: quay.io/tembo/vector-serve:latest diff --git a/README.md b/README.md index de6f9e8..26f3d30 100644 --- a/README.md +++ b/README.md @@ -244,8 +244,8 @@ Alternatively, `schedule => 'realtime` creates triggers on the source table and Statements below would will result in new embeddings being generated either immediately (`schedule => 'realtime'`) or within the cron schedule set in the `schedule` parameter. ```sql -INSERT INTO products (product_id, product_name, description) -VALUES (12345, 'pizza', 'dish of Italian origin consisting of a flattened disk of bread'); +INSERT INTO products (product_id, product_name, description, product_category, price) +VALUES (12345, 'pizza', 'dish of Italian origin consisting of a flattened disk of bread', 'food', 5.99); UPDATE products SET description = 'sling made of fabric, rope, or netting, suspended between two or more points, used for swinging, sleeping, or resting' diff --git a/docs/examples/scheduling.md b/docs/examples/scheduling.md index b77873c..b964bb0 100644 --- a/docs/examples/scheduling.md +++ b/docs/examples/scheduling.md @@ -9,8 +9,8 @@ Alternatively, `schedule => 'realtime` creates triggers on the source table and Statements below would will result in new embeddings being generated either immediately (`schedule => 'realtime'`) or within the cron schedule set in the `schedule` parameter. ```sql -INSERT INTO products (product_id, product_name, description) -VALUES (12345, 'pizza', 'dish of Italian origin consisting of a flattened disk of bread'); +INSERT INTO products (product_id, product_name, description, product_category, price) +VALUES (12345, 'pizza', 'dish of Italian origin consisting of a flattened disk of bread', 'food', 5.99); UPDATE products SET description = 'sling made of fabric, rope, or netting, suspended between two or more points, used for swinging, sleeping, or resting' diff --git a/extension/Cargo.toml b/extension/Cargo.toml index 3a2e328..cc2bcfa 100644 --- a/extension/Cargo.toml +++ b/extension/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "vectorize" -version = "0.19.0" +version = "0.19.1" edition = "2021" publish = false diff --git a/extension/Trunk.toml b/extension/Trunk.toml index 164d00d..472d5d5 100644 --- a/extension/Trunk.toml +++ b/extension/Trunk.toml @@ -6,7 +6,7 @@ description = "The simplest way to orchestrate vector search on Postgres." homepage = "https://github.com/tembo-io/pg_vectorize" documentation = "https://github.com/tembo-io/pg_vectorize" categories = ["orchestration", "machine_learning"] -version = "0.19.0" +version = "0.19.1" loadable_libraries = [{ library_name = "vectorize", requires_restart = true }] [build] diff --git a/extension/sql/vectorize--0.18.3--0.19.0.sql b/extension/sql/vectorize--0.18.3--0.19.0.sql new file mode 100644 index 0000000..e69de29 diff --git a/extension/sql/vectorize--0.19.0--0.19.1.sql b/extension/sql/vectorize--0.19.0--0.19.1.sql new file mode 100644 index 0000000..56cf6dd --- /dev/null +++ b/extension/sql/vectorize--0.19.0--0.19.1.sql @@ -0,0 +1,2 @@ +ALTER TABLE vectorize.example_products ADD COLUMN product_category TEXT NOT NULL; +ALTER TABLE vectorize.example_products ADD COLUMN price DECIMAL(10, 2) NOT NULL; \ No newline at end of file diff --git a/extension/tests/integration_tests.rs b/extension/tests/integration_tests.rs index 02cb904..6361682 100644 --- a/extension/tests/integration_tests.rs +++ b/extension/tests/integration_tests.rs @@ -166,8 +166,8 @@ async fn test_realtime_job() { let random_product_id = rng.gen_range(0..100000); let insert_query = format!( - "INSERT INTO \"{test_table_name}\"(product_id, product_name, description) - VALUES ({random_product_id}, 'car tester', $$a product for testing car's components$$);" + "INSERT INTO \"{test_table_name}\"(product_id, product_name, description, product_category, price) + VALUES ({random_product_id}, 'car tester', $$a product for testing car's components$$, 'electronics', 10.99);" ); // insert a new row @@ -198,8 +198,8 @@ async fn test_realtime_job() { let random_product_id = rng.gen_range(0..100000); let insert_query = format!( - "INSERT INTO \"{test_table_name}\"(product_id, product_name, description) - VALUES ({random_product_id}, 'messy-product', $DELIM$the $$quick brown fox jump's over the lazy dog$DELIM$);" + "INSERT INTO \"{test_table_name}\"(product_id, product_name, description, product_category, price) + VALUES ({random_product_id}, 'messy-product', $DELIM$the $$quick brown fox jump's over the lazy dog$DELIM$, 'product', 10.99);" ); // insert a new row @@ -332,8 +332,8 @@ async fn test_static() { let random_product_id = rng.gen_range(1..100000); let insert_query = format!( - "INSERT INTO \"{test_table_name}\"(product_id, product_name, description) - VALUES ({random_product_id}, 'car tester', 'a product for testing cars');" + "INSERT INTO \"{test_table_name}\"(product_id, product_name, description, product_category, price) + VALUES ({random_product_id}, 'car tester', 'a product for testing cars', 'electronics', 10.99);" ); // insert a new row @@ -424,8 +424,8 @@ async fn test_realtime_tabled() { // insert a new row let insert_query = format!( - "INSERT INTO \"{test_table_name}\"(product_id, product_name, description) - VALUES ({random_product_id}, 'car tester', 'a product for testing cars');" + "INSERT INTO \"{test_table_name}\"(product_id, product_name, description, product_category, price) + VALUES ({random_product_id}, 'car tester', 'a product for testing cars', 'electronics', 10.99);" ); let _result = sqlx::query(&insert_query) .execute(&conn)