documentrix 0.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (33) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +1 -0
  3. data/Gemfile +5 -0
  4. data/README.md +71 -0
  5. data/Rakefile +48 -0
  6. data/documentrix.gemspec +41 -0
  7. data/lib/documentrix/documents/cache/common.rb +43 -0
  8. data/lib/documentrix/documents/cache/memory_cache.rb +91 -0
  9. data/lib/documentrix/documents/cache/records.rb +145 -0
  10. data/lib/documentrix/documents/cache/redis_backed_memory_cache.rb +64 -0
  11. data/lib/documentrix/documents/cache/redis_cache.rb +128 -0
  12. data/lib/documentrix/documents/cache/sqlite_cache.rb +335 -0
  13. data/lib/documentrix/documents/splitters/character.rb +72 -0
  14. data/lib/documentrix/documents/splitters/semantic.rb +91 -0
  15. data/lib/documentrix/documents.rb +328 -0
  16. data/lib/documentrix/utils/colorize_texts.rb +65 -0
  17. data/lib/documentrix/utils/math.rb +48 -0
  18. data/lib/documentrix/utils/tags.rb +112 -0
  19. data/lib/documentrix/utils.rb +5 -0
  20. data/lib/documentrix/version.rb +8 -0
  21. data/lib/documentrix.rb +11 -0
  22. data/spec/assets/embeddings.json +1 -0
  23. data/spec/documentrix/documents/cache/memory_cache_spec.rb +98 -0
  24. data/spec/documentrix/documents/cache/redis_backed_memory_cache_spec.rb +121 -0
  25. data/spec/documentrix/documents/cache/redis_cache_spec.rb +123 -0
  26. data/spec/documentrix/documents/cache/sqlite_cache_spec.rb +141 -0
  27. data/spec/documentrix/documents/splitters/character_spec.rb +110 -0
  28. data/spec/documentrix/documents/splitters/semantic_spec.rb +56 -0
  29. data/spec/documents_spec.rb +174 -0
  30. data/spec/spec_helper.rb +23 -0
  31. data/spec/utils/colorize_texts_spec.rb +13 -0
  32. data/spec/utils/tags_spec.rb +53 -0
  33. metadata +329 -0
