qdrant-ruby 0.9.8 → 0.9.9
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 +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile +3 -3
- data/Gemfile.lock +43 -29
- data/lib/qdrant/collections.rb +2 -0
- data/lib/qdrant/points.rb +39 -0
- data/lib/qdrant/version.rb +1 -1
- metadata +3 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fb6e4fdc4875c35aa2a6e4a921fae8fd79c7407ec4d20395382829e843e33827
|
4
|
+
data.tar.gz: eb54d1c1e4cafb05a792c990325a633cb42dcaae8231c3f2246af285578a6b77
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7db835fa9f01ba9c1ada4732c0a21b531ded39088edc5f523fa12226275f595ec434d7be1f83040c1f7534002f8fdded17b9b26cf1b1beb3c87ea03e5476085c
|
7
|
+
data.tar.gz: 06017bfade0b83bde059a15012c53cb943a56b61bce6be10d906f449e599b0e8275b5ba492502a4846ed75bdbbbc7bbbe09595cc27325cee8eddafda53ba6386
|
data/CHANGELOG.md
CHANGED
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,74 +1,88 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
qdrant-ruby (0.9.
|
4
|
+
qdrant-ruby (0.9.9)
|
5
5
|
faraday (>= 2.0.1, < 3)
|
6
6
|
|
7
7
|
GEM
|
8
8
|
remote: https://rubygems.org/
|
9
9
|
specs:
|
10
10
|
ast (2.4.2)
|
11
|
+
base64 (0.2.0)
|
11
12
|
byebug (11.1.3)
|
12
13
|
coderay (1.1.3)
|
13
|
-
diff-lcs (1.5.
|
14
|
-
faraday (2.
|
14
|
+
diff-lcs (1.5.1)
|
15
|
+
faraday (2.8.1)
|
16
|
+
base64
|
15
17
|
faraday-net_http (>= 2.0, < 3.1)
|
16
18
|
ruby2_keywords (>= 0.0.4)
|
17
19
|
faraday-net_http (3.0.2)
|
18
|
-
json (2.
|
20
|
+
json (2.7.4)
|
19
21
|
language_server-protocol (3.17.0.3)
|
22
|
+
lint_roller (1.1.0)
|
20
23
|
method_source (1.0.0)
|
21
|
-
parallel (1.
|
22
|
-
parser (3.
|
24
|
+
parallel (1.24.0)
|
25
|
+
parser (3.3.5.0)
|
23
26
|
ast (~> 2.4.1)
|
27
|
+
racc
|
24
28
|
pry (0.14.2)
|
25
29
|
coderay (~> 1.1)
|
26
30
|
method_source (~> 1.0)
|
27
31
|
pry-byebug (3.10.1)
|
28
32
|
byebug (~> 11.0)
|
29
33
|
pry (>= 0.13, < 0.15)
|
34
|
+
racc (1.8.1)
|
30
35
|
rainbow (3.1.1)
|
31
|
-
rake (13.
|
32
|
-
regexp_parser (2.
|
33
|
-
rexml (3.
|
34
|
-
rspec (3.
|
35
|
-
rspec-core (~> 3.
|
36
|
-
rspec-expectations (~> 3.
|
37
|
-
rspec-mocks (~> 3.
|
38
|
-
rspec-core (3.
|
39
|
-
rspec-support (~> 3.
|
40
|
-
rspec-expectations (3.
|
36
|
+
rake (13.2.1)
|
37
|
+
regexp_parser (2.9.2)
|
38
|
+
rexml (3.3.9)
|
39
|
+
rspec (3.13.0)
|
40
|
+
rspec-core (~> 3.13.0)
|
41
|
+
rspec-expectations (~> 3.13.0)
|
42
|
+
rspec-mocks (~> 3.13.0)
|
43
|
+
rspec-core (3.13.2)
|
44
|
+
rspec-support (~> 3.13.0)
|
45
|
+
rspec-expectations (3.13.3)
|
41
46
|
diff-lcs (>= 1.2.0, < 2.0)
|
42
|
-
rspec-support (~> 3.
|
43
|
-
rspec-mocks (3.
|
47
|
+
rspec-support (~> 3.13.0)
|
48
|
+
rspec-mocks (3.13.2)
|
44
49
|
diff-lcs (>= 1.2.0, < 2.0)
|
45
|
-
rspec-support (~> 3.
|
46
|
-
rspec-support (3.
|
47
|
-
rubocop (1.
|
50
|
+
rspec-support (~> 3.13.0)
|
51
|
+
rspec-support (3.13.1)
|
52
|
+
rubocop (1.50.2)
|
48
53
|
json (~> 2.3)
|
49
54
|
parallel (~> 1.10)
|
50
55
|
parser (>= 3.2.0.0)
|
51
56
|
rainbow (>= 2.2.2, < 4.0)
|
52
57
|
regexp_parser (>= 1.8, < 3.0)
|
53
58
|
rexml (>= 3.2.5, < 4.0)
|
54
|
-
rubocop-ast (>= 1.
|
59
|
+
rubocop-ast (>= 1.28.0, < 2.0)
|
55
60
|
ruby-progressbar (~> 1.7)
|
56
61
|
unicode-display_width (>= 2.4.0, < 3.0)
|
57
|
-
rubocop-ast (1.
|
62
|
+
rubocop-ast (1.30.0)
|
58
63
|
parser (>= 3.2.1.0)
|
59
64
|
rubocop-performance (1.16.0)
|
60
65
|
rubocop (>= 1.7.0, < 2.0)
|
61
66
|
rubocop-ast (>= 0.4.0)
|
62
67
|
ruby-progressbar (1.13.0)
|
63
68
|
ruby2_keywords (0.0.5)
|
64
|
-
standard (1.
|
69
|
+
standard (1.28.5)
|
65
70
|
language_server-protocol (~> 3.17.0.2)
|
66
|
-
|
71
|
+
lint_roller (~> 1.0)
|
72
|
+
rubocop (~> 1.50.2)
|
73
|
+
standard-custom (~> 1.0.0)
|
74
|
+
standard-performance (~> 1.0.1)
|
75
|
+
standard-custom (1.0.2)
|
76
|
+
lint_roller (~> 1.0)
|
77
|
+
rubocop (~> 1.50)
|
78
|
+
standard-performance (1.0.1)
|
79
|
+
lint_roller (~> 1.0)
|
67
80
|
rubocop-performance (~> 1.16.0)
|
68
|
-
unicode-display_width (2.
|
81
|
+
unicode-display_width (2.6.0)
|
69
82
|
|
70
83
|
PLATFORMS
|
71
84
|
arm64-darwin-23
|
85
|
+
arm64-darwin-24
|
72
86
|
x86_64-darwin-19
|
73
87
|
x86_64-darwin-21
|
74
88
|
x86_64-linux
|
@@ -76,9 +90,9 @@ PLATFORMS
|
|
76
90
|
DEPENDENCIES
|
77
91
|
pry-byebug (~> 3.9)
|
78
92
|
qdrant-ruby!
|
79
|
-
rake (~> 13.
|
80
|
-
rspec (~> 3.
|
81
|
-
standard (~> 1.
|
93
|
+
rake (~> 13.2)
|
94
|
+
rspec (~> 3.13)
|
95
|
+
standard (~> 1.28.5)
|
82
96
|
|
83
97
|
BUNDLED WITH
|
84
98
|
2.4.0
|
data/lib/qdrant/collections.rb
CHANGED
@@ -20,6 +20,7 @@ module Qdrant
|
|
20
20
|
def create(
|
21
21
|
collection_name:,
|
22
22
|
vectors:,
|
23
|
+
sparse_vectors: nil,
|
23
24
|
shard_number: nil,
|
24
25
|
replication_factor: nil,
|
25
26
|
write_consistency_factor: nil,
|
@@ -33,6 +34,7 @@ module Qdrant
|
|
33
34
|
response = client.connection.put("#{PATH}/#{collection_name}") do |req|
|
34
35
|
req.body = {}
|
35
36
|
req.body["vectors"] = vectors
|
37
|
+
req.body["sparse_vectors"] = sparse_vectors unless sparse_vectors.nil?
|
36
38
|
req.body["shard_number"] = shard_number unless shard_number.nil?
|
37
39
|
req.body["replication_factor"] = replication_factor unless replication_factor.nil?
|
38
40
|
req.body["write_consistency_factor"] = write_consistency_factor unless write_consistency_factor.nil?
|
data/lib/qdrant/points.rb
CHANGED
@@ -294,6 +294,45 @@ module Qdrant
|
|
294
294
|
response.body
|
295
295
|
end
|
296
296
|
|
297
|
+
# Universally query points. This endpoint covers all capabilities of search, recommend, discover, filters. But also enables hybrid and multi-stage queries.
|
298
|
+
def query(
|
299
|
+
collection_name:,
|
300
|
+
consistency: nil,
|
301
|
+
timeout: nil,
|
302
|
+
shard_key: nil,
|
303
|
+
prefetch: nil,
|
304
|
+
query: nil,
|
305
|
+
using: nil,
|
306
|
+
filter: nil,
|
307
|
+
params: nil,
|
308
|
+
score_threshold: nil,
|
309
|
+
limit: nil,
|
310
|
+
offset: nil,
|
311
|
+
with_vector: nil,
|
312
|
+
with_payload: nil,
|
313
|
+
lookup_from: nil
|
314
|
+
)
|
315
|
+
response = client.connection.post("collections/#{collection_name}/#{PATH}/query") do |req|
|
316
|
+
req.params["consistency"] = consistency unless consistency.nil?
|
317
|
+
req.params["timeout"] = timeout unless timeout.nil?
|
318
|
+
|
319
|
+
req.body = {}
|
320
|
+
req.body["shard_key"] = shard_key unless shard_key.nil?
|
321
|
+
req.body["prefetch"] = prefetch unless prefetch.nil?
|
322
|
+
req.body["query"] = query unless query.nil?
|
323
|
+
req.body["using"] = using unless using.nil?
|
324
|
+
req.body["filter"] = filter unless filter.nil?
|
325
|
+
req.body["params"] = params unless params.nil?
|
326
|
+
req.body["score_threshold"] = score_threshold unless score_threshold.nil?
|
327
|
+
req.body["limit"] = limit unless limit.nil?
|
328
|
+
req.body["offset"] = offset unless offset.nil?
|
329
|
+
req.body["with_vector"] = with_vector unless with_vector.nil?
|
330
|
+
req.body["with_payload"] = with_payload unless with_payload.nil?
|
331
|
+
req.body["lookup_from"] = lookup_from unless lookup_from.nil?
|
332
|
+
end
|
333
|
+
response.body
|
334
|
+
end
|
335
|
+
|
297
336
|
# Count points which matches given filtering condition
|
298
337
|
def count(
|
299
338
|
collection_name:,
|
data/lib/qdrant/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: qdrant-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrei Bondarev
|
8
|
-
autorequire:
|
9
8
|
bindir: exe
|
10
9
|
cert_chain: []
|
11
|
-
date:
|
10
|
+
date: 2025-04-11 00:00:00.000000000 Z
|
12
11
|
dependencies:
|
13
12
|
- !ruby/object:Gem::Dependency
|
14
13
|
name: faraday
|
@@ -79,7 +78,6 @@ metadata:
|
|
79
78
|
homepage_uri: https://github.com/andreibondarev/qdrant-ruby
|
80
79
|
source_code_uri: https://github.com/andreibondarev/qdrant-ruby
|
81
80
|
changelog_uri: https://github.com/andreibondarev/qdrant-ruby/CHANGELOG.md
|
82
|
-
post_install_message:
|
83
81
|
rdoc_options: []
|
84
82
|
require_paths:
|
85
83
|
- lib
|
@@ -94,8 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
94
92
|
- !ruby/object:Gem::Version
|
95
93
|
version: '0'
|
96
94
|
requirements: []
|
97
|
-
rubygems_version: 3.
|
98
|
-
signing_key:
|
95
|
+
rubygems_version: 3.6.2
|
99
96
|
specification_version: 4
|
100
97
|
summary: Ruby wrapper for the Qdrant vector search database API
|
101
98
|
test_files: []
|