ollama_chat 0.0.5 → 0.0.6
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/CHANGES.md +10 -0
- data/Rakefile +1 -1
- data/VERSION +1 -1
- data/lib/ollama_chat/model_handling.rb +2 -2
- data/lib/ollama_chat/utils/fetcher.rb +6 -3
- data/lib/ollama_chat/version.rb +1 -1
- data/ollama_chat.gemspec +4 -4
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 495be78e16eba41edf9e1a785ed215a6137750d17c0faf9ca77b26cd45d9003b
|
4
|
+
data.tar.gz: 1e8bdf99a0b5171ba786e09109892e1fe05743886b0a9990c0ad14d8ca8c9a4d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d83e739ee797ef746a53b96d76b8cca1e57c12a4f0325106c031108d1c5306899475d887e8ac8572364ee9d5167f864743620b380d981dfc6cccfbce1394e412
|
7
|
+
data.tar.gz: a9ef9c72777c16d5321b11fb7b0f00278cde2a4e44a1fb01ecf3de5bef6abbbe98bcbb7c774423b0df73e2876618027613b2202d416ce636514c56e86d6fd97d
|
data/CHANGES.md
CHANGED
@@ -1,5 +1,15 @@
|
|
1
1
|
# Changes
|
2
2
|
|
3
|
+
## 2025-04-15 v0.0.6
|
4
|
+
|
5
|
+
* Updated Rakefile to use `ollama-ruby` version **1.0**.
|
6
|
+
* Modified `model_present?` method in `lib/ollama_chat/model_handling.rb` to use `ollama.show(model:)`.
|
7
|
+
* Changed `pull_model_from_remote` method in `lib/ollama_chat/model_handling.rb` to use `ollama.pull(model:).
|
8
|
+
* Updated `ollama_chat.gemspec` to use `ollama-ruby` version **1.0** and updated date to **2025-04-14**.
|
9
|
+
* Attempt to capture stderr as well by redirecting stderr to stdout for
|
10
|
+
commands that output to it always or in the error case.
|
11
|
+
* Updated development dependencies in `ollama_chat.gemspec`.
|
12
|
+
|
3
13
|
## 2025-03-22 v0.0.5
|
4
14
|
|
5
15
|
* Updated default config to use environment variable for Searxng URL:
|
data/Rakefile
CHANGED
@@ -30,7 +30,7 @@ GemHadar do
|
|
30
30
|
executables << 'ollama_chat'
|
31
31
|
|
32
32
|
dependency 'excon', '~> 1.0'
|
33
|
-
dependency 'ollama-ruby', '~> 0
|
33
|
+
dependency 'ollama-ruby', '~> 1.0'
|
34
34
|
dependency 'documentrix', '~> 0.0'
|
35
35
|
dependency 'rss', '~> 0.3'
|
36
36
|
dependency 'term-ansicolor', '~> 1.11'
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.6
|
@@ -1,13 +1,13 @@
|
|
1
1
|
module OllamaChat::ModelHandling
|
2
2
|
def model_present?(model)
|
3
|
-
ollama.show(
|
3
|
+
ollama.show(model:) { return _1.system.to_s }
|
4
4
|
rescue Ollama::Errors::NotFoundError
|
5
5
|
false
|
6
6
|
end
|
7
7
|
|
8
8
|
def pull_model_from_remote(model)
|
9
9
|
STDOUT.puts "Model #{bold{model}} not found locally, attempting to pull it from remote now…"
|
10
|
-
ollama.pull(
|
10
|
+
ollama.pull(model:)
|
11
11
|
end
|
12
12
|
|
13
13
|
def pull_model_unless_present(model, options)
|
@@ -59,9 +59,12 @@ class OllamaChat::Utils::Fetcher
|
|
59
59
|
|
60
60
|
def self.execute(command, &block)
|
61
61
|
Tempfile.open do |tmp|
|
62
|
-
|
63
|
-
|
64
|
-
|
62
|
+
unless command =~ /2>&1/
|
63
|
+
command += ' 2>&1'
|
64
|
+
end
|
65
|
+
IO.popen(command) do |io|
|
66
|
+
until io.eof?
|
67
|
+
tmp.write io.read(1 << 14)
|
65
68
|
end
|
66
69
|
tmp.rewind
|
67
70
|
tmp.extend(OllamaChat::Utils::Fetcher::HeaderExtension)
|
data/lib/ollama_chat/version.rb
CHANGED
data/ollama_chat.gemspec
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
|
-
# stub: ollama_chat 0.0.
|
2
|
+
# stub: ollama_chat 0.0.6 ruby lib
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "ollama_chat".freeze
|
6
|
-
s.version = "0.0.
|
6
|
+
s.version = "0.0.6".freeze
|
7
7
|
|
8
8
|
s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
|
9
9
|
s.require_paths = ["lib".freeze]
|
10
10
|
s.authors = ["Florian Frank".freeze]
|
11
|
-
s.date = "2025-
|
11
|
+
s.date = "2025-04-14"
|
12
12
|
s.description = "The app provides a command-line interface (CLI) to an Ollama AI model,\nallowing users to engage in text-based conversations and generate\nhuman-like responses. Users can import data from local files or web pages,\nwhich are then processed through three different modes: fully importing the\ncontent into the conversation context, summarizing the information for\nconcise reference, or storing it in an embedding vector database for later\nretrieval based on the conversation.\n".freeze
|
13
13
|
s.email = "flori@ping.de".freeze
|
14
14
|
s.executables = ["ollama_chat".freeze]
|
@@ -32,7 +32,7 @@ Gem::Specification.new do |s|
|
|
32
32
|
s.add_development_dependency(%q<debug>.freeze, [">= 0".freeze])
|
33
33
|
s.add_development_dependency(%q<simplecov>.freeze, [">= 0".freeze])
|
34
34
|
s.add_runtime_dependency(%q<excon>.freeze, ["~> 1.0".freeze])
|
35
|
-
s.add_runtime_dependency(%q<ollama-ruby>.freeze, ["~> 0
|
35
|
+
s.add_runtime_dependency(%q<ollama-ruby>.freeze, ["~> 1.0".freeze])
|
36
36
|
s.add_runtime_dependency(%q<documentrix>.freeze, ["~> 0.0".freeze])
|
37
37
|
s.add_runtime_dependency(%q<rss>.freeze, ["~> 0.3".freeze])
|
38
38
|
s.add_runtime_dependency(%q<term-ansicolor>.freeze, ["~> 1.11".freeze])
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ollama_chat
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Florian Frank
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-
|
10
|
+
date: 2025-04-14 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: gem_hadar
|
@@ -127,14 +127,14 @@ dependencies:
|
|
127
127
|
requirements:
|
128
128
|
- - "~>"
|
129
129
|
- !ruby/object:Gem::Version
|
130
|
-
version: '0
|
130
|
+
version: '1.0'
|
131
131
|
type: :runtime
|
132
132
|
prerelease: false
|
133
133
|
version_requirements: !ruby/object:Gem::Requirement
|
134
134
|
requirements:
|
135
135
|
- - "~>"
|
136
136
|
- !ruby/object:Gem::Version
|
137
|
-
version: '0
|
137
|
+
version: '1.0'
|
138
138
|
- !ruby/object:Gem::Dependency
|
139
139
|
name: documentrix
|
140
140
|
requirement: !ruby/object:Gem::Requirement
|