mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-05-21 18:46:08 +00:00
32 lines
730 B
Go
32 lines
730 B
Go
package api
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
|
|
"github.com/rcourtman/pulse-go-rewrite/internal/config"
|
|
)
|
|
|
|
func loadHostedAwareAIConfig(hostedMode bool, billingBaseDir, orgID string, persistence *config.ConfigPersistence) (*config.AIConfig, error) {
|
|
if persistence == nil {
|
|
return nil, fmt.Errorf("Pulse Assistant config persistence unavailable")
|
|
}
|
|
|
|
cfg, err := persistence.LoadAIConfig()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return cfg, nil
|
|
}
|
|
|
|
func shouldAutoBootstrapHostedAIConfig(hostedMode bool, persistence *config.ConfigPersistence) bool {
|
|
return false
|
|
}
|
|
|
|
func hostedAIAutoBootstrapEligible(state *billingState) bool {
|
|
return false
|
|
}
|
|
|
|
func hostedModeEnabledFromEnv() bool {
|
|
return os.Getenv("PULSE_HOSTED_MODE") == "true"
|
|
}
|