mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-03-16 21:53:07 +00:00
Merge remote-tracking branch 'upstream/v0.15.0rc' into refactor/auto-mode-service-gsxdsm
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
* IMPORTANT: All Codex models use 'codex-' prefix to distinguish from Cursor CLI models
|
||||
*/
|
||||
export type CodexModelId =
|
||||
| 'codex-gpt-5.3-codex'
|
||||
| 'codex-gpt-5.2-codex'
|
||||
| 'codex-gpt-5.1-codex-max'
|
||||
| 'codex-gpt-5.1-codex-mini'
|
||||
@@ -29,31 +30,38 @@ export interface CodexModelConfig {
|
||||
* All keys use 'codex-' prefix to distinguish from Cursor CLI models
|
||||
*/
|
||||
export const CODEX_MODEL_CONFIG_MAP: Record<CodexModelId, CodexModelConfig> = {
|
||||
'codex-gpt-5.3-codex': {
|
||||
id: 'codex-gpt-5.3-codex',
|
||||
label: 'GPT-5.3-Codex',
|
||||
description: 'Latest frontier agentic coding model',
|
||||
hasThinking: true,
|
||||
supportsVision: true,
|
||||
},
|
||||
'codex-gpt-5.2-codex': {
|
||||
id: 'codex-gpt-5.2-codex',
|
||||
label: 'GPT-5.2-Codex',
|
||||
description: 'Most advanced agentic coding model for complex software engineering',
|
||||
description: 'Frontier agentic coding model',
|
||||
hasThinking: true,
|
||||
supportsVision: true,
|
||||
},
|
||||
'codex-gpt-5.1-codex-max': {
|
||||
id: 'codex-gpt-5.1-codex-max',
|
||||
label: 'GPT-5.1-Codex-Max',
|
||||
description: 'Optimized for long-horizon, agentic coding tasks in Codex',
|
||||
description: 'Codex-optimized flagship for deep and fast reasoning',
|
||||
hasThinking: true,
|
||||
supportsVision: true,
|
||||
},
|
||||
'codex-gpt-5.1-codex-mini': {
|
||||
id: 'codex-gpt-5.1-codex-mini',
|
||||
label: 'GPT-5.1-Codex-Mini',
|
||||
description: 'Smaller, more cost-effective version for faster workflows',
|
||||
description: 'Optimized for codex. Cheaper, faster, but less capable',
|
||||
hasThinking: false,
|
||||
supportsVision: true,
|
||||
},
|
||||
'codex-gpt-5.2': {
|
||||
id: 'codex-gpt-5.2',
|
||||
label: 'GPT-5.2 (Codex)',
|
||||
description: 'Best general agentic model for tasks across industries and domains via Codex',
|
||||
description: 'Latest frontier model with improvements across knowledge, reasoning and coding',
|
||||
hasThinking: true,
|
||||
supportsVision: true,
|
||||
},
|
||||
|
||||
@@ -46,6 +46,7 @@ export type EventType =
|
||||
| 'dev-server:started'
|
||||
| 'dev-server:output'
|
||||
| 'dev-server:stopped'
|
||||
| 'dev-server:url-detected'
|
||||
| 'test-runner:started'
|
||||
| 'test-runner:progress'
|
||||
| 'test-runner:output'
|
||||
|
||||
@@ -196,6 +196,8 @@ export {
|
||||
PROJECT_SETTINGS_VERSION,
|
||||
THINKING_TOKEN_BUDGET,
|
||||
getThinkingTokenBudget,
|
||||
isAdaptiveThinkingModel,
|
||||
getThinkingLevelsForModel,
|
||||
// Event hook constants
|
||||
EVENT_HOOK_TRIGGER_LABELS,
|
||||
// Claude-compatible provider templates (new)
|
||||
|
||||
@@ -72,10 +72,18 @@ export const CLAUDE_MODELS: ModelOption[] = [
|
||||
* Official models from https://developers.openai.com/codex/models/
|
||||
*/
|
||||
export const CODEX_MODELS: (ModelOption & { hasReasoning?: boolean })[] = [
|
||||
{
|
||||
id: CODEX_MODEL_MAP.gpt53Codex,
|
||||
label: 'GPT-5.3-Codex',
|
||||
description: 'Latest frontier agentic coding model.',
|
||||
badge: 'Premium',
|
||||
provider: 'codex',
|
||||
hasReasoning: true,
|
||||
},
|
||||
{
|
||||
id: CODEX_MODEL_MAP.gpt52Codex,
|
||||
label: 'GPT-5.2-Codex',
|
||||
description: 'Most advanced agentic coding model for complex software engineering.',
|
||||
description: 'Frontier agentic coding model.',
|
||||
badge: 'Premium',
|
||||
provider: 'codex',
|
||||
hasReasoning: true,
|
||||
@@ -83,7 +91,7 @@ export const CODEX_MODELS: (ModelOption & { hasReasoning?: boolean })[] = [
|
||||
{
|
||||
id: CODEX_MODEL_MAP.gpt51CodexMax,
|
||||
label: 'GPT-5.1-Codex-Max',
|
||||
description: 'Optimized for long-horizon, agentic coding tasks in Codex.',
|
||||
description: 'Codex-optimized flagship for deep and fast reasoning.',
|
||||
badge: 'Premium',
|
||||
provider: 'codex',
|
||||
hasReasoning: true,
|
||||
@@ -91,7 +99,7 @@ export const CODEX_MODELS: (ModelOption & { hasReasoning?: boolean })[] = [
|
||||
{
|
||||
id: CODEX_MODEL_MAP.gpt51CodexMini,
|
||||
label: 'GPT-5.1-Codex-Mini',
|
||||
description: 'Smaller, more cost-effective version for faster workflows.',
|
||||
description: 'Optimized for codex. Cheaper, faster, but less capable.',
|
||||
badge: 'Speed',
|
||||
provider: 'codex',
|
||||
hasReasoning: false,
|
||||
@@ -99,7 +107,7 @@ export const CODEX_MODELS: (ModelOption & { hasReasoning?: boolean })[] = [
|
||||
{
|
||||
id: CODEX_MODEL_MAP.gpt52,
|
||||
label: 'GPT-5.2',
|
||||
description: 'Best general agentic model for tasks across industries and domains.',
|
||||
description: 'Latest frontier model with improvements across knowledge, reasoning and coding.',
|
||||
badge: 'Balanced',
|
||||
provider: 'codex',
|
||||
hasReasoning: true,
|
||||
@@ -141,6 +149,7 @@ export const THINKING_LEVELS: ThinkingLevelOption[] = [
|
||||
{ id: 'medium', label: 'Medium' },
|
||||
{ id: 'high', label: 'High' },
|
||||
{ id: 'ultrathink', label: 'Ultrathink' },
|
||||
{ id: 'adaptive', label: 'Adaptive' },
|
||||
];
|
||||
|
||||
/**
|
||||
@@ -154,6 +163,7 @@ export const THINKING_LEVEL_LABELS: Record<ThinkingLevel, string> = {
|
||||
medium: 'Med',
|
||||
high: 'High',
|
||||
ultrathink: 'Ultra',
|
||||
adaptive: 'Adaptive',
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -211,6 +221,7 @@ export function getModelDisplayName(model: ModelAlias | string): string {
|
||||
haiku: 'Claude Haiku',
|
||||
sonnet: 'Claude Sonnet',
|
||||
opus: 'Claude Opus',
|
||||
[CODEX_MODEL_MAP.gpt53Codex]: 'GPT-5.3-Codex',
|
||||
[CODEX_MODEL_MAP.gpt52Codex]: 'GPT-5.2-Codex',
|
||||
[CODEX_MODEL_MAP.gpt51CodexMax]: 'GPT-5.1-Codex-Max',
|
||||
[CODEX_MODEL_MAP.gpt51CodexMini]: 'GPT-5.1-Codex-Mini',
|
||||
|
||||
@@ -18,7 +18,7 @@ export type ClaudeCanonicalId = 'claude-haiku' | 'claude-sonnet' | 'claude-opus'
|
||||
export const CLAUDE_CANONICAL_MAP: Record<ClaudeCanonicalId, string> = {
|
||||
'claude-haiku': 'claude-haiku-4-5-20251001',
|
||||
'claude-sonnet': 'claude-sonnet-4-5-20250929',
|
||||
'claude-opus': 'claude-opus-4-5-20251101',
|
||||
'claude-opus': 'claude-opus-4-6',
|
||||
} as const;
|
||||
|
||||
/**
|
||||
@@ -29,7 +29,7 @@ export const CLAUDE_CANONICAL_MAP: Record<ClaudeCanonicalId, string> = {
|
||||
export const CLAUDE_MODEL_MAP: Record<string, string> = {
|
||||
haiku: 'claude-haiku-4-5-20251001',
|
||||
sonnet: 'claude-sonnet-4-5-20250929',
|
||||
opus: 'claude-opus-4-5-20251101',
|
||||
opus: 'claude-opus-4-6',
|
||||
} as const;
|
||||
|
||||
/**
|
||||
@@ -50,15 +50,17 @@ export const LEGACY_CLAUDE_ALIAS_MAP: Record<string, ClaudeCanonicalId> = {
|
||||
*/
|
||||
export const CODEX_MODEL_MAP = {
|
||||
// Recommended Codex-specific models
|
||||
/** Most advanced agentic coding model for complex software engineering (default for ChatGPT users) */
|
||||
/** Latest frontier agentic coding model */
|
||||
gpt53Codex: 'codex-gpt-5.3-codex',
|
||||
/** Frontier agentic coding model */
|
||||
gpt52Codex: 'codex-gpt-5.2-codex',
|
||||
/** Optimized for long-horizon, agentic coding tasks in Codex */
|
||||
/** Codex-optimized flagship for deep and fast reasoning */
|
||||
gpt51CodexMax: 'codex-gpt-5.1-codex-max',
|
||||
/** Smaller, more cost-effective version for faster workflows */
|
||||
/** Optimized for codex. Cheaper, faster, but less capable */
|
||||
gpt51CodexMini: 'codex-gpt-5.1-codex-mini',
|
||||
|
||||
// General-purpose GPT models (also available in Codex)
|
||||
/** Best general agentic model for tasks across industries and domains */
|
||||
/** Latest frontier model with improvements across knowledge, reasoning and coding */
|
||||
gpt52: 'codex-gpt-5.2',
|
||||
/** Great for coding and agentic tasks across domains */
|
||||
gpt51: 'codex-gpt-5.1',
|
||||
@@ -71,6 +73,7 @@ export const CODEX_MODEL_IDS = Object.values(CODEX_MODEL_MAP);
|
||||
* These models can use reasoning.effort parameter
|
||||
*/
|
||||
export const REASONING_CAPABLE_MODELS = new Set([
|
||||
CODEX_MODEL_MAP.gpt53Codex,
|
||||
CODEX_MODEL_MAP.gpt52Codex,
|
||||
CODEX_MODEL_MAP.gpt51CodexMax,
|
||||
CODEX_MODEL_MAP.gpt52,
|
||||
@@ -96,9 +99,9 @@ export function getAllCodexModelIds(): CodexModelId[] {
|
||||
* Uses canonical prefixed IDs for consistent routing.
|
||||
*/
|
||||
export const DEFAULT_MODELS = {
|
||||
claude: 'claude-opus-4-5-20251101',
|
||||
claude: 'claude-opus-4-6',
|
||||
cursor: 'cursor-auto', // Cursor's recommended default (with prefix)
|
||||
codex: CODEX_MODEL_MAP.gpt52Codex, // GPT-5.2-Codex is the most advanced agentic coding model
|
||||
codex: CODEX_MODEL_MAP.gpt53Codex, // GPT-5.3-Codex is the latest frontier agentic coding model
|
||||
} as const;
|
||||
|
||||
export type ModelAlias = keyof typeof CLAUDE_MODEL_MAP;
|
||||
|
||||
@@ -213,7 +213,7 @@ export type PlanningMode = 'skip' | 'lite' | 'spec' | 'full';
|
||||
export type ServerLogLevel = 'error' | 'warn' | 'info' | 'debug';
|
||||
|
||||
/** ThinkingLevel - Extended thinking levels for Claude models (reasoning intensity) */
|
||||
export type ThinkingLevel = 'none' | 'low' | 'medium' | 'high' | 'ultrathink';
|
||||
export type ThinkingLevel = 'none' | 'low' | 'medium' | 'high' | 'ultrathink' | 'adaptive';
|
||||
|
||||
/**
|
||||
* SidebarStyle - Sidebar layout style options
|
||||
@@ -237,6 +237,7 @@ export const THINKING_TOKEN_BUDGET: Record<ThinkingLevel, number | undefined> =
|
||||
medium: 10000, // Light reasoning
|
||||
high: 16000, // Complex tasks (recommended starting point)
|
||||
ultrathink: 32000, // Maximum safe (above this risks timeouts)
|
||||
adaptive: undefined, // Adaptive thinking (Opus 4.6) - SDK handles token allocation
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -247,6 +248,26 @@ export function getThinkingTokenBudget(level: ThinkingLevel | undefined): number
|
||||
return THINKING_TOKEN_BUDGET[level];
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a model uses adaptive thinking (Opus 4.6+)
|
||||
* Adaptive thinking models let the SDK decide token allocation automatically.
|
||||
*/
|
||||
export function isAdaptiveThinkingModel(model: string): boolean {
|
||||
return model.includes('opus-4-6') || model === 'claude-opus';
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the available thinking levels for a given model.
|
||||
* - Opus 4.6: Only 'none' and 'adaptive' (SDK handles token allocation)
|
||||
* - Others: Full range of manual thinking levels
|
||||
*/
|
||||
export function getThinkingLevelsForModel(model: string): ThinkingLevel[] {
|
||||
if (isAdaptiveThinkingModel(model)) {
|
||||
return ['none', 'adaptive'];
|
||||
}
|
||||
return ['none', 'low', 'medium', 'high', 'ultrathink'];
|
||||
}
|
||||
|
||||
/** ModelProvider - AI model provider for credentials and API key management */
|
||||
export type ModelProvider = 'claude' | 'cursor' | 'codex' | 'opencode' | 'gemini' | 'copilot';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user