README.md in gen-ai-0.2.0 vs README.md in gen-ai-0.2.1
- old
+ new
@@ -1,10 +1,10 @@
# GenAI
✨ Generative AI toolset for Ruby ✨
-GenAI allows you to easily integrate Generative AI model providers like OpenAI, Google Vertex AI, Stability AI, etc. Easily add Large Language Models, Stable Diffusion image generation, and other AI models into your application!
+GenAI allows you to easily integrate Generative AI model providers like OpenAI, Google Vertex AI, Stability AI, etc. Easily add Large Language Models, Stable Diffusion image generation, and other AI model integrations into your application!
![Tests](https://github.com/alchaplinsky/gen-ai/actions/workflows/main.yml/badge.svg?branch=main)
[![Gem Version](https://badge.fury.io/rb/gen-ai.svg)](https://badge.fury.io/rb/gen-ai)
[![License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/alchaplinsky/gen-ai/blob/main/LICENSE.txt)
@@ -29,16 +29,16 @@
| ---------------- | --------- | :--------: | :----------: | :-------: | :-----------: |
| **OpenAI** | ✅ | ✅ | ✅ | 🛠️ | 🛠️ |
| **Google Palm2** | ✅ | ✅ | ✅ | 🛠️ | 🛠️ |
-Image generation model capabilities
+Image generation model capabilities
| Provider | Generate | Variations | Edit | Upscale |
| ---------------- | --------- | :--------: | :----------: | :-------: |
| **OpenAI** | ✅ | ✅ | ✅ | ❌ |
-| **StabilityAI** | ✅ | ❌ | ✅ | 🛠️ |
+| **StabilityAI** | ✅ | ❌ | ✅ | ✅ |
### Language
Instantiate a language model client by passing a provider name and an API token.
@@ -121,11 +121,13 @@
# Save image to file
File.open('dog.jpg', 'wb') do |f|
f.write(Base64.decode64(result.value))
end
```
+![dog](https://github.com/alchaplinsky/gen-ai/assets/695947/27a2af5d-530b-4966-94e8-6cdf628b6cac)
+
Get more **variations** of the same image
```ruby
result = model.variations('./dog.jpg')
# => #<GenAI::Result:0x0000000116a1ec50...>
@@ -137,11 +139,13 @@
File.open('dog_variation.jpg', 'wb') do |f|
f.write(Base64.decode64(result.value))
end
```
+![dog_variation](https://github.com/alchaplinsky/gen-ai/assets/695947/977f5238-0114-4085-8e61-8f8b356ce308)
+
**Editing** existing images with additional prompt
```ruby
result = model.edit('./llama.jpg', 'A cute llama wearing a beret', mask: './mask.png')
# => #<GenAI::Result:0x0000000116a1ec50...>
@@ -151,11 +155,14 @@
# Save image to file
File.open('dog_edited.jpg', 'wb') do |f|
f.write(Base64.decode64(result.value))
end
-
```
+
+![llama](https://github.com/alchaplinsky/gen-ai/assets/695947/9c862c6c-428e-463c-b935-ca749a6a33df)
+![llama_edited](https://github.com/alchaplinsky/gen-ai/assets/695947/070d8e6a-07a0-4ed2-826f-8b9aabd183ae)
+
## Development
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.