MCPcopy
hub / github.com/pingdotgg/t3code / createModelSelection

Function createModelSelection

packages/shared/src/model.ts:316–327  ·  view source on GitHub ↗
(
  instanceId: ProviderInstanceId,
  model: string,
  options?: ReadonlyArray<ProviderOptionSelection> | null,
)

Source from the content-addressed store, hash-verified

314}
315
316export function createModelSelection(
317 instanceId: ProviderInstanceId,
318 model: string,
319 options?: ReadonlyArray<ProviderOptionSelection> | null,
320): ModelSelection {
321 const selections = options ? cloneSelections(options) : [];
322 const base: ModelSelection = {
323 instanceId,
324 model,
325 };
326 return selections.length > 0 ? { ...base, options: selections } : base;
327}
328
329/**
330 * Returns the effort value if it is a prompt-injected value according to

Calls 1

cloneSelectionsFunction · 0.85

Tested by 1

modelSelectionFunction · 0.72