Merge branch 'ava-docbuf-insanity' into 'main'

runtime data persistence

See merge request whom/bingobot!16
This commit is contained in:
Ava Apples Affine 2024-12-06 00:48:22 +00:00
commit 41c420ebcc
9 changed files with 1425 additions and 146 deletions

View file

@ -35,6 +35,12 @@ type AppConfig struct {
current recommended value is 1000ms.
*/
VoiceActivityTimerSleepIntervalMillis int `yaml:"voice_activity_timer_sleep_interval_millis"`
/* persistent state file store */
PersistentCacheStore string `yaml:"persistent_cache_store"`
/* number of internal state events to cache in memory */
InMemoryEventCacheSize int `yaml:"InMemoryEventCacheSize"`
}
var config *AppConfig
@ -102,4 +108,6 @@ func setDefaults() {
viper.SetDefault("LogAddSource", true)
viper.SetDefault("VoiceActivityThresholdSeconds", 600)
viper.SetDefault("VoiceActivityTimerSleepIntervalMillis", 1000)
viper.SetDefault("PersistentCacheStore", "/tmp/bingobot")
viper.SetDefault("InMemoryEventCacheSize", 512)
}