From 71987d25e9b0f8afeb885e8719fa8fabb7caef3e Mon Sep 17 00:00:00 2001 From: Grail Finder Date: Wed, 19 Feb 2025 19:56:58 +0300 Subject: Chore: move rag settings to config --- config/config.go | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'config/config.go') diff --git a/config/config.go b/config/config.go index f26a82e..63495b5 100644 --- a/config/config.go +++ b/config/config.go @@ -26,6 +26,10 @@ type Config struct { EmbedURL string `toml:"EmbedURL"` HFToken string `toml:"HFToken"` RAGDir string `toml:"RAGDir"` + // rag settings + RAGWorkers uint32 `toml:"RAGWorkers"` + RAGBatchSize int `toml:"RAGBatchSize"` + RAGWordLimit uint32 `toml:"RAGWordLimit"` } func LoadConfigOrDefault(fn string) *Config { @@ -47,6 +51,10 @@ func LoadConfigOrDefault(fn string) *Config { config.AssistantRole = "assistant" config.SysDir = "sysprompts" config.ChunkLimit = 8192 + // + config.RAGBatchSize = 100 + config.RAGWordLimit = 80 + config.RAGWorkers = 5 } config.CurrentAPI = config.ChatAPI config.APIMap = map[string]string{ -- cgit v1.2.3