diff options
author | Grail Finder <wohilas@gmail.com> | 2025-08-20 22:45:41 +0300 |
---|---|---|
committer | Grail Finder <wohilas@gmail.com> | 2025-08-20 22:45:41 +0300 |
commit | eee5e83d329fa9a19cf04ba290102ea650aca580 (patch) | |
tree | 79b20b29dd6db0f1c4c2ace8a1a3bbebd1378d94 /llm.go | |
parent | 6955a5bc3a89e982f0b05d1e8e6f109e3b79d9ca (diff) |
Feat: bot to write for any char in chat (completion only)
Diffstat (limited to 'llm.go')
-rw-r--r-- | llm.go | 18 |
1 files changed, 15 insertions, 3 deletions
@@ -92,7 +92,11 @@ func (lcp LlamaCPPeer) FormMsg(msg, role string, resume bool) (io.Reader, error) prompt := strings.Join(messages, "\n") // strings builder? if !resume { - botMsgStart := "\n" + cfg.AssistantRole + ":\n" + botPersona := cfg.AssistantRole + if cfg.WriteNextMsgAsCompletionAgent != "" { + botPersona = cfg.WriteNextMsgAsCompletionAgent + } + botMsgStart := "\n" + botPersona + ":\n" prompt += botMsgStart } if cfg.ThinkUse && !cfg.ToolUse { @@ -234,7 +238,11 @@ func (ds DeepSeekerCompletion) FormMsg(msg, role string, resume bool) (io.Reader prompt := strings.Join(messages, "\n") // strings builder? if !resume { - botMsgStart := "\n" + cfg.AssistantRole + ":\n" + botPersona := cfg.AssistantRole + if cfg.WriteNextMsgAsCompletionAgent != "" { + botPersona = cfg.WriteNextMsgAsCompletionAgent + } + botMsgStart := "\n" + botPersona + ":\n" prompt += botMsgStart } if cfg.ThinkUse && !cfg.ToolUse { @@ -376,7 +384,11 @@ func (or OpenRouterCompletion) FormMsg(msg, role string, resume bool) (io.Reader prompt := strings.Join(messages, "\n") // strings builder? if !resume { - botMsgStart := "\n" + cfg.AssistantRole + ":\n" + botPersona := cfg.AssistantRole + if cfg.WriteNextMsgAsCompletionAgent != "" { + botPersona = cfg.WriteNextMsgAsCompletionAgent + } + botMsgStart := "\n" + botPersona + ":\n" prompt += botMsgStart } if cfg.ThinkUse && !cfg.ToolUse { |