tiny_ollama 1.0.0 → 1.0.1
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 +4 -4
- data/lib/tiny_ollama.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 36c40168a27181184b384503b7e1ad46186bb271f22bd7784ad817d069c9edcb
|
4
|
+
data.tar.gz: aff09cee4326797ed6020053bc1d35d1f7f82d0a86667ada0525b8b0180a2149
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d35d657124e45275b31e9a08d01ef05b081e332cd7db1d542e43e2d3c1bcc1fe96ab93ad1b689ec5e481eb4a4395e39cbd92722e1cb139caa07481edfcd53cfa
|
7
|
+
data.tar.gz: 3eec3df3884bc4545215c2bde92fb0a2336cdf84e704e2c2611ec4aaed5c5343be903014674ed54af296049566701387e5b4f742c773166b04523ef79c6c1c42
|
data/lib/tiny_ollama.rb
CHANGED
@@ -91,11 +91,11 @@ class TinyOllama
|
|
91
91
|
|
92
92
|
# Handle potential errors (e.g., non-200 responses)
|
93
93
|
unless response.is_a?(Net::HTTPSuccess)
|
94
|
-
raise TinyOllamaModelError
|
94
|
+
raise TinyOllamaModelError, "Ollama API Error: #{response.code} - #{response.body}"
|
95
95
|
end
|
96
96
|
|
97
97
|
JSON.parse(response.body)['message']['content']
|
98
98
|
end
|
99
99
|
end
|
100
100
|
|
101
|
-
class TinyOllamaModelError; end
|
101
|
+
class TinyOllamaModelError < StandardError; end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tiny_ollama
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jeff Lunt
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-07-07 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: a tiny gem for using ollama's generate and chat endpoints
|
14
14
|
email: jefflunt@gmail.com
|