patient_llm 0.5.0 → 0.5.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: e41751b511195c13cb2ce097a6c4bd7c7eac6b5396d9194cc0c831dfc37213bc
4
- data.tar.gz: 245940b4b96b8c558c417945564f64a03866a75d4715600cbb2232be69d9f8d9
3
+ metadata.gz: f1b92ba6cfe7609461cc940064399ce5a9c17f79ad18b5beaea3ae33ef9bfb11
4
+ data.tar.gz: c3420d27801ab7571685e6d3fde742ed7203ecb01a068a89749c07c6511fc11b
5
5
  SHA512:
6
- metadata.gz: 6ed8d318bdbf43564895ab93bfe6020abdded82573d042e2d568bf598af595d769520dd3b61ca348dd05a0a8796da2900e0c70fa204ff6884c9d170c4f777edc
7
- data.tar.gz: a93fed561708169bcb3b6f38c5db9158a4079a0e1d8e400af3892d1cd3fe198aa75648e080a685022b864aec6954bc082a359ac9fc25e457a25442f7999a4f12
6
+ metadata.gz: eab9baa8560c32b4af7cdda7c1f72b13701f86c7295e3c2b5ae990b073707f69687e207b9908672e8dc78a6d0134fe829f20b3d40cb9d3b3c2bc5197b53c071a
7
+ data.tar.gz: 826f52f65cf57779edcbb1ee5dcdb8be254cff69d509eaa30b25e799a955db4f5c5413160b535c2169906a62f0e6d7bfda55589f7a7273a2003a431de49cdc25
data/CHANGELOG.md CHANGED
@@ -4,6 +4,16 @@ All notable changes to this project will be documented in this file.
4
4
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
5
5
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## 0.5.1
8
+
9
+ ### Added
10
+
11
+ - Added `PatientLLM::Agent::Response#messages` to retrieve only the message items from the session, filtering out non-message items like tool calls, compactions, and reasoning traces.
12
+
13
+ ### Changed
14
+
15
+ - Updated `PatientLLM::Agent::Response#model` to fall back to the session's model if the response does not specify one.
16
+
7
17
  ## 0.5.0
8
18
 
9
19
  ### Added
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.5.0
1
+ 0.5.1
@@ -86,11 +86,20 @@ module PatientLLM
86
86
  llm_response.usage
87
87
  end
88
88
 
89
+ # Get just the message items in the session. This filters out any non-message items
90
+ # like tool calls, compactions, reasoning traces, etc. It includes just the system,
91
+ # user, and assistant messages.
92
+ #
93
+ # @return [Array<PromptBuilder::Items::Message>]
94
+ def messages
95
+ session.items.select { |item| item.is_a?(PromptBuilder::Items::Message) }
96
+ end
97
+
89
98
  # The model that produced the response.
90
99
  #
91
100
  # @return [String, nil]
92
101
  def model
93
- llm_response.model
102
+ llm_response.model || session.model
94
103
  end
95
104
 
96
105
  # Whether the response contains tool calls.
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: patient_llm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Durand
@@ -81,7 +81,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
83
  requirements: []
84
- rubygems_version: 4.0.3
84
+ rubygems_version: 3.6.9
85
85
  specification_version: 4
86
86
  summary: Asynchronous LLM API requests via patient_http using prompt_builder for multi-format
87
87
  LLM API support.