Add backend provider and cost configuration
This commit is contained in:
@@ -15,6 +15,9 @@ func resolveBackends(entries []backendConfig, base configkit.Path, resolution *c
|
||||
for i := range entries {
|
||||
entry := &entries[i]
|
||||
path := base.Index(i)
|
||||
if entry.Provider != nil {
|
||||
recordStringNormalization(&entry.Provider, path.Key("provider"), resolution, strings.ToLower(strings.TrimSpace(*entry.Provider)))
|
||||
}
|
||||
if entry.Endpoint != nil {
|
||||
if normalized, err := domain.NormalizeOpenAICompatibleBaseEndpoint(*entry.Endpoint); err == nil {
|
||||
recordStringNormalization(&entry.Endpoint, path.Key("endpoint"), resolution, normalized)
|
||||
|
||||
Reference in New Issue
Block a user