smart_agent 0.2.7 → 0.2.8

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: ff8fd3192792e6b8cb6f4763f443d72525ddcec5ac8f3ea8b48dd8b1b46271ac
4
- data.tar.gz: af335195cf3dfa97419c9a9b3eee058b9167c4b3e288b813283721efd97172ea
3
+ metadata.gz: 666973e72e303998abcf62405a78a124205ccdbc741c011d3a3cec05a234e7a0
4
+ data.tar.gz: eaf248d80cd7f5c203cfde80de6dc1ed9827539173dce3afb704e5661631cf77
5
5
  SHA512:
6
- metadata.gz: 1287d8e23a9535e82f286c10209b5f01bf4d3a560c61e77aa0f64f3926332907c484e07f83a1986ba942580a92deeee19db9ed203d2896e5b0d1c32e97b02bec
7
- data.tar.gz: a5afa33689f0bb2792915ff9414e3cd4fae54ce13254ba8490f58e1ec4910d1287edfcfd77bdb4b54f8f170279cb2720ba4be28d177d4f5abfefab2d4170e34b
6
+ metadata.gz: bcf37c58978695dd35a844a31ea998f30cc8035c8b51b4267b47ab9a90d29d0d4b59de0a67194632c641e2737de1bc1692452d31fa1640b89e344760cb2e62e4
7
+ data.tar.gz: c4f6a71d195797d30ebf34a82c02e5f637bd31e3085ac056092189199628b0c34b6d23d54be3936e4c13d02d8e879c228840e2c66b3c66f16334b6cb0b7010de
@@ -153,7 +153,7 @@ module SmartAgent
153
153
  if Tool.find_tool(tool_name)
154
154
  tool_result = Tool.find_tool(tool_name).call(params, @agent)
155
155
  if tool_result
156
- @agent.processor(:tool).call({ :content => tool_result })
156
+ @agent.processor(:tool).call({ :content => tool_result }) if @agent.processor(:tool)
157
157
  SmartAgent.prompt_engine.history_messages << { "role" => "assistant", "content" => "", "tool_calls" => [tool] } #result.response.dig("choices", 0, "message")
158
158
  SmartAgent.prompt_engine.history_messages << { "role" => "tool", "tool_call_id" => tool_call_id, "content" => tool_result.to_s.force_encoding("UTF-8") }
159
159
  results << tool_result
@@ -162,7 +162,7 @@ module SmartAgent
162
162
  if server_name = MCPClient.find_server_by_tool_name(tool_name)
163
163
  tool_result = MCPClient.new(server_name).call(tool_name, params, @agent)
164
164
  if tool_result
165
- @agent.processor(:tool).call({ :content => tool_result })
165
+ @agent.processor(:tool).call({ :content => tool_result }) if @agent.processor(:tool)
166
166
  SmartAgent.prompt_engine.history_messages << { "role" => "assistant", "content" => "", "tool_calls" => [tool] } # result.response.dig("choices", 0, "message")
167
167
  SmartAgent.prompt_engine.history_messages << { "role" => "tool", "tool_call_id" => tool_call_id, "content" => tool_result.to_s }
168
168
  results << tool_result
@@ -1,3 +1,3 @@
1
1
  module SmartAgent
2
- VERSION = "0.2.7"
2
+ VERSION = "0.2.8"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: smart_agent
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.7
4
+ version: 0.2.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Zhuang Biaowei
@@ -13,16 +13,16 @@ dependencies:
13
13
  name: smart_prompt
14
14
  requirement: !ruby/object:Gem::Requirement
15
15
  requirements:
16
- - - "~>"
16
+ - - ">="
17
17
  - !ruby/object:Gem::Version
18
- version: 0.4.2
18
+ version: 0.5.2
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
- - - "~>"
23
+ - - ">="
24
24
  - !ruby/object:Gem::Version
25
- version: 0.4.2
25
+ version: 0.5.2
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: mcp-sdk.rb
28
28
  requirement: !ruby/object:Gem::Requirement
@@ -85,7 +85,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
85
85
  - !ruby/object:Gem::Version
86
86
  version: '0'
87
87
  requirements: []
88
- rubygems_version: 4.0.10
88
+ rubygems_version: 4.0.13
89
89
  specification_version: 4
90
90
  summary: Intelligent agent framework with DSL and MCP integration
91
91
  test_files: []