MCPcopy Create free account
hub / github.com/github/gh-aw / normalizeCatalogProvider

Function normalizeCatalogProvider

pkg/cli/model_costs.go:143–150  ·  view source on GitHub ↗
(provider string)

Source from the content-addressed store, hash-verified

141}
142
143func normalizeCatalogProvider(provider string) string {
144 switch strings.ToLower(strings.TrimSpace(provider)) {
145 case "github", "copilot", "github_models":
146 return "github-copilot"
147 default:
148 return strings.ToLower(strings.TrimSpace(provider))
149 }
150}
151
152func normalizeComparableModelID(value string) string {
153 return strings.NewReplacer(".", "-", "_", "-").Replace(strings.ToLower(strings.TrimSpace(value)))

Callers 2

findModelPricingFunction · 0.85

Calls 1

ToLowerMethod · 0.80

Tested by 1