ruby_llm-contract 0.4.1 → 0.4.2
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 +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile.lock +2 -2
- data/lib/ruby_llm/contract/rake_task.rb +2 -1
- data/lib/ruby_llm/contract/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e7f3a23f6ba5f67352d32b67ba0737c60d0112dc1db866c9988bbd5d894dcb4f
|
|
4
|
+
data.tar.gz: 7b94ae8959fd87e695063b4e94a3e7217d8bb9b93a860c574f3f1d626bb4a94d
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4abcaf1069f7e97072375027cadbcbcb2b4970a48a5d0a21cb25bc992f53cba6a3c8c6061cc24749f3162600a99017213a58e91f30b52a690deae4102ec153c9
|
|
7
|
+
data.tar.gz: 6ba8118f0ba2b14b43a5908afc5118f96a585026257a3fef97d07a232ac35442b88d6210e2a0c155396dde487f85d9ebb50f65ab104e645abd6ea38128300877
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.4.2 (2026-03-24)
|
|
4
|
+
|
|
5
|
+
- **RakeTask lazy context** — `t.context` now accepts a Proc, resolved at task runtime (after `:environment`). Fixes adapter not being available at Rake load time in Rails apps.
|
|
6
|
+
|
|
3
7
|
## 0.4.1 (2026-03-24)
|
|
4
8
|
|
|
5
9
|
- **RakeTask `:environment` fix** — uses `defined?(::Rails)` instead of `Rake::Task.task_defined?(:environment)`. Works in Rails 8 without manual `Rake::Task.enhance`.
|
data/Gemfile.lock
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
ruby_llm-contract (0.4.
|
|
4
|
+
ruby_llm-contract (0.4.2)
|
|
5
5
|
dry-types (~> 1.7)
|
|
6
6
|
ruby_llm (~> 1.0)
|
|
7
7
|
ruby_llm-schema (~> 0.3)
|
|
@@ -165,7 +165,7 @@ CHECKSUMS
|
|
|
165
165
|
rubocop-ast (1.49.1) sha256=4412f3ee70f6fe4546cc489548e0f6fcf76cafcfa80fa03af67098ffed755035
|
|
166
166
|
ruby-progressbar (1.13.0) sha256=80fc9c47a9b640d6834e0dc7b3c94c9df37f08cb072b7761e4a71e22cff29b33
|
|
167
167
|
ruby_llm (1.14.0) sha256=57c6f7034fc4a44504ea137d70f853b07824f1c1cdbe774ab3ab3522e7098deb
|
|
168
|
-
ruby_llm-contract (0.4.
|
|
168
|
+
ruby_llm-contract (0.4.2)
|
|
169
169
|
ruby_llm-schema (0.3.0) sha256=a591edc5ca1b7f0304f0e2261de61ba4b3bea17be09f5cf7558153adfda3dec6
|
|
170
170
|
unicode-display_width (3.2.0) sha256=0cdd96b5681a5949cdbc2c55e7b420facae74c4aaf9a9815eee1087cb1853c42
|
|
171
171
|
unicode-emoji (4.2.0) sha256=519e69150f75652e40bf736106cfbc8f0f73aa3fb6a65afe62fefa7f80b0f80f
|
|
@@ -31,7 +31,8 @@ module RubyLLM
|
|
|
31
31
|
require "ruby_llm/contract"
|
|
32
32
|
RubyLLM::Contract.load_evals!(*@eval_dirs)
|
|
33
33
|
|
|
34
|
-
|
|
34
|
+
context = @context.respond_to?(:call) ? @context.call : @context
|
|
35
|
+
results = RubyLLM::Contract.run_all_evals(context: context)
|
|
35
36
|
|
|
36
37
|
if results.empty?
|
|
37
38
|
if @fail_on_empty
|