llm_specs 0.1.3 → 0.1.4

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: e55746ce8150b1e3fc1554277363ad1b03828eee4a13b3199d461dc811547e64
4
- data.tar.gz: 320e3b24f5b6373f2e76d98be22d35d8589d727cd48914f7f26c0f419aece373
3
+ metadata.gz: 4604604399ad4ef7ff18abb3c93064b17a1d6e2fa068e5b6204b1bf7c4303b68
4
+ data.tar.gz: 6592a5f8cdaed54ff6688a846d979ff7b41bdfe94f4a9b1144fa29714b61205c
5
5
  SHA512:
6
- metadata.gz: d3ccbf4b868ebca48dcdf748a48a37e14cea5b0fabd7170ec26cb76f602eb182acff5225b3bc36f246ba0b15db5db31f8dae7fe771e19c62788990355cffc267
7
- data.tar.gz: 01047dcd8b33b838da2bdeb67781416b58a5564031848aa02a4f78a165cbfce6e2ea929a5eb9deb2850a8e38412a58ceadc4c0f5705e44f803e2cdb37b7e7929
6
+ metadata.gz: fae24b7964fef5f7533c905e061f12d83f9b7817b1e3b769ad8a27dfcd2292135e4d9eac4637b389de9f006a4d103b2f4b3c7ead7f59122cea15656d58fb8eb7
7
+ data.tar.gz: 749105c92098bc6105c2e7e28d8def9a9d44fb7eb3cd40da77e1e747fd5c3f3017307ca479bc3badcd5ff106b6eb31b428afebab68576c0d009992d4efe64f03
data/README.md CHANGED
@@ -66,27 +66,34 @@ model.supports?(:function_calling, :batch) # => true/false
66
66
 
67
67
  or input or output modalities:
68
68
  ```ruby
69
- models.supports_input?(:audio) # => true/false
70
- models.supports_input?(:audio, :text) # multiple argument
71
- models.audio_input? # shortcut
72
- models.image_input?
73
- models.text_input?
74
-
75
- models.supports_output?(:audio) # => true/false
76
- models.supports_output?(:audio, :embeddings) # multiple argument
77
- models.audio_output? # shortcut
78
- models.image_output?
79
- models.text_output?
80
- models.embeddings_output?
69
+ model.supports_input?(:audio) # => true/false
70
+ model.supports_input?(:audio, :text) # multiple argument
71
+ model.audio_input? # shortcut
72
+ model.image_input?
73
+ model.text_input?
74
+
75
+ model.supports_output?(:audio) # => true/false
76
+ model.supports_output?(:audio, :embeddings) # multiple argument
77
+ model.audio_output? # shortcut
78
+ model.image_output?
79
+ model.text_output?
80
+ model.embeddings_output?
81
81
  ```
82
82
 
83
83
  Pricing methods:
84
84
  ```ruby
85
- model.input_pricing # => $ per 1M input tokens (default :text_tokens)
85
+ model.input_pricing # 1.1 => $ per 1M input tokens (default :text_tokens)
86
+ model.output_pricing
87
+
86
88
  model.input_pricing(:text_tokens, :batch)
87
89
  model.output_pricing(:embeddings)
88
90
  ```
89
91
 
92
+ ## Cache configuration
93
+
94
+ ```ruby
95
+ LLMSpecs.cache_path = Rails.root.join("tmp", "cache", "llm-specs-cache.json")
96
+ ```
90
97
 
91
98
  ## License
92
99
 
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module LLMSpecs
3
- VERSION = "0.1.3"
3
+ VERSION = "0.1.4"
4
4
  end
data/lib/llm_specs.rb CHANGED
@@ -15,7 +15,7 @@ module LLMSpecs
15
15
  attr_writer :cache_path
16
16
 
17
17
  def cache_path
18
- @cache_path || "models.json"
18
+ @cache_path || "llm-specs.json"
19
19
  end
20
20
 
21
21
  def models
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.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Max Power