Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion conf/mod_ollama_chat.conf.dist
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,20 @@ OllamaChat.DebugShowFullPrompt = 0
# OLLAMA LLM CONNECTION AND INFERENCE
# --------------------------------------------

# OllamaChat.ApiProvider
# Description: The API backend provider to use for LLM inference.
# "ollama" - Ollama's native generation endpoint (/api/generate).
# "llamacpp" - llama.cpp's native completion endpoint (/completion).
# "openai" - OpenAI-compatible chat completions endpoint (/v1/chat/completions).
# Supported by llama.cpp, LM Studio, Ollama, and cloud hosts.
# Default: "ollama"
OllamaChat.ApiProvider = "ollama"

# OllamaChat.Url
# Description: The URL used to query the Ollama API.
# Default: http://localhost:11434/api/generate
# Default: http://localhost:11434/api/generate (For Ollama)
# http://localhost:8080/completion (For llama.cpp native)
# http://localhost:8080/v1/chat/completions (For OpenAI-compatible)
OllamaChat.Url = http://localhost:11434/api/generate

# OllamaChat.Model
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
INSERT INTO mod_ollama_chat_personality (guid, personality)
SELECT
c.guid,
(
SELECT `key`
FROM mod_ollama_chat_personality_templates
-- Exclude templates meant only for manual assignment
WHERE manual_only = 0
-- This dummy condition forces MySQL to evaluate the subquery per row
AND c.guid IS NOT NULL
ORDER BY RAND()
LIMIT 1
) AS random_personality
FROM characters c
LEFT JOIN mod_ollama_chat_personality p
ON c.guid = p.guid
WHERE p.guid IS NULL;
Loading