llm_specs 0.2.4 → 0.2.5

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: 3cb2e8ade72b5fe9e057124190234502a235a56a43ed1c3cf1fe0f0311807682
4
- data.tar.gz: f3369cd6edb1258ad214b78912e88c8f5e43eebe6df91606db49c47b4fe4de7d
3
+ metadata.gz: b6b6732cff5f8db0347ee4a2ed1bf43c4981c70c04f9a2ed9f5ff59ec4055685
4
+ data.tar.gz: bba0fdccda578ebd1cded497a4a083a5242c2d423896ee65a157f47599577178
5
5
  SHA512:
6
- metadata.gz: b3dbbbe7ac817b114f834527c564d737cf15b11d959129a5a835a96416ebea1a9032ca7cd4cbef465ce5a7dc7846b480361d34f332e44c83d8a156cdec4c87ba
7
- data.tar.gz: b4399e86752127360e59b61c72323343c38c7c7ad7ef342aff8497d9dde46526ad44270d9c9d2d17465f1177b54742f87d9ee4a212f2e8463a00d535647f9a9b
6
+ metadata.gz: e2cfa31b8f64598e7137aaa755e124e7a6b451e2f7abc934eabece9ee68d72ca6af9c29f16aa0dff9ee65cd5bc17dc21482c88b93ae13c98ea1555d3bf511e94
7
+ data.tar.gz: fda0105ebf561c455d7ded186c8dab14bc2d8373a4a1eeb3e0e59ccd0bc0a31858dc86efebdb25052e65c3d0f5e479d2fb99e9ab4fe3e054abd8a1255a6cb8cb
@@ -0,0 +1,18 @@
1
+ #require "activesupport/lib/active_support/core_ext/class/attribute"
2
+ module LLMSpecs
3
+ def self.use_relative_model_naming? = true
4
+
5
+ class Model
6
+ module ActiveModelCompliance
7
+ def persisted? = true
8
+ def errors = Hash.new { |h,k| h[k] = [] }
9
+ def to_model = self
10
+ def to_key = [id]
11
+ def to_param = id
12
+ def to_partial_path = "models/model"
13
+ end
14
+
15
+ extend ActiveModel::Naming
16
+ include ActiveModelCompliance
17
+ end
18
+ end
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module LLMSpecs
3
- VERSION = "0.2.4"
3
+ VERSION = "0.2.5"
4
4
  end
data/lib/llm_specs.rb CHANGED
@@ -7,6 +7,7 @@ require_relative "llm_specs/cache"
7
7
  require_relative "llm_specs/catalog"
8
8
  require_relative "llm_specs/collection"
9
9
  require_relative "llm_specs/model"
10
+ require_relative "llm_specs/active_model" if defined?(ActiveModel)
10
11
 
11
12
  module LLMSpecs
12
13
  API_URI = "https://api.parsera.org/v1/llm-specs"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: llm_specs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.4
4
+ version: 0.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Max Power
@@ -37,6 +37,7 @@ files:
37
37
  - README.md
38
38
  - Rakefile
39
39
  - lib/llm_specs.rb
40
+ - lib/llm_specs/active_model.rb
40
41
  - lib/llm_specs/cache.rb
41
42
  - lib/llm_specs/catalog.rb
42
43
  - lib/llm_specs/collection.rb