Skip to content

Commit

Permalink
Update Rubygems file amd dep
Browse files Browse the repository at this point in the history
  • Loading branch information
alexshapalov committed Oct 22, 2024
1 parent 997d0fa commit 77540f5
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 10 deletions.
6 changes: 5 additions & 1 deletion lib/rubyai.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
require_relative "rubyai/client"
require_relative "rubyai/configuration"
require_relative "rubyai/http"
require_relative "rubyai/version"

require 'faraday'

module RubyAI
class Error < StandardError; end
end
end
3 changes: 0 additions & 3 deletions lib/rubyai/client.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
require_relative 'configuration'
require_relative 'http'

module RubyAI
class Client
attr_reader :configuration
Expand Down
3 changes: 0 additions & 3 deletions lib/rubyai/configuration.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
require 'faraday'
require 'json'

module RubyAI
class Configuration
BASE_URL = "https://api.openai.com/v1/chat/completions"
Expand Down
2 changes: 0 additions & 2 deletions lib/rubyai/http.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
require_relative 'configuration'

module RubyAI
module HTTP
extend self
Expand Down
17 changes: 16 additions & 1 deletion rubyai.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,23 @@ Gem::Specification.new do |s|
s.name = "rubyai"
s.version = "0.3.1"
s.summary = "A Ruby gem for the OpenAI (GPT-3 and GPT-4) API"
s.description = "RubyAI is a wrapper for the OpenAI API that allows you to interact with GPT-3 and GPT-4 from within Ruby applications. It provides simple methods for integrating language model capabilities into your Ruby projects."
s.homepage = "https://github.com/alexshapalov/rubyai"
s.authors = ["Alex Shapalov"]
s.files = ["lib/rubyai.rb"]
s.email = "[email protected]" # Optional, but often useful
s.license = "MIT"

s.files = Dir.glob("**/*").select { |f| File.file?(f) } + ["README.md", "LICENSE.txt"]

s.require_paths = ["."]
s.required_ruby_version = ">= 2.6"

s.add_dependency "faraday", "~> 2.0"
s.add_development_dependency "rspec", "~> 3.10"

s.metadata = {
"source_code_uri" => "https://github.com/alexshapalov/rubyai",
"changelog_uri" => "https://github.com/alexshapalov/rubyai/CHANGELOG.md",
"documentation_uri" => "https://github.com/alexshapalov/rubyai#readme"
}
end

0 comments on commit 77540f5

Please sign in to comment.