@@ -0,0 +1,174 @@
1
+ require 'spec_helper'
2
+
3
+ RSpec.describe Documentrix::Documents do
4
+ let :ollama do
5
+ double('Ollama::Client')
6
+ end
7
+
8
+ let :model do
9
+ 'mxbai-embed-large'
10
+ end
11
+
12
+ let :documents do
13
+ described_class.new ollama:, model:
14
+ end
15
+
16
+ it 'can be instantiated' do
17
+ expect(documents).to be_a described_class
18
+ end
19
+
20
+ it 'no texts can be added to it' do
21
+ expect(documents.add([])).to eq documents
22
+ end
23
+
24
+ it 'texts can be added to it' do
25
+ expect(ollama).to receive(:embed).
26
+ with(model:, input: %w[ foo bar ], options: nil).
27
+ and_return(double(embeddings: [ [ 0.1 ], [ 0.2 ] ]))
28
+ expect(documents.add(%w[ foo bar ])).to eq documents
29
+ expect(documents.exist?('foo')).to eq true
30
+ expect(documents.exist?('bar')).to eq true
31
+ expect(documents['foo']).to be_a Documentrix::Documents::Record
32
+ end
33
+
34
+ it 'a text can be added to it' do
35
+ expect(ollama).to receive(:embed).
36
+ with(model:, input: %w[ foo ], options: nil).
37
+ and_return(double(embeddings: [ [ 0.1 ] ]))
38
+ expect(documents << 'foo').to eq documents
39
+ expect(documents.exist?('foo')).to eq true
40
+ expect(documents.exist?('bar')).to eq false
41
+ expect(documents['foo']).to be_a Documentrix::Documents::Record
42
+ end
43
+
44
+ it 'a text with can be added to it' do
45
+ expect(ollama).to receive(:embed).
46
+ with(model:, input: %w[ foo ], options: nil).
47
+ and_return(double(embeddings: [ [ 0.1 ] ]))
48
+ expect_any_instance_of(Documentrix::Utils::Tags).to\
49
+ receive(:add).with('bar.rb', source: '/foo/bar.rb')
50
+ expect(documents.add('foo', source: '/foo/bar.rb')).to eq documents
51
+ expect(documents.exist?('foo')).to eq true
52
+ expect(documents.exist?('bar')).to eq false
53
+ expect(documents['foo']).to be_a Documentrix::Documents::Record
54
+ end
55
+
56
+ it 'can find strings' do
57
+ expect(ollama).to receive(:embed).
58
+ with(model:, input: [ 'foo' ], options: nil).
59
+ and_return(double(embeddings: [ [ 0.1 ] ]))
60
+ expect(documents << 'foo').to eq documents
61
+ expect(ollama).to receive(:embed).
62
+ with(model:, input: 'foo', options: nil).
63
+ and_return(double(embeddings: [ [ 0.1 ] ]))
64
+ records = documents.find('foo')
65
+ expect(records).to eq [
66
+ Documentrix::Documents::Record[text: 'foo', embedding: [ 0.1 ], similarity: 1.0 ]
67
+ ]
68
+ expect(records[0].to_s).to eq '#<Documentrix::Documents::Record "foo" 1.0>'
69
+ end
70
+
71
+ it 'can find only tagged strings' do
72
+ expect(ollama).to receive(:embed).
73
+ with(model:, input: [ 'foo' ], options: nil).
74
+ and_return(double(embeddings: [ [ 0.1 ] ]))
75
+ expect(documents.add('foo', tags: %w[ test ])).to eq documents
76
+ expect(ollama).to receive(:embed).
77
+ with(model:, input: 'foo', options: nil).
78
+ and_return(double(embeddings: [ [ 0.1 ] ]))
79
+ records = documents.find('foo', tags: %w[ nix ])
80
+ expect(records).to eq []
81
+ expect(ollama).to receive(:embed).
82
+ with(model:, input: 'foo', options: nil).
83
+ and_return(double(embeddings: [ [ 0.1 ] ]))
84
+ records = documents.find('foo', tags: %w[ test ])
85
+ expect(records).to eq [
86
+ Documentrix::Documents::Record[text: 'foo', embedding: [ 0.1 ], similarity: 1.0 ]
87
+ ]
88
+ expect(records[0].to_s).to eq '#<Documentrix::Documents::Record "foo" #test 1.0>'
89
+ end
90
+
91
+ it 'can find strings conditionally' do
92
+ expect(ollama).to receive(:embed).
93
+ with(model:, input: [ 'foobar' ], options: nil).
94
+ and_return(double(embeddings: [ [ 0.01 ] ]))
95
+ expect(ollama).to receive(:embed).
96
+ with(model:, input: [ 'foo' ], options: nil).
97
+ and_return(double(embeddings: [ [ 0.1 ] ]))
98
+ expect(documents << 'foobar').to eq documents
99
+ expect(documents << 'foo').to eq documents
100
+ expect(ollama).to receive(:embed).at_least(:once).
101
+ with(model:, input: 'foo', options: nil).
102
+ and_return(double(embeddings: [ [ 0.1 ] ]))
103
+ records = documents.find_where('foo', text_count: 1)
104
+ expect(records).to eq [
105
+ Documentrix::Documents::Record[text: 'foo', embedding: [ 0.1 ], similarity: 1.0 ],
106
+ ]
107
+ records = documents.find_where('foo', text_size: 3)
108
+ expect(records).to eq [
109
+ Documentrix::Documents::Record[text: 'foo', embedding: [ 0.1 ], similarity: 1.0 ],
110
+ ]
111
+ records = documents.find_where('foo')
112
+ expect(records).to eq [
113
+ Documentrix::Documents::Record[text: 'foo', embedding: [ 0.1 ], similarity: 1.0 ],
114
+ Documentrix::Documents::Record[text: 'foobar', embedding: [ 0.1 ], similarity: 1.0 ],
115
+ ]
116
+ end
117
+
118
+
119
+ context 'it uses cache' do
120
+ before do
121
+ allow(ollama).to receive(:embed).
122
+ with(model:, input: %w[ foo ], options: nil).
123
+ and_return(double(embeddings: [ [ 0.1 ] ]))
124
+ end
125
+
126
+ it 'can delete texts' do
127
+ expect(documents << 'foo').to eq documents
128
+ expect {
129
+ documents.delete('foo')
130
+ }.to change { documents.exist?('foo') }.from(true).to(false)
131
+ end
132
+
133
+ it 'tracks size' do
134
+ expect {
135
+ expect(documents << 'foo').to eq documents
136
+ }.to change { documents.size }.from(0).to(1)
137
+ end
138
+
139
+ it 'can clear texts' do
140
+ expect(documents << 'foo').to eq documents
141
+ expect {
142
+ documents.clear
143
+ }.to change { documents.size }.from(1).to(0)
144
+ end
145
+
146
+ it 'can clear texts with tags' do
147
+ expect(ollama).to receive(:embed).
148
+ with(model:, input: %w[ bar ], options: nil).
149
+ and_return(double(embeddings: [ [ 0.1 ] ]))
150
+ expect(documents.add('foo', tags: %w[ test ])).to eq documents
151
+ expect(documents.add('bar', tags: %w[ test2 ])).to eq documents
152
+ expect(documents.tags.to_a).to eq %w[ test test2 ]
153
+ expect {
154
+ documents.clear tags: 'test'
155
+ }.to change { documents.size }.from(2).to(1)
156
+ expect {
157
+ documents.clear tags: :test2
158
+ }.to change { documents.size }.from(1).to(0)
159
+ end
160
+
161
+ it 'returns collections' do
162
+ expect(documents.collections).to eq [ :default ]
163
+ end
164
+
165
+ it 'can change collection' do
166
+ expect(documents.instance_eval { @cache }).to receive(:prefix=).
167
+ with(/#@collection/).and_call_original
168
+ expect { documents.collection = :new_collection }.
169
+ to change { documents.collection }.
170
+ from(:default).
171
+ to(:new_collection)
172
+ end
173
+ end
174
+ end
@@ -0,0 +1,23 @@
1
+ if ENV['START_SIMPLECOV'].to_i == 1
2
+ require 'simplecov'
3
+ SimpleCov.start do
4
+ add_filter "#{File.basename(File.dirname(__FILE__))}/"
5
+ end
6
+ end
7
+ require 'rspec'
8
+ require 'tins/xt/expose'
9
+ begin
10
+ require 'debug'
11
+ rescue LoadError
12
+ end
13
+ require 'documentrix'
14
+
15
+ def asset(name)
16
+ File.join(__dir__, 'assets', name)
17
+ end
18
+
19
+ RSpec.configure do |config|
20
+ config.before(:suite) do
21
+ infobar.show = nil
22
+ end
23
+ end
@@ -0,0 +1,13 @@
1
+ require 'spec_helper'
2
+
3
+ RSpec.describe Documentrix::Utils::ColorizeTexts do
4
+ it 'colorizes texts' do
5
+ ct = described_class.new(%w[ foo bar ])
6
+ colored = ct.to_s
7
+ uncolored = Term::ANSIColor.uncolor(ct.to_s)
8
+ expect(colored.size).to be > uncolored.size
9
+ expect(uncolored).to eq(
10
+ "foo\n#3 \n\nbar\n#3 \n\n"
11
+ )
12
+ end
13
+ end
@@ -0,0 +1,53 @@
1
+ require 'spec_helper'
2
+
3
+ RSpec.describe Documentrix::Utils::Tags do
4
+ it 'can be instantiated' do
5
+ expect(described_class.new).to be_a described_class
6
+ end
7
+
8
+ it 'can contain unique tags and is sorted' do
9
+ tags = described_class.new(%w[ bar foo ])
10
+ expect(tags.to_a).to eq %w[ bar foo ]
11
+ end
12
+
13
+ it 'can contain unique tags with leading # characters and is sorted' do
14
+ tags = described_class.new(%w[ #bar ##foo ])
15
+ expect(tags.to_a).to eq %w[ bar foo ]
16
+ end
17
+
18
+ it 'tags can be added to it' do
19
+ tags = described_class.new([ 'foo' ])
20
+ tags.add 'bar'
21
+ expect(tags.to_a).to eq %w[ bar foo ]
22
+ end
23
+
24
+ it 'can increase in size' do
25
+ tags = described_class.new
26
+ expect { tags.add 'foo' }.to change { tags.size }.from(0).to(1)
27
+ expect { tags.add 'bar' }.to change { tags.size }.from(1).to(2)
28
+ end
29
+
30
+ it 'can be cleared' do
31
+ tags = described_class.new([ 'foo', 'bar' ])
32
+ expect { tags.clear }.to change { tags.size }.from(2).to(0)
33
+ end
34
+
35
+ it 'tags can be empty' do
36
+ tags = described_class.new([ 'foo' ])
37
+ expect { tags.clear }.to change { tags.empty? }.from(false).to(true)
38
+ end
39
+
40
+ it 'can be output nicely' do
41
+ expect(described_class.new(%w[ #foo bar ]).to_s).to eq '#bar #foo'
42
+ end
43
+
44
+ it 'can be output nicely with links to source' do
45
+ tags = described_class.new([ 'foo' ], source: 'https://foo.example.com')
46
+ tags.add 'bar', source: '/path/to/bar.html'
47
+ expect(tags.to_a).to eq %w[ bar foo ]
48
+ tags.all? { expect(_1).to be_a(Documentrix::Utils::Tags::Tag) }
49
+ expect(tags.to_s).to eq(
50
+ "\e]8;;file:///path/to/bar.html\e\\#bar\e]8;;\e\\ \e]8;;https://foo.example.com\e\\#foo\e]8;;\e\\"
51
+ )
52
+ end
53
+ end
metadata ADDED
@@ -0,0 +1,329 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: documentrix
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Florian Frank
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2024-12-06 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: gem_hadar
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.19'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.19'
27
+ - !ruby/object:Gem::Dependency
28
+ name: all_images
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '0.6'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '0.6'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '3.2'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '3.2'
55
+ - !ruby/object:Gem::Dependency
56
+ name: kramdown
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '2.0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '2.0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: debug
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: simplecov
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: infobar
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - "~>"
102
+ - !ruby/object:Gem::Version
103
+ version: '0.8'
104
+ type: :runtime
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - "~>"
109
+ - !ruby/object:Gem::Version
110
+ version: '0.8'
111
+ - !ruby/object:Gem::Dependency
112
+ name: json
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - "~>"
116
+ - !ruby/object:Gem::Version
117
+ version: '2.0'
118
+ type: :runtime
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - "~>"
123
+ - !ruby/object:Gem::Version
124
+ version: '2.0'
125
+ - !ruby/object:Gem::Dependency
126
+ name: tins
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - "~>"
130
+ - !ruby/object:Gem::Version
131
+ version: '1.34'
132
+ type: :runtime
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - "~>"
137
+ - !ruby/object:Gem::Version
138
+ version: '1.34'
139
+ - !ruby/object:Gem::Dependency
140
+ name: sqlite-vec
141
+ requirement: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - "~>"
144
+ - !ruby/object:Gem::Version
145
+ version: '0.0'
146
+ type: :runtime
147
+ prerelease: false
148
+ version_requirements: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - "~>"
151
+ - !ruby/object:Gem::Version
152
+ version: '0.0'
153
+ - !ruby/object:Gem::Dependency
154
+ name: sqlite3
155
+ requirement: !ruby/object:Gem::Requirement
156
+ requirements:
157
+ - - "~>"
158
+ - !ruby/object:Gem::Version
159
+ version: '2.0'
160
+ - - ">="
161
+ - !ruby/object:Gem::Version
162
+ version: 2.0.1
163
+ type: :runtime
164
+ prerelease: false
165
+ version_requirements: !ruby/object:Gem::Requirement
166
+ requirements:
167
+ - - "~>"
168
+ - !ruby/object:Gem::Version
169
+ version: '2.0'
170
+ - - ">="
171
+ - !ruby/object:Gem::Version
172
+ version: 2.0.1
173
+ - !ruby/object:Gem::Dependency
174
+ name: kramdown-ansi
175
+ requirement: !ruby/object:Gem::Requirement
176
+ requirements:
177
+ - - "~>"
178
+ - !ruby/object:Gem::Version
179
+ version: '0.0'
180
+ - - ">="
181
+ - !ruby/object:Gem::Version
182
+ version: 0.0.1
183
+ type: :runtime
184
+ prerelease: false
185
+ version_requirements: !ruby/object:Gem::Requirement
186
+ requirements:
187
+ - - "~>"
188
+ - !ruby/object:Gem::Version
189
+ version: '0.0'
190
+ - - ">="
191
+ - !ruby/object:Gem::Version
192
+ version: 0.0.1
193
+ - !ruby/object:Gem::Dependency
194
+ name: numo-narray
195
+ requirement: !ruby/object:Gem::Requirement
196
+ requirements:
197
+ - - "~>"
198
+ - !ruby/object:Gem::Version
199
+ version: '0.9'
200
+ type: :runtime
201
+ prerelease: false
202
+ version_requirements: !ruby/object:Gem::Requirement
203
+ requirements:
204
+ - - "~>"
205
+ - !ruby/object:Gem::Version
206
+ version: '0.9'
207
+ - !ruby/object:Gem::Dependency
208
+ name: redis
209
+ requirement: !ruby/object:Gem::Requirement
210
+ requirements:
211
+ - - "~>"
212
+ - !ruby/object:Gem::Version
213
+ version: '5.0'
214
+ type: :runtime
215
+ prerelease: false
216
+ version_requirements: !ruby/object:Gem::Requirement
217
+ requirements:
218
+ - - "~>"
219
+ - !ruby/object:Gem::Version
220
+ version: '5.0'
221
+ - !ruby/object:Gem::Dependency
222
+ name: more_math
223
+ requirement: !ruby/object:Gem::Requirement
224
+ requirements:
225
+ - - "~>"
226
+ - !ruby/object:Gem::Version
227
+ version: '1.1'
228
+ type: :runtime
229
+ prerelease: false
230
+ version_requirements: !ruby/object:Gem::Requirement
231
+ requirements:
232
+ - - "~>"
233
+ - !ruby/object:Gem::Version
234
+ version: '1.1'
235
+ description: |
236
+ The Ruby library, Documentrix, is designed to provide a way to build and
237
+ query vector databases for applications in natural language processing
238
+ (NLP) and large language models (LLMs). It allows users to store and
239
+ retrieve dense vector embeddings for text strings.
240
+ email: flori@ping.de
241
+ executables: []
242
+ extensions: []
243
+ extra_rdoc_files:
244
+ - README.md
245
+ - lib/documentrix.rb
246
+ - lib/documentrix/documents.rb
247
+ - lib/documentrix/documents/cache/common.rb
248
+ - lib/documentrix/documents/cache/memory_cache.rb
249
+ - lib/documentrix/documents/cache/records.rb
250
+ - lib/documentrix/documents/cache/redis_backed_memory_cache.rb
251
+ - lib/documentrix/documents/cache/redis_cache.rb
252
+ - lib/documentrix/documents/cache/sqlite_cache.rb
253
+ - lib/documentrix/documents/splitters/character.rb
254
+ - lib/documentrix/documents/splitters/semantic.rb
255
+ - lib/documentrix/utils.rb
256
+ - lib/documentrix/utils/colorize_texts.rb
257
+ - lib/documentrix/utils/math.rb
258
+ - lib/documentrix/utils/tags.rb
259
+ - lib/documentrix/version.rb
260
+ files:
261
+ - ".yardopts"
262
+ - Gemfile
263
+ - README.md
264
+ - Rakefile
265
+ - documentrix.gemspec
266
+ - lib/documentrix.rb
267
+ - lib/documentrix/documents.rb
268
+ - lib/documentrix/documents/cache/common.rb
269
+ - lib/documentrix/documents/cache/memory_cache.rb
270
+ - lib/documentrix/documents/cache/records.rb
271
+ - lib/documentrix/documents/cache/redis_backed_memory_cache.rb
272
+ - lib/documentrix/documents/cache/redis_cache.rb
273
+ - lib/documentrix/documents/cache/sqlite_cache.rb
274
+ - lib/documentrix/documents/splitters/character.rb
275
+ - lib/documentrix/documents/splitters/semantic.rb
276
+ - lib/documentrix/utils.rb
277
+ - lib/documentrix/utils/colorize_texts.rb
278
+ - lib/documentrix/utils/math.rb
279
+ - lib/documentrix/utils/tags.rb
280
+ - lib/documentrix/version.rb
281
+ - spec/assets/embeddings.json
282
+ - spec/documentrix/documents/cache/memory_cache_spec.rb
283
+ - spec/documentrix/documents/cache/redis_backed_memory_cache_spec.rb
284
+ - spec/documentrix/documents/cache/redis_cache_spec.rb
285
+ - spec/documentrix/documents/cache/sqlite_cache_spec.rb
286
+ - spec/documentrix/documents/splitters/character_spec.rb
287
+ - spec/documentrix/documents/splitters/semantic_spec.rb
288
+ - spec/documents_spec.rb
289
+ - spec/spec_helper.rb
290
+ - spec/utils/colorize_texts_spec.rb
291
+ - spec/utils/tags_spec.rb
292
+ homepage: https://github.com/flori/documentrix
293
+ licenses:
294
+ - MIT
295
+ metadata: {}
296
+ post_install_message:
297
+ rdoc_options:
298
+ - "--title"
299
+ - Documentrix - "Ruby library for embedding vector database
300
+ - "--main"
301
+ - README.md
302
+ require_paths:
303
+ - lib
304
+ required_ruby_version: !ruby/object:Gem::Requirement
305
+ requirements:
306
+ - - "~>"
307
+ - !ruby/object:Gem::Version
308
+ version: '3.1'
309
+ required_rubygems_version: !ruby/object:Gem::Requirement
310
+ requirements:
311
+ - - ">="
312
+ - !ruby/object:Gem::Version
313
+ version: '0'
314
+ requirements: []
315
+ rubygems_version: 3.5.23
316
+ signing_key:
317
+ specification_version: 4
318
+ summary: "\"Ruby library for embedding vector database"
319
+ test_files:
320
+ - spec/documentrix/documents/cache/memory_cache_spec.rb
321
+ - spec/documentrix/documents/cache/redis_backed_memory_cache_spec.rb
322
+ - spec/documentrix/documents/cache/redis_cache_spec.rb
323
+ - spec/documentrix/documents/cache/sqlite_cache_spec.rb
324
+ - spec/documentrix/documents/splitters/character_spec.rb
325
+ - spec/documentrix/documents/splitters/semantic_spec.rb
326
+ - spec/documents_spec.rb
327
+ - spec/spec_helper.rb
328
+ - spec/utils/colorize_texts_spec.rb
329
+ - spec/utils/tags_spec.rb