MCPcopy
hub / github.com/claude-code-best/claude-code / renderModelName

Function renderModelName

src/utils/model/model.ts:485–505  ·  view source on GitHub ↗
(model: ModelName)

Source from the content-addressed store, hash-verified

483}
484
485export function renderModelName(model: ModelName): string {
486 const publicName = getPublicModelDisplayName(model)
487 if (publicName) {
488 return publicName
489 }
490 if (process.env.USER_TYPE === 'ant') {
491 const resolved = parseUserSpecifiedModel(model)
492 const antModel = resolveAntModel(model)
493 if (antModel) {
494 const baseName = antModel.model.replace(/\[1m\]$/i, '')
495 const masked = maskModelCodename(baseName)
496 const suffix = has1mContext(resolved) ? '[1m]' : ''
497 return masked + suffix
498 }
499 if (resolved !== model) {
500 return `${model} (${resolved})`
501 }
502 return resolved
503 }
504 return model
505}
506
507/**
508 * Returns a safe author name for public display (e.g., in git commit trailers).

Callers 14

renderToolUseTagFunction · 0.85
queryLoopFunction · 0.85
StatusLineInnerFunction · 0.85
OverviewTabFunction · 0.85
ModelEntryFunction · 0.85
generateTokenChartFunction · 0.85
renderOverviewToAnsiFunction · 0.85
renderModelsToAnsiFunction · 0.85
AdvisorMessageFunction · 0.85
AssistantTextMessageFunction · 0.85

Calls 5

parseUserSpecifiedModelFunction · 0.85
resolveAntModelFunction · 0.85
maskModelCodenameFunction · 0.85
has1mContextFunction · 0.85

Tested by

no test coverage detected