langchainrb_datadog 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: abb023d18e8b8502d417d70b5cf6e004aa4d490f47bf5eb7f71af13ea6d48fc7
4
- data.tar.gz: 8d8be0154c9707258f9a306834c2818a302225294001ab3155c2b9584e05ddd6
3
+ metadata.gz: 23338bc6bd38a2b3ec5c71341951b9ae8e257942bb98db4bbecf475c2ae16a8b
4
+ data.tar.gz: 4ef7916a9f9d603ffe8ee5336c330d9e763b7f14387c4b1c1a81d9767ac33d57
5
5
  SHA512:
6
- metadata.gz: 3cb22c5a223473a51557211ebdfcfb0d41b309e39469fcd01b193e5cccb702f483d5d3a7033adbdd90c86eefa7a1b769f8550a53088783a18a471d1f0ef140c3
7
- data.tar.gz: 998cbea79f0ca64a80622816e036d8ad4af6ce6abc2552491d6b9c604ff5828b052b59b2e3ee2516a281c8c513502f7cb2f2bc4c5dbbaf2034d2086538955f6c
6
+ metadata.gz: e77c86b700e4c40581233cac7e1dc867da1d5f2a46646a606ed90f443923cc88c485b9e5c8959694e40ecaf7725e94dd83be67630713e1f324c7d0bcd105f03c
7
+ data.tar.gz: '01608efee90006c6217680eeb7c1020ed007456f29bac2d5ed6986e40714ab16d987408898394d32a720737cb8f05236388a97e19be13f4d1dd39fd5879df363'
@@ -36,11 +36,15 @@ module Langchain
36
36
 
37
37
  # Starts a new workflow span.
38
38
  def self.workflow(input = nil, name: nil, &block)
39
+ return yield unless Datadog.enabled?
40
+
39
41
  span(input, name:, kind: 'workflow', &block)
40
42
  end
41
43
 
42
44
  # Starts a new agent span.
43
45
  def self.agent(input = nil, name: nil, &block)
46
+ return yield unless Datadog.enabled?
47
+
44
48
  span(input, name:, kind: 'agent', &block)
45
49
  end
46
50
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Langchain
4
4
  module Datadog
5
- VERSION = '0.1.0'
5
+ VERSION = '0.1.1'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: langchainrb_datadog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - GaggleAMP
@@ -53,7 +53,6 @@ files:
53
53
  - LICENSE.txt
54
54
  - README.md
55
55
  - Rakefile
56
- - langchainrb_datadog.gemspec
57
56
  - lib/langchain/datadog.rb
58
57
  - lib/langchain/datadog/llm.rb
59
58
  - lib/langchain/datadog/tracing.rb
@@ -1,39 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative 'lib/langchain/datadog/version'
4
-
5
- Gem::Specification.new do |spec|
6
- spec.name = 'langchainrb_datadog'
7
- spec.version = Langchain::Datadog::VERSION
8
- spec.authors = ['GaggleAMP', 'Nikolaos Anastopoulos']
9
- spec.email = ['info@gaggleamp.com', 'ebababi@ebababi.net']
10
-
11
- spec.summary = 'Enables LLM observability with Datadog for Langchain.rb.'
12
- spec.description = 'Hooks into Langchain.rb methods to capture LLM calls and ' \
13
- 'report them to the Datadog LLM Observability API.'
14
- spec.homepage = 'https://github.com/GaggleAMP/langchainrb_datadog'
15
- spec.license = 'MIT'
16
- spec.required_ruby_version = '>= 3.1.0'
17
-
18
- spec.metadata['homepage_uri'] = spec.homepage
19
- spec.metadata['source_code_uri'] = 'https://github.com/GaggleAMP/langchainrb_datadog'
20
- spec.metadata['github_repo'] = 'git@github.com:GaggleAMP/langchainrb_datadog.git'
21
-
22
- # Specify which files should be added to the gem when it is released.
23
- # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
24
- spec.files = Dir.chdir(__dir__) do
25
- `git ls-files -z`.split("\x0").reject do |f|
26
- (File.expand_path(f) == __FILE__) ||
27
- f.start_with?(*%w[bin/ test/ spec/ features/ .git .circleci appveyor Gemfile])
28
- end
29
- end
30
- spec.bindir = 'exe'
31
- spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
32
- spec.require_paths = ['lib']
33
-
34
- spec.add_dependency 'faraday'
35
- spec.add_dependency 'langchainrb', '~> 0.17.1'
36
-
37
- # For more information and examples about making a new gem, check out our
38
- # guide at: https://bundler.io/guides/creating_gem.html
39
- end