summaryrefslogtreecommitdiff
path: root/bot.go
diff options
context:
space:
mode:
authorGrail Finder <wohilas@gmail.com>2025-11-21 11:17:00 +0300
committerGrail Finder <wohilas@gmail.com>2025-11-21 11:17:00 +0300
commit866a74e459ee2bec64d2b542394a09143d6d00f4 (patch)
tree5c0f03b78abecfb63062bf69089acf1d1f63b73e /bot.go
parent7ee2a87b4956f072121af69de16f750afb54a83a (diff)
Chore: config update
Diffstat (limited to 'bot.go')
-rw-r--r--bot.go8
1 files changed, 7 insertions, 1 deletions
diff --git a/bot.go b/bot.go
index 4dbe5af..e25ada0 100644
--- a/bot.go
+++ b/bot.go
@@ -545,7 +545,13 @@ func charToStart(agentName string) bool {
}
func init() {
- cfg = config.LoadConfigOrDefault("config.toml")
+ var err error
+ cfg, err = config.LoadConfig("config.toml")
+ if err != nil {
+ fmt.Println("failed to load config.toml")
+ os.Exit(1)
+ return
+ }
defaultStarter = []models.RoleMsg{
{Role: "system", Content: basicSysMsg},
{Role: cfg.AssistantRole, Content: defaultFirstMsg},