@contentful/experience-design-system-generation 2.32.1-dev-build-2277e1e.0 → 2.32.1-dev-build-d5e6302.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentful/experience-design-system-generation",
3
- "version": "2.32.1-dev-build-2277e1e.0",
3
+ "version": "2.32.1-dev-build-d5e6302.0",
4
4
  "description": "Agent-invocation and skill-prompt engine for the Contentful Experience Design System SDK",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -111,7 +111,7 @@ export declare function agentSupportsBedrock(agent: AgentName): boolean;
111
111
  * agents whose model id changes shape under Bedrock (codex, opencode) — an
112
112
  * explicit value or env override is never rewritten.
113
113
  */
114
- export declare function resolveAgentModel(agent: AgentName, explicit?: string, bedrock?: boolean): string;
114
+ export declare function resolveAgentModel(agent: AgentName, explicit?: string, bedrock?: boolean): string | undefined;
115
115
  export type AgentDebugEvent = (name: string, payload?: Record<string, unknown>) => void;
116
116
  export declare function buildArgs(agent: AgentName, prompt: string, model?: string, promptViaStdin?: boolean, bedrock?: boolean): string[];
117
117
  export declare function runAgent(options: {
@@ -295,18 +295,21 @@ export function agentSupportsBedrock(agent) {
295
295
  return BEDROCK_CAPABLE_AGENTS.has(agent);
296
296
  }
297
297
  const DEFAULT_CODEX_BEDROCK_REGION = 'us-east-1';
298
+ const DEFAULT_OPENCODE_MODEL = 'claude-haiku-4-5';
298
299
  /**
299
300
  * Default models per agent — lightweight/fast picks to control cost when no
300
301
  * explicit model is configured. cursor uses `gpt-mini` (verified alias from
301
- * GetUsableModels; haiku is not available in cursor's model catalog). codex's
302
- * default differs on Bedrock: the model id there carries an `openai.` prefix,
303
- * required by the Bedrock provider and absent from the direct api.openai.com
304
- * id.
302
+ * GetUsableModels; haiku is not available in cursor's model catalog).
303
+ *
304
+ * codex is deliberately absent: with no entry here it gets no `--model` at
305
+ * all, so the installed Codex CLI picks whatever its account supports. On
306
+ * Bedrock it still needs an explicit id, since the model id there carries an
307
+ * `openai.` prefix required by the Bedrock provider and absent from the
308
+ * direct api.openai.com id — see DEFAULT_CODEX_BEDROCK_MODEL.
305
309
  */
306
310
  const DEFAULT_MODELS = {
307
311
  claude: 'haiku',
308
- codex: 'gpt-5.6-luna', // requires OPENAI_API_KEY; ChatGPT account users must pass --model
309
- opencode: 'claude-haiku-4-5',
312
+ opencode: DEFAULT_OPENCODE_MODEL,
310
313
  cursor: 'gpt-mini', // cursor alias for gpt-5.4-mini-medium; haiku not in cursor's catalog
311
314
  copilot: 'Auto', // the only model guaranteed on every Copilot plan (Free/Pro/Business/Enterprise); Pro+ users override via EDS_AGENT_MODEL_COPILOT
312
315
  };
@@ -328,7 +331,7 @@ export function resolveAgentModel(agent, explicit, bedrock = false) {
328
331
  if (bedrock && agent === 'codex')
329
332
  return DEFAULT_CODEX_BEDROCK_MODEL;
330
333
  if (bedrock && agent === 'opencode')
331
- return withBedrockProviderPrefix(DEFAULT_MODELS.opencode);
334
+ return withBedrockProviderPrefix(DEFAULT_OPENCODE_MODEL);
332
335
  return DEFAULT_MODELS[agent];
333
336
  }
334
337
  /**
@@ -353,7 +356,10 @@ function codexBedrockConfigArgs() {
353
356
  return ['-c', 'model_provider=amazon-bedrock', '-c', `model_providers.amazon-bedrock.region=${region}`];
354
357
  }
355
358
  export function buildArgs(agent, prompt, model, promptViaStdin = false, bedrock = false) {
356
- const modelArg = ['--model', resolveAgentModel(agent, model, bedrock)];
359
+ // codex with no configured model resolves to undefined — omit --model
360
+ // entirely so the CLI picks its own account-compatible default.
361
+ const resolvedModel = resolveAgentModel(agent, model, bedrock);
362
+ const modelArg = resolvedModel ? ['--model', resolvedModel] : [];
357
363
  // When the prompt is delivered on stdin, omit it from argv — a large prompt
358
364
  // as a command-line argument overflows ARG_MAX (spawn E2BIG). All four CLIs
359
365
  // read the prompt from stdin when it isn't passed positionally.
@@ -387,7 +393,7 @@ export function buildArgs(agent, prompt, model, promptViaStdin = false, bedrock
387
393
  // value, so promptViaStdin will fail here — callers must pass the
388
394
  // prompt inline for copilot.
389
395
  const copilotModel = resolveAgentModel('copilot', model);
390
- const copilotModelArg = copilotModel === 'Auto' ? [] : ['--model', copilotModel];
396
+ const copilotModelArg = !copilotModel || copilotModel === 'Auto' ? [] : ['--model', copilotModel];
391
397
  return ['-p', ...promptArg, ...copilotModelArg, '--allow-all-tools'];
392
398
  }
393
399
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentful/experience-design-system-generation",
3
- "version": "2.32.1-dev-build-2277e1e.0",
3
+ "version": "2.32.1-dev-build-d5e6302.0",
4
4
  "description": "Agent-invocation and skill-prompt engine for the Contentful Experience Design System SDK",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -22,7 +22,7 @@
22
22
  "skills/"
23
23
  ],
24
24
  "dependencies": {
25
- "@contentful/experience-design-system-types": "2.32.1-dev-build-2277e1e.0"
25
+ "@contentful/experience-design-system-types": "2.32.1-dev-build-d5e6302.0"
26
26
  },
27
27
  "devDependencies": {
28
28
  "@tsconfig/node24": "^24.0.4",