everyai 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/everyai.rb +14 -1
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6ea764a415337390655eac1973ead20886de6249f5273505dcdb3ee9cb970b07
4
- data.tar.gz: 5e4bf2b5117151b6c02e665c9eba8c1cbc23f81baaa8d270888a7ac9d6fa7ce1
3
+ metadata.gz: 0e34063bbc0fe6f0e542cea2aaddf8cd6e1672711ffc4ba4d943fdc5e151ca72
4
+ data.tar.gz: 565d0a57a5010b82912a6b2cd317d76fd43f77a2e14bac13db645bd5d9687dab
5
5
  SHA512:
6
- metadata.gz: 33cca902618206760751f9274e43e884c1331075ae23f1dcd7bad6d404988826eece90e63d8dc57de1ea517ef7ccbacc3860415817386a975e8e30aee2e1d8bc
7
- data.tar.gz: 758901673c3c431c113136f2e0b12c2a7085d5a0a9ce9cd088d3a445c7cd1eb7095cb62f58714d08651a6e1b548d277ee16b52f612560080c75ea29782faf66f
6
+ metadata.gz: 34cfb4e39a7ee9d63658daaa7ab55c9eaac756413fbf387c35f18b75c85db66fb1080aa06f98c2c6087ab7b8ea7fe4e6beaa700e909d3635d904e534b0e86925
7
+ data.tar.gz: 9681df02cac08959f37f5ff9e89b43c9a619f23f31a43603593233d9a128ba77cd72b5739ddad2471d4e50b18c8b88a33462cecd87f0639ba021a5fccc6e33aa
data/lib/everyai.rb CHANGED
@@ -3,7 +3,8 @@ require 'uri'
3
3
  require 'json'
4
4
 
5
5
  class Everyai
6
- API_GENERATIONS_PATH = "https://every-llm.com/api/v1/generations"
6
+ DOMAIN = "http://localhost:3000" #"https://every-llm.com"
7
+ API_GENERATIONS_PATH = "#{DOMAIN}/api/v1/generations"
7
8
 
8
9
  class << self
9
10
  @api_key = nil
@@ -26,5 +27,17 @@ class Everyai
26
27
  body["errors"]
27
28
  end
28
29
  end
30
+
31
+ def chatgpt(prompt, model: "chatgpt")
32
+ generate(prompt, model: model )
33
+ end
34
+
35
+ def llama(prompt, model: "llama3.1")
36
+ generate(prompt, model: model)
37
+ end
38
+
39
+ def anthropic(prompt, model: "anthropic")
40
+ generate(prompt, model: model)
41
+ end
29
42
  end
30
43
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: everyai
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Enoch Tamulonis
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2024-09-07 00:00:00.000000000 Z
12
+ date: 2024-09-08 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: This ruby gem allows you to connect to any AI model with one simple interface.
15
15
  Never worry about configuration and installing libraries. We make connecting to