MCPcopy Index your code
hub / github.com/ChatGPTNextWeb/NextChat / getModelProvider

Function getModelProvider

app/utils/model.ts:46–49  ·  view source on GitHub ↗
(modelWithProvider: string)

Source from the content-addressed store, hash-verified

44 * @returns [model, provider] tuple, if no `@` char found, provider is undefined
45 */
46export function getModelProvider(modelWithProvider: string): [string, string?] {
47 const [model, provider] = modelWithProvider.split(/@(?!.*@)/);
48 return [model, provider];
49}
50
51export function collectModelTable(
52 models: readonly LLMModel[],

Callers 7

ModelConfigListFunction · 0.90
ChatActionsFunction · 0.90
fetchFunction · 0.90
requestOpenaiFunction · 0.90
collectModelTableFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected