Module: OllamaChat
- Defined in:
- lib/ollama_chat.rb,
lib/ollama_chat/version.rb
Overview
The main module namespace for the OllamaChat application.
This module serves as the root namespace for all components of the OllamaChat Ruby gem, providing access to core classes, utilities, and configuration management for interacting with Ollama language models through a terminal interface.
All public classes and modules are namespaced under this module.
Defined Under Namespace
Modules: Clipboard, CommandConcern, Commands, ConfigHandling, Conversation, Database, Dialog, DocumentCache, FavouritesManagement, FileEditing, HTTPHandling, History, Information, InputContent, KramdownANSI, LocationHandling, Logging, MessageEditing, MessageFormat, MessageMixin, MessageOutput, ModelHandling, Pager, Parsing, PersonaeManagement, PromptHandling, PromptManagement, RAGHandling, ServerSocket, SessionManagement, SourceFetching, StateSelectors, Switches, SystemPromptManagement, ThinkControl, TokenEstimator, ToolCalling, Tools, UUIDV7, Utils, WebSearching Classes: Chat, ConfigMissingError, ExecuteError, FollowChat, HTTPError, InvalidPathError, LinksSet, Message, MessageList, OllamaChatConfig, OllamaChatError, OllamaChatQuitError, RedisCache, Say, ToolFunctionArgumentError, UnknownModelError, Vim
Constant Summary collapse
- COLLECTION_NAME_REGEXP =
Regular expression defining the allowed characters for collection names.
Matches alphanumeric characters, underscores, hyphens, and dots. Explicitly excludes slashes and other shell metacharacters to prevent path traversal and parsing issues.
/[-\w\.]+/- VERSION =
OllamaChat version
'0.0.110'- VERSION_ARRAY =
:nodoc:
VERSION.split('.').map(&:to_i)
- VERSION_MAJOR =
:nodoc:
VERSION_ARRAY[0]
- VERSION_MINOR =
:nodoc:
VERSION_ARRAY[1]
- VERSION_BUILD =
:nodoc:
VERSION_ARRAY[2]
Class Attribute Summary collapse
-
.test_mode ⇒ Object
writeonly
Sets the attribute test_mode.
Class Method Summary collapse
-
.test_mode? ⇒ Boolean
Checks whether test mode is enabled.
Class Attribute Details
.test_mode=(value) ⇒ Object (writeonly)
Sets the attribute test_mode
82 83 84 |
# File 'lib/ollama_chat.rb', line 82 def test_mode=(value) @test_mode = value end |
Class Method Details
.test_mode? ⇒ Boolean
Checks whether test mode is enabled.
When true, AppState.seed skips the interactive
confirm? prompt and auto-accepts new prompt fingerprints.
90 91 92 |
# File 'lib/ollama_chat.rb', line 90 def test_mode? !!@test_mode end |