gemini
Version, currently 0.2.01 version
- 0.2.0latestDec 8, 2024
github.com/joseafga/gemini.cr
Google Gemini API for Crystal
0 stars
1 dependent
License: MIT
Installation
# Add this to your shard.yml
dependencies:
gemini:
github: joseafga/gemini.cr
version: ~> 0.2.0Then run:
shards installshard.yml
- Crystal
>= 1.14.0- License
- MIT
- Author
- José Almeida
- Target
geminifrom src/gemini.cr
Dependencies
Development Dependencies
- ameba*github: crystal-ameba/amebadev
README
Gemini.cr
Google Gemini API written in Crystal.
It is not complete, it was created for use in another project, but it may be usable.
Installation
-
Add the dependency to your
shard.yml:dependencies: gemini: github: joseafga/gemini.cr -
Run
shards install
Usage
require "gemini"
Gemini.configure do |config|
config.api_key = "GEMINI_API_KEY"
end
model = Gemini::GenerativeModel.new("gemini-1.5-flash")
response = model.generate_content("Explain how AI works")
puts response.text
Contributing
- Fork it (https://github.com/joseafga/gemini.cr/fork)
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create a new Pull Request
Contributors
- José Almeida - creator and maintainer
Documentation
Built from the current release. The first visit to a release nobody has asked for starts its build.
Links
This release
- Version
0.2.0- Tagged
- Dec 8, 2024
- Commit
aac4081fabaf- Crystal
>= 1.14.0- Indexed
- yes
Dependents
Repository
github.com/joseafga/gemini.cr
Metadata
- Created
- Aug 12, 2026
- Updated
- Aug 14, 2026
- Synced
- Aug 14, 2026
- Versions
- 1