lex-agentic-social 0.1.10 → 0.1.11

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: 0fc83af9a2de72c88452553af56512be4b8fd0ae78460677ede2acb8741b4717
4
- data.tar.gz: c73bca2d3963eb2d3b565e5086e471e34a822bc5b51e4ea6e7beb40cf8a065f3
3
+ metadata.gz: e7c9279bedede69a220b1beab53826fcc730ce652a399f56b3c525dd1ad1bff9
4
+ data.tar.gz: f37c06453a43c45a11adad8567852d80d35cfe56bddd40b6a837a23ed396cc6b
5
5
  SHA512:
6
- metadata.gz: b49a7f8ff8a8c950c03fd88291efa84ccbdf73be77c3581572149fcfa99d4084d041584c63c6044da0fd275803ad75a2ef10cc930ac1c0f0561b624fab73190e
7
- data.tar.gz: d37843a8af2d489580cb9f74923a82390e763939f8a81edc1870d28e42476b383e33d88074305df3c371bcf8ed4b8e01fa6f469ca5753b99cc71fcc1e15f1736
6
+ metadata.gz: 2b8a707d9fc9dd4578d7129296c775abcd487649acb70f00876b7465e7f303a81cd3291b625951dbff7c6802e359279908f81ee23139a4e56a413f794366cea3
7
+ data.tar.gz: eeed5f4c8e0b987a557c066554c5a7ab3840515dc1740356e9f29ccf300711c396cbf480d0802d651640251b2e0b35599b5e8dd8210e8bdaeabd6f4430da633b
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.1.11] - 2026-04-03
4
+
5
+ ### Fixed
6
+ - `retrieve_from_apollo_local` now correctly unpacks `{ success:, results: }` hash from `Apollo::Local.query_by_tags` instead of treating it as an array
7
+
3
8
  ## [0.1.10] - 2026-03-31
4
9
 
5
10
  ### Fixed
@@ -136,8 +136,10 @@ module Legion
136
136
  def retrieve_from_apollo_local
137
137
  return [] unless defined?(Legion::Apollo::Local) && Legion::Apollo::Local.started?
138
138
 
139
- entries = Legion::Apollo::Local.query_by_tags(tags: ['partner_interaction'], limit: 50)
140
- entries.map { |e| { content: e[:content], tags: e[:tags], confidence: e[:confidence] } }
139
+ result = Legion::Apollo::Local.query_by_tags(tags: ['partner_interaction'], limit: 50)
140
+ return [] unless result[:success] && result[:results].is_a?(Array)
141
+
142
+ result[:results].map { |e| { content: e[:content], tags: e[:tags], confidence: e[:confidence] } }
141
143
  rescue StandardError => e
142
144
  Legion::Logging.warn("[calibration] retrieve_from_apollo_local error: #{e.message}")
143
145
  []
@@ -4,7 +4,7 @@ module Legion
4
4
  module Extensions
5
5
  module Agentic
6
6
  module Social
7
- VERSION = '0.1.10'
7
+ VERSION = '0.1.11'
8
8
  end
9
9
  end
10
10
  end
@@ -90,13 +90,15 @@ RSpec.describe Legion::Extensions::Agentic::Social::Calibration::Runners::Calibr
90
90
  stub_const('Legion::Apollo', Module.new)
91
91
  stub_const('Legion::Apollo::Local', mock_local)
92
92
  allow(mock_local).to receive(:started?).and_return(true)
93
- allow(mock_local).to receive(:query_by_tags).with(tags: ['partner_interaction'], limit: 50).and_return([
94
- {
93
+ allow(mock_local).to receive(:query_by_tags).with(tags: ['partner_interaction'], limit: 50).and_return({
94
+ success: true,
95
+ results: [{
95
96
  content: 'hello partner',
96
97
  tags: ['partner_interaction'],
97
98
  confidence: 0.8
98
- }
99
- ])
99
+ }],
100
+ count: 1
101
+ })
100
102
 
101
103
  result = client.send(:retrieve_from_apollo_local)
102
104
  expect(result).to be_an(Array)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lex-agentic-social
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.10
4
+ version: 0.1.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Esity