MCPcopy Create free account
hub / github.com/codeaashu/claude-code / call

Function call

src/commands/model/model.tsx:271–292  ·  view source on GitHub ↗
(onDone, _context, args)

Source from the content-addressed store, hash-verified

269 return s.mainLoopModel;
270}
271export const call: LocalJSXCommandCall = async (onDone, _context, args) => {
272 args = args?.trim() || '';
273 if (COMMON_INFO_ARGS.includes(args)) {
274 logEvent('tengu_model_command_inline_help', {
275 args: args as AnalyticsMetadata_I_VERIFIED_THIS_IS_NOT_CODE_OR_FILEPATHS
276 });
277 return <ShowModelAndClose onDone={onDone} />;
278 }
279 if (COMMON_HELP_ARGS.includes(args)) {
280 onDone('Run /model to open the model selection menu, or /model [modelName] to set the model.', {
281 display: 'system'
282 });
283 return;
284 }
285 if (args) {
286 logEvent('tengu_model_command_inline', {
287 args: args as AnalyticsMetadata_I_VERIFIED_THIS_IS_NOT_CODE_OR_FILEPATHS
288 });
289 return <SetModelAndClose args={args} onDone={onDone} />;
290 }
291 return <ModelPickerWrapper onDone={onDone} />;
292};
293function renderModelLabel(model: string | null): string {
294 const rendered = renderDefaultModelSetting(model ?? getDefaultMainLoopModelSetting());
295 return model === null ? `${rendered} (default)` : rendered;

Callers

nothing calls this directly

Calls 2

logEventFunction · 0.85
onDoneFunction · 0.50

Tested by

no test coverage detected