llm.rb 17.0.0 → 17.0.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: '058dd39edfa1c7dee3a429e32c0af2f1ad022fbbfd4c5341be2116264027a09f'
4
- data.tar.gz: 460e7aca153eff0138e53ca21e7b1063294869983676562c41f31a076cd74d91
3
+ metadata.gz: 64500ab12462e962a82bb878d1216396f2cde76c07223dda496a1868de5f5520
4
+ data.tar.gz: e708caa24c81cc66585ae69fc95a5437a89b2b279b9eb4c5bc544457dc519bbf
5
5
  SHA512:
6
- metadata.gz: 9f9edd9b05c9825e5c9854fb113d98fd7e76bf53e992fd26ffb83e4021ac4a64902246389f2620de23901a939890ad2601366dead580036c64c37dad4ab92d62
7
- data.tar.gz: 5b34de772aa2c6c1823e5bde6b2a8314ff4de120edbe1a1a64cd3be8b9c0b4f448806a8630ff79bfec39acc200e3c2a35720cd59ae95fb0aae82f0850878fc79
6
+ metadata.gz: 702022be0328b36155d9832a36241f5aaf79d7af6111024bd21ecbe3f75b7f0078995c3c6bceff8b134b03a8ee582815ef82ebe8320ddcfeb56a51d4ad70cc7c
7
+ data.tar.gz: 15092c8243ec262af8b77d98833a3c05a259a8e2413317f6002e5de9467ebd29eb0af7baaa4b08c22dabc9b943ad344cc938be1600e5382fb0b9f186e671bde6
data/CHANGELOG.md CHANGED
@@ -9,6 +9,31 @@ before) can be seen in [changelog/old.md](changelog/old.md).
9
9
 
10
10
  *No unreleased changes yet. Check back after the next release.*
11
11
 
12
+ ## v17.0.1
13
+
14
+ Changes since `v17.0.0`.
15
+
16
+ This is a small release with a single fix. An `intercept:`
17
+ given to an agent is passed to the context now, so the
18
+ intercept is called when a tool call is about to run.
19
+
20
+ ### Fix
21
+
22
+ * **agent: forward `intercept:` to `LLM::Context`** <br>
23
+ An `intercept:` given to an agent was kept on the
24
+ agent as an instance variable and never read, so the
25
+ context a turn runs against fell back to
26
+ [`LLM::Intercept::Null`](https://r.uby.dev/api-docs/llm.rb/LLM/Intercept/Null.html)
27
+ and no tool call was intercepted. The option is
28
+ passed to
29
+ [`LLM::Context`](https://r.uby.dev/api-docs/llm.rb/LLM/Context.html)
30
+ as a parameter now, the way `tools:` and `stream:`
31
+ are. Each way to set it works: `set intercept:`, a
32
+ block given to
33
+ [`LLM::Agent.intercept`](https://r.uby.dev/api-docs/llm.rb/LLM/Agent.html#intercept-class_method),
34
+ and an `intercept:` given to
35
+ [`LLM::Agent.new`](https://r.uby.dev/api-docs/llm.rb/LLM/Agent.html#initialize-instance_method).
36
+
12
37
  ## v17.0.0
13
38
 
14
39
  Changes since `v16.0.0`.
@@ -22,7 +47,7 @@ to learn more.
22
47
  The Files API provided by deepseek is now supported
23
48
  (via [LLM::DeepSeek#files](https://r.uby.dev/api-docs/llm.rb/LLM/DeepSeek/Files.html)),
24
49
  and there was a large focus on the cancellation and
25
- interrupt story. [LLM::Tracer]((https://r.uby.dev/api-docs/llm.rb/LLM/Tracer.html)
50
+ interrupt story. [LLM::Tracer](https://r.uby.dev/api-docs/llm.rb/LLM/Tracer.html)
26
51
  saw a lot of changes and it has the most changelog
27
52
  entries in this release.
28
53
 
@@ -37,9 +62,9 @@ tool could do.
37
62
 
38
63
  It is now possible to combine multiple tracers _or_
39
64
  intercepts into a single tracer, or intercept. The
40
- [LLM::Tracer.multi]((https://r.uby.dev/api-docs/llm.rb/LLM/Tracer.html#multi-class_method))
65
+ [LLM::Tracer.multi](https://r.uby.dev/api-docs/llm.rb/LLM/Tracer.html#multi-class_method)
41
66
  and
42
- [LLM::Intercept.multi]((https://r.uby.dev/api-docs/llm.rb/LLM/Intercept.html#multi-class_method))
67
+ [LLM::Intercept.multi](https://r.uby.dev/api-docs/llm.rb/LLM/Intercept.html#multi-class_method)
43
68
  methods exist for this purpose.
44
69
 
45
70
  For everything else, keep reading.
data/lib/llm/agent.rb CHANGED
@@ -62,8 +62,7 @@ module LLM
62
62
  name description
63
63
  path tool_budget
64
64
  tracer concurrency
65
- instructions confirm
66
- intercept]
65
+ instructions confirm]
67
66
  private_constant :FIELDS, :IVARS
68
67
 
69
68
  ##
data/lib/llm/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module LLM
4
- VERSION = "17.0.0"
4
+ VERSION = "17.0.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: llm.rb
3
3
  version: !ruby/object:Gem::Version
4
- version: 17.0.0
4
+ version: 17.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Gleeson