From f83d29118da7a0e67f59b79f7ee0eebaa16d0a53 Mon Sep 17 00:00:00 2001 From: aleksei-okatiev <64004628+aleksei-okatiev@users.noreply.github.com> Date: Thu, 6 Mar 2025 11:53:18 +0100 Subject: [PATCH] fix span and generation for local adapter --- CHANGELOG.md | 4 ++++ Gemfile.lock | 2 +- lib/llm_eval_ruby/trace_adapters/local.rb | 4 ++-- lib/llm_eval_ruby/version.rb | 2 +- spec/llm_eval_ruby_spec.rb | 2 +- 5 files changed, 9 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 90e3136..f5c3f6f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,3 +19,7 @@ ## [0.2.5] - 2024-12-16 - Added metadata field to traces. + +## [0.2.6] - 2025-03-07 + +- Fixed span for local adapter. diff --git a/Gemfile.lock b/Gemfile.lock index 372ad1b..b62d5d8 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ PATH remote: . specs: - llm_eval_ruby (0.2.5) + llm_eval_ruby (0.2.6) httparty (~> 0.22.0) liquid (~> 5.5.0) diff --git a/lib/llm_eval_ruby/trace_adapters/local.rb b/lib/llm_eval_ruby/trace_adapters/local.rb index 6707968..567f68a 100644 --- a/lib/llm_eval_ruby/trace_adapters/local.rb +++ b/lib/llm_eval_ruby/trace_adapters/local.rb @@ -21,7 +21,7 @@ def span(**kwargs) return span unless block_given? - result = yield + result = yield span end_span(span, result) @@ -43,7 +43,7 @@ def generation(**kwargs) return generation unless block_given? - result = yield + result = yield generation end_generation(generation, result) diff --git a/lib/llm_eval_ruby/version.rb b/lib/llm_eval_ruby/version.rb index 9268ebd..869eb7c 100644 --- a/lib/llm_eval_ruby/version.rb +++ b/lib/llm_eval_ruby/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module LlmEvalRuby - VERSION = "0.2.5" + VERSION = "0.2.6" end diff --git a/spec/llm_eval_ruby_spec.rb b/spec/llm_eval_ruby_spec.rb index be0b2f0..c086bab 100644 --- a/spec/llm_eval_ruby_spec.rb +++ b/spec/llm_eval_ruby_spec.rb @@ -2,6 +2,6 @@ RSpec.describe LlmEvalRuby do it "has a version number" do - expect(LlmEvalRuby::VERSION).to be("0.2.5") + expect(LlmEvalRuby::VERSION).to be("0.2.6") end end