MCPcopy Create free account
hub / github.com/simstudioai/sim / stripProviderPrefix

Function stripProviderPrefix

apps/sim/app/(landing)/models/utils.ts:238–246  ·  view source on GitHub ↗
(providerId: string, modelId: string)

Source from the content-addressed store, hash-verified

236}
237
238function stripProviderPrefix(providerId: string, modelId: string): string {
239 for (const prefix of getProviderPrefixes(providerId)) {
240 if (modelId.startsWith(prefix)) {
241 return modelId.slice(prefix.length)
242 }
243 }
244
245 return modelId
246}
247
248function stripTechnicalSuffixes(value: string): string {
249 return value

Callers 2

formatModelDisplayNameFunction · 0.85
utils.tsFile · 0.85

Calls 1

getProviderPrefixesFunction · 0.85

Tested by

no test coverage detected