MCPcopy Create free account
hub / github.com/agenticsorg/edge-agents / getModelConfig

Function getModelConfig

scripts/agentic-mcp/src/utils/model-config.ts:13–31  ·  view source on GitHub ↗
(baseConfig: {
  model: string;
  messages: any[];
  temperature?: number;
  max_tokens?: number;
  web_search_options?: any;
  [key: string]: any; // Allow for other parameters
})

Source from the content-addressed store, hash-verified

11 * @returns A model-specific configuration with appropriate parameters
12 */
13export function getModelConfig(baseConfig: {
14 model: string;
15 messages: any[];
16 temperature?: number;
17 max_tokens?: number;
18 web_search_options?: any;
19 [key: string]: any; // Allow for other parameters
20}) {
21 const config = { ...baseConfig };
22
23 // Models that don't support temperature
24 const noTempModels = ['o3-mini', 'gpt-4o-search-preview'];
25
26 if (noTempModels.includes(config.model)) {
27 delete config.temperature;
28 }
29
30 return config;
31}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected