multiwoven-integrations 0.32.0 → 0.32.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9455dc8be1de31368a3f1020d07ac58815e7a9658ac51c12981c86d7ca390496
4
- data.tar.gz: 8601b4ca19210ed1aeca50aaeeb6e5b261d4ee5df268f97240d6f9d2b6b8a413
3
+ metadata.gz: c0b4f6ea78531a85e85756309808d6cd57bd8606b71ec05aaf786e325bb23e92
4
+ data.tar.gz: 926e33e3cb1f81864006459fa3cc2e5bf1866ed9209b9dbc5f6802d3882b1710
5
5
  SHA512:
6
- metadata.gz: dfdff633b5152d44508879be3ab350473680843957df08d6bb7fa4b9df69e517bac5906a58f435734a983cbf56702c9a4e1732f702010e8218ba9f49ed69aafa
7
- data.tar.gz: e11cf12ce58a056a809a6946afa8f19d7834138682b6243f07629f8cb638bd4e3d88846e9859aaa039118fcedd6746e9a830b817b67d1bed571b25a40640be48
6
+ metadata.gz: b129d5f53d325a2e08ee38885d49c7b0857ba1257eb62c5dd320aaec013901da61e505e13844c84a3043efb7df8b69ffe194b93e51caa07bd8505d5335587550
7
+ data.tar.gz: aabcbd41b1fa36e1302c119363c85b0fa32e689c7d1795581809d801120bf157f41cd9eba0e4ccafa0a658c233749c3024b812de41284d43e3185d60bf2fb469
@@ -182,7 +182,7 @@ module Multiwoven
182
182
 
183
183
  class VectorConfig < ProtocolModel
184
184
  attribute :source, Connector
185
- attribute :vector, Types::Array.of(Types::Float)
185
+ attribute :vector, Types::Array.of(Types::Float) | Types::String
186
186
  attribute :limit, Types::Integer.default(1)
187
187
  end
188
188
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Multiwoven
4
4
  module Integrations
5
- VERSION = "0.32.0"
5
+ VERSION = "0.32.1"
6
6
 
7
7
  ENABLED_SOURCES = %w[
8
8
  Snowflake
@@ -65,6 +65,19 @@ module Multiwoven::Integrations::Source
65
65
  db&.close
66
66
  end
67
67
 
68
+ def search(vector_search_config)
69
+ connection_config = vector_search_config.source.connection_specification
70
+ connection_config = connection_config.with_indifferent_access
71
+ query = "#{vector_search_config[:vector]} LIMIT #{vector_search_config[:limit]}"
72
+ db = create_connection(connection_config)
73
+ query(db, query)
74
+ rescue StandardError => e
75
+ handle_exception(e, {
76
+ context: "POSTGRESQL:SEARCH:EXCEPTION",
77
+ type: "error"
78
+ })
79
+ end
80
+
68
81
  private
69
82
 
70
83
  def query(connection, query)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: multiwoven-integrations
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.32.0
4
+ version: 0.32.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Subin T P
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-07-12 00:00:00.000000000 Z
11
+ date: 2025-07-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport